@epilot/entity-client 4.24.0 → 4.25.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4693,6 +4693,87 @@
4693
4693
  },
4694
4694
  "additionalProperties": true
4695
4695
  },
4696
+ "HydratedEntity": {
4697
+ "type": "object",
4698
+ "description": "Entity with relation data resolved into the attribute values",
4699
+ "properties": {
4700
+ "_relations": {
4701
+ "type": "array",
4702
+ "items": {
4703
+ "type": "object",
4704
+ "properties": {
4705
+ "entity_id": {
4706
+ "$ref": "#/components/schemas/EntityId"
4707
+ }
4708
+ },
4709
+ "required": [
4710
+ "entity_id"
4711
+ ]
4712
+ }
4713
+ }
4714
+ },
4715
+ "additionalProperties": true,
4716
+ "required": [
4717
+ "_relations"
4718
+ ],
4719
+ "example": {
4720
+ "_relations": [
4721
+ {
4722
+ "entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
4723
+ }
4724
+ ],
4725
+ "status": "active",
4726
+ "customer_number": "abc123",
4727
+ "email": [
4728
+ {
4729
+ "label": "work",
4730
+ "email": "user@example.com"
4731
+ }
4732
+ ],
4733
+ "phone": [
4734
+ {
4735
+ "label": "work",
4736
+ "phone": "+49123456789"
4737
+ }
4738
+ ],
4739
+ "first_name": "First Name",
4740
+ "middle_name": "Middle Name",
4741
+ "last_name": "Last Name",
4742
+ "date_of_birth": "2019-08-24",
4743
+ "title": "Mr.",
4744
+ "account": [
4745
+ {
4746
+ "status": "active",
4747
+ "name": "Company name",
4748
+ "company_email": [
4749
+ {
4750
+ "label": "Company email",
4751
+ "email": "company@example.com"
4752
+ }
4753
+ ],
4754
+ "company_phone": [
4755
+ {
4756
+ "label": "Support phone",
4757
+ "phone": "+49123456789"
4758
+ }
4759
+ ],
4760
+ "company_website": "https://example.com",
4761
+ "tax_id": "DE123456789",
4762
+ "tax_exemption": "2019-08-24",
4763
+ "contacts": {
4764
+ "$relation": [
4765
+ {
4766
+ "_tags": [
4767
+ "CEO"
4768
+ ],
4769
+ "entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
4770
+ }
4771
+ ]
4772
+ }
4773
+ }
4774
+ ]
4775
+ }
4776
+ },
4696
4777
  "EntityItem": {
4697
4778
  "allOf": [
4698
4779
  {
@@ -4874,6 +4955,10 @@
4874
4955
  "type": "string",
4875
4956
  "example": "_schema:contact AND status:active"
4876
4957
  },
4958
+ "filter": {
4959
+ "description": "Filter queries supported with ElasticSearch",
4960
+ "type": "array"
4961
+ },
4877
4962
  "sort": {
4878
4963
  "type": "string",
4879
4964
  "example": "_created_at:desc"
@@ -6384,9 +6469,6 @@
6384
6469
  }
6385
6470
  },
6386
6471
  "servers": [
6387
- {
6388
- "url": "https://entity.sls.epilot.io"
6389
- },
6390
6472
  {
6391
6473
  "url": "https://entity.sls.epilot.io"
6392
6474
  }
@@ -0,0 +1,11 @@
1
+ import { Components } from './openapi';
2
+ export declare enum RelationAffinityMode {
3
+ /**
4
+ * For strong affinity mode on a relation attribute, deleting or creating the parent or the relation linkage will trigger a CASCADE delete or create to the relation entity itself.
5
+ * For weak affinity mode on a relation attribute, deleting or creating the parent or the relation linkage will NOT trigger a CASCADE delete or create to the relation entity itself.
6
+ */
7
+ WEAK = "weak",
8
+ STRONG = "strong"
9
+ }
10
+ export type Attribute = Components.Schemas.Attribute;
11
+ export type AttributeType = Attribute['type'];
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.RelationAffinityMode = void 0;
4
+ var RelationAffinityMode;
5
+ (function (RelationAffinityMode) {
6
+ /**
7
+ * For strong affinity mode on a relation attribute, deleting or creating the parent or the relation linkage will trigger a CASCADE delete or create to the relation entity itself.
8
+ * For weak affinity mode on a relation attribute, deleting or creating the parent or the relation linkage will NOT trigger a CASCADE delete or create to the relation entity itself.
9
+ */
10
+ RelationAffinityMode["WEAK"] = "weak";
11
+ RelationAffinityMode["STRONG"] = "strong";
12
+ })(RelationAffinityMode = exports.RelationAffinityMode || (exports.RelationAffinityMode = {}));
13
+ //# sourceMappingURL=schema-model.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epilot/entity-client",
3
- "version": "4.24.0",
3
+ "version": "4.25.0-alpha.0",
4
4
  "description": "JavaScript client library for the epilot Core Entity API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,8GAAqE;AACrE,8EAAsD;AAEtD,4DAAsC;AAGtC,IAAI,MAAc,CAAC;AACZ,IAAM,SAAS,GAAG;IACvB,IAAI,CAAC,MAAM,EAAE;QACX,MAAM,GAAG,IAAA,oBAAY,GAAE,CAAC;KACzB;IAED,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC;AANW,QAAA,SAAS,aAMpB;AAEK,IAAM,YAAY,GAAG;;IAC1B,IAAM,GAAG,GAAG,IAAI,8BAAkB,CAAC,EAAE,UAAU,sBAAA,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;IAChE,IAAM,SAAS,GAAG,GAAG,CAAC,QAAQ,EAAU,CAAC;IAEzC,SAAS,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,yBAC5B,CAAC,MAAA,SAAS,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,mCAAI,EAAE,CAAC,GACzC,CAAC,2CAAc,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAChC,CAAC;IAEF,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC;AAVW,QAAA,YAAY,gBAUvB"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"definition.js","sourceRoot":"","sources":["../src/definition.ts"],"names":[],"mappings":";;;;;AAEA,gFAAgD;AAEhD,kBAAgB,8BAAkC,CAAC"}
package/dist/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,iDAA+B"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"schema-model.js","sourceRoot":"","sources":["../src/schema-model.ts"],"names":[],"mappings":";;;AAEA,IAAY,oBAOX;AAPD,WAAY,oBAAoB;IAC9B;;;OAGG;IACH,qCAAa,CAAA;IACb,yCAAiB,CAAA;AACnB,CAAC,EAPW,oBAAoB,GAApB,4BAAoB,KAApB,4BAAoB,QAO/B"}
package/jest.config.ts DELETED
@@ -1,16 +0,0 @@
1
- import type { Config } from '@jest/types';
2
-
3
- const config: Config.InitialOptions = {
4
- preset: 'ts-jest',
5
- testEnvironment: 'node',
6
- testMatch: ['**/?(*.)+(spec|test).ts?(x)'],
7
- testPathIgnorePatterns: ['node_modules'],
8
- coveragePathIgnorePatterns: ['__tests__', 'node_modules'],
9
- verbose: true,
10
- silent: true,
11
- moduleNameMapper: {
12
- '^axios$': require.resolve('axios'),
13
- },
14
- };
15
-
16
- export default config;