@whiplashmerch/whiplash-api-client 3.2.0 → 3.2.2
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/client.esm.js +140 -1
- package/dist/client.esm.js.map +1 -1
- package/dist/generated/Orders.d.ts +19 -1
- package/dist/generated/Packages.d.ts +19 -1
- package/dist/generated/Scancodes.d.ts +37 -1
- package/dist/generated/data-contracts.d.ts +200 -0
- package/generated/Orders.ts +46 -0
- package/generated/Packages.ts +62 -0
- package/generated/data-contracts.ts +186 -0
- package/generated/index.ts +1 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApiSharedEntitiesAudits, ApiSharedEntitiesMetaFields, ApiSharedEntitiesSidekiqBatch, ApiV21EntitiesCount, ApiV21EntitiesCustomsInfo, ApiV21EntitiesIncident, ApiV21EntitiesListValue, ApiV21EntitiesMessage, ApiV21EntitiesOrder, ApiV21EntitiesOrderDocument, ApiV21EntitiesOrderEvent, ApiV21EntitiesOrderItem, ApiV21EntitiesOrderItemLotMap, ApiV21EntitiesOrderMetadata, ApiV21EntitiesOriginator, ApiV21EntitiesPackage, ApiV21EntitiesPostResponse, ApiV21EntitiesResult, ApiV21EntitiesRuleDismissal, ApiV21EntitiesSerialNumber, ApiV21EntitiesShippingRate, ApiV21EntitiesWholesale, ApiV2EntitiesCount, ApiV2EntitiesCustomsInfo, ApiV2EntitiesIncident, ApiV2EntitiesListValue, ApiV2EntitiesMessage, ApiV2EntitiesOrder, ApiV2EntitiesOrderDocument, ApiV2EntitiesOrderEvent, ApiV2EntitiesOrderItem, ApiV2EntitiesOrderItemLotMap, ApiV2EntitiesOrderMetadata, ApiV2EntitiesOriginator, ApiV2EntitiesPackage, ApiV2EntitiesResult, ApiV2EntitiesRuleDismissal, ApiV2EntitiesSerialNumber, ApiV2EntitiesShippingRate, ApiV2EntitiesWholesale, GetApiV21OrdersAggregateParams, GetApiV21OrdersCountParams, GetApiV21OrdersIdCallTraitParams, GetApiV21OrdersIdEventsCountParams, GetApiV21OrdersIdEventsParams, GetApiV21OrdersIdIncidentsCountParams, GetApiV21OrdersIdIncidentsParams, GetApiV21OrdersIdMessagesCountParams, GetApiV21OrdersIdMessagesParams, GetApiV21OrdersIdMetaFieldsParams, GetApiV21OrdersIdOrderDocumentsCountParams, GetApiV21OrdersIdOrderDocumentsParams, GetApiV21OrdersIdOrderItemsCountParams, GetApiV21OrdersIdOrderItemsParams, GetApiV21OrdersIdPackagesCountParams, GetApiV21OrdersIdPackagesParams, GetApiV21OrdersIdTraitsParams, GetApiV21OrdersParams, GetApiV2OrdersAggregateParams, GetApiV2OrdersCountParams, GetApiV2OrdersIdCallTraitParams, GetApiV2OrdersIdEventsCountParams, GetApiV2OrdersIdEventsParams, GetApiV2OrdersIdIncidentsCountParams, GetApiV2OrdersIdIncidentsParams, GetApiV2OrdersIdMessagesCountParams, GetApiV2OrdersIdMessagesParams, GetApiV2OrdersIdMetaFieldsParams, GetApiV2OrdersIdOrderDocumentsCountParams, GetApiV2OrdersIdOrderDocumentsParams, GetApiV2OrdersIdOrderItemsCountParams, GetApiV2OrdersIdOrderItemsParams, GetApiV2OrdersIdPackagesCountParams, GetApiV2OrdersIdPackagesParams, GetApiV2OrdersIdTraitsParams, GetApiV2OrdersParams, PostApiV21OrdersBulkRequest, PostApiV21OrdersIdIncidentsRequest, PostApiV21OrdersIdMessagesRequest, PostApiV21OrdersIdOrderDocumentsRequest, PostApiV21OrdersIdOrderItemsRequest, PostApiV21OrdersIdPackagesRequest, PostApiV21OrdersIdRuleDismissalsRequest, PostApiV21OrdersRequest, PostApiV2OrdersBulkRequest, PostApiV2OrdersIdIncidentsRequest, PostApiV2OrdersIdMessagesRequest, PostApiV2OrdersIdOrderDocumentsRequest, PostApiV2OrdersIdOrderItemsRequest, PostApiV2OrdersIdPackagesRequest, PostApiV2OrdersIdRuleDismissalsRequest, PostApiV2OrdersRequest, PutApiV21OrdersIdCallActionRequest, PutApiV21OrdersIdCallAsyncActionRequest, PutApiV21OrdersIdCustomsInfoRequest, PutApiV21OrdersIdMetaFieldsRequest, PutApiV21OrdersIdRequest, PutApiV21OrdersIdWholesaleRequest, PutApiV2OrdersIdCallActionRequest, PutApiV2OrdersIdCallAsyncActionRequest, PutApiV2OrdersIdCustomsInfoRequest, PutApiV2OrdersIdMetaFieldsRequest, PutApiV2OrdersIdRequest, PutApiV2OrdersIdWholesaleRequest } from "./data-contracts";
|
|
1
|
+
import { ApiSharedEntitiesAudits, ApiSharedEntitiesMetaFields, ApiSharedEntitiesSidekiqBatch, ApiV21EntitiesCount, ApiV21EntitiesCustomsInfo, ApiV21EntitiesIncident, ApiV21EntitiesListValue, ApiV21EntitiesMessage, ApiV21EntitiesOrder, ApiV21EntitiesOrderDocument, ApiV21EntitiesOrderEvent, ApiV21EntitiesOrderItem, ApiV21EntitiesOrderItemLotMap, ApiV21EntitiesOrderMetadata, ApiV21EntitiesOriginator, ApiV21EntitiesPackage, ApiV21EntitiesPostResponse, ApiV21EntitiesResult, ApiV21EntitiesRuleDismissal, ApiV21EntitiesSerialNumber, ApiV21EntitiesShippingDocument, ApiV21EntitiesShippingRate, ApiV21EntitiesWholesale, ApiV2EntitiesCount, ApiV2EntitiesCustomsInfo, ApiV2EntitiesIncident, ApiV2EntitiesListValue, ApiV2EntitiesMessage, ApiV2EntitiesOrder, ApiV2EntitiesOrderDocument, ApiV2EntitiesOrderEvent, ApiV2EntitiesOrderItem, ApiV2EntitiesOrderItemLotMap, ApiV2EntitiesOrderMetadata, ApiV2EntitiesOriginator, ApiV2EntitiesPackage, ApiV2EntitiesResult, ApiV2EntitiesRuleDismissal, ApiV2EntitiesSerialNumber, ApiV2EntitiesShippingDocument, ApiV2EntitiesShippingRate, ApiV2EntitiesWholesale, GetApiV21OrdersAggregateParams, GetApiV21OrdersCountParams, GetApiV21OrdersIdCallTraitParams, GetApiV21OrdersIdEventsCountParams, GetApiV21OrdersIdEventsParams, GetApiV21OrdersIdIncidentsCountParams, GetApiV21OrdersIdIncidentsParams, GetApiV21OrdersIdMessagesCountParams, GetApiV21OrdersIdMessagesParams, GetApiV21OrdersIdMetaFieldsParams, GetApiV21OrdersIdOrderDocumentsCountParams, GetApiV21OrdersIdOrderDocumentsParams, GetApiV21OrdersIdOrderItemsCountParams, GetApiV21OrdersIdOrderItemsParams, GetApiV21OrdersIdPackagesCountParams, GetApiV21OrdersIdPackagesParams, GetApiV21OrdersIdShippingDocumentsParams, GetApiV21OrdersIdTraitsParams, GetApiV21OrdersParams, GetApiV2OrdersAggregateParams, GetApiV2OrdersCountParams, GetApiV2OrdersIdCallTraitParams, GetApiV2OrdersIdEventsCountParams, GetApiV2OrdersIdEventsParams, GetApiV2OrdersIdIncidentsCountParams, GetApiV2OrdersIdIncidentsParams, GetApiV2OrdersIdMessagesCountParams, GetApiV2OrdersIdMessagesParams, GetApiV2OrdersIdMetaFieldsParams, GetApiV2OrdersIdOrderDocumentsCountParams, GetApiV2OrdersIdOrderDocumentsParams, GetApiV2OrdersIdOrderItemsCountParams, GetApiV2OrdersIdOrderItemsParams, GetApiV2OrdersIdPackagesCountParams, GetApiV2OrdersIdPackagesParams, GetApiV2OrdersIdShippingDocumentsParams, GetApiV2OrdersIdTraitsParams, GetApiV2OrdersParams, PostApiV21OrdersBulkRequest, PostApiV21OrdersIdIncidentsRequest, PostApiV21OrdersIdMessagesRequest, PostApiV21OrdersIdOrderDocumentsRequest, PostApiV21OrdersIdOrderItemsRequest, PostApiV21OrdersIdPackagesRequest, PostApiV21OrdersIdRuleDismissalsRequest, PostApiV21OrdersRequest, PostApiV2OrdersBulkRequest, PostApiV2OrdersIdIncidentsRequest, PostApiV2OrdersIdMessagesRequest, PostApiV2OrdersIdOrderDocumentsRequest, PostApiV2OrdersIdOrderItemsRequest, PostApiV2OrdersIdPackagesRequest, PostApiV2OrdersIdRuleDismissalsRequest, PostApiV2OrdersRequest, PutApiV21OrdersIdCallActionRequest, PutApiV21OrdersIdCallAsyncActionRequest, PutApiV21OrdersIdCustomsInfoRequest, PutApiV21OrdersIdMetaFieldsRequest, PutApiV21OrdersIdRequest, PutApiV21OrdersIdWholesaleRequest, PutApiV2OrdersIdCallActionRequest, PutApiV2OrdersIdCallAsyncActionRequest, PutApiV2OrdersIdCustomsInfoRequest, PutApiV2OrdersIdMetaFieldsRequest, PutApiV2OrdersIdRequest, PutApiV2OrdersIdWholesaleRequest } from "./data-contracts";
|
|
2
2
|
import { HttpClient, RequestParams } from "./http-client";
|
|
3
3
|
/**
|
|
4
4
|
* @description Retrieves a list of orders
|
|
@@ -396,6 +396,15 @@ export declare const getApiV2OrdersIdSerialNumbers: (client: HttpClient, id: num
|
|
|
396
396
|
* @request GET:/api/v2/orders/{id}/shipment_rates
|
|
397
397
|
*/
|
|
398
398
|
export declare const getApiV2OrdersIdShipmentRates: (client: HttpClient, id: number, params?: RequestParams) => Promise<ApiV2EntitiesShippingRate[]>;
|
|
399
|
+
/**
|
|
400
|
+
* @description List all shipping documents for a order
|
|
401
|
+
*
|
|
402
|
+
* @tags orders
|
|
403
|
+
* @name GetApiV2OrdersIdShippingDocuments
|
|
404
|
+
* @summary List shipping documents for a order
|
|
405
|
+
* @request GET:/api/v2/orders/{id}/shipping_documents
|
|
406
|
+
*/
|
|
407
|
+
export declare const getApiV2OrdersIdShippingDocuments: (client: HttpClient, { id, ...query }: GetApiV2OrdersIdShippingDocumentsParams, params?: RequestParams) => Promise<ApiV2EntitiesShippingDocument[]>;
|
|
399
408
|
/**
|
|
400
409
|
* @description List shipping rates for an order
|
|
401
410
|
*
|
|
@@ -837,6 +846,15 @@ export declare const getApiV21OrdersIdSerialNumbers: (client: HttpClient, id: nu
|
|
|
837
846
|
* @request GET:/api/v2.1/orders/{id}/shipment_rates
|
|
838
847
|
*/
|
|
839
848
|
export declare const getApiV21OrdersIdShipmentRates: (client: HttpClient, id: number, params?: RequestParams) => Promise<ApiV21EntitiesShippingRate[]>;
|
|
849
|
+
/**
|
|
850
|
+
* @description List all shipping documents for a order
|
|
851
|
+
*
|
|
852
|
+
* @tags orders
|
|
853
|
+
* @name GetApiV21OrdersIdShippingDocuments
|
|
854
|
+
* @summary List shipping documents for a order
|
|
855
|
+
* @request GET:/api/v2.1/orders/{id}/shipping_documents
|
|
856
|
+
*/
|
|
857
|
+
export declare const getApiV21OrdersIdShippingDocuments: (client: HttpClient, { id, ...query }: GetApiV21OrdersIdShippingDocumentsParams, params?: RequestParams) => Promise<ApiV21EntitiesShippingDocument[]>;
|
|
840
858
|
/**
|
|
841
859
|
* @description List shipping rates for an order
|
|
842
860
|
*
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApiSharedEntitiesAudits, ApiV21EntitiesCount, ApiV21EntitiesPackage, ApiV21EntitiesResult, ApiV2EntitiesCount, ApiV2EntitiesPackage, ApiV2EntitiesResult, GetApiV21PackagesAggregateParams, GetApiV21PackagesIdCallTraitParams, GetApiV21PackagesIdTraitsParams, GetApiV21PackagesParams, GetApiV2PackagesAggregateParams, GetApiV2PackagesIdCallTraitParams, GetApiV2PackagesIdTraitsParams, GetApiV2PackagesParams, PutApiV21PackagesIdCallActionRequest, PutApiV21PackagesIdRequest, PutApiV2PackagesIdCallActionRequest, PutApiV2PackagesIdRequest } from "./data-contracts";
|
|
1
|
+
import { ApiSharedEntitiesAudits, ApiV21EntitiesCount, ApiV21EntitiesPackage, ApiV21EntitiesResult, ApiV21EntitiesShippingDocument, ApiV2EntitiesCount, ApiV2EntitiesPackage, ApiV2EntitiesResult, ApiV2EntitiesShippingDocument, GetApiV21PackagesAggregateParams, GetApiV21PackagesIdCallTraitParams, GetApiV21PackagesIdShippingDocumentsParams, GetApiV21PackagesIdTraitsParams, GetApiV21PackagesParams, GetApiV2PackagesAggregateParams, GetApiV2PackagesIdCallTraitParams, GetApiV2PackagesIdShippingDocumentsParams, GetApiV2PackagesIdTraitsParams, GetApiV2PackagesParams, PutApiV21PackagesIdCallActionRequest, PutApiV21PackagesIdRequest, PutApiV2PackagesIdCallActionRequest, PutApiV2PackagesIdRequest } from "./data-contracts";
|
|
2
2
|
import { HttpClient, RequestParams } from "./http-client";
|
|
3
3
|
/**
|
|
4
4
|
* @description get packages
|
|
@@ -99,6 +99,15 @@ export declare const getApiV2PackagesIdCallTrait: (client: HttpClient, { trait,
|
|
|
99
99
|
* @request GET:/api/v2/packages/{id}/shipment
|
|
100
100
|
*/
|
|
101
101
|
export declare const getApiV2PackagesIdShipment: (client: HttpClient, id: number, params?: RequestParams) => Promise<any>;
|
|
102
|
+
/**
|
|
103
|
+
* @description List all shipping documents for a package
|
|
104
|
+
*
|
|
105
|
+
* @tags packages
|
|
106
|
+
* @name GetApiV2PackagesIdShippingDocuments
|
|
107
|
+
* @summary List shipping documents for a package
|
|
108
|
+
* @request GET:/api/v2/packages/{id}/shipping_documents
|
|
109
|
+
*/
|
|
110
|
+
export declare const getApiV2PackagesIdShippingDocuments: (client: HttpClient, { id, ...query }: GetApiV2PackagesIdShippingDocumentsParams, params?: RequestParams) => Promise<ApiV2EntitiesShippingDocument[]>;
|
|
102
111
|
/**
|
|
103
112
|
* @description Get the specified packages traits
|
|
104
113
|
*
|
|
@@ -207,6 +216,15 @@ export declare const getApiV21PackagesIdCallTrait: (client: HttpClient, { trait,
|
|
|
207
216
|
* @request GET:/api/v2.1/packages/{id}/shipment
|
|
208
217
|
*/
|
|
209
218
|
export declare const getApiV21PackagesIdShipment: (client: HttpClient, id: number, params?: RequestParams) => Promise<any>;
|
|
219
|
+
/**
|
|
220
|
+
* @description List all shipping documents for a package
|
|
221
|
+
*
|
|
222
|
+
* @tags packages
|
|
223
|
+
* @name GetApiV21PackagesIdShippingDocuments
|
|
224
|
+
* @summary List shipping documents for a package
|
|
225
|
+
* @request GET:/api/v2.1/packages/{id}/shipping_documents
|
|
226
|
+
*/
|
|
227
|
+
export declare const getApiV21PackagesIdShippingDocuments: (client: HttpClient, { id, ...query }: GetApiV21PackagesIdShippingDocumentsParams, params?: RequestParams) => Promise<ApiV21EntitiesShippingDocument[]>;
|
|
210
228
|
/**
|
|
211
229
|
* @description Get the specified packages traits
|
|
212
230
|
*
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApiV21EntitiesScancode, ApiV2EntitiesScancode, GetApiV21ScancodesParams, GetApiV2ScancodesParams, PutApiV21ScancodesIdRequest, PutApiV2ScancodesIdRequest } from "./data-contracts";
|
|
1
|
+
import { ApiSharedEntitiesSidekiqBatch, ApiV21EntitiesScancode, ApiV2EntitiesScancode, GetApiV21ScancodesParams, GetApiV2ScancodesParams, PutApiV21ScancodesIdCallActionRequest, PutApiV21ScancodesIdCallAsyncActionRequest, PutApiV21ScancodesIdRequest, PutApiV2ScancodesIdCallActionRequest, PutApiV2ScancodesIdCallAsyncActionRequest, PutApiV2ScancodesIdRequest } from "./data-contracts";
|
|
2
2
|
import { HttpClient, RequestParams } from "./http-client";
|
|
3
3
|
/**
|
|
4
4
|
* @description Get all scancodes
|
|
@@ -18,6 +18,24 @@ export declare const getApiV2Scancodes: (client: HttpClient, query: GetApiV2Scan
|
|
|
18
18
|
* @request PUT:/api/v2/scancodes/{id}
|
|
19
19
|
*/
|
|
20
20
|
export declare const putApiV2ScancodesId: (client: HttpClient, id: number, data: PutApiV2ScancodesIdRequest, params?: RequestParams) => Promise<ApiV2EntitiesScancode>;
|
|
21
|
+
/**
|
|
22
|
+
* @description Perform an action on a scancode
|
|
23
|
+
*
|
|
24
|
+
* @tags scancodes
|
|
25
|
+
* @name PutApiV2ScancodesIdCallAction
|
|
26
|
+
* @summary Perform an action on a scancode
|
|
27
|
+
* @request PUT:/api/v2/scancodes/{id}/call/{action}
|
|
28
|
+
*/
|
|
29
|
+
export declare const putApiV2ScancodesIdCallAction: (client: HttpClient, action: string, id: number, data: PutApiV2ScancodesIdCallActionRequest, params?: RequestParams) => Promise<ApiV2EntitiesScancode>;
|
|
30
|
+
/**
|
|
31
|
+
* @description Perform an action on a scancode asynchronously
|
|
32
|
+
*
|
|
33
|
+
* @tags scancodes
|
|
34
|
+
* @name PutApiV2ScancodesIdCallAsyncAction
|
|
35
|
+
* @summary Perform an action on a scancode asynchronously
|
|
36
|
+
* @request PUT:/api/v2/scancodes/{id}/call_async/{action}
|
|
37
|
+
*/
|
|
38
|
+
export declare const putApiV2ScancodesIdCallAsyncAction: (client: HttpClient, action: string, id: number, data: PutApiV2ScancodesIdCallAsyncActionRequest, params?: RequestParams) => Promise<ApiSharedEntitiesSidekiqBatch>;
|
|
21
39
|
/**
|
|
22
40
|
* @description Get all scancodes
|
|
23
41
|
*
|
|
@@ -36,3 +54,21 @@ export declare const getApiV21Scancodes: (client: HttpClient, query: GetApiV21Sc
|
|
|
36
54
|
* @request PUT:/api/v2.1/scancodes/{id}
|
|
37
55
|
*/
|
|
38
56
|
export declare const putApiV21ScancodesId: (client: HttpClient, id: number, data: PutApiV21ScancodesIdRequest, params?: RequestParams) => Promise<void>;
|
|
57
|
+
/**
|
|
58
|
+
* @description Perform an action on a scancode
|
|
59
|
+
*
|
|
60
|
+
* @tags scancodes
|
|
61
|
+
* @name PutApiV21ScancodesIdCallAction
|
|
62
|
+
* @summary Perform an action on a scancode
|
|
63
|
+
* @request PUT:/api/v2.1/scancodes/{id}/call/{action}
|
|
64
|
+
*/
|
|
65
|
+
export declare const putApiV21ScancodesIdCallAction: (client: HttpClient, action: string, id: number, data: PutApiV21ScancodesIdCallActionRequest, params?: RequestParams) => Promise<void>;
|
|
66
|
+
/**
|
|
67
|
+
* @description Perform an action on a scancode asynchronously
|
|
68
|
+
*
|
|
69
|
+
* @tags scancodes
|
|
70
|
+
* @name PutApiV21ScancodesIdCallAsyncAction
|
|
71
|
+
* @summary Perform an action on a scancode asynchronously
|
|
72
|
+
* @request PUT:/api/v2.1/scancodes/{id}/call_async/{action}
|
|
73
|
+
*/
|
|
74
|
+
export declare const putApiV21ScancodesIdCallAsyncAction: (client: HttpClient, action: string, id: number, data: PutApiV21ScancodesIdCallAsyncActionRequest, params?: RequestParams) => Promise<ApiSharedEntitiesSidekiqBatch>;
|
|
@@ -4826,6 +4826,50 @@ export interface ApiV2EntitiesShippingBlacklistedMethod {
|
|
|
4826
4826
|
updated_at?: string;
|
|
4827
4827
|
}
|
|
4828
4828
|
/** V2 */
|
|
4829
|
+
export interface ApiV2EntitiesShippingDocument {
|
|
4830
|
+
/**
|
|
4831
|
+
* the document creation date and time
|
|
4832
|
+
* @format date-time
|
|
4833
|
+
*/
|
|
4834
|
+
created_at?: string;
|
|
4835
|
+
/** document format (e.g. PDF, PNG) */
|
|
4836
|
+
document_format?: string;
|
|
4837
|
+
/** whether the document was electronically submitted to customs */
|
|
4838
|
+
electronically_submitted?: boolean;
|
|
4839
|
+
/**
|
|
4840
|
+
* the shipping document id
|
|
4841
|
+
* @format int32
|
|
4842
|
+
*/
|
|
4843
|
+
id?: number;
|
|
4844
|
+
/** label provider name (e.g. easypost, shipium) */
|
|
4845
|
+
label_provider?: string | null;
|
|
4846
|
+
/**
|
|
4847
|
+
* the associated order id
|
|
4848
|
+
* @format int32
|
|
4849
|
+
*/
|
|
4850
|
+
order_id?: number;
|
|
4851
|
+
/**
|
|
4852
|
+
* the owner id (Package or Order id)
|
|
4853
|
+
* @format int32
|
|
4854
|
+
*/
|
|
4855
|
+
owner_id?: number;
|
|
4856
|
+
/** the owner type (Package or Order) */
|
|
4857
|
+
owner_type?: string;
|
|
4858
|
+
/** type of document from provider (e.g. commercial_invoice, label) */
|
|
4859
|
+
provider_document_type?: string | null;
|
|
4860
|
+
/** the raw carrier-provided document url (staff only) */
|
|
4861
|
+
provider_url?: string | null;
|
|
4862
|
+
/** the pre-signed or resolved document url */
|
|
4863
|
+
resolved_url?: string;
|
|
4864
|
+
/**
|
|
4865
|
+
* the document last updated date and time
|
|
4866
|
+
* @format date-time
|
|
4867
|
+
*/
|
|
4868
|
+
updated_at?: string;
|
|
4869
|
+
/** the internal document file url (S3 or CDN path) (staff only) */
|
|
4870
|
+
url?: string;
|
|
4871
|
+
}
|
|
4872
|
+
/** V2 */
|
|
4829
4873
|
export interface ApiV2EntitiesShippingMethod {
|
|
4830
4874
|
/** is the shipping method active? */
|
|
4831
4875
|
active?: boolean | null;
|
|
@@ -9709,6 +9753,50 @@ export interface ApiV21EntitiesShippingBlacklistedMethod {
|
|
|
9709
9753
|
updated_at?: string;
|
|
9710
9754
|
}
|
|
9711
9755
|
/** V3 */
|
|
9756
|
+
export interface ApiV21EntitiesShippingDocument {
|
|
9757
|
+
/**
|
|
9758
|
+
* the document creation date and time
|
|
9759
|
+
* @format date-time
|
|
9760
|
+
*/
|
|
9761
|
+
created_at?: string;
|
|
9762
|
+
/** document format (e.g. PDF, PNG) */
|
|
9763
|
+
document_format?: string;
|
|
9764
|
+
/** whether the document was electronically submitted to customs */
|
|
9765
|
+
electronically_submitted?: boolean;
|
|
9766
|
+
/**
|
|
9767
|
+
* the shipping document id
|
|
9768
|
+
* @format int32
|
|
9769
|
+
*/
|
|
9770
|
+
id?: number;
|
|
9771
|
+
/** label provider name (e.g. easypost, shipium) */
|
|
9772
|
+
label_provider?: string | null;
|
|
9773
|
+
/**
|
|
9774
|
+
* the associated order id
|
|
9775
|
+
* @format int32
|
|
9776
|
+
*/
|
|
9777
|
+
order_id?: number;
|
|
9778
|
+
/**
|
|
9779
|
+
* the owner id (Package or Order id)
|
|
9780
|
+
* @format int32
|
|
9781
|
+
*/
|
|
9782
|
+
owner_id?: number;
|
|
9783
|
+
/** the owner type (Package or Order) */
|
|
9784
|
+
owner_type?: string;
|
|
9785
|
+
/** type of document from provider (e.g. commercial_invoice, label) */
|
|
9786
|
+
provider_document_type?: string | null;
|
|
9787
|
+
/** the raw carrier-provided document url (staff only) */
|
|
9788
|
+
provider_url?: string | null;
|
|
9789
|
+
/** the pre-signed or resolved document url */
|
|
9790
|
+
resolved_url?: string;
|
|
9791
|
+
/**
|
|
9792
|
+
* the document last updated date and time
|
|
9793
|
+
* @format date-time
|
|
9794
|
+
*/
|
|
9795
|
+
updated_at?: string;
|
|
9796
|
+
/** the internal document file url (S3 or CDN path) (staff only) */
|
|
9797
|
+
url?: string;
|
|
9798
|
+
}
|
|
9799
|
+
/** V3 */
|
|
9712
9800
|
export interface ApiV21EntitiesShippingMethod {
|
|
9713
9801
|
/** is the shipping method active? */
|
|
9714
9802
|
active?: boolean | null;
|
|
@@ -12279,6 +12367,29 @@ export interface GetApiV21OrdersIdPackagesParams {
|
|
|
12279
12367
|
page_links?: boolean;
|
|
12280
12368
|
id: number;
|
|
12281
12369
|
}
|
|
12370
|
+
export interface GetApiV21OrdersIdShippingDocumentsParams {
|
|
12371
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
12372
|
+
search?: string;
|
|
12373
|
+
/** Comma-separated list of fields to include in the response */
|
|
12374
|
+
fields?: string;
|
|
12375
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
12376
|
+
sort?: string;
|
|
12377
|
+
/**
|
|
12378
|
+
* Page of results to fetch
|
|
12379
|
+
* @format int32
|
|
12380
|
+
*/
|
|
12381
|
+
page?: number;
|
|
12382
|
+
/**
|
|
12383
|
+
* Number of results to return per page
|
|
12384
|
+
* @format int32
|
|
12385
|
+
*/
|
|
12386
|
+
per_page?: number;
|
|
12387
|
+
/** Include total count of results */
|
|
12388
|
+
page_total?: boolean;
|
|
12389
|
+
/** Include prev/next links in response headers */
|
|
12390
|
+
page_links?: boolean;
|
|
12391
|
+
id: number;
|
|
12392
|
+
}
|
|
12282
12393
|
export interface GetApiV21OrdersIdTraitsParams {
|
|
12283
12394
|
/** List of traits to return */
|
|
12284
12395
|
traits: string;
|
|
@@ -12344,6 +12455,29 @@ export interface GetApiV21PackagesIdCallTraitParams {
|
|
|
12344
12455
|
trait: string;
|
|
12345
12456
|
id: number;
|
|
12346
12457
|
}
|
|
12458
|
+
export interface GetApiV21PackagesIdShippingDocumentsParams {
|
|
12459
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
12460
|
+
search?: string;
|
|
12461
|
+
/** Comma-separated list of fields to include in the response */
|
|
12462
|
+
fields?: string;
|
|
12463
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
12464
|
+
sort?: string;
|
|
12465
|
+
/**
|
|
12466
|
+
* Page of results to fetch
|
|
12467
|
+
* @format int32
|
|
12468
|
+
*/
|
|
12469
|
+
page?: number;
|
|
12470
|
+
/**
|
|
12471
|
+
* Number of results to return per page
|
|
12472
|
+
* @format int32
|
|
12473
|
+
*/
|
|
12474
|
+
per_page?: number;
|
|
12475
|
+
/** Include total count of results */
|
|
12476
|
+
page_total?: boolean;
|
|
12477
|
+
/** Include prev/next links in response headers */
|
|
12478
|
+
page_links?: boolean;
|
|
12479
|
+
id: number;
|
|
12480
|
+
}
|
|
12347
12481
|
export interface GetApiV21PackagesIdTraitsParams {
|
|
12348
12482
|
/** List of traits to return */
|
|
12349
12483
|
traits: string;
|
|
@@ -15033,6 +15167,29 @@ export interface GetApiV2OrdersIdPackagesParams {
|
|
|
15033
15167
|
page_links?: boolean;
|
|
15034
15168
|
id: number;
|
|
15035
15169
|
}
|
|
15170
|
+
export interface GetApiV2OrdersIdShippingDocumentsParams {
|
|
15171
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
15172
|
+
search?: string;
|
|
15173
|
+
/** Comma-separated list of fields to include in the response */
|
|
15174
|
+
fields?: string;
|
|
15175
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
15176
|
+
sort?: string;
|
|
15177
|
+
/**
|
|
15178
|
+
* Page of results to fetch
|
|
15179
|
+
* @format int32
|
|
15180
|
+
*/
|
|
15181
|
+
page?: number;
|
|
15182
|
+
/**
|
|
15183
|
+
* Number of results to return per page
|
|
15184
|
+
* @format int32
|
|
15185
|
+
*/
|
|
15186
|
+
per_page?: number;
|
|
15187
|
+
/** Include total count of results */
|
|
15188
|
+
page_total?: boolean;
|
|
15189
|
+
/** Include prev/next links in response headers */
|
|
15190
|
+
page_links?: boolean;
|
|
15191
|
+
id: number;
|
|
15192
|
+
}
|
|
15036
15193
|
export interface GetApiV2OrdersIdTraitsParams {
|
|
15037
15194
|
/** List of traits to return */
|
|
15038
15195
|
traits: string;
|
|
@@ -15098,6 +15255,29 @@ export interface GetApiV2PackagesIdCallTraitParams {
|
|
|
15098
15255
|
trait: string;
|
|
15099
15256
|
id: number;
|
|
15100
15257
|
}
|
|
15258
|
+
export interface GetApiV2PackagesIdShippingDocumentsParams {
|
|
15259
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
15260
|
+
search?: string;
|
|
15261
|
+
/** Comma-separated list of fields to include in the response */
|
|
15262
|
+
fields?: string;
|
|
15263
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
15264
|
+
sort?: string;
|
|
15265
|
+
/**
|
|
15266
|
+
* Page of results to fetch
|
|
15267
|
+
* @format int32
|
|
15268
|
+
*/
|
|
15269
|
+
page?: number;
|
|
15270
|
+
/**
|
|
15271
|
+
* Number of results to return per page
|
|
15272
|
+
* @format int32
|
|
15273
|
+
*/
|
|
15274
|
+
per_page?: number;
|
|
15275
|
+
/** Include total count of results */
|
|
15276
|
+
page_total?: boolean;
|
|
15277
|
+
/** Include prev/next links in response headers */
|
|
15278
|
+
page_links?: boolean;
|
|
15279
|
+
id: number;
|
|
15280
|
+
}
|
|
15101
15281
|
export interface GetApiV2PackagesIdTraitsParams {
|
|
15102
15282
|
/** List of traits to return */
|
|
15103
15283
|
traits: string;
|
|
@@ -25136,6 +25316,16 @@ export interface PutApiV21ScancodeAliasesIdRequest {
|
|
|
25136
25316
|
/** the scancode for the scancode_alias */
|
|
25137
25317
|
scancode?: string;
|
|
25138
25318
|
}
|
|
25319
|
+
export interface PutApiV21ScancodesIdCallActionRequest {
|
|
25320
|
+
action?: string;
|
|
25321
|
+
/** Method params */
|
|
25322
|
+
args?: string;
|
|
25323
|
+
}
|
|
25324
|
+
export interface PutApiV21ScancodesIdCallAsyncActionRequest {
|
|
25325
|
+
action?: string;
|
|
25326
|
+
/** Method params */
|
|
25327
|
+
args?: string;
|
|
25328
|
+
}
|
|
25139
25329
|
export interface PutApiV21ScancodesIdRequest {
|
|
25140
25330
|
/** is this scancode active? */
|
|
25141
25331
|
active?: boolean;
|
|
@@ -27951,6 +28141,16 @@ export interface PutApiV2ScancodeAliasesIdRequest {
|
|
|
27951
28141
|
/** the scancode for the scancode_alias */
|
|
27952
28142
|
scancode?: string;
|
|
27953
28143
|
}
|
|
28144
|
+
export interface PutApiV2ScancodesIdCallActionRequest {
|
|
28145
|
+
action?: string;
|
|
28146
|
+
/** Method params */
|
|
28147
|
+
args?: string;
|
|
28148
|
+
}
|
|
28149
|
+
export interface PutApiV2ScancodesIdCallAsyncActionRequest {
|
|
28150
|
+
action?: string;
|
|
28151
|
+
/** Method params */
|
|
28152
|
+
args?: string;
|
|
28153
|
+
}
|
|
27954
28154
|
export interface PutApiV2ScancodesIdRequest {
|
|
27955
28155
|
/** is this scancode active? */
|
|
27956
28156
|
active?: boolean;
|
package/generated/Orders.ts
CHANGED
|
@@ -21,6 +21,7 @@ import {
|
|
|
21
21
|
ApiV21EntitiesPostResponse,
|
|
22
22
|
ApiV21EntitiesResult,
|
|
23
23
|
ApiV21EntitiesSerialNumber,
|
|
24
|
+
ApiV21EntitiesShippingDocument,
|
|
24
25
|
ApiV21EntitiesWholesale,
|
|
25
26
|
ApiV2EntitiesCount,
|
|
26
27
|
ApiV2EntitiesCustomsInfo,
|
|
@@ -30,6 +31,7 @@ import {
|
|
|
30
31
|
ApiV2EntitiesOrderItem,
|
|
31
32
|
ApiV2EntitiesResult,
|
|
32
33
|
ApiV2EntitiesSerialNumber,
|
|
34
|
+
ApiV2EntitiesShippingDocument,
|
|
33
35
|
ApiV2EntitiesWholesale,
|
|
34
36
|
GetApiV21OrdersCountParams,
|
|
35
37
|
GetApiV21OrdersIdEventsCountParams,
|
|
@@ -39,6 +41,7 @@ import {
|
|
|
39
41
|
GetApiV21OrdersIdOrderDocumentsParams,
|
|
40
42
|
GetApiV21OrdersIdOrderItemsCountParams,
|
|
41
43
|
GetApiV21OrdersIdOrderItemsParams,
|
|
44
|
+
GetApiV21OrdersIdShippingDocumentsParams,
|
|
42
45
|
GetApiV21OrdersParams,
|
|
43
46
|
GetApiV2OrdersCountParams,
|
|
44
47
|
GetApiV2OrdersIdEventsCountParams,
|
|
@@ -48,6 +51,7 @@ import {
|
|
|
48
51
|
GetApiV2OrdersIdOrderDocumentsParams,
|
|
49
52
|
GetApiV2OrdersIdOrderItemsCountParams,
|
|
50
53
|
GetApiV2OrdersIdOrderItemsParams,
|
|
54
|
+
GetApiV2OrdersIdShippingDocumentsParams,
|
|
51
55
|
GetApiV2OrdersParams,
|
|
52
56
|
PostApiV21OrdersBulkRequest,
|
|
53
57
|
PostApiV21OrdersIdOrderDocumentsRequest,
|
|
@@ -469,6 +473,27 @@ export const getApiV2OrdersIdSerialNumbers = (client: HttpClient, id: number, pa
|
|
|
469
473
|
...params,
|
|
470
474
|
});
|
|
471
475
|
};
|
|
476
|
+
/**
|
|
477
|
+
* @description List all shipping documents for a order
|
|
478
|
+
*
|
|
479
|
+
* @tags orders
|
|
480
|
+
* @name GetApiV2OrdersIdShippingDocuments
|
|
481
|
+
* @summary List shipping documents for a order
|
|
482
|
+
* @request GET:/api/v2/orders/{id}/shipping_documents
|
|
483
|
+
*/
|
|
484
|
+
export const getApiV2OrdersIdShippingDocuments = (
|
|
485
|
+
client: HttpClient,
|
|
486
|
+
{ id, ...query }: GetApiV2OrdersIdShippingDocumentsParams,
|
|
487
|
+
params: RequestParams = {},
|
|
488
|
+
) => {
|
|
489
|
+
return client.request<ApiV2EntitiesShippingDocument[], ApiSharedEntitiesApiError>({
|
|
490
|
+
path: `/api/v2/orders/${id}/shipping_documents`,
|
|
491
|
+
method: "GET",
|
|
492
|
+
query: query,
|
|
493
|
+
format: "json",
|
|
494
|
+
...params,
|
|
495
|
+
});
|
|
496
|
+
};
|
|
472
497
|
/**
|
|
473
498
|
* @description get the Wholesale object for an order
|
|
474
499
|
*
|
|
@@ -886,6 +911,27 @@ export const getApiV21OrdersIdSerialNumbers = (client: HttpClient, id: number, p
|
|
|
886
911
|
...params,
|
|
887
912
|
});
|
|
888
913
|
};
|
|
914
|
+
/**
|
|
915
|
+
* @description List all shipping documents for a order
|
|
916
|
+
*
|
|
917
|
+
* @tags orders
|
|
918
|
+
* @name GetApiV21OrdersIdShippingDocuments
|
|
919
|
+
* @summary List shipping documents for a order
|
|
920
|
+
* @request GET:/api/v2.1/orders/{id}/shipping_documents
|
|
921
|
+
*/
|
|
922
|
+
export const getApiV21OrdersIdShippingDocuments = (
|
|
923
|
+
client: HttpClient,
|
|
924
|
+
{ id, ...query }: GetApiV21OrdersIdShippingDocumentsParams,
|
|
925
|
+
params: RequestParams = {},
|
|
926
|
+
) => {
|
|
927
|
+
return client.request<ApiV21EntitiesShippingDocument[], ApiSharedEntitiesApiError>({
|
|
928
|
+
path: `/api/v2.1/orders/${id}/shipping_documents`,
|
|
929
|
+
method: "GET",
|
|
930
|
+
query: query,
|
|
931
|
+
format: "json",
|
|
932
|
+
...params,
|
|
933
|
+
});
|
|
934
|
+
};
|
|
889
935
|
/**
|
|
890
936
|
* @description get the Wholesale object for an order
|
|
891
937
|
*
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/*
|
|
4
|
+
* ---------------------------------------------------------------
|
|
5
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
6
|
+
* ## ##
|
|
7
|
+
* ## AUTHOR: acacode ##
|
|
8
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
9
|
+
* ---------------------------------------------------------------
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
import {
|
|
13
|
+
ApiSharedEntitiesApiError,
|
|
14
|
+
ApiV21EntitiesShippingDocument,
|
|
15
|
+
ApiV2EntitiesShippingDocument,
|
|
16
|
+
GetApiV21PackagesIdShippingDocumentsParams,
|
|
17
|
+
GetApiV2PackagesIdShippingDocumentsParams,
|
|
18
|
+
} from "./data-contracts";
|
|
19
|
+
import { HttpClient, RequestParams } from "./http-client";
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* @description List all shipping documents for a package
|
|
23
|
+
*
|
|
24
|
+
* @tags packages
|
|
25
|
+
* @name GetApiV2PackagesIdShippingDocuments
|
|
26
|
+
* @summary List shipping documents for a package
|
|
27
|
+
* @request GET:/api/v2/packages/{id}/shipping_documents
|
|
28
|
+
*/
|
|
29
|
+
export const getApiV2PackagesIdShippingDocuments = (
|
|
30
|
+
client: HttpClient,
|
|
31
|
+
{ id, ...query }: GetApiV2PackagesIdShippingDocumentsParams,
|
|
32
|
+
params: RequestParams = {},
|
|
33
|
+
) => {
|
|
34
|
+
return client.request<ApiV2EntitiesShippingDocument[], ApiSharedEntitiesApiError>({
|
|
35
|
+
path: `/api/v2/packages/${id}/shipping_documents`,
|
|
36
|
+
method: "GET",
|
|
37
|
+
query: query,
|
|
38
|
+
format: "json",
|
|
39
|
+
...params,
|
|
40
|
+
});
|
|
41
|
+
};
|
|
42
|
+
/**
|
|
43
|
+
* @description List all shipping documents for a package
|
|
44
|
+
*
|
|
45
|
+
* @tags packages
|
|
46
|
+
* @name GetApiV21PackagesIdShippingDocuments
|
|
47
|
+
* @summary List shipping documents for a package
|
|
48
|
+
* @request GET:/api/v2.1/packages/{id}/shipping_documents
|
|
49
|
+
*/
|
|
50
|
+
export const getApiV21PackagesIdShippingDocuments = (
|
|
51
|
+
client: HttpClient,
|
|
52
|
+
{ id, ...query }: GetApiV21PackagesIdShippingDocumentsParams,
|
|
53
|
+
params: RequestParams = {},
|
|
54
|
+
) => {
|
|
55
|
+
return client.request<ApiV21EntitiesShippingDocument[], ApiSharedEntitiesApiError>({
|
|
56
|
+
path: `/api/v2.1/packages/${id}/shipping_documents`,
|
|
57
|
+
method: "GET",
|
|
58
|
+
query: query,
|
|
59
|
+
format: "json",
|
|
60
|
+
...params,
|
|
61
|
+
});
|
|
62
|
+
};
|