@poweredbysous/storefront-all-sdk 4.13.1 → 4.14.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/index.d.cts CHANGED
@@ -5933,6 +5933,28 @@ interface paths {
5933
5933
  patch?: never;
5934
5934
  trace?: never;
5935
5935
  };
5936
+ "/api/v1/products/{id}/orderable-dates/": {
5937
+ parameters: {
5938
+ query?: never;
5939
+ header?: never;
5940
+ path?: never;
5941
+ cookie?: never;
5942
+ };
5943
+ /**
5944
+ * @description The dates this product can be ordered for, within the location's
5945
+ * pre-order horizon, as the cart's ``fulfilment-dates`` lists them for
5946
+ * a basket holding only this product's line, so the storefront can tell
5947
+ * a customer when a product it hides for their date is available.
5948
+ */
5949
+ get: operations["products_orderable_dates_retrieve"];
5950
+ put?: never;
5951
+ post?: never;
5952
+ delete?: never;
5953
+ options?: never;
5954
+ head?: never;
5955
+ patch?: never;
5956
+ trace?: never;
5957
+ };
5936
5958
  "/api/v1/products/{id}/suggestions/": {
5937
5959
  parameters: {
5938
5960
  query?: never;
@@ -7018,6 +7040,11 @@ interface components {
7018
7040
  fulfillment_type?: string;
7019
7041
  /** Format: date */
7020
7042
  fulfillment_date?: string;
7043
+ /**
7044
+ * Format: date
7045
+ * @description The customer's chosen handover date. The product is refused when its own dates (weekly days, included and excluded dates, order-until) do not accept it; the line is not dated by it.
7046
+ */
7047
+ handover_date?: string;
7021
7048
  /** @default */
7022
7049
  fulfillment_time_slot: string;
7023
7050
  options?: components["schemas"]["OptionInput"][];
@@ -7694,6 +7721,7 @@ interface components {
7694
7721
  [key: string]: unknown;
7695
7722
  } | null;
7696
7723
  readonly note: string;
7724
+ readonly order_dates: components["schemas"]["CartLineOrderDates"] | null;
7697
7725
  };
7698
7726
  CartLineItemOption: {
7699
7727
  option_id: number;
@@ -7749,6 +7777,20 @@ interface components {
7749
7777
  /** @description 'product' or 'modifier' */
7750
7778
  source: string;
7751
7779
  };
7780
+ /**
7781
+ * @description The product's own dates. An excluded date closes it, an included date
7782
+ * opens it on a day ``weekly_days`` does not cover, and ``order_until`` closes
7783
+ * it once passed. Checkout refuses a handover date outside them with
7784
+ * ``PRODUCT_NOT_ORDERABLE_FOR_DATE``.
7785
+ */
7786
+ CartLineOrderDates: {
7787
+ /** @description Lower-case weekday names, or null to follow the store's schedule. */
7788
+ weekly_days: string[] | null;
7789
+ included_dates: string[];
7790
+ excluded_dates: string[];
7791
+ /** Format: date */
7792
+ order_until: string | null;
7793
+ };
7752
7794
  /**
7753
7795
  * @description A codeless discount the cart holds products for but does not get yet.
7754
7796
  *
@@ -10861,6 +10903,19 @@ interface components {
10861
10903
  /** Format: date-time */
10862
10904
  readonly updated_at: string;
10863
10905
  };
10906
+ /**
10907
+ * @description The dates one product can be ordered for, within the location's
10908
+ * pre-order horizon (``ProductViewSet.orderable_dates``).
10909
+ */
10910
+ ProductFulfilmentDates: {
10911
+ dates: string[];
10912
+ reason: (components["schemas"]["ProductFulfilmentDatesReasonEnum"] | components["schemas"]["NullEnum"]) | null;
10913
+ };
10914
+ /**
10915
+ * @description * `no_dates` - no_dates
10916
+ * @enum {string}
10917
+ */
10918
+ ProductFulfilmentDatesReasonEnum: "no_dates";
10864
10919
  ProductImage: {
10865
10920
  readonly id: number;
10866
10921
  /** Format: uri */
@@ -39053,6 +39108,8 @@ interface operations {
39053
39108
  query?: {
39054
39109
  /** @description Delivery destination country as ISO 3166-1 alpha-2 (e.g. NL, BE), used with latitude and longitude. A nationwide carrier that declares per-country service areas only offers its products once the country is known. Case-insensitive; any other value is treated as no country. */
39055
39110
  country?: string;
39111
+ /** @description The pickup or delivery date the customer has chosen (YYYY-MM-DD). Lists only the products that can be ordered today for that date by their own dates: weekly days, included and excluded dates, and order-until. Whether the store is open that day is the time-slots endpoint's answer, not this filter's. An unreadable value is ignored. */
39112
+ handover_date?: string;
39056
39113
  /** @description Sort order for products. Use '-popularity' for most popular first. */
39057
39114
  ordering?: "-popularity" | "-position" | "position";
39058
39115
  /** @description A page number within the paginated result set. */
@@ -39289,6 +39346,91 @@ interface operations {
39289
39346
  };
39290
39347
  };
39291
39348
  };
39349
+ products_orderable_dates_retrieve: {
39350
+ parameters: {
39351
+ query: {
39352
+ /** @description For type=delivery: the customer's delivery types in order of preference, comma-separated (local_delivery, nationwide_delivery). The product's schedule follows the first of them it offers, the type its cart line would get; without one it follows the delivery types the product offers. */
39353
+ fulfillment_types?: string;
39354
+ /** @description Pickup location id, as the pickup time-slots endpoint takes it. Defaults to the store's active pickup location. */
39355
+ location?: number;
39356
+ /** @description Fulfilment type the dates are for. */
39357
+ type: "delivery" | "pickup";
39358
+ /** @description Language override for translated content. The primary mechanism is the `Accept-Language` header; this query parameter is an override for widget embedding where merchants cannot control browser headers. Defaults to `en`. */
39359
+ lang?: string;
39360
+ };
39361
+ header?: never;
39362
+ path: {
39363
+ /** @description A unique integer value identifying this product. */
39364
+ id: number;
39365
+ };
39366
+ cookie?: never;
39367
+ };
39368
+ requestBody?: never;
39369
+ responses: {
39370
+ 200: {
39371
+ headers: {
39372
+ [name: string]: unknown;
39373
+ };
39374
+ content: {
39375
+ "application/json": components["schemas"]["ProductFulfilmentDates"];
39376
+ };
39377
+ };
39378
+ /** @description Possible error codes: `VALIDATION_ERROR`. Retryable: no. Possible error codes include `VALIDATION_ERROR`. Use `x-error-codes` for machine-readable retryability metadata. */
39379
+ 400: {
39380
+ headers: {
39381
+ [name: string]: unknown;
39382
+ };
39383
+ content: {
39384
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39385
+ };
39386
+ };
39387
+ /** @description Possible error codes include `UNAUTHORIZED`. Use `x-error-codes` for machine-readable retryability metadata. */
39388
+ 401: {
39389
+ headers: {
39390
+ [name: string]: unknown;
39391
+ };
39392
+ content: {
39393
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39394
+ };
39395
+ };
39396
+ /** @description Possible error codes include `FORBIDDEN`. Use `x-error-codes` for machine-readable retryability metadata. */
39397
+ 403: {
39398
+ headers: {
39399
+ [name: string]: unknown;
39400
+ };
39401
+ content: {
39402
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39403
+ };
39404
+ };
39405
+ /** @description Possible error codes: `NOT_FOUND`, `LOCATION_NOT_FOUND`. Retryable: no. Possible error codes include `NOT_FOUND`. Use `x-error-codes` for machine-readable retryability metadata. Possible error codes include `PRODUCT_NOT_FOUND`. Use `x-error-codes` for machine-readable retryability metadata. Possible error codes include `LOCATION_NOT_FOUND`. Use `x-error-codes` for machine-readable retryability metadata. */
39406
+ 404: {
39407
+ headers: {
39408
+ [name: string]: unknown;
39409
+ };
39410
+ content: {
39411
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39412
+ };
39413
+ };
39414
+ /** @description Possible error codes include `RATE_LIMITED`. Use `x-error-codes` for machine-readable retryability metadata. */
39415
+ 429: {
39416
+ headers: {
39417
+ [name: string]: unknown;
39418
+ };
39419
+ content: {
39420
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39421
+ };
39422
+ };
39423
+ /** @description Possible error codes include `INTERNAL_ERROR`. Use `x-error-codes` for machine-readable retryability metadata. */
39424
+ 500: {
39425
+ headers: {
39426
+ [name: string]: unknown;
39427
+ };
39428
+ content: {
39429
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39430
+ };
39431
+ };
39432
+ };
39433
+ };
39292
39434
  products_suggestions_list: {
39293
39435
  parameters: {
39294
39436
  query?: {
package/dist/index.d.ts CHANGED
@@ -5933,6 +5933,28 @@ interface paths {
5933
5933
  patch?: never;
5934
5934
  trace?: never;
5935
5935
  };
5936
+ "/api/v1/products/{id}/orderable-dates/": {
5937
+ parameters: {
5938
+ query?: never;
5939
+ header?: never;
5940
+ path?: never;
5941
+ cookie?: never;
5942
+ };
5943
+ /**
5944
+ * @description The dates this product can be ordered for, within the location's
5945
+ * pre-order horizon, as the cart's ``fulfilment-dates`` lists them for
5946
+ * a basket holding only this product's line, so the storefront can tell
5947
+ * a customer when a product it hides for their date is available.
5948
+ */
5949
+ get: operations["products_orderable_dates_retrieve"];
5950
+ put?: never;
5951
+ post?: never;
5952
+ delete?: never;
5953
+ options?: never;
5954
+ head?: never;
5955
+ patch?: never;
5956
+ trace?: never;
5957
+ };
5936
5958
  "/api/v1/products/{id}/suggestions/": {
5937
5959
  parameters: {
5938
5960
  query?: never;
@@ -7018,6 +7040,11 @@ interface components {
7018
7040
  fulfillment_type?: string;
7019
7041
  /** Format: date */
7020
7042
  fulfillment_date?: string;
7043
+ /**
7044
+ * Format: date
7045
+ * @description The customer's chosen handover date. The product is refused when its own dates (weekly days, included and excluded dates, order-until) do not accept it; the line is not dated by it.
7046
+ */
7047
+ handover_date?: string;
7021
7048
  /** @default */
7022
7049
  fulfillment_time_slot: string;
7023
7050
  options?: components["schemas"]["OptionInput"][];
@@ -7694,6 +7721,7 @@ interface components {
7694
7721
  [key: string]: unknown;
7695
7722
  } | null;
7696
7723
  readonly note: string;
7724
+ readonly order_dates: components["schemas"]["CartLineOrderDates"] | null;
7697
7725
  };
7698
7726
  CartLineItemOption: {
7699
7727
  option_id: number;
@@ -7749,6 +7777,20 @@ interface components {
7749
7777
  /** @description 'product' or 'modifier' */
7750
7778
  source: string;
7751
7779
  };
7780
+ /**
7781
+ * @description The product's own dates. An excluded date closes it, an included date
7782
+ * opens it on a day ``weekly_days`` does not cover, and ``order_until`` closes
7783
+ * it once passed. Checkout refuses a handover date outside them with
7784
+ * ``PRODUCT_NOT_ORDERABLE_FOR_DATE``.
7785
+ */
7786
+ CartLineOrderDates: {
7787
+ /** @description Lower-case weekday names, or null to follow the store's schedule. */
7788
+ weekly_days: string[] | null;
7789
+ included_dates: string[];
7790
+ excluded_dates: string[];
7791
+ /** Format: date */
7792
+ order_until: string | null;
7793
+ };
7752
7794
  /**
7753
7795
  * @description A codeless discount the cart holds products for but does not get yet.
7754
7796
  *
@@ -10861,6 +10903,19 @@ interface components {
10861
10903
  /** Format: date-time */
10862
10904
  readonly updated_at: string;
10863
10905
  };
10906
+ /**
10907
+ * @description The dates one product can be ordered for, within the location's
10908
+ * pre-order horizon (``ProductViewSet.orderable_dates``).
10909
+ */
10910
+ ProductFulfilmentDates: {
10911
+ dates: string[];
10912
+ reason: (components["schemas"]["ProductFulfilmentDatesReasonEnum"] | components["schemas"]["NullEnum"]) | null;
10913
+ };
10914
+ /**
10915
+ * @description * `no_dates` - no_dates
10916
+ * @enum {string}
10917
+ */
10918
+ ProductFulfilmentDatesReasonEnum: "no_dates";
10864
10919
  ProductImage: {
10865
10920
  readonly id: number;
10866
10921
  /** Format: uri */
@@ -39053,6 +39108,8 @@ interface operations {
39053
39108
  query?: {
39054
39109
  /** @description Delivery destination country as ISO 3166-1 alpha-2 (e.g. NL, BE), used with latitude and longitude. A nationwide carrier that declares per-country service areas only offers its products once the country is known. Case-insensitive; any other value is treated as no country. */
39055
39110
  country?: string;
39111
+ /** @description The pickup or delivery date the customer has chosen (YYYY-MM-DD). Lists only the products that can be ordered today for that date by their own dates: weekly days, included and excluded dates, and order-until. Whether the store is open that day is the time-slots endpoint's answer, not this filter's. An unreadable value is ignored. */
39112
+ handover_date?: string;
39056
39113
  /** @description Sort order for products. Use '-popularity' for most popular first. */
39057
39114
  ordering?: "-popularity" | "-position" | "position";
39058
39115
  /** @description A page number within the paginated result set. */
@@ -39289,6 +39346,91 @@ interface operations {
39289
39346
  };
39290
39347
  };
39291
39348
  };
39349
+ products_orderable_dates_retrieve: {
39350
+ parameters: {
39351
+ query: {
39352
+ /** @description For type=delivery: the customer's delivery types in order of preference, comma-separated (local_delivery, nationwide_delivery). The product's schedule follows the first of them it offers, the type its cart line would get; without one it follows the delivery types the product offers. */
39353
+ fulfillment_types?: string;
39354
+ /** @description Pickup location id, as the pickup time-slots endpoint takes it. Defaults to the store's active pickup location. */
39355
+ location?: number;
39356
+ /** @description Fulfilment type the dates are for. */
39357
+ type: "delivery" | "pickup";
39358
+ /** @description Language override for translated content. The primary mechanism is the `Accept-Language` header; this query parameter is an override for widget embedding where merchants cannot control browser headers. Defaults to `en`. */
39359
+ lang?: string;
39360
+ };
39361
+ header?: never;
39362
+ path: {
39363
+ /** @description A unique integer value identifying this product. */
39364
+ id: number;
39365
+ };
39366
+ cookie?: never;
39367
+ };
39368
+ requestBody?: never;
39369
+ responses: {
39370
+ 200: {
39371
+ headers: {
39372
+ [name: string]: unknown;
39373
+ };
39374
+ content: {
39375
+ "application/json": components["schemas"]["ProductFulfilmentDates"];
39376
+ };
39377
+ };
39378
+ /** @description Possible error codes: `VALIDATION_ERROR`. Retryable: no. Possible error codes include `VALIDATION_ERROR`. Use `x-error-codes` for machine-readable retryability metadata. */
39379
+ 400: {
39380
+ headers: {
39381
+ [name: string]: unknown;
39382
+ };
39383
+ content: {
39384
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39385
+ };
39386
+ };
39387
+ /** @description Possible error codes include `UNAUTHORIZED`. Use `x-error-codes` for machine-readable retryability metadata. */
39388
+ 401: {
39389
+ headers: {
39390
+ [name: string]: unknown;
39391
+ };
39392
+ content: {
39393
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39394
+ };
39395
+ };
39396
+ /** @description Possible error codes include `FORBIDDEN`. Use `x-error-codes` for machine-readable retryability metadata. */
39397
+ 403: {
39398
+ headers: {
39399
+ [name: string]: unknown;
39400
+ };
39401
+ content: {
39402
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39403
+ };
39404
+ };
39405
+ /** @description Possible error codes: `NOT_FOUND`, `LOCATION_NOT_FOUND`. Retryable: no. Possible error codes include `NOT_FOUND`. Use `x-error-codes` for machine-readable retryability metadata. Possible error codes include `PRODUCT_NOT_FOUND`. Use `x-error-codes` for machine-readable retryability metadata. Possible error codes include `LOCATION_NOT_FOUND`. Use `x-error-codes` for machine-readable retryability metadata. */
39406
+ 404: {
39407
+ headers: {
39408
+ [name: string]: unknown;
39409
+ };
39410
+ content: {
39411
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39412
+ };
39413
+ };
39414
+ /** @description Possible error codes include `RATE_LIMITED`. Use `x-error-codes` for machine-readable retryability metadata. */
39415
+ 429: {
39416
+ headers: {
39417
+ [name: string]: unknown;
39418
+ };
39419
+ content: {
39420
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39421
+ };
39422
+ };
39423
+ /** @description Possible error codes include `INTERNAL_ERROR`. Use `x-error-codes` for machine-readable retryability metadata. */
39424
+ 500: {
39425
+ headers: {
39426
+ [name: string]: unknown;
39427
+ };
39428
+ content: {
39429
+ "application/json": components["schemas"]["APIErrorEnvelope"];
39430
+ };
39431
+ };
39432
+ };
39433
+ };
39292
39434
  products_suggestions_list: {
39293
39435
  parameters: {
39294
39436
  query?: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@poweredbysous/storefront-all-sdk",
3
- "version": "4.13.1",
3
+ "version": "4.14.0",
4
4
  "description": "Type-safe TypeScript SDK for all SOUS Storefront Backend endpoints",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,