@epilot/pricing-client 3.51.3 → 3.51.4

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={390:function(e,r,t){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0});var n=i(t(466));r.default=n.default},466:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"","version":""},"servers":[{"url":"https://pricing-api.sls.epilot.io"}],"paths":{"/v1/pricing:compute":{"post":{"operationId":"$calculatePricingDetails","requestBody":{"required":false,"content":{"application/json":{}}},"responses":{}}},"/v1/order":{"post":{"operationId":"createOrder","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/order/{id}":{"put":{"operationId":"putOrder","parameters":[{"in":"path","name":"id","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/cart:checkout":{"post":{"operationId":"$checkoutCart","parameters":[{"in":"header","name":"X-Ivy-Org-ID","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/catalog":{"post":{"operationId":"$searchCatalog","parameters":[{"in":"header","name":"X-Ivy-Org-ID"},{"in":"header","name":"Authorization"}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/catalog":{"post":{"operationId":"$privateSearchCatalog","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/validate-promo-codes":{"post":{"operationId":"$validatePromoCodes","parameters":[{"in":"header","name":"X-Ivy-Org-ID","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/availability:check":{"post":{"operationId":"$availabilityCheck","parameters":[{"in":"header","name":"X-Ivy-Org-ID","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/validate-availability/{id}":{"get":{"operationId":"$validateAvailabilityFile","parameters":[{"in":"path","name":"id","required":true},{"in":"header","name":"X-Epilot-Org-ID","required":true}],"responses":{}}},"/v1/public/historicMarketPrices":{"get":{"operationId":"$historicMarketPrices","parameters":[{"in":"query","name":"market","required":true},{"in":"query","name":"bidding_zone","required":true},{"in":"query","name":"frequency","required":true},{"in":"query","name":"from","required":true},{"in":"query","name":"to","required":true}],"responses":{}}},"/v1/public/averageMarketPrice":{"get":{"operationId":"$averageMarketPrice","parameters":[{"in":"query","name":"market","required":true},{"in":"query","name":"bidding_zone","required":true},{"in":"query","name":"from","required":true},{"in":"query","name":"to","required":true}],"responses":{}}},"/v1/public/integration/{integrationId}/products":{"post":{"operationId":"$searchExternalProducts","parameters":[{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/products-recommendation":{"post":{"operationId":"$searchExternalProductsRecommendation","parameters":[{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/providers:search":{"post":{"operationId":"$searchProviders","parameters":[{"in":"header","name":"X-Epilot-Org-ID","required":true},{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/streets:search":{"post":{"operationId":"$searchStreets","parameters":[{"in":"header","name":"X-Epilot-Org-ID","required":true},{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/compute-price":{"post":{"operationId":"$computePrice","parameters":[{"in":"header","name":"X-Epilot-Org-ID","required":true},{"in":"path","name":"integrationId","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/integration/{integrationId}/credentials":{"get":{"operationId":"$getCredentials","parameters":[{"in":"path","name":"integrationId","required":true}],"responses":{}}},"/v1/integration/{integrationId}/credentials:save":{"put":{"operationId":"$saveCredentials","parameters":[{"in":"path","name":"integrationId","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/integration/{integrationId}/credentials:delete":{"delete":{"operationId":"$deleteCredentials","parameters":[{"in":"path","name":"integrationId","required":true}],"responses":{}}},"/v1/public/external-catalog/products":{"post":{"operationId":"$getExternalCatalogProducts","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/product-recommendations":{"post":{"operationId":"$productRecommendations","parameters":[{"in":"header","name":"X-Ivy-Org-ID"}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}}},"components":{}}')}},r={},t=function t(i){var n=r[i];if(void 0!==n)return n.exports;var a=r[i]={exports:{}};return e[i].call(a.exports,a,a.exports,t),a.exports}(390),i=exports;for(var n in t)i[n]=t[n];t.__esModule&&Object.defineProperty(i,"__esModule",{value:!0})})();
1
+ (()=>{"use strict";var e={390:function(e,r,t){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0});var n=i(t(466));r.default=n.default},466:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"","version":""},"servers":[{"url":"https://pricing-api.sls.epilot.io"}],"paths":{"/v1/pricing:compute":{"post":{"operationId":"$calculatePricingDetails","requestBody":{"required":false,"content":{"application/json":{}}},"responses":{}}},"/v1/order":{"post":{"operationId":"createOrder","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/order/{id}":{"put":{"operationId":"putOrder","parameters":[{"in":"path","name":"id","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/cart:checkout":{"post":{"operationId":"$checkoutCart","parameters":[{"in":"header","name":"X-Ivy-Org-ID","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/catalog":{"post":{"operationId":"$searchCatalog","parameters":[{"in":"header","name":"X-Ivy-Org-ID"},{"in":"header","name":"Authorization"}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/catalog":{"post":{"operationId":"$privateSearchCatalog","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/validate-promo-codes":{"post":{"operationId":"$validatePromoCodes","parameters":[{"in":"header","name":"X-Ivy-Org-ID","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/availability:check":{"post":{"operationId":"$availabilityCheck","parameters":[{"in":"header","name":"X-Ivy-Org-ID","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/validate-availability/{id}":{"get":{"operationId":"$validateAvailabilityFile","parameters":[{"in":"path","name":"id","required":true},{"in":"header","name":"X-Epilot-Org-ID","required":true}],"responses":{}}},"/v1/public/historicMarketPrices":{"get":{"operationId":"$historicMarketPrices","parameters":[{"in":"query","name":"market","required":true},{"in":"query","name":"bidding_zone","required":true},{"in":"query","name":"frequency","required":true},{"in":"query","name":"from","required":true},{"in":"query","name":"to","required":true}],"responses":{}}},"/v1/public/averageMarketPrice":{"get":{"operationId":"$averageMarketPrice","parameters":[{"in":"query","name":"market","required":true},{"in":"query","name":"bidding_zone","required":true},{"in":"query","name":"from","required":true},{"in":"query","name":"to","required":true}],"responses":{}}},"/v1/public/integration/{integrationId}/products":{"post":{"operationId":"$searchExternalProducts","parameters":[{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/products-recommendation":{"post":{"operationId":"$searchExternalProductsRecommendation","parameters":[{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/providers:search":{"post":{"operationId":"$searchProviders","parameters":[{"in":"header","name":"X-Epilot-Org-ID","required":true},{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/streets:search":{"post":{"operationId":"$searchStreets","parameters":[{"in":"header","name":"X-Epilot-Org-ID","required":true},{"in":"path","name":"integrationId","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/integration/{integrationId}/compute-price":{"post":{"operationId":"$computePrice","parameters":[{"in":"header","name":"X-Epilot-Org-ID","required":true},{"in":"path","name":"integrationId","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/integration/{integrationId}/credentials":{"get":{"operationId":"$getCredentials","parameters":[{"in":"path","name":"integrationId","required":true}],"responses":{}}},"/v1/integration/{integrationId}/credentials:save":{"put":{"operationId":"$saveCredentials","parameters":[{"in":"path","name":"integrationId","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/integration/{integrationId}/credentials:delete":{"delete":{"operationId":"$deleteCredentials","parameters":[{"in":"path","name":"integrationId","required":true}],"responses":{}}},"/v1/public/external-catalog/products":{"post":{"operationId":"$getExternalCatalogProducts","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/external-catalog/products-recommendation":{"post":{"operationId":"$getExternalCatalogProductsRecommendation","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/product-recommendations":{"post":{"operationId":"$productRecommendations","parameters":[{"in":"header","name":"X-Ivy-Org-ID"}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}}},"components":{}}')}},r={},t=function t(i){var n=r[i];if(void 0!==n)return n.exports;var a=r[i]={exports:{}};return e[i].call(a.exports,a,a.exports,t),a.exports}(390),i=exports;for(var n in t)i[n]=t[n];t.__esModule&&Object.defineProperty(i,"__esModule",{value:!0})})();
@@ -388,6 +388,18 @@
388
388
  "responses": {}
389
389
  }
390
390
  },
391
+ "/v1/public/external-catalog/products-recommendation": {
392
+ "post": {
393
+ "operationId": "$getExternalCatalogProductsRecommendation",
394
+ "requestBody": {
395
+ "required": true,
396
+ "content": {
397
+ "application/json": {}
398
+ }
399
+ },
400
+ "responses": {}
401
+ }
402
+ },
391
403
  "/v1/public/product-recommendations": {
392
404
  "post": {
393
405
  "operationId": "$productRecommendations",
package/dist/openapi.d.ts CHANGED
@@ -4534,15 +4534,15 @@ declare namespace Components {
4534
4534
  * example:
4535
4535
  * 1234567890
4536
4536
  */
4537
- appId?: string;
4537
+ appId: string;
4538
4538
  /**
4539
4539
  * The component id.
4540
4540
  * example:
4541
4541
  * 1234567890
4542
4542
  */
4543
- componentId?: string;
4543
+ componentId: string;
4544
4544
  /**
4545
- * The hook id.
4545
+ * The hook id. If not provided, the first valid hook will be used.
4546
4546
  * example:
4547
4547
  * 1234567890
4548
4548
  */
@@ -4551,42 +4551,8 @@ declare namespace Components {
4551
4551
  }
4552
4552
  /**
4553
4553
  * The request payload for the external catalog service with a custom context. E.g. for requests from the Portal.
4554
- * example:
4555
- * {
4556
- * "config": {
4557
- * "appId": "1234567890",
4558
- * "componentId": "1234567890",
4559
- * "hookId": "1234567890"
4560
- * },
4561
- * "origin": "custom",
4562
- * "context": {
4563
- * "user_id": "user-12345",
4564
- * "session_id": "session-67890",
4565
- * "custom_context_key": "custom_context_value"
4566
- * }
4567
- * }
4568
4554
  */
4569
4555
  export interface ExternalCatalogCustomRequest {
4570
- config?: {
4571
- /**
4572
- * The app id.
4573
- * example:
4574
- * 1234567890
4575
- */
4576
- appId?: string;
4577
- /**
4578
- * The component id.
4579
- * example:
4580
- * 1234567890
4581
- */
4582
- componentId?: string;
4583
- /**
4584
- * The hook id.
4585
- * example:
4586
- * 1234567890
4587
- */
4588
- hookId?: string;
4589
- };
4590
4556
  /**
4591
4557
  * The origin of the request.
4592
4558
  * example:
@@ -4611,6 +4577,18 @@ declare namespace Components {
4611
4577
  }
4612
4578
  /**
4613
4579
  * The request payload for the external catalog service with a journey context.
4580
+ */
4581
+ export interface ExternalCatalogJourneyRequest {
4582
+ /**
4583
+ * The origin of the request.
4584
+ * example:
4585
+ * journey
4586
+ */
4587
+ origin: "journey";
4588
+ context: JourneyContext;
4589
+ }
4590
+ /**
4591
+ * The request payload for the external catalog service.
4614
4592
  * example:
4615
4593
  * {
4616
4594
  * "config": {
@@ -4651,40 +4629,29 @@ declare namespace Components {
4651
4629
  * }
4652
4630
  * }
4653
4631
  */
4654
- export interface ExternalCatalogJourneyRequest {
4632
+ export type ExternalCatalogRequest = {
4655
4633
  config?: {
4656
4634
  /**
4657
4635
  * The app id.
4658
4636
  * example:
4659
4637
  * 1234567890
4660
4638
  */
4661
- appId?: string;
4639
+ appId: string;
4662
4640
  /**
4663
4641
  * The component id.
4664
4642
  * example:
4665
4643
  * 1234567890
4666
4644
  */
4667
- componentId?: string;
4645
+ componentId: string;
4668
4646
  /**
4669
- * The hook id.
4647
+ * The hook id. If not provided, the first valid hook will be used.
4670
4648
  * example:
4671
4649
  * 1234567890
4672
4650
  */
4673
4651
  hookId?: string;
4674
4652
  };
4675
- /**
4676
- * The origin of the request.
4677
- * example:
4678
- * journey
4679
- */
4680
- origin: "journey";
4681
- context: JourneyContext;
4682
- }
4683
- /**
4653
+ } & (/**
4684
4654
  * The request payload for the external catalog service.
4685
- */
4686
- export type ExternalCatalogRequest = /* The request payload for the external catalog service. */ /**
4687
- * The request payload for the external catalog service with a journey context.
4688
4655
  * example:
4689
4656
  * {
4690
4657
  * "config": {
@@ -4725,24 +4692,7 @@ declare namespace Components {
4725
4692
  * }
4726
4693
  * }
4727
4694
  */
4728
- ExternalCatalogJourneyRequest | /**
4729
- * The request payload for the external catalog service with a custom context. E.g. for requests from the Portal.
4730
- * example:
4731
- * {
4732
- * "config": {
4733
- * "appId": "1234567890",
4734
- * "componentId": "1234567890",
4735
- * "hookId": "1234567890"
4736
- * },
4737
- * "origin": "custom",
4738
- * "context": {
4739
- * "user_id": "user-12345",
4740
- * "session_id": "session-67890",
4741
- * "custom_context_key": "custom_context_value"
4742
- * }
4743
- * }
4744
- */
4745
- ExternalCatalogCustomRequest;
4695
+ /* The request payload for the external catalog service with a journey context. */ ExternalCatalogJourneyRequest | /* The request payload for the external catalog service with a custom context. E.g. for requests from the Portal. */ ExternalCatalogCustomRequest);
4746
4696
  /**
4747
4697
  * example:
4748
4698
  * {
@@ -9745,13 +9695,105 @@ declare namespace Paths {
9745
9695
  }
9746
9696
  }
9747
9697
  namespace $GetExternalCatalogProducts {
9748
- export type RequestBody = /* The request payload for the external catalog service. */ Components.Schemas.ExternalCatalogRequest;
9698
+ export type RequestBody = /**
9699
+ * The request payload for the external catalog service.
9700
+ * example:
9701
+ * {
9702
+ * "config": {
9703
+ * "appId": "1234567890",
9704
+ * "componentId": "1234567890",
9705
+ * "hookId": "1234567890"
9706
+ * },
9707
+ * "origin": "journey",
9708
+ * "context": {
9709
+ * "journey_id": "8d0a2235-97ce-42d0-88a3-e374634ca44e",
9710
+ * "entity_id": "9e1b3346-a8df-53e1-99b4-f485745db55f",
9711
+ * "journey_name": "Product Selection Journey",
9712
+ * "journey_tags": [
9713
+ * "electricity",
9714
+ * "residential"
9715
+ * ],
9716
+ * "journey_url_params": {
9717
+ * "utm_source": "google",
9718
+ * "utm_campaign": "spring2024"
9719
+ * },
9720
+ * "current_step_name": "Product Selection",
9721
+ * "current_block_name": "Energy Products",
9722
+ * "steps_data": [
9723
+ * {
9724
+ * "step_name": "Address Information",
9725
+ * "step_index": 0,
9726
+ * "blocks": {
9727
+ * "Adresse": {
9728
+ * "countryCode": "DE",
9729
+ * "city": "Koblenz",
9730
+ * "zipCode": "56068",
9731
+ * "streetName": "Am Alten Hospital",
9732
+ * "houseNumber": "123"
9733
+ * }
9734
+ * }
9735
+ * }
9736
+ * ]
9737
+ * }
9738
+ * }
9739
+ */
9740
+ Components.Schemas.ExternalCatalogRequest;
9749
9741
  namespace Responses {
9750
9742
  export type $200 = Components.Schemas.SearchExternalCatalogResult;
9751
9743
  export type $400 = Components.Schemas.Error;
9752
9744
  export type $403 = Components.Schemas.Error;
9753
9745
  }
9754
9746
  }
9747
+ namespace $GetExternalCatalogProductsRecommendation {
9748
+ export type RequestBody = /**
9749
+ * The request payload for the external catalog service.
9750
+ * example:
9751
+ * {
9752
+ * "config": {
9753
+ * "appId": "1234567890",
9754
+ * "componentId": "1234567890",
9755
+ * "hookId": "1234567890"
9756
+ * },
9757
+ * "origin": "journey",
9758
+ * "context": {
9759
+ * "journey_id": "8d0a2235-97ce-42d0-88a3-e374634ca44e",
9760
+ * "entity_id": "9e1b3346-a8df-53e1-99b4-f485745db55f",
9761
+ * "journey_name": "Product Selection Journey",
9762
+ * "journey_tags": [
9763
+ * "electricity",
9764
+ * "residential"
9765
+ * ],
9766
+ * "journey_url_params": {
9767
+ * "utm_source": "google",
9768
+ * "utm_campaign": "spring2024"
9769
+ * },
9770
+ * "current_step_name": "Product Selection",
9771
+ * "current_block_name": "Energy Products",
9772
+ * "steps_data": [
9773
+ * {
9774
+ * "step_name": "Address Information",
9775
+ * "step_index": 0,
9776
+ * "blocks": {
9777
+ * "Adresse": {
9778
+ * "countryCode": "DE",
9779
+ * "city": "Koblenz",
9780
+ * "zipCode": "56068",
9781
+ * "streetName": "Am Alten Hospital",
9782
+ * "houseNumber": "123"
9783
+ * }
9784
+ * }
9785
+ * }
9786
+ * ]
9787
+ * }
9788
+ * }
9789
+ */
9790
+ Components.Schemas.ExternalCatalogRequest;
9791
+ namespace Responses {
9792
+ export type $200 = Components.Schemas.SearchExternalCatalogRecommendationsResult;
9793
+ export type $400 = Components.Schemas.Error;
9794
+ export type $403 = Components.Schemas.Error;
9795
+ }
9796
+ }
9755
9797
  namespace $HistoricMarketPrices {
9756
9798
  namespace Parameters {
9757
9799
  export type BiddingZone = /* The bidding zone for a spot market price. */ Components.Schemas.SpotMarketBiddingZone;
@@ -11343,6 +11385,16 @@ export interface OperationMethods {
11343
11385
  data?: Paths.$GetExternalCatalogProducts.RequestBody,
11344
11386
  config?: AxiosRequestConfig
11345
11387
  ): OperationResponse<Paths.$GetExternalCatalogProducts.Responses.$200>
11388
+ /**
11389
+ * $getExternalCatalogProductsRecommendation - getExternalCatalogProductsRecommendation
11390
+ *
11391
+ * Returns the list of available external catalog products recommendations based on a given context
11392
+ */
11393
+ '$getExternalCatalogProductsRecommendation'(
11394
+ parameters?: Parameters<UnknownParamsObject> | null,
11395
+ data?: Paths.$GetExternalCatalogProductsRecommendation.RequestBody,
11396
+ config?: AxiosRequestConfig
11397
+ ): OperationResponse<Paths.$GetExternalCatalogProductsRecommendation.Responses.$200>
11346
11398
  /**
11347
11399
  * $productRecommendations - productRecommendations
11348
11400
  *
@@ -11607,6 +11659,18 @@ export interface PathsDictionary {
11607
11659
  config?: AxiosRequestConfig
11608
11660
  ): OperationResponse<Paths.$GetExternalCatalogProducts.Responses.$200>
11609
11661
  }
11662
+ ['/v1/public/external-catalog/products-recommendation']: {
11663
+ /**
11664
+ * $getExternalCatalogProductsRecommendation - getExternalCatalogProductsRecommendation
11665
+ *
11666
+ * Returns the list of available external catalog products recommendations based on a given context
11667
+ */
11668
+ 'post'(
11669
+ parameters?: Parameters<UnknownParamsObject> | null,
11670
+ data?: Paths.$GetExternalCatalogProductsRecommendation.RequestBody,
11671
+ config?: AxiosRequestConfig
11672
+ ): OperationResponse<Paths.$GetExternalCatalogProductsRecommendation.Responses.$200>
11673
+ }
11610
11674
  ['/v1/public/product-recommendations']: {
11611
11675
  /**
11612
11676
  * $productRecommendations - productRecommendations
package/dist/openapi.json CHANGED
@@ -2854,6 +2854,339 @@
2854
2854
  }
2855
2855
  }
2856
2856
  },
2857
+ "/v1/public/external-catalog/products-recommendation": {
2858
+ "post": {
2859
+ "description": "Returns the list of available external catalog products recommendations based on a given context",
2860
+ "operationId": "$getExternalCatalogProductsRecommendation",
2861
+ "security": [
2862
+ {},
2863
+ {
2864
+ "EpilotPublicAuth": []
2865
+ }
2866
+ ],
2867
+ "summary": "getExternalCatalogProductsRecommendation",
2868
+ "tags": [
2869
+ "External Catalog API"
2870
+ ],
2871
+ "requestBody": {
2872
+ "required": true,
2873
+ "content": {
2874
+ "application/json": {
2875
+ "schema": {
2876
+ "$ref": "#/components/schemas/ExternalCatalogRequest"
2877
+ }
2878
+ }
2879
+ }
2880
+ },
2881
+ "responses": {
2882
+ "200": {
2883
+ "description": "The available products response payload",
2884
+ "content": {
2885
+ "application/json": {
2886
+ "schema": {
2887
+ "$ref": "#/components/schemas/SearchExternalCatalogRecommendationsResult"
2888
+ },
2889
+ "examples": {
2890
+ "External catalog recommendations": {
2891
+ "value": {
2892
+ "source": {
2893
+ "pricing_details": {
2894
+ "items": [
2895
+ {
2896
+ "_id": "price-12312414",
2897
+ "price_id": "price-12312414",
2898
+ "product_id": "product-12312414",
2899
+ "is_composite_price": true,
2900
+ "description": "Home Energy Package Composite",
2901
+ "item_components": [
2902
+ {
2903
+ "_id": "price-12312414-component-0",
2904
+ "price_id": "price-12312414-component-0",
2905
+ "product_id": "product-12312414",
2906
+ "description": "Working Price",
2907
+ "is_tax_inclusive": true,
2908
+ "amount_total_decimal": "50",
2909
+ "amount_total": 5000,
2910
+ "amount_subtotal_decimal": "50",
2911
+ "amount_subtotal": 5000,
2912
+ "unit_amount": 5,
2913
+ "unit_amount_gross": 5,
2914
+ "unit_amount_gross_decimal": "0.05",
2915
+ "unit_amount_net": 5,
2916
+ "unit_amount_net_decimal": "0.05",
2917
+ "billing_period": "monthly",
2918
+ "type": "recurring",
2919
+ "taxes": [],
2920
+ "pricing_model": "per_unit",
2921
+ "quantity": 1,
2922
+ "_price": {
2923
+ "_id": "price-12312414-component-0",
2924
+ "unit_amount_currency": "EUR",
2925
+ "description": "Working Price",
2926
+ "is_tax_inclusive": true,
2927
+ "unit_amount": 5,
2928
+ "unit_amount_decimal": "0.05",
2929
+ "unit": "kWh",
2930
+ "billing_period": "monthly",
2931
+ "type": "recurring",
2932
+ "billing_duration_amount": 24,
2933
+ "billing_duration_unit": "months",
2934
+ "notice_time_amount": 3,
2935
+ "notice_time_unit": "months",
2936
+ "termination_time_amount": 3,
2937
+ "termination_time_unit": "months",
2938
+ "renewal_duration_amount": 12,
2939
+ "renewal_duration_unit": "months",
2940
+ "active": true,
2941
+ "is_composite_price": false,
2942
+ "variable_price": true,
2943
+ "pricing_model": "per_unit",
2944
+ "price_display_in_journeys": "show_price"
2945
+ },
2946
+ "_product": {
2947
+ "_id": "product-12312414",
2948
+ "name": "Home Energy Package",
2949
+ "description": "Composite home energy solution with solar panels and battery"
2950
+ }
2951
+ }
2952
+ ]
2953
+ }
2954
+ ],
2955
+ "currency": "EUR",
2956
+ "amount_subtotal": 5000,
2957
+ "amount_total": 5000,
2958
+ "amount_tax": 0,
2959
+ "total_details": {
2960
+ "amount_tax": 0,
2961
+ "breakdown": {
2962
+ "taxes": [],
2963
+ "recurrences": [
2964
+ {
2965
+ "type": "recurring",
2966
+ "billing_period": "monthly",
2967
+ "amount_total": 5000,
2968
+ "amount_total_decimal": "50.00",
2969
+ "amount_subtotal": 5000,
2970
+ "amount_subtotal_decimal": "50.00",
2971
+ "amount_tax": 0
2972
+ }
2973
+ ]
2974
+ }
2975
+ }
2976
+ },
2977
+ "_meta": {
2978
+ "signature": "abc123",
2979
+ "timestamp": 1712049221642
2980
+ }
2981
+ },
2982
+ "offers": [
2983
+ {
2984
+ "pricing_details": {
2985
+ "items": [
2986
+ {
2987
+ "_id": "price-999857a4",
2988
+ "price_id": "price-999857a4",
2989
+ "product_id": "product-999857a4",
2990
+ "is_composite_price": false,
2991
+ "description": "Single Price",
2992
+ "is_tax_inclusive": true,
2993
+ "amount_total_decimal": "25",
2994
+ "amount_total": 2500,
2995
+ "amount_subtotal_decimal": "25",
2996
+ "amount_subtotal": 2500,
2997
+ "unit_amount": 25,
2998
+ "unit_amount_gross": 25,
2999
+ "unit_amount_gross_decimal": "25",
3000
+ "unit_amount_net": 25,
3001
+ "unit_amount_net_decimal": "25",
3002
+ "billing_period": null,
3003
+ "type": "one_time",
3004
+ "taxes": [],
3005
+ "pricing_model": "per_unit",
3006
+ "quantity": 1,
3007
+ "_price": {
3008
+ "_id": "price-999857a4",
3009
+ "unit_amount_currency": "EUR",
3010
+ "description": "Single Price",
3011
+ "is_tax_inclusive": true,
3012
+ "unit_amount": 25,
3013
+ "unit_amount_decimal": "25",
3014
+ "billing_duration_amount": 24,
3015
+ "billing_duration_unit": "months",
3016
+ "notice_time_amount": 3,
3017
+ "notice_time_unit": "months",
3018
+ "termination_time_amount": 3,
3019
+ "termination_time_unit": "months",
3020
+ "renewal_duration_amount": 12,
3021
+ "renewal_duration_unit": "months",
3022
+ "active": true,
3023
+ "is_composite_price": false,
3024
+ "pricing_model": "per_unit",
3025
+ "price_display_in_journeys": "show_price"
3026
+ },
3027
+ "_product": {
3028
+ "_id": "product-999857a4",
3029
+ "name": "Solar Panel X2",
3030
+ "description": "High-efficiency solar panel for residential use"
3031
+ }
3032
+ }
3033
+ ]
3034
+ },
3035
+ "currency": "EUR",
3036
+ "amount_subtotal": 2500,
3037
+ "amount_total": 2500,
3038
+ "amount_tax": 0,
3039
+ "total_details": {
3040
+ "amount_tax": 0,
3041
+ "breakdown": {
3042
+ "taxes": [],
3043
+ "recurrences": [
3044
+ {
3045
+ "type": "one_time",
3046
+ "amount_total": 2500,
3047
+ "amount_total_decimal": "25.00",
3048
+ "amount_subtotal": 2500,
3049
+ "amount_subtotal_decimal": "25.00",
3050
+ "amount_tax": 0
3051
+ }
3052
+ ]
3053
+ }
3054
+ },
3055
+ "_meta": {
3056
+ "signature": "def456",
3057
+ "timestamp": 1712049221643
3058
+ }
3059
+ },
3060
+ {
3061
+ "pricing_details": {
3062
+ "items": [
3063
+ {
3064
+ "_id": "price-93f857a4",
3065
+ "price_id": "price-93f857a4",
3066
+ "product_id": "product-93f857a4",
3067
+ "is_composite_price": false,
3068
+ "description": "Single Price",
3069
+ "is_tax_inclusive": false,
3070
+ "amount_total_decimal": "29.75",
3071
+ "amount_total": 2975,
3072
+ "amount_subtotal_decimal": "25",
3073
+ "amount_subtotal": 2500,
3074
+ "unit_amount": 25,
3075
+ "unit_amount_gross": 29.75,
3076
+ "unit_amount_gross_decimal": "29.75",
3077
+ "unit_amount_net": 25,
3078
+ "unit_amount_net_decimal": "25",
3079
+ "billing_period": null,
3080
+ "type": "one_time",
3081
+ "taxes": [
3082
+ {
3083
+ "tax": {
3084
+ "_id": "tax-vat-19",
3085
+ "name": "VAT",
3086
+ "type": "VAT",
3087
+ "rate": 19,
3088
+ "region": "DE"
3089
+ },
3090
+ "amount": 475
3091
+ }
3092
+ ],
3093
+ "pricing_model": "per_unit",
3094
+ "quantity": 1,
3095
+ "_price": {
3096
+ "_id": "price-93f857a4",
3097
+ "unit_amount_currency": "EUR",
3098
+ "description": "Single Price",
3099
+ "is_tax_inclusive": false,
3100
+ "unit_amount": 25,
3101
+ "unit_amount_decimal": "25",
3102
+ "active": true,
3103
+ "is_composite_price": false,
3104
+ "pricing_model": "per_unit",
3105
+ "price_display_in_journeys": "show_price",
3106
+ "tax": [
3107
+ {
3108
+ "_id": "tax-vat-19",
3109
+ "name": "VAT",
3110
+ "type": "VAT",
3111
+ "rate": 19,
3112
+ "region": "DE"
3113
+ }
3114
+ ]
3115
+ },
3116
+ "_product": {
3117
+ "_id": "product-93f857a4",
3118
+ "name": "Solar Panel X3",
3119
+ "description": "New generation of high-efficiency solar panel for residential use"
3120
+ }
3121
+ }
3122
+ ]
3123
+ },
3124
+ "currency": "EUR",
3125
+ "amount_subtotal": 2500,
3126
+ "amount_total": 2975,
3127
+ "amount_tax": 475,
3128
+ "total_details": {
3129
+ "amount_tax": 475,
3130
+ "breakdown": {
3131
+ "taxes": [
3132
+ {
3133
+ "tax": {
3134
+ "_id": "tax-vat-19",
3135
+ "name": "VAT",
3136
+ "type": "VAT",
3137
+ "rate": 19,
3138
+ "region": "DE"
3139
+ },
3140
+ "amount": 475
3141
+ }
3142
+ ],
3143
+ "recurrences": [
3144
+ {
3145
+ "type": "one_time",
3146
+ "amount_total": 2975,
3147
+ "amount_total_decimal": "29.75",
3148
+ "amount_subtotal": 2500,
3149
+ "amount_subtotal_decimal": "25.00",
3150
+ "amount_tax": 475
3151
+ }
3152
+ ]
3153
+ }
3154
+ },
3155
+ "_meta": {
3156
+ "signature": "ghi789",
3157
+ "timestamp": 1712049221644
3158
+ }
3159
+ }
3160
+ ]
3161
+ }
3162
+ }
3163
+ }
3164
+ }
3165
+ }
3166
+ },
3167
+ "400": {
3168
+ "description": "Invalid payload",
3169
+ "content": {
3170
+ "application/json": {
3171
+ "schema": {
3172
+ "$ref": "#/components/schemas/Error"
3173
+ }
3174
+ }
3175
+ }
3176
+ },
3177
+ "403": {
3178
+ "description": "Forbidden, no credentials found for the given integration / organization",
3179
+ "content": {
3180
+ "application/json": {
3181
+ "schema": {
3182
+ "$ref": "#/components/schemas/Error"
3183
+ }
3184
+ }
3185
+ }
3186
+ }
3187
+ }
3188
+ }
3189
+ },
2857
3190
  "/v1/public/product-recommendations": {
2858
3191
  "post": {
2859
3192
  "description": "Get a list of product recommendations based on the search parameters.",
@@ -8437,12 +8770,19 @@
8437
8770
  },
8438
8771
  "ExternalCatalogRequest": {
8439
8772
  "description": "The request payload for the external catalog service.",
8440
- "oneOf": [
8773
+ "allOf": [
8441
8774
  {
8442
- "$ref": "#/components/schemas/ExternalCatalogJourneyRequest"
8775
+ "$ref": "#/components/schemas/ExternalCatalogConfigurationRequest"
8443
8776
  },
8444
8777
  {
8445
- "$ref": "#/components/schemas/ExternalCatalogCustomRequest"
8778
+ "oneOf": [
8779
+ {
8780
+ "$ref": "#/components/schemas/ExternalCatalogJourneyRequest"
8781
+ },
8782
+ {
8783
+ "$ref": "#/components/schemas/ExternalCatalogCustomRequest"
8784
+ }
8785
+ ]
8446
8786
  }
8447
8787
  ],
8448
8788
  "discriminator": {
@@ -8451,6 +8791,44 @@
8451
8791
  "journey": "#/components/schemas/ExternalCatalogJourneyRequest",
8452
8792
  "custom": "#/components/schemas/ExternalCatalogCustomRequest"
8453
8793
  }
8794
+ },
8795
+ "example": {
8796
+ "config": {
8797
+ "appId": "1234567890",
8798
+ "componentId": "1234567890",
8799
+ "hookId": "1234567890"
8800
+ },
8801
+ "origin": "journey",
8802
+ "context": {
8803
+ "journey_id": "8d0a2235-97ce-42d0-88a3-e374634ca44e",
8804
+ "entity_id": "9e1b3346-a8df-53e1-99b4-f485745db55f",
8805
+ "journey_name": "Product Selection Journey",
8806
+ "journey_tags": [
8807
+ "electricity",
8808
+ "residential"
8809
+ ],
8810
+ "journey_url_params": {
8811
+ "utm_source": "google",
8812
+ "utm_campaign": "spring2024"
8813
+ },
8814
+ "current_step_name": "Product Selection",
8815
+ "current_block_name": "Energy Products",
8816
+ "steps_data": [
8817
+ {
8818
+ "step_name": "Address Information",
8819
+ "step_index": 0,
8820
+ "blocks": {
8821
+ "Adresse": {
8822
+ "countryCode": "DE",
8823
+ "city": "Koblenz",
8824
+ "zipCode": "56068",
8825
+ "streetName": "Am Alten Hospital",
8826
+ "houseNumber": "123"
8827
+ }
8828
+ }
8829
+ }
8830
+ ]
8831
+ }
8454
8832
  }
8455
8833
  },
8456
8834
  "ExternalCatalogConfigurationRequest": {
@@ -8472,10 +8850,14 @@
8472
8850
  },
8473
8851
  "hookId": {
8474
8852
  "type": "string",
8475
- "description": "The hook id.",
8853
+ "description": "The hook id. If not provided, the first valid hook will be used.",
8476
8854
  "example": "1234567890"
8477
8855
  }
8478
- }
8856
+ },
8857
+ "required": [
8858
+ "appId",
8859
+ "componentId"
8860
+ ]
8479
8861
  }
8480
8862
  },
8481
8863
  "example": {
@@ -8487,102 +8869,45 @@
8487
8869
  }
8488
8870
  },
8489
8871
  "ExternalCatalogJourneyRequest": {
8490
- "allOf": [
8491
- {
8492
- "$ref": "#/components/schemas/ExternalCatalogConfigurationRequest"
8493
- },
8494
- {
8495
- "type": "object",
8496
- "description": "The request payload for the external catalog service with a journey context.",
8497
- "properties": {
8498
- "origin": {
8499
- "type": "string",
8500
- "description": "The origin of the request.",
8501
- "enum": [
8502
- "journey"
8503
- ],
8504
- "example": "journey"
8505
- },
8506
- "context": {
8507
- "$ref": "#/components/schemas/JourneyContext"
8508
- }
8509
- },
8510
- "additionalProperties": false,
8511
- "required": [
8512
- "origin",
8513
- "context"
8872
+ "type": "object",
8873
+ "description": "The request payload for the external catalog service with a journey context.",
8874
+ "properties": {
8875
+ "origin": {
8876
+ "type": "string",
8877
+ "description": "The origin of the request.",
8878
+ "enum": [
8879
+ "journey"
8514
8880
  ],
8515
- "example": {
8516
- "origin": "journey",
8517
- "context": {
8518
- "journey_id": "8d0a2235-97ce-42d0-88a3-e374634ca44e",
8519
- "entity_id": "9e1b3346-a8df-53e1-99b4-f485745db55f",
8520
- "journey_name": "Product Selection Journey",
8521
- "journey_tags": [
8522
- "electricity",
8523
- "residential"
8524
- ],
8525
- "journey_url_params": {
8526
- "utm_source": "google",
8527
- "utm_campaign": "spring2024"
8528
- },
8529
- "current_step_name": "Product Selection",
8530
- "current_block_name": "Energy Products",
8531
- "steps_data": [
8532
- {
8533
- "step_name": "Address Information",
8534
- "step_index": 0,
8535
- "blocks": {
8536
- "Adresse": {
8537
- "countryCode": "DE",
8538
- "city": "Koblenz",
8539
- "zipCode": "56068",
8540
- "streetName": "Am Alten Hospital",
8541
- "houseNumber": "123"
8542
- }
8543
- }
8544
- }
8545
- ]
8546
- }
8547
- }
8881
+ "example": "journey"
8882
+ },
8883
+ "context": {
8884
+ "$ref": "#/components/schemas/JourneyContext"
8548
8885
  }
8886
+ },
8887
+ "required": [
8888
+ "origin",
8889
+ "context"
8549
8890
  ]
8550
8891
  },
8551
8892
  "ExternalCatalogCustomRequest": {
8552
- "allOf": [
8553
- {
8554
- "$ref": "#/components/schemas/ExternalCatalogConfigurationRequest"
8555
- },
8556
- {
8557
- "type": "object",
8558
- "description": "The request payload for the external catalog service with a custom context. E.g. for requests from the Portal.",
8559
- "properties": {
8560
- "origin": {
8561
- "type": "string",
8562
- "description": "The origin of the request.",
8563
- "enum": [
8564
- "custom"
8565
- ],
8566
- "example": "custom"
8567
- },
8568
- "context": {
8569
- "$ref": "#/components/schemas/CustomContext"
8570
- }
8571
- },
8572
- "additionalProperties": false,
8573
- "required": [
8574
- "origin",
8575
- "context"
8893
+ "type": "object",
8894
+ "description": "The request payload for the external catalog service with a custom context. E.g. for requests from the Portal.",
8895
+ "properties": {
8896
+ "origin": {
8897
+ "type": "string",
8898
+ "description": "The origin of the request.",
8899
+ "enum": [
8900
+ "custom"
8576
8901
  ],
8577
- "example": {
8578
- "origin": "custom",
8579
- "context": {
8580
- "user_id": "user-12345",
8581
- "session_id": "session-67890",
8582
- "custom_context_key": "custom_context_value"
8583
- }
8584
- }
8902
+ "example": "custom"
8903
+ },
8904
+ "context": {
8905
+ "$ref": "#/components/schemas/CustomContext"
8585
8906
  }
8907
+ },
8908
+ "required": [
8909
+ "origin",
8910
+ "context"
8586
8911
  ]
8587
8912
  },
8588
8913
  "CustomContext": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epilot/pricing-client",
3
- "version": "3.51.3",
3
+ "version": "3.51.4",
4
4
  "description": "Client for epilot Pricing APIs",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",