@epilot/erp-integration-client 0.14.0 → 0.15.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.
package/dist/openapi.d.ts CHANGED
@@ -197,25 +197,6 @@ declare namespace Components {
197
197
  */
198
198
  message?: string;
199
199
  }
200
- /**
201
- * Extended unique identifier field configuration with type hints for repeatable fields
202
- */
203
- export interface ExtendedUniqueIdField {
204
- /**
205
- * The attribute name to use as unique identifier
206
- */
207
- attribute: string;
208
- _type?: /**
209
- * Type hint for repeatable fields that require special search handling.
210
- * These fields are stored as arrays of objects (e.g., email: [{ email: "value" }]).
211
- *
212
- */
213
- RepeatableFieldType;
214
- /**
215
- * Which array item to use (0-indexed, default first)
216
- */
217
- index?: number;
218
- }
219
200
  /**
220
201
  * Configuration for inbound use cases (ERP to epilot)
221
202
  */
@@ -381,12 +362,6 @@ declare namespace Components {
381
362
  * Constant value to assign (any type)
382
363
  */
383
364
  constant?: any;
384
- /**
385
- * Type hint for repeatable fields (email, phone).
386
- * When this attribute is used as a unique identifier, specifying the _type
387
- * enables correct search path generation (e.g., email.email.keyword).
388
- *
389
- */
390
365
  _type?: /**
391
366
  * Type hint for repeatable fields that require special search handling.
392
367
  * These fields are stored as arrays of objects (e.g., email: [{ email: "value" }]).
@@ -429,6 +404,14 @@ declare namespace Components {
429
404
  * JSONata expression to extract meter reading items from the event data
430
405
  */
431
406
  jsonataExpression: string;
407
+ /**
408
+ * Strategy for matching incoming readings against existing readings.
409
+ * - 'external_id': Match readings by external_id attribute (default behavior)
410
+ * - 'strict-date': Match by meter_id + counter_id + direction + date (German timezone).
411
+ * Useful when readings originate from ECP and are echoed back by the ERP with truncated timestamps.
412
+ *
413
+ */
414
+ reading_matching?: "external_id" | "strict-date";
432
415
  meter: MeterUniqueIdsConfig;
433
416
  meter_counter?: MeterUniqueIdsConfig;
434
417
  /**
@@ -930,34 +913,6 @@ declare namespace Components {
930
913
  end_date?: string;
931
914
  event_id?: string;
932
915
  }
933
- /**
934
- * Unique identifier field configuration. Can be either:
935
- * - A simple string (attribute name)
936
- * - An extended object with type hints for repeatable fields
937
- *
938
- */
939
- export type UniqueIdField = /**
940
- * Unique identifier field configuration. Can be either:
941
- * - A simple string (attribute name)
942
- * - An extended object with type hints for repeatable fields
943
- *
944
- */
945
- string | /* Extended unique identifier field configuration with type hints for repeatable fields */ ExtendedUniqueIdField;
946
- /**
947
- * Metadata about a unique identifier field (used in message payloads)
948
- */
949
- export interface UniqueIdMetadata {
950
- fieldType?: /**
951
- * Type hint for repeatable fields that require special search handling.
952
- * These fields are stored as arrays of objects (e.g., email: [{ email: "value" }]).
953
- *
954
- */
955
- RepeatableFieldType;
956
- /**
957
- * Which array item was used (0-indexed)
958
- */
959
- index?: number;
960
- }
961
916
  export interface UpdateInboundUseCaseRequest {
962
917
  /**
963
918
  * Use case name
@@ -1961,7 +1916,6 @@ export type EntityUpdate = Components.Schemas.EntityUpdate;
1961
1916
  export type ErpEvent = Components.Schemas.ErpEvent;
1962
1917
  export type ErpUpdatesEventsV2Request = Components.Schemas.ErpUpdatesEventsV2Request;
1963
1918
  export type ErrorResponseBase = Components.Schemas.ErrorResponseBase;
1964
- export type ExtendedUniqueIdField = Components.Schemas.ExtendedUniqueIdField;
1965
1919
  export type InboundIntegrationEventConfiguration = Components.Schemas.InboundIntegrationEventConfiguration;
1966
1920
  export type InboundUseCase = Components.Schemas.InboundUseCase;
1967
1921
  export type InboundUseCaseHistoryEntry = Components.Schemas.InboundUseCaseHistoryEntry;
@@ -1994,8 +1948,6 @@ export type ReplayEventsRequest = Components.Schemas.ReplayEventsRequest;
1994
1948
  export type SetIntegrationAppMappingRequest = Components.Schemas.SetIntegrationAppMappingRequest;
1995
1949
  export type TriggerErpActionRequest = Components.Schemas.TriggerErpActionRequest;
1996
1950
  export type TriggerWebhookResp = Components.Schemas.TriggerWebhookResp;
1997
- export type UniqueIdField = Components.Schemas.UniqueIdField;
1998
- export type UniqueIdMetadata = Components.Schemas.UniqueIdMetadata;
1999
1951
  export type UpdateInboundUseCaseRequest = Components.Schemas.UpdateInboundUseCaseRequest;
2000
1952
  export type UpdateIntegrationRequest = Components.Schemas.UpdateIntegrationRequest;
2001
1953
  export type UpdateOutboundUseCaseRequest = Components.Schemas.UpdateOutboundUseCaseRequest;
package/dist/openapi.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "openapi": "3.0.3",
3
3
  "info": {
4
4
  "title": "ERP Integration API",
5
- "version": "0.17.0",
5
+ "version": "0.17.2",
6
6
  "description": "API for integrating with ERP systems, handling tracking acknowledgments, triggering ERP processes, and processing ERP updates."
7
7
  },
8
8
  "tags": [
@@ -2786,6 +2786,15 @@
2786
2786
  "type": "string",
2787
2787
  "description": "JSONata expression to extract meter reading items from the event data"
2788
2788
  },
2789
+ "reading_matching": {
2790
+ "type": "string",
2791
+ "enum": [
2792
+ "external_id",
2793
+ "strict-date"
2794
+ ],
2795
+ "default": "external_id",
2796
+ "description": "Strategy for matching incoming readings against existing readings.\n- 'external_id': Match readings by external_id attribute (default behavior)\n- 'strict-date': Match by meter_id + counter_id + direction + date (German timezone).\n Useful when readings originate from ECP and are echoed back by the ERP with truncated timestamps.\n"
2797
+ },
2789
2798
  "meter": {
2790
2799
  "$ref": "#/components/schemas/MeterUniqueIdsConfig"
2791
2800
  },
@@ -2839,8 +2848,7 @@
2839
2848
  "description": "Constant value to assign (any type)"
2840
2849
  },
2841
2850
  "_type": {
2842
- "$ref": "#/components/schemas/RepeatableFieldType",
2843
- "description": "Type hint for repeatable fields (email, phone).\nWhen this attribute is used as a unique identifier, specifying the _type\nenables correct search path generation (e.g., email.email.keyword).\n"
2851
+ "$ref": "#/components/schemas/RepeatableFieldType"
2844
2852
  },
2845
2853
  "enabled": {
2846
2854
  "oneOf": [
@@ -3042,54 +3050,6 @@
3042
3050
  ],
3043
3051
  "description": "Type hint for repeatable fields that require special search handling.\nThese fields are stored as arrays of objects (e.g., email: [{ email: \"value\" }]).\n"
3044
3052
  },
3045
- "ExtendedUniqueIdField": {
3046
- "type": "object",
3047
- "description": "Extended unique identifier field configuration with type hints for repeatable fields",
3048
- "required": [
3049
- "attribute"
3050
- ],
3051
- "properties": {
3052
- "attribute": {
3053
- "type": "string",
3054
- "description": "The attribute name to use as unique identifier"
3055
- },
3056
- "_type": {
3057
- "$ref": "#/components/schemas/RepeatableFieldType"
3058
- },
3059
- "index": {
3060
- "type": "integer",
3061
- "default": 0,
3062
- "minimum": 0,
3063
- "description": "Which array item to use (0-indexed, default first)"
3064
- }
3065
- }
3066
- },
3067
- "UniqueIdField": {
3068
- "description": "Unique identifier field configuration. Can be either:\n- A simple string (attribute name)\n- An extended object with type hints for repeatable fields\n",
3069
- "oneOf": [
3070
- {
3071
- "type": "string",
3072
- "description": "Simple attribute name"
3073
- },
3074
- {
3075
- "$ref": "#/components/schemas/ExtendedUniqueIdField"
3076
- }
3077
- ]
3078
- },
3079
- "UniqueIdMetadata": {
3080
- "type": "object",
3081
- "description": "Metadata about a unique identifier field (used in message payloads)",
3082
- "properties": {
3083
- "fieldType": {
3084
- "$ref": "#/components/schemas/RepeatableFieldType"
3085
- },
3086
- "index": {
3087
- "type": "integer",
3088
- "default": 0,
3089
- "description": "Which array item was used (0-indexed)"
3090
- }
3091
- }
3092
- },
3093
3053
  "ReplayEventsRequest": {
3094
3054
  "type": "object",
3095
3055
  "required": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epilot/erp-integration-client",
3
- "version": "0.14.0",
3
+ "version": "0.15.0",
4
4
  "description": "Client library for ePilot ERP Integration API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",