@zippendo/sdk 1.2.3 → 1.2.5
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/apis/OrderChannelsApi.d.ts +195 -0
- package/dist/apis/OrderChannelsApi.js +496 -0
- package/dist/apis/index.d.ts +1 -0
- package/dist/apis/index.js +1 -0
- package/dist/esm/apis/OrderChannelsApi.d.ts +195 -0
- package/dist/esm/apis/OrderChannelsApi.js +492 -0
- package/dist/esm/apis/index.d.ts +1 -0
- package/dist/esm/apis/index.js +1 -0
- package/dist/esm/models/BatchSendShipments200ResponseResultsInner.d.ts +1 -0
- package/dist/esm/models/BatchSendShipments200ResponseResultsInner.js +1 -0
- package/dist/esm/models/CreateOrderChannelRequest.d.ts +65 -0
- package/dist/esm/models/CreateOrderChannelRequest.js +61 -0
- package/dist/esm/models/CreateOrderChannelRequestSettings.d.ts +105 -0
- package/dist/esm/models/CreateOrderChannelRequestSettings.js +66 -0
- package/dist/esm/models/CreateOrderChannelRequestSettingsShippingMethodMappingsInner.d.ts +52 -0
- package/dist/esm/models/CreateOrderChannelRequestSettingsShippingMethodMappingsInner.js +56 -0
- package/dist/esm/models/CreateOrderChannelWebhookSecret201Response.d.ts +44 -0
- package/dist/esm/models/CreateOrderChannelWebhookSecret201Response.js +51 -0
- package/dist/esm/models/CreateOrderRequest.d.ts +12 -0
- package/dist/esm/models/CreateOrderRequest.js +4 -0
- package/dist/esm/models/GetOrderChannelWebhookStatus200Response.d.ts +45 -0
- package/dist/esm/models/GetOrderChannelWebhookStatus200Response.js +52 -0
- package/dist/esm/models/GetOrderChannelWebhookStatus200ResponseWebhooksInner.d.ts +62 -0
- package/dist/esm/models/GetOrderChannelWebhookStatus200ResponseWebhooksInner.js +59 -0
- package/dist/esm/models/ListApiTokens401Response.d.ts +1 -0
- package/dist/esm/models/ListApiTokens401Response.js +1 -0
- package/dist/esm/models/ListAvailableCarriers200ResponseInner.d.ts +12 -0
- package/dist/esm/models/ListAvailableCarriers200ResponseInner.js +4 -0
- package/dist/esm/models/ListCarriers200ResponseDataInner.d.ts +12 -0
- package/dist/esm/models/ListCarriers200ResponseDataInner.js +4 -0
- package/dist/esm/models/ListOrderChannels200Response.d.ts +57 -0
- package/dist/esm/models/ListOrderChannels200Response.js +60 -0
- package/dist/esm/models/ListOrderChannels200ResponseDataInner.d.ts +121 -0
- package/dist/esm/models/ListOrderChannels200ResponseDataInner.js +97 -0
- package/dist/esm/models/ListOrderChannels200ResponseDataInnerSettings.d.ts +129 -0
- package/dist/esm/models/ListOrderChannels200ResponseDataInnerSettings.js +86 -0
- package/dist/esm/models/ListOrderChannels200ResponseDataInnerSettingsShippingMethodMappingsInner.d.ts +52 -0
- package/dist/esm/models/ListOrderChannels200ResponseDataInnerSettingsShippingMethodMappingsInner.js +56 -0
- package/dist/esm/models/ListOrders200ResponseDataInnerOrderChannel.d.ts +1 -0
- package/dist/esm/models/ListOrders200ResponseDataInnerOrderChannel.js +2 -1
- package/dist/esm/models/RevokeOrderChannelWebhookSecret200Response.d.ts +32 -0
- package/dist/esm/models/RevokeOrderChannelWebhookSecret200Response.js +43 -0
- package/dist/esm/models/SendShipment422Response.d.ts +1 -0
- package/dist/esm/models/SendShipment422Response.js +1 -0
- package/dist/esm/models/UpdateOrderChannelRequest.d.ts +65 -0
- package/dist/esm/models/UpdateOrderChannelRequest.js +52 -0
- package/dist/esm/models/UpdateOrderChannelRequestSettings.d.ts +105 -0
- package/dist/esm/models/UpdateOrderChannelRequestSettings.js +66 -0
- package/dist/esm/models/index.d.ts +13 -0
- package/dist/esm/models/index.js +13 -0
- package/dist/models/BatchSendShipments200ResponseResultsInner.d.ts +1 -0
- package/dist/models/BatchSendShipments200ResponseResultsInner.js +1 -0
- package/dist/models/CreateOrderChannelRequest.d.ts +65 -0
- package/dist/models/CreateOrderChannelRequest.js +69 -0
- package/dist/models/CreateOrderChannelRequestSettings.d.ts +105 -0
- package/dist/models/CreateOrderChannelRequestSettings.js +73 -0
- package/dist/models/CreateOrderChannelRequestSettingsShippingMethodMappingsInner.d.ts +52 -0
- package/dist/models/CreateOrderChannelRequestSettingsShippingMethodMappingsInner.js +64 -0
- package/dist/models/CreateOrderChannelWebhookSecret201Response.d.ts +44 -0
- package/dist/models/CreateOrderChannelWebhookSecret201Response.js +58 -0
- package/dist/models/CreateOrderRequest.d.ts +12 -0
- package/dist/models/CreateOrderRequest.js +4 -0
- package/dist/models/GetOrderChannelWebhookStatus200Response.d.ts +45 -0
- package/dist/models/GetOrderChannelWebhookStatus200Response.js +59 -0
- package/dist/models/GetOrderChannelWebhookStatus200ResponseWebhooksInner.d.ts +62 -0
- package/dist/models/GetOrderChannelWebhookStatus200ResponseWebhooksInner.js +66 -0
- package/dist/models/ListApiTokens401Response.d.ts +1 -0
- package/dist/models/ListApiTokens401Response.js +1 -0
- package/dist/models/ListAvailableCarriers200ResponseInner.d.ts +12 -0
- package/dist/models/ListAvailableCarriers200ResponseInner.js +4 -0
- package/dist/models/ListCarriers200ResponseDataInner.d.ts +12 -0
- package/dist/models/ListCarriers200ResponseDataInner.js +4 -0
- package/dist/models/ListOrderChannels200Response.d.ts +57 -0
- package/dist/models/ListOrderChannels200Response.js +67 -0
- package/dist/models/ListOrderChannels200ResponseDataInner.d.ts +121 -0
- package/dist/models/ListOrderChannels200ResponseDataInner.js +105 -0
- package/dist/models/ListOrderChannels200ResponseDataInnerSettings.d.ts +129 -0
- package/dist/models/ListOrderChannels200ResponseDataInnerSettings.js +93 -0
- package/dist/models/ListOrderChannels200ResponseDataInnerSettingsShippingMethodMappingsInner.d.ts +52 -0
- package/dist/models/ListOrderChannels200ResponseDataInnerSettingsShippingMethodMappingsInner.js +64 -0
- package/dist/models/ListOrders200ResponseDataInnerOrderChannel.d.ts +1 -0
- package/dist/models/ListOrders200ResponseDataInnerOrderChannel.js +2 -1
- package/dist/models/RevokeOrderChannelWebhookSecret200Response.d.ts +32 -0
- package/dist/models/RevokeOrderChannelWebhookSecret200Response.js +50 -0
- package/dist/models/SendShipment422Response.d.ts +1 -0
- package/dist/models/SendShipment422Response.js +1 -0
- package/dist/models/UpdateOrderChannelRequest.d.ts +65 -0
- package/dist/models/UpdateOrderChannelRequest.js +59 -0
- package/dist/models/UpdateOrderChannelRequestSettings.d.ts +105 -0
- package/dist/models/UpdateOrderChannelRequestSettings.js +73 -0
- package/dist/models/index.d.ts +13 -0
- package/dist/models/index.js +13 -0
- package/docs/CreateOrderChannelRequest.md +42 -0
- package/docs/CreateOrderChannelRequestSettings.md +58 -0
- package/docs/CreateOrderChannelRequestSettingsShippingMethodMappingsInner.md +38 -0
- package/docs/CreateOrderChannelWebhookSecret201Response.md +38 -0
- package/docs/CreateOrderRequest.md +4 -0
- package/docs/GetOrderChannelWebhookStatus200Response.md +38 -0
- package/docs/GetOrderChannelWebhookStatus200ResponseWebhooksInner.md +44 -0
- package/docs/ListAvailableCarriers200ResponseInner.md +4 -0
- package/docs/ListCarriers200ResponseDataInner.md +4 -0
- package/docs/ListOrderChannels200Response.md +42 -0
- package/docs/ListOrderChannels200ResponseDataInner.md +60 -0
- package/docs/ListOrderChannels200ResponseDataInnerSettings.md +67 -0
- package/docs/ListOrderChannels200ResponseDataInnerSettingsShippingMethodMappingsInner.md +38 -0
- package/docs/OrderChannelsApi.md +650 -0
- package/docs/OrdersApi.md +1 -0
- package/docs/RevokeOrderChannelWebhookSecret200Response.md +34 -0
- package/docs/UpdateOrderChannelRequest.md +44 -0
- package/docs/UpdateOrderChannelRequestSettings.md +59 -0
- package/package.json +1 -1
- package/src/apis/OrderChannelsApi.ts +670 -0
- package/src/apis/index.ts +1 -0
- package/src/models/BatchSendShipments200ResponseResultsInner.ts +1 -0
- package/src/models/CreateOrderChannelRequest.ts +118 -0
- package/src/models/CreateOrderChannelRequestSettings.ts +169 -0
- package/src/models/CreateOrderChannelRequestSettingsShippingMethodMappingsInner.ts +94 -0
- package/src/models/CreateOrderChannelWebhookSecret201Response.ts +84 -0
- package/src/models/CreateOrderRequest.ts +16 -0
- package/src/models/GetOrderChannelWebhookStatus200Response.ts +92 -0
- package/src/models/GetOrderChannelWebhookStatus200ResponseWebhooksInner.ts +109 -0
- package/src/models/ListApiTokens401Response.ts +1 -0
- package/src/models/ListAvailableCarriers200ResponseInner.ts +16 -0
- package/src/models/ListCarriers200ResponseDataInner.ts +16 -0
- package/src/models/ListOrderChannels200Response.ts +110 -0
- package/src/models/ListOrderChannels200ResponseDataInner.ts +200 -0
- package/src/models/ListOrderChannels200ResponseDataInnerSettings.ts +207 -0
- package/src/models/ListOrderChannels200ResponseDataInnerSettingsShippingMethodMappingsInner.ts +94 -0
- package/src/models/ListOrders200ResponseDataInnerOrderChannel.ts +2 -1
- package/src/models/RevokeOrderChannelWebhookSecret200Response.ts +66 -0
- package/src/models/SendShipment422Response.ts +1 -0
- package/src/models/UpdateOrderChannelRequest.ts +113 -0
- package/src/models/UpdateOrderChannelRequestSettings.ts +169 -0
- package/src/models/index.ts +13 -0
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Zippendo Public API
|
|
6
|
+
* Public API documentation for Zippendo. Authenticate using your API token (Bearer token prefixed with zipp_). **Brands (sub-accounts).** An organization can be split into brands, each keeping its own orders, shipments and configuration separate. There are two ways to scope requests to one brand, and NEITHER changes any request body: 1. **Bind the token.** Create an API token with a `brandId` and every request it makes is confined to that brand — reads filtered, writes stamped. This is the recommended way to give a single brand\'s team its own credential. 2. **Send the `X-Zippendo-Brand` header.** An organization-wide token can scope an individual request by sending the brand\'s id or slug in this header. Most SDKs let you set it once on the client so every call inherits it. A brand-bound token that receives an `X-Zippendo-Brand` header naming a different brand is rejected with `403 BRAND_ACCESS_DENIED` — the binding is never widened. Omit both and requests cover the whole organization, which is the behaviour of every existing token. Records that belong to no brand carry `brandId: null`. Configuration (carriers, shipping rules, addresses) with a null brand is organization-wide and remains visible inside every brand; orders and shipments with a null brand are only visible organization-wide. List endpoints additionally take a `?brandScope=own|shared|both` parameter to narrow further within whichever brand context already applies. `own` returns only rows assigned to that brand, and requires a brand context — a brand-bound token, a resolved brand session, or the `X-Zippendo-Brand` header above — otherwise `400`. `shared` returns only the organization-wide rows (equivalent to filtering `brandId=none`). The default, `both`, keeps the existing behaviour: a brand context sees its own rows plus the organization-wide ones. Set `X-Zippendo-Brand-Scope` as a client default to apply the same choice to every request instead of repeating the query parameter on each call — an explicit `brandScope` query parameter always wins over the header, and a blank header value is ignored. Brands themselves are managed under the **Brands** tag. Retiring a brand is done with `POST /orgs/{orgId}/brands/{brandId}/archive` — permanent deletion is a dashboard-only action, since it is refused while any order, shipment, member or token still references the brand. Brands require a plan that includes them; creating one beyond your plan\'s limit returns `403`.
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
* Contact: support@zippendo.com
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfCreateOrderChannelWebhookSecret201Response = instanceOfCreateOrderChannelWebhookSecret201Response;
|
|
17
|
+
exports.CreateOrderChannelWebhookSecret201ResponseFromJSON = CreateOrderChannelWebhookSecret201ResponseFromJSON;
|
|
18
|
+
exports.CreateOrderChannelWebhookSecret201ResponseFromJSONTyped = CreateOrderChannelWebhookSecret201ResponseFromJSONTyped;
|
|
19
|
+
exports.CreateOrderChannelWebhookSecret201ResponseToJSON = CreateOrderChannelWebhookSecret201ResponseToJSON;
|
|
20
|
+
exports.CreateOrderChannelWebhookSecret201ResponseToJSONTyped = CreateOrderChannelWebhookSecret201ResponseToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the CreateOrderChannelWebhookSecret201Response interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfCreateOrderChannelWebhookSecret201Response(value) {
|
|
25
|
+
if (!('secret' in value) || value['secret'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('webhookUrl' in value) || value['webhookUrl'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
return true;
|
|
32
|
+
}
|
|
33
|
+
function CreateOrderChannelWebhookSecret201ResponseFromJSON(json) {
|
|
34
|
+
return CreateOrderChannelWebhookSecret201ResponseFromJSONTyped(json, false);
|
|
35
|
+
}
|
|
36
|
+
function CreateOrderChannelWebhookSecret201ResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
37
|
+
if (json == null) {
|
|
38
|
+
return json;
|
|
39
|
+
}
|
|
40
|
+
return {
|
|
41
|
+
'secret': json['secret'],
|
|
42
|
+
'webhookUrl': json['webhookUrl'],
|
|
43
|
+
'createdAt': (new Date(json['createdAt'])),
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
function CreateOrderChannelWebhookSecret201ResponseToJSON(json) {
|
|
47
|
+
return CreateOrderChannelWebhookSecret201ResponseToJSONTyped(json, false);
|
|
48
|
+
}
|
|
49
|
+
function CreateOrderChannelWebhookSecret201ResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
50
|
+
if (value == null) {
|
|
51
|
+
return value;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
'secret': value['secret'],
|
|
55
|
+
'webhookUrl': value['webhookUrl'],
|
|
56
|
+
'createdAt': value['createdAt'].toISOString(),
|
|
57
|
+
};
|
|
58
|
+
}
|
|
@@ -83,6 +83,18 @@ export interface CreateOrderRequest {
|
|
|
83
83
|
* @memberof CreateOrderRequest
|
|
84
84
|
*/
|
|
85
85
|
notes?: string | null;
|
|
86
|
+
/**
|
|
87
|
+
* Shipping rule to ship this order with. When set, a shipment is created immediately (and dispatched if the channel has autoShipOnCreate enabled).
|
|
88
|
+
* @type {string}
|
|
89
|
+
* @memberof CreateOrderRequest
|
|
90
|
+
*/
|
|
91
|
+
shippingRuleId?: string | null;
|
|
92
|
+
/**
|
|
93
|
+
* Shipping-method title from the source checkout; matched against the order channel's shipping-method mappings to pick a shipping rule.
|
|
94
|
+
* @type {string}
|
|
95
|
+
* @memberof CreateOrderRequest
|
|
96
|
+
*/
|
|
97
|
+
shippingMethodTitle?: string | null;
|
|
86
98
|
/**
|
|
87
99
|
* Raw platform-specific payload for reference.
|
|
88
100
|
* @type {{ [key: string]: any; }}
|
|
@@ -51,6 +51,8 @@ function CreateOrderRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
51
51
|
'totalAmount': json['totalAmount'] === undefined ? undefined : json['totalAmount'] === null ? null : json['totalAmount'],
|
|
52
52
|
'currency': json['currency'] === undefined ? undefined : json['currency'] === null ? null : json['currency'],
|
|
53
53
|
'notes': json['notes'] === undefined ? undefined : json['notes'] === null ? null : json['notes'],
|
|
54
|
+
'shippingRuleId': json['shippingRuleId'] === undefined ? undefined : json['shippingRuleId'] === null ? null : json['shippingRuleId'],
|
|
55
|
+
'shippingMethodTitle': json['shippingMethodTitle'] === undefined ? undefined : json['shippingMethodTitle'] === null ? null : json['shippingMethodTitle'],
|
|
54
56
|
'externalData': json['externalData'] === undefined ? undefined : json['externalData'] === null ? null : json['externalData'],
|
|
55
57
|
};
|
|
56
58
|
}
|
|
@@ -73,6 +75,8 @@ function CreateOrderRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
73
75
|
'totalAmount': value['totalAmount'],
|
|
74
76
|
'currency': value['currency'],
|
|
75
77
|
'notes': value['notes'],
|
|
78
|
+
'shippingRuleId': value['shippingRuleId'],
|
|
79
|
+
'shippingMethodTitle': value['shippingMethodTitle'],
|
|
76
80
|
'externalData': value['externalData'],
|
|
77
81
|
};
|
|
78
82
|
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Zippendo Public API
|
|
3
|
+
* Public API documentation for Zippendo. Authenticate using your API token (Bearer token prefixed with zipp_). **Brands (sub-accounts).** An organization can be split into brands, each keeping its own orders, shipments and configuration separate. There are two ways to scope requests to one brand, and NEITHER changes any request body: 1. **Bind the token.** Create an API token with a `brandId` and every request it makes is confined to that brand — reads filtered, writes stamped. This is the recommended way to give a single brand\'s team its own credential. 2. **Send the `X-Zippendo-Brand` header.** An organization-wide token can scope an individual request by sending the brand\'s id or slug in this header. Most SDKs let you set it once on the client so every call inherits it. A brand-bound token that receives an `X-Zippendo-Brand` header naming a different brand is rejected with `403 BRAND_ACCESS_DENIED` — the binding is never widened. Omit both and requests cover the whole organization, which is the behaviour of every existing token. Records that belong to no brand carry `brandId: null`. Configuration (carriers, shipping rules, addresses) with a null brand is organization-wide and remains visible inside every brand; orders and shipments with a null brand are only visible organization-wide. List endpoints additionally take a `?brandScope=own|shared|both` parameter to narrow further within whichever brand context already applies. `own` returns only rows assigned to that brand, and requires a brand context — a brand-bound token, a resolved brand session, or the `X-Zippendo-Brand` header above — otherwise `400`. `shared` returns only the organization-wide rows (equivalent to filtering `brandId=none`). The default, `both`, keeps the existing behaviour: a brand context sees its own rows plus the organization-wide ones. Set `X-Zippendo-Brand-Scope` as a client default to apply the same choice to every request instead of repeating the query parameter on each call — an explicit `brandScope` query parameter always wins over the header, and a blank header value is ignored. Brands themselves are managed under the **Brands** tag. Retiring a brand is done with `POST /orgs/{orgId}/brands/{brandId}/archive` — permanent deletion is a dashboard-only action, since it is refused while any order, shipment, member or token still references the brand. Brands require a plan that includes them; creating one beyond your plan\'s limit returns `403`.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: support@zippendo.com
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { GetOrderChannelWebhookStatus200ResponseWebhooksInner } from './GetOrderChannelWebhookStatus200ResponseWebhooksInner';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface GetOrderChannelWebhookStatus200Response
|
|
17
|
+
*/
|
|
18
|
+
export interface GetOrderChannelWebhookStatus200Response {
|
|
19
|
+
/**
|
|
20
|
+
* Whether webhooks are enabled for the channel.
|
|
21
|
+
* @type {boolean}
|
|
22
|
+
* @memberof GetOrderChannelWebhookStatus200Response
|
|
23
|
+
*/
|
|
24
|
+
enabled: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* Expected callback URL for this channel.
|
|
27
|
+
* @type {string}
|
|
28
|
+
* @memberof GetOrderChannelWebhookStatus200Response
|
|
29
|
+
*/
|
|
30
|
+
webhookUrl: string;
|
|
31
|
+
/**
|
|
32
|
+
* Webhooks registered for this channel's callback URL.
|
|
33
|
+
* @type {Array<GetOrderChannelWebhookStatus200ResponseWebhooksInner>}
|
|
34
|
+
* @memberof GetOrderChannelWebhookStatus200Response
|
|
35
|
+
*/
|
|
36
|
+
webhooks: Array<GetOrderChannelWebhookStatus200ResponseWebhooksInner>;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Check if a given object implements the GetOrderChannelWebhookStatus200Response interface.
|
|
40
|
+
*/
|
|
41
|
+
export declare function instanceOfGetOrderChannelWebhookStatus200Response(value: object): value is GetOrderChannelWebhookStatus200Response;
|
|
42
|
+
export declare function GetOrderChannelWebhookStatus200ResponseFromJSON(json: any): GetOrderChannelWebhookStatus200Response;
|
|
43
|
+
export declare function GetOrderChannelWebhookStatus200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetOrderChannelWebhookStatus200Response;
|
|
44
|
+
export declare function GetOrderChannelWebhookStatus200ResponseToJSON(json: any): GetOrderChannelWebhookStatus200Response;
|
|
45
|
+
export declare function GetOrderChannelWebhookStatus200ResponseToJSONTyped(value?: GetOrderChannelWebhookStatus200Response | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Zippendo Public API
|
|
6
|
+
* Public API documentation for Zippendo. Authenticate using your API token (Bearer token prefixed with zipp_). **Brands (sub-accounts).** An organization can be split into brands, each keeping its own orders, shipments and configuration separate. There are two ways to scope requests to one brand, and NEITHER changes any request body: 1. **Bind the token.** Create an API token with a `brandId` and every request it makes is confined to that brand — reads filtered, writes stamped. This is the recommended way to give a single brand\'s team its own credential. 2. **Send the `X-Zippendo-Brand` header.** An organization-wide token can scope an individual request by sending the brand\'s id or slug in this header. Most SDKs let you set it once on the client so every call inherits it. A brand-bound token that receives an `X-Zippendo-Brand` header naming a different brand is rejected with `403 BRAND_ACCESS_DENIED` — the binding is never widened. Omit both and requests cover the whole organization, which is the behaviour of every existing token. Records that belong to no brand carry `brandId: null`. Configuration (carriers, shipping rules, addresses) with a null brand is organization-wide and remains visible inside every brand; orders and shipments with a null brand are only visible organization-wide. List endpoints additionally take a `?brandScope=own|shared|both` parameter to narrow further within whichever brand context already applies. `own` returns only rows assigned to that brand, and requires a brand context — a brand-bound token, a resolved brand session, or the `X-Zippendo-Brand` header above — otherwise `400`. `shared` returns only the organization-wide rows (equivalent to filtering `brandId=none`). The default, `both`, keeps the existing behaviour: a brand context sees its own rows plus the organization-wide ones. Set `X-Zippendo-Brand-Scope` as a client default to apply the same choice to every request instead of repeating the query parameter on each call — an explicit `brandScope` query parameter always wins over the header, and a blank header value is ignored. Brands themselves are managed under the **Brands** tag. Retiring a brand is done with `POST /orgs/{orgId}/brands/{brandId}/archive` — permanent deletion is a dashboard-only action, since it is refused while any order, shipment, member or token still references the brand. Brands require a plan that includes them; creating one beyond your plan\'s limit returns `403`.
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
* Contact: support@zippendo.com
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfGetOrderChannelWebhookStatus200Response = instanceOfGetOrderChannelWebhookStatus200Response;
|
|
17
|
+
exports.GetOrderChannelWebhookStatus200ResponseFromJSON = GetOrderChannelWebhookStatus200ResponseFromJSON;
|
|
18
|
+
exports.GetOrderChannelWebhookStatus200ResponseFromJSONTyped = GetOrderChannelWebhookStatus200ResponseFromJSONTyped;
|
|
19
|
+
exports.GetOrderChannelWebhookStatus200ResponseToJSON = GetOrderChannelWebhookStatus200ResponseToJSON;
|
|
20
|
+
exports.GetOrderChannelWebhookStatus200ResponseToJSONTyped = GetOrderChannelWebhookStatus200ResponseToJSONTyped;
|
|
21
|
+
const GetOrderChannelWebhookStatus200ResponseWebhooksInner_1 = require("./GetOrderChannelWebhookStatus200ResponseWebhooksInner");
|
|
22
|
+
/**
|
|
23
|
+
* Check if a given object implements the GetOrderChannelWebhookStatus200Response interface.
|
|
24
|
+
*/
|
|
25
|
+
function instanceOfGetOrderChannelWebhookStatus200Response(value) {
|
|
26
|
+
if (!('enabled' in value) || value['enabled'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
if (!('webhookUrl' in value) || value['webhookUrl'] === undefined)
|
|
29
|
+
return false;
|
|
30
|
+
if (!('webhooks' in value) || value['webhooks'] === undefined)
|
|
31
|
+
return false;
|
|
32
|
+
return true;
|
|
33
|
+
}
|
|
34
|
+
function GetOrderChannelWebhookStatus200ResponseFromJSON(json) {
|
|
35
|
+
return GetOrderChannelWebhookStatus200ResponseFromJSONTyped(json, false);
|
|
36
|
+
}
|
|
37
|
+
function GetOrderChannelWebhookStatus200ResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
38
|
+
if (json == null) {
|
|
39
|
+
return json;
|
|
40
|
+
}
|
|
41
|
+
return {
|
|
42
|
+
'enabled': json['enabled'],
|
|
43
|
+
'webhookUrl': json['webhookUrl'],
|
|
44
|
+
'webhooks': (json['webhooks'].map(GetOrderChannelWebhookStatus200ResponseWebhooksInner_1.GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSON)),
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
function GetOrderChannelWebhookStatus200ResponseToJSON(json) {
|
|
48
|
+
return GetOrderChannelWebhookStatus200ResponseToJSONTyped(json, false);
|
|
49
|
+
}
|
|
50
|
+
function GetOrderChannelWebhookStatus200ResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
51
|
+
if (value == null) {
|
|
52
|
+
return value;
|
|
53
|
+
}
|
|
54
|
+
return {
|
|
55
|
+
'enabled': value['enabled'],
|
|
56
|
+
'webhookUrl': value['webhookUrl'],
|
|
57
|
+
'webhooks': (value['webhooks'].map(GetOrderChannelWebhookStatus200ResponseWebhooksInner_1.GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSON)),
|
|
58
|
+
};
|
|
59
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Zippendo Public API
|
|
3
|
+
* Public API documentation for Zippendo. Authenticate using your API token (Bearer token prefixed with zipp_). **Brands (sub-accounts).** An organization can be split into brands, each keeping its own orders, shipments and configuration separate. There are two ways to scope requests to one brand, and NEITHER changes any request body: 1. **Bind the token.** Create an API token with a `brandId` and every request it makes is confined to that brand — reads filtered, writes stamped. This is the recommended way to give a single brand\'s team its own credential. 2. **Send the `X-Zippendo-Brand` header.** An organization-wide token can scope an individual request by sending the brand\'s id or slug in this header. Most SDKs let you set it once on the client so every call inherits it. A brand-bound token that receives an `X-Zippendo-Brand` header naming a different brand is rejected with `403 BRAND_ACCESS_DENIED` — the binding is never widened. Omit both and requests cover the whole organization, which is the behaviour of every existing token. Records that belong to no brand carry `brandId: null`. Configuration (carriers, shipping rules, addresses) with a null brand is organization-wide and remains visible inside every brand; orders and shipments with a null brand are only visible organization-wide. List endpoints additionally take a `?brandScope=own|shared|both` parameter to narrow further within whichever brand context already applies. `own` returns only rows assigned to that brand, and requires a brand context — a brand-bound token, a resolved brand session, or the `X-Zippendo-Brand` header above — otherwise `400`. `shared` returns only the organization-wide rows (equivalent to filtering `brandId=none`). The default, `both`, keeps the existing behaviour: a brand context sees its own rows plus the organization-wide ones. Set `X-Zippendo-Brand-Scope` as a client default to apply the same choice to every request instead of repeating the query parameter on each call — an explicit `brandScope` query parameter always wins over the header, and a blank header value is ignored. Brands themselves are managed under the **Brands** tag. Retiring a brand is done with `POST /orgs/{orgId}/brands/{brandId}/archive` — permanent deletion is a dashboard-only action, since it is refused while any order, shipment, member or token still references the brand. Brands require a plan that includes them; creating one beyond your plan\'s limit returns `403`.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: support@zippendo.com
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface GetOrderChannelWebhookStatus200ResponseWebhooksInner
|
|
16
|
+
*/
|
|
17
|
+
export interface GetOrderChannelWebhookStatus200ResponseWebhooksInner {
|
|
18
|
+
/**
|
|
19
|
+
* Platform webhook ID.
|
|
20
|
+
* @type {number}
|
|
21
|
+
* @memberof GetOrderChannelWebhookStatus200ResponseWebhooksInner
|
|
22
|
+
*/
|
|
23
|
+
id: number;
|
|
24
|
+
/**
|
|
25
|
+
* Webhook event topic.
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof GetOrderChannelWebhookStatus200ResponseWebhooksInner
|
|
28
|
+
*/
|
|
29
|
+
topic: string;
|
|
30
|
+
/**
|
|
31
|
+
* Registered callback address.
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof GetOrderChannelWebhookStatus200ResponseWebhooksInner
|
|
34
|
+
*/
|
|
35
|
+
address: string;
|
|
36
|
+
/**
|
|
37
|
+
* Webhook creation timestamp.
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof GetOrderChannelWebhookStatus200ResponseWebhooksInner
|
|
40
|
+
*/
|
|
41
|
+
createdAt: string;
|
|
42
|
+
/**
|
|
43
|
+
* WooCommerce delivery URL (same as `address`; present for WooCommerce channels).
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof GetOrderChannelWebhookStatus200ResponseWebhooksInner
|
|
46
|
+
*/
|
|
47
|
+
deliveryUrl?: string;
|
|
48
|
+
/**
|
|
49
|
+
* WooCommerce webhook status. A value other than `active` means WooCommerce disabled the webhook (e.g. after repeated delivery failures).
|
|
50
|
+
* @type {string}
|
|
51
|
+
* @memberof GetOrderChannelWebhookStatus200ResponseWebhooksInner
|
|
52
|
+
*/
|
|
53
|
+
status?: string;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Check if a given object implements the GetOrderChannelWebhookStatus200ResponseWebhooksInner interface.
|
|
57
|
+
*/
|
|
58
|
+
export declare function instanceOfGetOrderChannelWebhookStatus200ResponseWebhooksInner(value: object): value is GetOrderChannelWebhookStatus200ResponseWebhooksInner;
|
|
59
|
+
export declare function GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSON(json: any): GetOrderChannelWebhookStatus200ResponseWebhooksInner;
|
|
60
|
+
export declare function GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetOrderChannelWebhookStatus200ResponseWebhooksInner;
|
|
61
|
+
export declare function GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSON(json: any): GetOrderChannelWebhookStatus200ResponseWebhooksInner;
|
|
62
|
+
export declare function GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSONTyped(value?: GetOrderChannelWebhookStatus200ResponseWebhooksInner | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Zippendo Public API
|
|
6
|
+
* Public API documentation for Zippendo. Authenticate using your API token (Bearer token prefixed with zipp_). **Brands (sub-accounts).** An organization can be split into brands, each keeping its own orders, shipments and configuration separate. There are two ways to scope requests to one brand, and NEITHER changes any request body: 1. **Bind the token.** Create an API token with a `brandId` and every request it makes is confined to that brand — reads filtered, writes stamped. This is the recommended way to give a single brand\'s team its own credential. 2. **Send the `X-Zippendo-Brand` header.** An organization-wide token can scope an individual request by sending the brand\'s id or slug in this header. Most SDKs let you set it once on the client so every call inherits it. A brand-bound token that receives an `X-Zippendo-Brand` header naming a different brand is rejected with `403 BRAND_ACCESS_DENIED` — the binding is never widened. Omit both and requests cover the whole organization, which is the behaviour of every existing token. Records that belong to no brand carry `brandId: null`. Configuration (carriers, shipping rules, addresses) with a null brand is organization-wide and remains visible inside every brand; orders and shipments with a null brand are only visible organization-wide. List endpoints additionally take a `?brandScope=own|shared|both` parameter to narrow further within whichever brand context already applies. `own` returns only rows assigned to that brand, and requires a brand context — a brand-bound token, a resolved brand session, or the `X-Zippendo-Brand` header above — otherwise `400`. `shared` returns only the organization-wide rows (equivalent to filtering `brandId=none`). The default, `both`, keeps the existing behaviour: a brand context sees its own rows plus the organization-wide ones. Set `X-Zippendo-Brand-Scope` as a client default to apply the same choice to every request instead of repeating the query parameter on each call — an explicit `brandScope` query parameter always wins over the header, and a blank header value is ignored. Brands themselves are managed under the **Brands** tag. Retiring a brand is done with `POST /orgs/{orgId}/brands/{brandId}/archive` — permanent deletion is a dashboard-only action, since it is refused while any order, shipment, member or token still references the brand. Brands require a plan that includes them; creating one beyond your plan\'s limit returns `403`.
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
* Contact: support@zippendo.com
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfGetOrderChannelWebhookStatus200ResponseWebhooksInner = instanceOfGetOrderChannelWebhookStatus200ResponseWebhooksInner;
|
|
17
|
+
exports.GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSON = GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSON;
|
|
18
|
+
exports.GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSONTyped = GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSONTyped;
|
|
19
|
+
exports.GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSON = GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSON;
|
|
20
|
+
exports.GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSONTyped = GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the GetOrderChannelWebhookStatus200ResponseWebhooksInner interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfGetOrderChannelWebhookStatus200ResponseWebhooksInner(value) {
|
|
25
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('topic' in value) || value['topic'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('address' in value) || value['address'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined)
|
|
32
|
+
return false;
|
|
33
|
+
return true;
|
|
34
|
+
}
|
|
35
|
+
function GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSON(json) {
|
|
36
|
+
return GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSONTyped(json, false);
|
|
37
|
+
}
|
|
38
|
+
function GetOrderChannelWebhookStatus200ResponseWebhooksInnerFromJSONTyped(json, ignoreDiscriminator) {
|
|
39
|
+
if (json == null) {
|
|
40
|
+
return json;
|
|
41
|
+
}
|
|
42
|
+
return {
|
|
43
|
+
'id': json['id'],
|
|
44
|
+
'topic': json['topic'],
|
|
45
|
+
'address': json['address'],
|
|
46
|
+
'createdAt': json['createdAt'],
|
|
47
|
+
'deliveryUrl': json['deliveryUrl'] == null ? undefined : json['deliveryUrl'],
|
|
48
|
+
'status': json['status'] == null ? undefined : json['status'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
function GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSON(json) {
|
|
52
|
+
return GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSONTyped(json, false);
|
|
53
|
+
}
|
|
54
|
+
function GetOrderChannelWebhookStatus200ResponseWebhooksInnerToJSONTyped(value, ignoreDiscriminator = false) {
|
|
55
|
+
if (value == null) {
|
|
56
|
+
return value;
|
|
57
|
+
}
|
|
58
|
+
return {
|
|
59
|
+
'id': value['id'],
|
|
60
|
+
'topic': value['topic'],
|
|
61
|
+
'address': value['address'],
|
|
62
|
+
'createdAt': value['createdAt'],
|
|
63
|
+
'deliveryUrl': value['deliveryUrl'],
|
|
64
|
+
'status': value['status'],
|
|
65
|
+
};
|
|
66
|
+
}
|
|
@@ -133,6 +133,7 @@ export declare const ListApiTokens401ResponseCodeEnum: {
|
|
|
133
133
|
readonly ShippingRuleInvalid: "SHIPPING_RULE_INVALID";
|
|
134
134
|
readonly AddressNotFound: "ADDRESS_NOT_FOUND";
|
|
135
135
|
readonly OrderNotFound: "ORDER_NOT_FOUND";
|
|
136
|
+
readonly OrderExists: "ORDER_EXISTS";
|
|
136
137
|
readonly OrderChannelNotFound: "ORDER_CHANNEL_NOT_FOUND";
|
|
137
138
|
readonly OrderChannelConfigInvalid: "ORDER_CHANNEL_CONFIG_INVALID";
|
|
138
139
|
readonly IntegrationNotConfigured: "INTEGRATION_NOT_CONFIGURED";
|
|
@@ -118,6 +118,7 @@ exports.ListApiTokens401ResponseCodeEnum = {
|
|
|
118
118
|
ShippingRuleInvalid: 'SHIPPING_RULE_INVALID',
|
|
119
119
|
AddressNotFound: 'ADDRESS_NOT_FOUND',
|
|
120
120
|
OrderNotFound: 'ORDER_NOT_FOUND',
|
|
121
|
+
OrderExists: 'ORDER_EXISTS',
|
|
121
122
|
OrderChannelNotFound: 'ORDER_CHANNEL_NOT_FOUND',
|
|
122
123
|
OrderChannelConfigInvalid: 'ORDER_CHANNEL_CONFIG_INVALID',
|
|
123
124
|
IntegrationNotConfigured: 'INTEGRATION_NOT_CONFIGURED',
|
|
@@ -82,6 +82,18 @@ export interface ListAvailableCarriers200ResponseInner {
|
|
|
82
82
|
* @memberof ListAvailableCarriers200ResponseInner
|
|
83
83
|
*/
|
|
84
84
|
deprecationMessage?: string;
|
|
85
|
+
/**
|
|
86
|
+
* Whether the carrier produces the customs declaration (CN22/CN23) itself and returns it with the label.
|
|
87
|
+
* @type {boolean}
|
|
88
|
+
* @memberof ListAvailableCarriers200ResponseInner
|
|
89
|
+
*/
|
|
90
|
+
generatesCustomsDocuments?: boolean;
|
|
91
|
+
/**
|
|
92
|
+
* Whether the carrier produces the commercial invoice itself and returns it with the label, e.g. via electronic trade documents.
|
|
93
|
+
* @type {boolean}
|
|
94
|
+
* @memberof ListAvailableCarriers200ResponseInner
|
|
95
|
+
*/
|
|
96
|
+
generatesCommercialInvoice?: boolean;
|
|
85
97
|
}
|
|
86
98
|
/**
|
|
87
99
|
* Check if a given object implements the ListAvailableCarriers200ResponseInner interface.
|
|
@@ -48,6 +48,8 @@ function ListAvailableCarriers200ResponseInnerFromJSONTyped(json, ignoreDiscrimi
|
|
|
48
48
|
'optionalFields': json['optionalFields'] == null ? undefined : (json['optionalFields'].map(ListAvailableCarriers200ResponseInnerRequiredFieldsInner_1.ListAvailableCarriers200ResponseInnerRequiredFieldsInnerFromJSON)),
|
|
49
49
|
'deprecated': json['deprecated'] == null ? undefined : json['deprecated'],
|
|
50
50
|
'deprecationMessage': json['deprecationMessage'] == null ? undefined : json['deprecationMessage'],
|
|
51
|
+
'generatesCustomsDocuments': json['generatesCustomsDocuments'] == null ? undefined : json['generatesCustomsDocuments'],
|
|
52
|
+
'generatesCommercialInvoice': json['generatesCommercialInvoice'] == null ? undefined : json['generatesCommercialInvoice'],
|
|
51
53
|
};
|
|
52
54
|
}
|
|
53
55
|
function ListAvailableCarriers200ResponseInnerToJSON(json) {
|
|
@@ -69,5 +71,7 @@ function ListAvailableCarriers200ResponseInnerToJSONTyped(value, ignoreDiscrimin
|
|
|
69
71
|
'optionalFields': value['optionalFields'] == null ? undefined : (value['optionalFields'].map(ListAvailableCarriers200ResponseInnerRequiredFieldsInner_1.ListAvailableCarriers200ResponseInnerRequiredFieldsInnerToJSON)),
|
|
70
72
|
'deprecated': value['deprecated'],
|
|
71
73
|
'deprecationMessage': value['deprecationMessage'],
|
|
74
|
+
'generatesCustomsDocuments': value['generatesCustomsDocuments'],
|
|
75
|
+
'generatesCommercialInvoice': value['generatesCommercialInvoice'],
|
|
72
76
|
};
|
|
73
77
|
}
|
|
@@ -90,6 +90,18 @@ export interface ListCarriers200ResponseDataInner {
|
|
|
90
90
|
* @memberof ListCarriers200ResponseDataInner
|
|
91
91
|
*/
|
|
92
92
|
deprecationMessage?: string;
|
|
93
|
+
/**
|
|
94
|
+
* Whether the carrier produces the customs declaration (CN22/CN23) itself and returns it with the label.
|
|
95
|
+
* @type {boolean}
|
|
96
|
+
* @memberof ListCarriers200ResponseDataInner
|
|
97
|
+
*/
|
|
98
|
+
generatesCustomsDocuments?: boolean;
|
|
99
|
+
/**
|
|
100
|
+
* Whether the carrier produces the commercial invoice itself and returns it with the label, e.g. via electronic trade documents.
|
|
101
|
+
* @type {boolean}
|
|
102
|
+
* @memberof ListCarriers200ResponseDataInner
|
|
103
|
+
*/
|
|
104
|
+
generatesCommercialInvoice?: boolean;
|
|
93
105
|
}
|
|
94
106
|
/**
|
|
95
107
|
* Check if a given object implements the ListCarriers200ResponseDataInner interface.
|
|
@@ -62,6 +62,8 @@ function ListCarriers200ResponseDataInnerFromJSONTyped(json, ignoreDiscriminator
|
|
|
62
62
|
'brandColor': json['brandColor'] == null ? undefined : json['brandColor'],
|
|
63
63
|
'deprecated': json['deprecated'] == null ? undefined : json['deprecated'],
|
|
64
64
|
'deprecationMessage': json['deprecationMessage'] == null ? undefined : json['deprecationMessage'],
|
|
65
|
+
'generatesCustomsDocuments': json['generatesCustomsDocuments'] == null ? undefined : json['generatesCustomsDocuments'],
|
|
66
|
+
'generatesCommercialInvoice': json['generatesCommercialInvoice'] == null ? undefined : json['generatesCommercialInvoice'],
|
|
65
67
|
};
|
|
66
68
|
}
|
|
67
69
|
function ListCarriers200ResponseDataInnerToJSON(json) {
|
|
@@ -84,5 +86,7 @@ function ListCarriers200ResponseDataInnerToJSONTyped(value, ignoreDiscriminator
|
|
|
84
86
|
'brandColor': value['brandColor'],
|
|
85
87
|
'deprecated': value['deprecated'],
|
|
86
88
|
'deprecationMessage': value['deprecationMessage'],
|
|
89
|
+
'generatesCustomsDocuments': value['generatesCustomsDocuments'],
|
|
90
|
+
'generatesCommercialInvoice': value['generatesCommercialInvoice'],
|
|
87
91
|
};
|
|
88
92
|
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Zippendo Public API
|
|
3
|
+
* Public API documentation for Zippendo. Authenticate using your API token (Bearer token prefixed with zipp_). **Brands (sub-accounts).** An organization can be split into brands, each keeping its own orders, shipments and configuration separate. There are two ways to scope requests to one brand, and NEITHER changes any request body: 1. **Bind the token.** Create an API token with a `brandId` and every request it makes is confined to that brand — reads filtered, writes stamped. This is the recommended way to give a single brand\'s team its own credential. 2. **Send the `X-Zippendo-Brand` header.** An organization-wide token can scope an individual request by sending the brand\'s id or slug in this header. Most SDKs let you set it once on the client so every call inherits it. A brand-bound token that receives an `X-Zippendo-Brand` header naming a different brand is rejected with `403 BRAND_ACCESS_DENIED` — the binding is never widened. Omit both and requests cover the whole organization, which is the behaviour of every existing token. Records that belong to no brand carry `brandId: null`. Configuration (carriers, shipping rules, addresses) with a null brand is organization-wide and remains visible inside every brand; orders and shipments with a null brand are only visible organization-wide. List endpoints additionally take a `?brandScope=own|shared|both` parameter to narrow further within whichever brand context already applies. `own` returns only rows assigned to that brand, and requires a brand context — a brand-bound token, a resolved brand session, or the `X-Zippendo-Brand` header above — otherwise `400`. `shared` returns only the organization-wide rows (equivalent to filtering `brandId=none`). The default, `both`, keeps the existing behaviour: a brand context sees its own rows plus the organization-wide ones. Set `X-Zippendo-Brand-Scope` as a client default to apply the same choice to every request instead of repeating the query parameter on each call — an explicit `brandScope` query parameter always wins over the header, and a blank header value is ignored. Brands themselves are managed under the **Brands** tag. Retiring a brand is done with `POST /orgs/{orgId}/brands/{brandId}/archive` — permanent deletion is a dashboard-only action, since it is refused while any order, shipment, member or token still references the brand. Brands require a plan that includes them; creating one beyond your plan\'s limit returns `403`.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: support@zippendo.com
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { ListOrderChannels200ResponseDataInner } from './ListOrderChannels200ResponseDataInner';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface ListOrderChannels200Response
|
|
17
|
+
*/
|
|
18
|
+
export interface ListOrderChannels200Response {
|
|
19
|
+
/**
|
|
20
|
+
* Page of results
|
|
21
|
+
* @type {Array<ListOrderChannels200ResponseDataInner>}
|
|
22
|
+
* @memberof ListOrderChannels200Response
|
|
23
|
+
*/
|
|
24
|
+
data: Array<ListOrderChannels200ResponseDataInner>;
|
|
25
|
+
/**
|
|
26
|
+
* Total matching items across all pages
|
|
27
|
+
* @type {number}
|
|
28
|
+
* @memberof ListOrderChannels200Response
|
|
29
|
+
*/
|
|
30
|
+
total: number;
|
|
31
|
+
/**
|
|
32
|
+
* Current page number (1-based)
|
|
33
|
+
* @type {number}
|
|
34
|
+
* @memberof ListOrderChannels200Response
|
|
35
|
+
*/
|
|
36
|
+
page: number;
|
|
37
|
+
/**
|
|
38
|
+
* Items per page
|
|
39
|
+
* @type {number}
|
|
40
|
+
* @memberof ListOrderChannels200Response
|
|
41
|
+
*/
|
|
42
|
+
limit: number;
|
|
43
|
+
/**
|
|
44
|
+
* Total number of pages
|
|
45
|
+
* @type {number}
|
|
46
|
+
* @memberof ListOrderChannels200Response
|
|
47
|
+
*/
|
|
48
|
+
totalPages: number;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Check if a given object implements the ListOrderChannels200Response interface.
|
|
52
|
+
*/
|
|
53
|
+
export declare function instanceOfListOrderChannels200Response(value: object): value is ListOrderChannels200Response;
|
|
54
|
+
export declare function ListOrderChannels200ResponseFromJSON(json: any): ListOrderChannels200Response;
|
|
55
|
+
export declare function ListOrderChannels200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ListOrderChannels200Response;
|
|
56
|
+
export declare function ListOrderChannels200ResponseToJSON(json: any): ListOrderChannels200Response;
|
|
57
|
+
export declare function ListOrderChannels200ResponseToJSONTyped(value?: ListOrderChannels200Response | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Zippendo Public API
|
|
6
|
+
* Public API documentation for Zippendo. Authenticate using your API token (Bearer token prefixed with zipp_). **Brands (sub-accounts).** An organization can be split into brands, each keeping its own orders, shipments and configuration separate. There are two ways to scope requests to one brand, and NEITHER changes any request body: 1. **Bind the token.** Create an API token with a `brandId` and every request it makes is confined to that brand — reads filtered, writes stamped. This is the recommended way to give a single brand\'s team its own credential. 2. **Send the `X-Zippendo-Brand` header.** An organization-wide token can scope an individual request by sending the brand\'s id or slug in this header. Most SDKs let you set it once on the client so every call inherits it. A brand-bound token that receives an `X-Zippendo-Brand` header naming a different brand is rejected with `403 BRAND_ACCESS_DENIED` — the binding is never widened. Omit both and requests cover the whole organization, which is the behaviour of every existing token. Records that belong to no brand carry `brandId: null`. Configuration (carriers, shipping rules, addresses) with a null brand is organization-wide and remains visible inside every brand; orders and shipments with a null brand are only visible organization-wide. List endpoints additionally take a `?brandScope=own|shared|both` parameter to narrow further within whichever brand context already applies. `own` returns only rows assigned to that brand, and requires a brand context — a brand-bound token, a resolved brand session, or the `X-Zippendo-Brand` header above — otherwise `400`. `shared` returns only the organization-wide rows (equivalent to filtering `brandId=none`). The default, `both`, keeps the existing behaviour: a brand context sees its own rows plus the organization-wide ones. Set `X-Zippendo-Brand-Scope` as a client default to apply the same choice to every request instead of repeating the query parameter on each call — an explicit `brandScope` query parameter always wins over the header, and a blank header value is ignored. Brands themselves are managed under the **Brands** tag. Retiring a brand is done with `POST /orgs/{orgId}/brands/{brandId}/archive` — permanent deletion is a dashboard-only action, since it is refused while any order, shipment, member or token still references the brand. Brands require a plan that includes them; creating one beyond your plan\'s limit returns `403`.
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
* Contact: support@zippendo.com
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfListOrderChannels200Response = instanceOfListOrderChannels200Response;
|
|
17
|
+
exports.ListOrderChannels200ResponseFromJSON = ListOrderChannels200ResponseFromJSON;
|
|
18
|
+
exports.ListOrderChannels200ResponseFromJSONTyped = ListOrderChannels200ResponseFromJSONTyped;
|
|
19
|
+
exports.ListOrderChannels200ResponseToJSON = ListOrderChannels200ResponseToJSON;
|
|
20
|
+
exports.ListOrderChannels200ResponseToJSONTyped = ListOrderChannels200ResponseToJSONTyped;
|
|
21
|
+
const ListOrderChannels200ResponseDataInner_1 = require("./ListOrderChannels200ResponseDataInner");
|
|
22
|
+
/**
|
|
23
|
+
* Check if a given object implements the ListOrderChannels200Response interface.
|
|
24
|
+
*/
|
|
25
|
+
function instanceOfListOrderChannels200Response(value) {
|
|
26
|
+
if (!('data' in value) || value['data'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
if (!('total' in value) || value['total'] === undefined)
|
|
29
|
+
return false;
|
|
30
|
+
if (!('page' in value) || value['page'] === undefined)
|
|
31
|
+
return false;
|
|
32
|
+
if (!('limit' in value) || value['limit'] === undefined)
|
|
33
|
+
return false;
|
|
34
|
+
if (!('totalPages' in value) || value['totalPages'] === undefined)
|
|
35
|
+
return false;
|
|
36
|
+
return true;
|
|
37
|
+
}
|
|
38
|
+
function ListOrderChannels200ResponseFromJSON(json) {
|
|
39
|
+
return ListOrderChannels200ResponseFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
function ListOrderChannels200ResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
42
|
+
if (json == null) {
|
|
43
|
+
return json;
|
|
44
|
+
}
|
|
45
|
+
return {
|
|
46
|
+
'data': (json['data'].map(ListOrderChannels200ResponseDataInner_1.ListOrderChannels200ResponseDataInnerFromJSON)),
|
|
47
|
+
'total': json['total'],
|
|
48
|
+
'page': json['page'],
|
|
49
|
+
'limit': json['limit'],
|
|
50
|
+
'totalPages': json['totalPages'],
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
function ListOrderChannels200ResponseToJSON(json) {
|
|
54
|
+
return ListOrderChannels200ResponseToJSONTyped(json, false);
|
|
55
|
+
}
|
|
56
|
+
function ListOrderChannels200ResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
57
|
+
if (value == null) {
|
|
58
|
+
return value;
|
|
59
|
+
}
|
|
60
|
+
return {
|
|
61
|
+
'data': (value['data'].map(ListOrderChannels200ResponseDataInner_1.ListOrderChannels200ResponseDataInnerToJSON)),
|
|
62
|
+
'total': value['total'],
|
|
63
|
+
'page': value['page'],
|
|
64
|
+
'limit': value['limit'],
|
|
65
|
+
'totalPages': value['totalPages'],
|
|
66
|
+
};
|
|
67
|
+
}
|