@epilot/erp-integration-client 0.30.0-rc3 → 0.30.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.
@@ -1 +1 @@
1
- (()=>{"use strict";var e={330(e,t,n){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(466));t.default=o.default},466(e){e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"","version":""},"servers":[{"url":"https://erp-integration-api.sls.epilot.io"}],"paths":{"/v1/erp/tracking/acknowledgement":{"post":{"operationId":"acknowledgeTracking","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/erp/trigger":{"post":{"operationId":"triggerErp","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/erp/updates/events":{"post":{"deprecated":true,"operationId":"processErpUpdatesEvents","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v2/erp/updates/events":{"post":{"deprecated":true,"operationId":"processErpUpdatesEventsV2","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v3/erp/updates/events":{"post":{"operationId":"processErpUpdatesEventsV3","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v2/erp/updates/mapping_simulation":{"post":{"operationId":"simulateMappingV2","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/erp/updates/mapping_simulation":{"post":{"operationId":"simulateMapping","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations":{"get":{"operationId":"listIntegrations","responses":{}},"post":{"operationId":"createIntegration","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}":{"get":{"operationId":"getIntegration","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}},"put":{"operationId":"updateIntegration","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteIntegration","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/events":{"post":{"operationId":"queryEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/events/replay":{"post":{"operationId":"replayEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/use-cases":{"get":{"operationId":"listUseCases","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}},"post":{"operationId":"createUseCase","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/use-cases/{useCaseId}":{"get":{"operationId":"getUseCase","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true}],"responses":{}},"put":{"operationId":"updateUseCase","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteUseCase","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/use-cases/{useCaseId}/history":{"get":{"operationId":"listUseCaseHistory","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true},{"name":"cursor","in":"query","required":false}],"responses":{}}},"/v2/integrations":{"get":{"operationId":"listIntegrationsV2","responses":{}},"post":{"operationId":"createIntegrationV2","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}":{"get":{"operationId":"getIntegrationV2","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}},"put":{"operationId":"updateIntegrationV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteIntegrationV2","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/app-mapping":{"put":{"operationId":"setIntegrationAppMapping","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteIntegrationAppMapping","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/inbound-events":{"post":{"operationId":"queryInboundMonitoringEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/stats":{"post":{"operationId":"getMonitoringStats","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/timeseries":{"post":{"operationId":"getMonitoringTimeSeries","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/outbound-status":{"get":{"operationId":"getOutboundStatus","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/monitoring/access-logs":{"post":{"operationId":"queryAccessLogs","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/outbound-events":{"post":{"operationId":"queryOutboundMonitoringEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/events":{"post":{"operationId":"queryMonitoringEventsV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/stats":{"post":{"operationId":"getMonitoringStatsV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/time-series":{"post":{"operationId":"getMonitoringTimeSeriesV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/events/{eventId}/associated":{"get":{"operationId":"getAssociatedMonitoringEvents","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"eventId","in":"path","required":true}],"responses":{}}},"/v1/integrations/secure-proxies":{"get":{"operationId":"listSecureProxies","responses":{}}},"/v1/secure-proxy":{"post":{"operationId":"secureProxy","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/managed-call/{slug}/execute":{"post":{"operationId":"managedCallExecute","parameters":[{"name":"slug","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}}},"components":{"responses":{"BadRequest":{"content":{"application/json":{}}},"NotFound":{"content":{"application/json":{}}},"Unauthorized":{"content":{"application/json":{}}},"Forbidden":{"content":{"application/json":{}}},"InternalServerError":{"content":{"application/json":{}}},"QueryInboundMonitoringEventsResponse":{"content":{"application/json":{}}},"GetMonitoringStatsResponse":{"content":{"application/json":{}}},"GetMonitoringTimeSeriesResponse":{"content":{"application/json":{}}},"QueryAccessLogsResponse":{"content":{"application/json":{}}},"QueryOutboundMonitoringEventsResponse":{"content":{"application/json":{}}},"ReplayEventsResponse":{"content":{"application/json":{}}},"ERPUpdatesResponse":{"content":{"application/json":{}}},"TriggerWebhookResponse":{"content":{"application/json":{}}},"QueryEventsResponse":{"content":{"application/json":{}}},"QueryMonitoringEventsV2Response":{"content":{"application/json":{}}},"GetMonitoringStatsV2Response":{"content":{"application/json":{}}},"GetMonitoringTimeSeriesV2Response":{"content":{"application/json":{}}},"GetAssociatedMonitoringEventsResponse":{"content":{"application/json":{}}}}}}')}},t={},n=function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}(330),r=exports;for(var o in n)r[o]=n[o];n.__esModule&&Object.defineProperty(r,"__esModule",{value:!0})})();
1
+ (()=>{"use strict";var e={330(e,t,n){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(466));t.default=o.default},466(e){e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"","version":""},"servers":[{"url":"https://erp-integration-api.sls.epilot.io"}],"paths":{"/v1/erp/tracking/acknowledgement":{"post":{"operationId":"acknowledgeTracking","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/erp/trigger":{"post":{"operationId":"triggerErp","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/erp/updates/events":{"post":{"deprecated":true,"operationId":"processErpUpdatesEvents","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v2/erp/updates/events":{"post":{"deprecated":true,"operationId":"processErpUpdatesEventsV2","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v3/erp/updates/events":{"post":{"operationId":"processErpUpdatesEventsV3","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v2/erp/updates/mapping_simulation":{"post":{"operationId":"simulateMappingV2","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/erp/updates/mapping_simulation":{"post":{"operationId":"simulateMapping","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations":{"get":{"operationId":"listIntegrations","responses":{}},"post":{"operationId":"createIntegration","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}":{"get":{"operationId":"getIntegration","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}},"put":{"operationId":"updateIntegration","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteIntegration","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/events":{"post":{"operationId":"queryEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/events/replay":{"post":{"operationId":"replayEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/use-cases":{"get":{"operationId":"listUseCases","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}},"post":{"operationId":"createUseCase","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/use-cases/{useCaseId}":{"get":{"operationId":"getUseCase","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true}],"responses":{}},"put":{"operationId":"updateUseCase","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteUseCase","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/use-cases/{useCaseId}/history":{"get":{"operationId":"listUseCaseHistory","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"useCaseId","in":"path","required":true},{"name":"cursor","in":"query","required":false}],"responses":{}}},"/v2/integrations":{"get":{"operationId":"listIntegrationsV2","responses":{}},"post":{"operationId":"createIntegrationV2","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}":{"get":{"operationId":"getIntegrationV2","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}},"put":{"operationId":"updateIntegrationV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteIntegrationV2","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/app-mapping":{"put":{"operationId":"setIntegrationAppMapping","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteIntegrationAppMapping","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/inbound-events":{"post":{"operationId":"queryInboundMonitoringEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/stats":{"post":{"operationId":"getMonitoringStats","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/timeseries":{"post":{"operationId":"getMonitoringTimeSeries","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/outbound-status":{"get":{"operationId":"getOutboundStatus","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/monitoring/access-logs":{"post":{"operationId":"queryAccessLogs","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/monitoring/outbound-events":{"post":{"operationId":"queryOutboundMonitoringEvents","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/events":{"post":{"operationId":"queryMonitoringEventsV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/stats":{"post":{"operationId":"getMonitoringStatsV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/time-series":{"post":{"operationId":"getMonitoringTimeSeriesV2","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v2/integrations/{integrationId}/monitoring/events/{eventId}/associated":{"get":{"operationId":"getAssociatedMonitoringEvents","parameters":[{"name":"integrationId","in":"path","required":true},{"name":"eventId","in":"path","required":true}],"responses":{}}},"/v1/integrations/secure-proxies":{"get":{"operationId":"listSecureProxies","responses":{}}},"/v1/secure-proxy":{"post":{"operationId":"secureProxy","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/managed-call/{slug}/execute":{"post":{"operationId":"managedCallExecute","parameters":[{"name":"slug","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/generate-types-preview":{"post":{"operationId":"generateTypesPreview","parameters":[{"name":"integrationId","in":"path","required":true}],"responses":{}}},"/v1/integrations/{integrationId}/generate-types":{"post":{"operationId":"generateTypes","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/integrations/{integrationId}/commit-types":{"post":{"operationId":"commitTypes","parameters":[{"name":"integrationId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}}},"components":{"responses":{"BadRequest":{"content":{"application/json":{}}},"NotFound":{"content":{"application/json":{}}},"Unauthorized":{"content":{"application/json":{}}},"Forbidden":{"content":{"application/json":{}}},"InternalServerError":{"content":{"application/json":{}}},"QueryInboundMonitoringEventsResponse":{"content":{"application/json":{}}},"GetMonitoringStatsResponse":{"content":{"application/json":{}}},"GetMonitoringTimeSeriesResponse":{"content":{"application/json":{}}},"QueryAccessLogsResponse":{"content":{"application/json":{}}},"QueryOutboundMonitoringEventsResponse":{"content":{"application/json":{}}},"ReplayEventsResponse":{"content":{"application/json":{}}},"ERPUpdatesResponse":{"content":{"application/json":{}}},"TriggerWebhookResponse":{"content":{"application/json":{}}},"QueryEventsResponse":{"content":{"application/json":{}}},"QueryMonitoringEventsV2Response":{"content":{"application/json":{}}},"GetMonitoringStatsV2Response":{"content":{"application/json":{}}},"GetMonitoringTimeSeriesV2Response":{"content":{"application/json":{}}},"GetAssociatedMonitoringEventsResponse":{"content":{"application/json":{}}}}}}')}},t={},n=function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}(330),r=exports;for(var o in n)r[o]=n[o];n.__esModule&&Object.defineProperty(r,"__esModule",{value:!0})})();
@@ -608,6 +608,57 @@
608
608
  },
609
609
  "responses": {}
610
610
  }
611
+ },
612
+ "/v1/integrations/{integrationId}/generate-types-preview": {
613
+ "post": {
614
+ "operationId": "generateTypesPreview",
615
+ "parameters": [
616
+ {
617
+ "name": "integrationId",
618
+ "in": "path",
619
+ "required": true
620
+ }
621
+ ],
622
+ "responses": {}
623
+ }
624
+ },
625
+ "/v1/integrations/{integrationId}/generate-types": {
626
+ "post": {
627
+ "operationId": "generateTypes",
628
+ "parameters": [
629
+ {
630
+ "name": "integrationId",
631
+ "in": "path",
632
+ "required": true
633
+ }
634
+ ],
635
+ "requestBody": {
636
+ "required": true,
637
+ "content": {
638
+ "application/json": {}
639
+ }
640
+ },
641
+ "responses": {}
642
+ }
643
+ },
644
+ "/v1/integrations/{integrationId}/commit-types": {
645
+ "post": {
646
+ "operationId": "commitTypes",
647
+ "parameters": [
648
+ {
649
+ "name": "integrationId",
650
+ "in": "path",
651
+ "required": true
652
+ }
653
+ ],
654
+ "requestBody": {
655
+ "required": true,
656
+ "content": {
657
+ "application/json": {}
658
+ }
659
+ },
660
+ "responses": {}
661
+ }
611
662
  }
612
663
  },
613
664
  "components": {
package/dist/openapi.d.ts CHANGED
@@ -238,6 +238,30 @@ declare namespace Components {
238
238
  */
239
239
  freshnessThresholdMinutes?: number;
240
240
  }
241
+ export interface CommitTypesRequest {
242
+ /**
243
+ * npm package name
244
+ * example:
245
+ * @epilot/hems-cleverpv
246
+ */
247
+ package_name: string;
248
+ /**
249
+ * Package version
250
+ * example:
251
+ * 1.0.0
252
+ */
253
+ version: string;
254
+ /**
255
+ * Type annotations per use case slug
256
+ */
257
+ annotations?: {
258
+ [name: string]: /* Developer-provided type annotations for a use case's request and response fields */ TypeAnnotations;
259
+ };
260
+ }
261
+ export interface CommitTypesResponse {
262
+ committed: boolean;
263
+ warnings?: string[];
264
+ }
241
265
  /**
242
266
  * Shared configuration for connector-type integrations
243
267
  */
@@ -247,6 +271,24 @@ declare namespace Components {
247
271
  */
248
272
  base_url?: string;
249
273
  auth?: /* Authentication configuration for managed call requests */ ManagedCallAuth;
274
+ /**
275
+ * History of generated type package versions
276
+ */
277
+ types_versions?: {
278
+ version: string;
279
+ package_name: string;
280
+ generated_at: string; // date-time
281
+ generated_by: string;
282
+ status: "active" | "deprecated";
283
+ }[];
284
+ /**
285
+ * Latest active types package version
286
+ */
287
+ latest_types_version?: string;
288
+ /**
289
+ * Latest active types package name
290
+ */
291
+ latest_types_package_name?: string;
250
292
  }
251
293
  export interface CreateFileProxyUseCaseRequest {
252
294
  /**
@@ -1149,6 +1191,69 @@ declare namespace Components {
1149
1191
  */
1150
1192
  FileProxyUseCaseConfiguration;
1151
1193
  }
1194
+ export interface GenerateTypesPreviewResponse {
1195
+ integration_name?: string;
1196
+ use_cases: /* Scaffolded type descriptors for a single use case */ UseCaseTypePreview[];
1197
+ /**
1198
+ * Previously generated version, if any
1199
+ */
1200
+ previous_version?: string;
1201
+ /**
1202
+ * Suggested next version based on detected changes
1203
+ */
1204
+ suggested_version?: string;
1205
+ suggested_bump?: "major" | "minor";
1206
+ detected_changes?: {
1207
+ slug: string;
1208
+ field: string;
1209
+ type: "breaking" | "non-breaking";
1210
+ description: string;
1211
+ }[];
1212
+ }
1213
+ export interface GenerateTypesRequest {
1214
+ /**
1215
+ * npm package name
1216
+ * example:
1217
+ * @epilot/hems-cleverpv
1218
+ */
1219
+ package_name: string;
1220
+ /**
1221
+ * Package version
1222
+ * example:
1223
+ * 1.0.0
1224
+ */
1225
+ version: string;
1226
+ description?: string;
1227
+ /**
1228
+ * Domain standard package to extend
1229
+ * example:
1230
+ * @epilot/hems
1231
+ */
1232
+ domain_package?: string;
1233
+ /**
1234
+ * Name of the domain UseCaseMap to extend
1235
+ * example:
1236
+ * HemsUseCaseMap
1237
+ */
1238
+ domain_map_name?: string;
1239
+ /**
1240
+ * Type annotations per use case slug
1241
+ */
1242
+ annotations?: {
1243
+ [name: string]: /* Developer-provided type annotations for a use case's request and response fields */ TypeAnnotations;
1244
+ };
1245
+ }
1246
+ export interface GenerateTypesResponse {
1247
+ package_name: string;
1248
+ version: string;
1249
+ /**
1250
+ * Generated file contents keyed by file path
1251
+ */
1252
+ files: {
1253
+ [name: string]: string;
1254
+ };
1255
+ warnings?: string[];
1256
+ }
1152
1257
  export interface GetMonitoringStatsRequest {
1153
1258
  /**
1154
1259
  * Start date for statistics period (inclusive)
@@ -1921,6 +2026,11 @@ declare namespace Components {
1921
2026
  */
1922
2027
  updated_at: string; // date-time
1923
2028
  configuration?: /* Configuration for managed_call use cases. Defines a single API operation with JSONata mapping. */ ManagedCallOperationConfig;
2029
+ type_annotations?: /* Developer-provided type annotations for a use case's request and response fields */ TypeAnnotations;
2030
+ /**
2031
+ * Whether types have been generated for this use case
2032
+ */
2033
+ types_locked?: boolean;
1924
2034
  }
1925
2035
  export interface ManagedCallUseCaseHistoryEntry {
1926
2036
  /**
@@ -1968,6 +2078,11 @@ declare namespace Components {
1968
2078
  */
1969
2079
  type: "managed_call";
1970
2080
  configuration?: /* Configuration for managed_call use cases. Defines a single API operation with JSONata mapping. */ ManagedCallOperationConfig;
2081
+ type_annotations?: /* Developer-provided type annotations for a use case's request and response fields */ TypeAnnotations;
2082
+ /**
2083
+ * Whether types have been generated for this use case
2084
+ */
2085
+ types_locked?: boolean;
1971
2086
  }
1972
2087
  export interface MappingSimulationRequest {
1973
2088
  mapping_configuration: IntegrationConfigurationV1 | IntegrationConfigurationV2;
@@ -3353,6 +3468,67 @@ declare namespace Components {
3353
3468
  end_date?: string;
3354
3469
  event_id?: string;
3355
3470
  }
3471
+ /**
3472
+ * Developer-provided type annotations for a use case's request and response fields
3473
+ */
3474
+ export interface TypeAnnotations {
3475
+ /**
3476
+ * Type annotations for request fields, keyed by dot-path (e.g., "vendors[].id" -> "string")
3477
+ */
3478
+ request?: {
3479
+ [name: string]: string;
3480
+ };
3481
+ /**
3482
+ * Type annotations for response fields
3483
+ */
3484
+ response?: {
3485
+ [name: string]: string;
3486
+ };
3487
+ }
3488
+ /**
3489
+ * Describes the inferred type shape of a JSONata expression
3490
+ */
3491
+ export interface TypeDescriptor {
3492
+ kind: "object" | "array" | "string" | "number" | "boolean" | "null" | "unknown" | "union";
3493
+ /**
3494
+ * For kind=object, the properties and their type descriptors
3495
+ */
3496
+ properties?: {
3497
+ [name: string]: /* Describes the inferred type shape of a JSONata expression */ TypeDescriptor;
3498
+ };
3499
+ /**
3500
+ * For kind=array, the type of array items
3501
+ */
3502
+ items?: {
3503
+ kind: "object" | "array" | "string" | "number" | "boolean" | "null" | "unknown" | "union";
3504
+ /**
3505
+ * For kind=object, the properties and their type descriptors
3506
+ */
3507
+ properties?: {
3508
+ [name: string]: /* Describes the inferred type shape of a JSONata expression */ TypeDescriptor;
3509
+ };
3510
+ /**
3511
+ * For kind=array, the type of array items
3512
+ */
3513
+ items?: any;
3514
+ /**
3515
+ * For kind=unknown, the JSONata path that produced this value
3516
+ */
3517
+ source?: string;
3518
+ /**
3519
+ * For kind=union, the variant types
3520
+ */
3521
+ variants?: /* Describes the inferred type shape of a JSONata expression */ TypeDescriptor[];
3522
+ };
3523
+ /**
3524
+ * For kind=unknown, the JSONata path that produced this value
3525
+ */
3526
+ source?: string;
3527
+ /**
3528
+ * For kind=union, the variant types
3529
+ */
3530
+ variants?: /* Describes the inferred type shape of a JSONata expression */ TypeDescriptor[];
3531
+ }
3356
3532
  export interface UpdateFileProxyUseCaseRequest {
3357
3533
  /**
3358
3534
  * Use case name
@@ -3433,6 +3609,7 @@ declare namespace Components {
3433
3609
  */
3434
3610
  type?: "managed_call";
3435
3611
  configuration?: /* Configuration for managed_call use cases. Defines a single API operation with JSONata mapping. */ ManagedCallOperationConfig;
3612
+ type_annotations?: /* Developer-provided type annotations for a use case's request and response fields */ TypeAnnotations;
3436
3613
  }
3437
3614
  export interface UpdateOutboundUseCaseRequest {
3438
3615
  /**
@@ -3632,6 +3809,16 @@ declare namespace Components {
3632
3809
  */
3633
3810
  history_created_at: string; // date-time
3634
3811
  }
3812
+ /**
3813
+ * Scaffolded type descriptors for a single use case
3814
+ */
3815
+ export interface UseCaseTypePreview {
3816
+ slug: string;
3817
+ name?: string;
3818
+ request_shape: /* Describes the inferred type shape of a JSONata expression */ TypeDescriptor;
3819
+ response_shape: /* Describes the inferred type shape of a JSONata expression */ TypeDescriptor;
3820
+ existing_annotations?: /* Developer-provided type annotations for a use case's request and response fields */ TypeAnnotations;
3821
+ }
3635
3822
  export interface WebhookStatus {
3636
3823
  /**
3637
3824
  * Unique identifier for the webhook
@@ -3670,6 +3857,22 @@ declare namespace Paths {
3670
3857
  }
3671
3858
  }
3672
3859
  }
3860
+ namespace CommitTypes {
3861
+ namespace Parameters {
3862
+ export type IntegrationId = string; // uuid
3863
+ }
3864
+ export interface PathParameters {
3865
+ integrationId: Parameters.IntegrationId /* uuid */;
3866
+ }
3867
+ export type RequestBody = Components.Schemas.CommitTypesRequest;
3868
+ namespace Responses {
3869
+ export type $200 = Components.Schemas.CommitTypesResponse;
3870
+ export type $400 = Components.Responses.BadRequest;
3871
+ export type $403 = Components.Responses.Forbidden;
3872
+ export type $404 = Components.Responses.NotFound;
3873
+ export type $500 = Components.Responses.InternalServerError;
3874
+ }
3875
+ }
3673
3876
  namespace CreateIntegration {
3674
3877
  export type RequestBody = Components.Schemas.CreateIntegrationRequest;
3675
3878
  namespace Responses {
@@ -3782,6 +3985,37 @@ declare namespace Paths {
3782
3985
  export type $500 = Components.Responses.InternalServerError;
3783
3986
  }
3784
3987
  }
3988
+ namespace GenerateTypes {
3989
+ namespace Parameters {
3990
+ export type IntegrationId = string; // uuid
3991
+ }
3992
+ export interface PathParameters {
3993
+ integrationId: Parameters.IntegrationId /* uuid */;
3994
+ }
3995
+ export type RequestBody = Components.Schemas.GenerateTypesRequest;
3996
+ namespace Responses {
3997
+ export type $200 = Components.Schemas.GenerateTypesResponse;
3998
+ export type $400 = Components.Responses.BadRequest;
3999
+ export type $403 = Components.Responses.Forbidden;
4000
+ export type $404 = Components.Responses.NotFound;
4001
+ export type $500 = Components.Responses.InternalServerError;
4002
+ }
4003
+ }
4004
+ namespace GenerateTypesPreview {
4005
+ namespace Parameters {
4006
+ export type IntegrationId = string; // uuid
4007
+ }
4008
+ export interface PathParameters {
4009
+ integrationId: Parameters.IntegrationId /* uuid */;
4010
+ }
4011
+ namespace Responses {
4012
+ export type $200 = Components.Schemas.GenerateTypesPreviewResponse;
4013
+ export type $400 = Components.Responses.BadRequest;
4014
+ export type $403 = Components.Responses.Forbidden;
4015
+ export type $404 = Components.Responses.NotFound;
4016
+ export type $500 = Components.Responses.InternalServerError;
4017
+ }
4018
+ }
3785
4019
  namespace GetAssociatedMonitoringEvents {
3786
4020
  namespace Parameters {
3787
4021
  export type EventId = string;
@@ -4760,6 +4994,39 @@ export interface OperationMethods {
4760
4994
  data?: Paths.ManagedCallExecute.RequestBody,
4761
4995
  config?: AxiosRequestConfig
4762
4996
  ): OperationResponse<Paths.ManagedCallExecute.Responses.$200>
4997
+ /**
4998
+ * generateTypesPreview - Preview scaffolded types for a connector integration
4999
+ *
5000
+ * Analyses the JSONata mappings of all managed-call use cases in the integration and returns scaffolded type descriptors. The frontend uses these to show the type editor modal where developers fill in leaf types.
5001
+ *
5002
+ */
5003
+ 'generateTypesPreview'(
5004
+ parameters?: Parameters<Paths.GenerateTypesPreview.PathParameters> | null,
5005
+ data?: any,
5006
+ config?: AxiosRequestConfig
5007
+ ): OperationResponse<Paths.GenerateTypesPreview.Responses.$200>
5008
+ /**
5009
+ * generateTypes - Generate a TypeScript npm package for a connector integration
5010
+ *
5011
+ * Generates a complete TypeScript npm package with typed interfaces for all managed-call use cases. This is a stateless operation that does not persist any changes. Use the commit-types endpoint to lock configurations after review.
5012
+ *
5013
+ */
5014
+ 'generateTypes'(
5015
+ parameters?: Parameters<Paths.GenerateTypes.PathParameters> | null,
5016
+ data?: Paths.GenerateTypes.RequestBody,
5017
+ config?: AxiosRequestConfig
5018
+ ): OperationResponse<Paths.GenerateTypes.Responses.$200>
5019
+ /**
5020
+ * commitTypes - Commit generated types and lock use case configurations
5021
+ *
5022
+ * Commits the generated types by locking use case configurations and updating version tracking. Should be called after the user reviews and downloads the generated package.
5023
+ *
5024
+ */
5025
+ 'commitTypes'(
5026
+ parameters?: Parameters<Paths.CommitTypes.PathParameters> | null,
5027
+ data?: Paths.CommitTypes.RequestBody,
5028
+ config?: AxiosRequestConfig
5029
+ ): OperationResponse<Paths.CommitTypes.Responses.$200>
4763
5030
  }
4764
5031
 
4765
5032
  export interface PathsDictionary {
@@ -5287,6 +5554,45 @@ export interface PathsDictionary {
5287
5554
  config?: AxiosRequestConfig
5288
5555
  ): OperationResponse<Paths.ManagedCallExecute.Responses.$200>
5289
5556
  }
5557
+ ['/v1/integrations/{integrationId}/generate-types-preview']: {
5558
+ /**
5559
+ * generateTypesPreview - Preview scaffolded types for a connector integration
5560
+ *
5561
+ * Analyses the JSONata mappings of all managed-call use cases in the integration and returns scaffolded type descriptors. The frontend uses these to show the type editor modal where developers fill in leaf types.
5562
+ *
5563
+ */
5564
+ 'post'(
5565
+ parameters?: Parameters<Paths.GenerateTypesPreview.PathParameters> | null,
5566
+ data?: any,
5567
+ config?: AxiosRequestConfig
5568
+ ): OperationResponse<Paths.GenerateTypesPreview.Responses.$200>
5569
+ }
5570
+ ['/v1/integrations/{integrationId}/generate-types']: {
5571
+ /**
5572
+ * generateTypes - Generate a TypeScript npm package for a connector integration
5573
+ *
5574
+ * Generates a complete TypeScript npm package with typed interfaces for all managed-call use cases. This is a stateless operation that does not persist any changes. Use the commit-types endpoint to lock configurations after review.
5575
+ *
5576
+ */
5577
+ 'post'(
5578
+ parameters?: Parameters<Paths.GenerateTypes.PathParameters> | null,
5579
+ data?: Paths.GenerateTypes.RequestBody,
5580
+ config?: AxiosRequestConfig
5581
+ ): OperationResponse<Paths.GenerateTypes.Responses.$200>
5582
+ }
5583
+ ['/v1/integrations/{integrationId}/commit-types']: {
5584
+ /**
5585
+ * commitTypes - Commit generated types and lock use case configurations
5586
+ *
5587
+ * Commits the generated types by locking use case configurations and updating version tracking. Should be called after the user reviews and downloads the generated package.
5588
+ *
5589
+ */
5590
+ 'post'(
5591
+ parameters?: Parameters<Paths.CommitTypes.PathParameters> | null,
5592
+ data?: Paths.CommitTypes.RequestBody,
5593
+ config?: AxiosRequestConfig
5594
+ ): OperationResponse<Paths.CommitTypes.Responses.$200>
5595
+ }
5290
5596
  }
5291
5597
 
5292
5598
  export type Client = OpenAPIClient<OperationMethods, PathsDictionary>
@@ -5294,6 +5600,8 @@ export type Client = OpenAPIClient<OperationMethods, PathsDictionary>
5294
5600
 
5295
5601
  export type AccessLogEntry = Components.Schemas.AccessLogEntry;
5296
5602
  export type AutoRefreshSettings = Components.Schemas.AutoRefreshSettings;
5603
+ export type CommitTypesRequest = Components.Schemas.CommitTypesRequest;
5604
+ export type CommitTypesResponse = Components.Schemas.CommitTypesResponse;
5297
5605
  export type ConnectorConfig = Components.Schemas.ConnectorConfig;
5298
5606
  export type CreateFileProxyUseCaseRequest = Components.Schemas.CreateFileProxyUseCaseRequest;
5299
5607
  export type CreateInboundUseCaseRequest = Components.Schemas.CreateInboundUseCaseRequest;
@@ -5330,6 +5638,9 @@ export type FileProxyUrlParams = Components.Schemas.FileProxyUrlParams;
5330
5638
  export type FileProxyUseCase = Components.Schemas.FileProxyUseCase;
5331
5639
  export type FileProxyUseCaseConfiguration = Components.Schemas.FileProxyUseCaseConfiguration;
5332
5640
  export type FileProxyUseCaseHistoryEntry = Components.Schemas.FileProxyUseCaseHistoryEntry;
5641
+ export type GenerateTypesPreviewResponse = Components.Schemas.GenerateTypesPreviewResponse;
5642
+ export type GenerateTypesRequest = Components.Schemas.GenerateTypesRequest;
5643
+ export type GenerateTypesResponse = Components.Schemas.GenerateTypesResponse;
5333
5644
  export type GetMonitoringStatsRequest = Components.Schemas.GetMonitoringStatsRequest;
5334
5645
  export type GetMonitoringStatsV2Request = Components.Schemas.GetMonitoringStatsV2Request;
5335
5646
  export type GetMonitoringTimeSeriesRequest = Components.Schemas.GetMonitoringTimeSeriesRequest;
@@ -5401,6 +5712,8 @@ export type TimeSeriesBucket = Components.Schemas.TimeSeriesBucket;
5401
5712
  export type TimeSeriesBucketV2 = Components.Schemas.TimeSeriesBucketV2;
5402
5713
  export type TriggerErpActionRequest = Components.Schemas.TriggerErpActionRequest;
5403
5714
  export type TriggerWebhookResp = Components.Schemas.TriggerWebhookResp;
5715
+ export type TypeAnnotations = Components.Schemas.TypeAnnotations;
5716
+ export type TypeDescriptor = Components.Schemas.TypeDescriptor;
5404
5717
  export type UpdateFileProxyUseCaseRequest = Components.Schemas.UpdateFileProxyUseCaseRequest;
5405
5718
  export type UpdateInboundUseCaseRequest = Components.Schemas.UpdateInboundUseCaseRequest;
5406
5719
  export type UpdateIntegrationRequest = Components.Schemas.UpdateIntegrationRequest;
@@ -5414,4 +5727,5 @@ export type UseCase = Components.Schemas.UseCase;
5414
5727
  export type UseCaseBase = Components.Schemas.UseCaseBase;
5415
5728
  export type UseCaseHistoryEntry = Components.Schemas.UseCaseHistoryEntry;
5416
5729
  export type UseCaseHistoryEntryBase = Components.Schemas.UseCaseHistoryEntryBase;
5730
+ export type UseCaseTypePreview = Components.Schemas.UseCaseTypePreview;
5417
5731
  export type WebhookStatus = Components.Schemas.WebhookStatus;
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.51.0",
5
+ "version": "0.56.0",
6
6
  "description": "API for integrating with ERP systems, handling tracking acknowledgments, triggering ERP processes, and processing ERP updates."
7
7
  },
8
8
  "tags": [
@@ -2668,6 +2668,176 @@
2668
2668
  }
2669
2669
  }
2670
2670
  }
2671
+ },
2672
+ "/v1/integrations/{integrationId}/generate-types-preview": {
2673
+ "post": {
2674
+ "operationId": "generateTypesPreview",
2675
+ "summary": "Preview scaffolded types for a connector integration",
2676
+ "description": "Analyses the JSONata mappings of all managed-call use cases in the integration and returns scaffolded type descriptors. The frontend uses these to show the type editor modal where developers fill in leaf types.\n",
2677
+ "tags": [
2678
+ "integrations"
2679
+ ],
2680
+ "security": [
2681
+ {
2682
+ "EpilotAuth": []
2683
+ }
2684
+ ],
2685
+ "parameters": [
2686
+ {
2687
+ "name": "integrationId",
2688
+ "in": "path",
2689
+ "required": true,
2690
+ "schema": {
2691
+ "type": "string",
2692
+ "format": "uuid"
2693
+ }
2694
+ }
2695
+ ],
2696
+ "responses": {
2697
+ "200": {
2698
+ "description": "Scaffolded type preview",
2699
+ "content": {
2700
+ "application/json": {
2701
+ "schema": {
2702
+ "$ref": "#/components/schemas/GenerateTypesPreviewResponse"
2703
+ }
2704
+ }
2705
+ }
2706
+ },
2707
+ "400": {
2708
+ "$ref": "#/components/responses/BadRequest"
2709
+ },
2710
+ "403": {
2711
+ "$ref": "#/components/responses/Forbidden"
2712
+ },
2713
+ "404": {
2714
+ "$ref": "#/components/responses/NotFound"
2715
+ },
2716
+ "500": {
2717
+ "$ref": "#/components/responses/InternalServerError"
2718
+ }
2719
+ }
2720
+ }
2721
+ },
2722
+ "/v1/integrations/{integrationId}/generate-types": {
2723
+ "post": {
2724
+ "operationId": "generateTypes",
2725
+ "summary": "Generate a TypeScript npm package for a connector integration",
2726
+ "description": "Generates a complete TypeScript npm package with typed interfaces for all managed-call use cases. This is a stateless operation that does not persist any changes. Use the commit-types endpoint to lock configurations after review.\n",
2727
+ "tags": [
2728
+ "integrations"
2729
+ ],
2730
+ "security": [
2731
+ {
2732
+ "EpilotAuth": []
2733
+ }
2734
+ ],
2735
+ "parameters": [
2736
+ {
2737
+ "name": "integrationId",
2738
+ "in": "path",
2739
+ "required": true,
2740
+ "schema": {
2741
+ "type": "string",
2742
+ "format": "uuid"
2743
+ }
2744
+ }
2745
+ ],
2746
+ "requestBody": {
2747
+ "required": true,
2748
+ "content": {
2749
+ "application/json": {
2750
+ "schema": {
2751
+ "$ref": "#/components/schemas/GenerateTypesRequest"
2752
+ }
2753
+ }
2754
+ }
2755
+ },
2756
+ "responses": {
2757
+ "200": {
2758
+ "description": "Generated package",
2759
+ "content": {
2760
+ "application/json": {
2761
+ "schema": {
2762
+ "$ref": "#/components/schemas/GenerateTypesResponse"
2763
+ }
2764
+ }
2765
+ }
2766
+ },
2767
+ "400": {
2768
+ "$ref": "#/components/responses/BadRequest"
2769
+ },
2770
+ "403": {
2771
+ "$ref": "#/components/responses/Forbidden"
2772
+ },
2773
+ "404": {
2774
+ "$ref": "#/components/responses/NotFound"
2775
+ },
2776
+ "500": {
2777
+ "$ref": "#/components/responses/InternalServerError"
2778
+ }
2779
+ }
2780
+ }
2781
+ },
2782
+ "/v1/integrations/{integrationId}/commit-types": {
2783
+ "post": {
2784
+ "operationId": "commitTypes",
2785
+ "summary": "Commit generated types and lock use case configurations",
2786
+ "description": "Commits the generated types by locking use case configurations and updating version tracking. Should be called after the user reviews and downloads the generated package.\n",
2787
+ "tags": [
2788
+ "integrations"
2789
+ ],
2790
+ "security": [
2791
+ {
2792
+ "EpilotAuth": []
2793
+ }
2794
+ ],
2795
+ "parameters": [
2796
+ {
2797
+ "name": "integrationId",
2798
+ "in": "path",
2799
+ "required": true,
2800
+ "schema": {
2801
+ "type": "string",
2802
+ "format": "uuid"
2803
+ }
2804
+ }
2805
+ ],
2806
+ "requestBody": {
2807
+ "required": true,
2808
+ "content": {
2809
+ "application/json": {
2810
+ "schema": {
2811
+ "$ref": "#/components/schemas/CommitTypesRequest"
2812
+ }
2813
+ }
2814
+ }
2815
+ },
2816
+ "responses": {
2817
+ "200": {
2818
+ "description": "Types committed successfully",
2819
+ "content": {
2820
+ "application/json": {
2821
+ "schema": {
2822
+ "$ref": "#/components/schemas/CommitTypesResponse"
2823
+ }
2824
+ }
2825
+ }
2826
+ },
2827
+ "400": {
2828
+ "$ref": "#/components/responses/BadRequest"
2829
+ },
2830
+ "403": {
2831
+ "$ref": "#/components/responses/Forbidden"
2832
+ },
2833
+ "404": {
2834
+ "$ref": "#/components/responses/NotFound"
2835
+ },
2836
+ "500": {
2837
+ "$ref": "#/components/responses/InternalServerError"
2838
+ }
2839
+ }
2840
+ }
2671
2841
  }
2672
2842
  },
2673
2843
  "components": {
@@ -3039,6 +3209,50 @@
3039
3209
  },
3040
3210
  "auth": {
3041
3211
  "$ref": "#/components/schemas/ManagedCallAuth"
3212
+ },
3213
+ "types_versions": {
3214
+ "type": "array",
3215
+ "description": "History of generated type package versions",
3216
+ "items": {
3217
+ "type": "object",
3218
+ "required": [
3219
+ "version",
3220
+ "package_name",
3221
+ "generated_at",
3222
+ "generated_by",
3223
+ "status"
3224
+ ],
3225
+ "properties": {
3226
+ "version": {
3227
+ "type": "string"
3228
+ },
3229
+ "package_name": {
3230
+ "type": "string"
3231
+ },
3232
+ "generated_at": {
3233
+ "type": "string",
3234
+ "format": "date-time"
3235
+ },
3236
+ "generated_by": {
3237
+ "type": "string"
3238
+ },
3239
+ "status": {
3240
+ "type": "string",
3241
+ "enum": [
3242
+ "active",
3243
+ "deprecated"
3244
+ ]
3245
+ }
3246
+ }
3247
+ }
3248
+ },
3249
+ "latest_types_version": {
3250
+ "type": "string",
3251
+ "description": "Latest active types package version"
3252
+ },
3253
+ "latest_types_package_name": {
3254
+ "type": "string",
3255
+ "description": "Latest active types package name"
3042
3256
  }
3043
3257
  }
3044
3258
  },
@@ -4032,6 +4246,13 @@
4032
4246
  },
4033
4247
  "configuration": {
4034
4248
  "$ref": "#/components/schemas/ManagedCallOperationConfig"
4249
+ },
4250
+ "type_annotations": {
4251
+ "$ref": "#/components/schemas/TypeAnnotations"
4252
+ },
4253
+ "types_locked": {
4254
+ "type": "boolean",
4255
+ "description": "Whether types have been generated for this use case"
4035
4256
  }
4036
4257
  }
4037
4258
  }
@@ -4411,6 +4632,9 @@
4411
4632
  },
4412
4633
  "configuration": {
4413
4634
  "$ref": "#/components/schemas/ManagedCallOperationConfig"
4635
+ },
4636
+ "type_annotations": {
4637
+ "$ref": "#/components/schemas/TypeAnnotations"
4414
4638
  }
4415
4639
  }
4416
4640
  }
@@ -4624,6 +4848,13 @@
4624
4848
  },
4625
4849
  "configuration": {
4626
4850
  "$ref": "#/components/schemas/ManagedCallOperationConfig"
4851
+ },
4852
+ "type_annotations": {
4853
+ "$ref": "#/components/schemas/TypeAnnotations"
4854
+ },
4855
+ "types_locked": {
4856
+ "type": "boolean",
4857
+ "description": "Whether types have been generated for this use case"
4627
4858
  }
4628
4859
  }
4629
4860
  }
@@ -4934,6 +5165,273 @@
4934
5165
  }
4935
5166
  }
4936
5167
  },
5168
+ "TypeAnnotations": {
5169
+ "type": "object",
5170
+ "description": "Developer-provided type annotations for a use case's request and response fields",
5171
+ "properties": {
5172
+ "request": {
5173
+ "type": "object",
5174
+ "description": "Type annotations for request fields, keyed by dot-path (e.g., \"vendors[].id\" -> \"string\")",
5175
+ "additionalProperties": {
5176
+ "type": "string"
5177
+ }
5178
+ },
5179
+ "response": {
5180
+ "type": "object",
5181
+ "description": "Type annotations for response fields",
5182
+ "additionalProperties": {
5183
+ "type": "string"
5184
+ }
5185
+ }
5186
+ }
5187
+ },
5188
+ "TypeDescriptor": {
5189
+ "type": "object",
5190
+ "description": "Describes the inferred type shape of a JSONata expression",
5191
+ "required": [
5192
+ "kind"
5193
+ ],
5194
+ "properties": {
5195
+ "kind": {
5196
+ "type": "string",
5197
+ "enum": [
5198
+ "object",
5199
+ "array",
5200
+ "string",
5201
+ "number",
5202
+ "boolean",
5203
+ "null",
5204
+ "unknown",
5205
+ "union"
5206
+ ]
5207
+ },
5208
+ "properties": {
5209
+ "type": "object",
5210
+ "description": "For kind=object, the properties and their type descriptors",
5211
+ "additionalProperties": {
5212
+ "$ref": "#/components/schemas/TypeDescriptor"
5213
+ }
5214
+ },
5215
+ "items": {
5216
+ "description": "For kind=array, the type of array items",
5217
+ "allOf": [
5218
+ {
5219
+ "$ref": "#/components/schemas/TypeDescriptor"
5220
+ }
5221
+ ]
5222
+ },
5223
+ "source": {
5224
+ "type": "string",
5225
+ "description": "For kind=unknown, the JSONata path that produced this value"
5226
+ },
5227
+ "variants": {
5228
+ "type": "array",
5229
+ "description": "For kind=union, the variant types",
5230
+ "items": {
5231
+ "$ref": "#/components/schemas/TypeDescriptor"
5232
+ }
5233
+ }
5234
+ }
5235
+ },
5236
+ "UseCaseTypePreview": {
5237
+ "type": "object",
5238
+ "description": "Scaffolded type descriptors for a single use case",
5239
+ "required": [
5240
+ "slug",
5241
+ "request_shape",
5242
+ "response_shape"
5243
+ ],
5244
+ "properties": {
5245
+ "slug": {
5246
+ "type": "string"
5247
+ },
5248
+ "name": {
5249
+ "type": "string"
5250
+ },
5251
+ "request_shape": {
5252
+ "$ref": "#/components/schemas/TypeDescriptor"
5253
+ },
5254
+ "response_shape": {
5255
+ "$ref": "#/components/schemas/TypeDescriptor"
5256
+ },
5257
+ "existing_annotations": {
5258
+ "$ref": "#/components/schemas/TypeAnnotations"
5259
+ }
5260
+ }
5261
+ },
5262
+ "GenerateTypesPreviewResponse": {
5263
+ "type": "object",
5264
+ "required": [
5265
+ "use_cases"
5266
+ ],
5267
+ "properties": {
5268
+ "integration_name": {
5269
+ "type": "string"
5270
+ },
5271
+ "use_cases": {
5272
+ "type": "array",
5273
+ "items": {
5274
+ "$ref": "#/components/schemas/UseCaseTypePreview"
5275
+ }
5276
+ },
5277
+ "previous_version": {
5278
+ "type": "string",
5279
+ "description": "Previously generated version, if any"
5280
+ },
5281
+ "suggested_version": {
5282
+ "type": "string",
5283
+ "description": "Suggested next version based on detected changes"
5284
+ },
5285
+ "suggested_bump": {
5286
+ "type": "string",
5287
+ "enum": [
5288
+ "major",
5289
+ "minor"
5290
+ ]
5291
+ },
5292
+ "detected_changes": {
5293
+ "type": "array",
5294
+ "items": {
5295
+ "type": "object",
5296
+ "required": [
5297
+ "slug",
5298
+ "field",
5299
+ "type",
5300
+ "description"
5301
+ ],
5302
+ "properties": {
5303
+ "slug": {
5304
+ "type": "string"
5305
+ },
5306
+ "field": {
5307
+ "type": "string"
5308
+ },
5309
+ "type": {
5310
+ "type": "string",
5311
+ "enum": [
5312
+ "breaking",
5313
+ "non-breaking"
5314
+ ]
5315
+ },
5316
+ "description": {
5317
+ "type": "string"
5318
+ }
5319
+ }
5320
+ }
5321
+ }
5322
+ }
5323
+ },
5324
+ "GenerateTypesRequest": {
5325
+ "type": "object",
5326
+ "required": [
5327
+ "package_name",
5328
+ "version"
5329
+ ],
5330
+ "properties": {
5331
+ "package_name": {
5332
+ "type": "string",
5333
+ "description": "npm package name",
5334
+ "example": "@epilot/hems-cleverpv"
5335
+ },
5336
+ "version": {
5337
+ "type": "string",
5338
+ "description": "Package version",
5339
+ "example": "1.0.0"
5340
+ },
5341
+ "description": {
5342
+ "type": "string"
5343
+ },
5344
+ "domain_package": {
5345
+ "type": "string",
5346
+ "description": "Domain standard package to extend",
5347
+ "example": "@epilot/hems"
5348
+ },
5349
+ "domain_map_name": {
5350
+ "type": "string",
5351
+ "description": "Name of the domain UseCaseMap to extend",
5352
+ "example": "HemsUseCaseMap"
5353
+ },
5354
+ "annotations": {
5355
+ "type": "object",
5356
+ "description": "Type annotations per use case slug",
5357
+ "additionalProperties": {
5358
+ "$ref": "#/components/schemas/TypeAnnotations"
5359
+ }
5360
+ }
5361
+ }
5362
+ },
5363
+ "GenerateTypesResponse": {
5364
+ "type": "object",
5365
+ "required": [
5366
+ "package_name",
5367
+ "version",
5368
+ "files"
5369
+ ],
5370
+ "properties": {
5371
+ "package_name": {
5372
+ "type": "string"
5373
+ },
5374
+ "version": {
5375
+ "type": "string"
5376
+ },
5377
+ "files": {
5378
+ "type": "object",
5379
+ "description": "Generated file contents keyed by file path",
5380
+ "additionalProperties": {
5381
+ "type": "string"
5382
+ }
5383
+ },
5384
+ "warnings": {
5385
+ "type": "array",
5386
+ "items": {
5387
+ "type": "string"
5388
+ }
5389
+ }
5390
+ }
5391
+ },
5392
+ "CommitTypesRequest": {
5393
+ "type": "object",
5394
+ "required": [
5395
+ "package_name",
5396
+ "version"
5397
+ ],
5398
+ "properties": {
5399
+ "package_name": {
5400
+ "type": "string",
5401
+ "description": "npm package name",
5402
+ "example": "@epilot/hems-cleverpv"
5403
+ },
5404
+ "version": {
5405
+ "type": "string",
5406
+ "description": "Package version",
5407
+ "example": "1.0.0"
5408
+ },
5409
+ "annotations": {
5410
+ "type": "object",
5411
+ "description": "Type annotations per use case slug",
5412
+ "additionalProperties": {
5413
+ "$ref": "#/components/schemas/TypeAnnotations"
5414
+ }
5415
+ }
5416
+ }
5417
+ },
5418
+ "CommitTypesResponse": {
5419
+ "type": "object",
5420
+ "required": [
5421
+ "committed"
5422
+ ],
5423
+ "properties": {
5424
+ "committed": {
5425
+ "type": "boolean"
5426
+ },
5427
+ "warnings": {
5428
+ "type": "array",
5429
+ "items": {
5430
+ "type": "string"
5431
+ }
5432
+ }
5433
+ }
5434
+ },
4937
5435
  "FileProxyUseCaseConfiguration": {
4938
5436
  "type": "object",
4939
5437
  "required": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epilot/erp-integration-client",
3
- "version": "0.30.0-rc3",
3
+ "version": "0.30.0",
4
4
  "description": "Client library for ePilot ERP Integration API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",