@whiplashmerch/whiplash-api-client 2.0.11 → 2.0.13
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 +280 -1
- package/dist/client.esm.js.map +1 -1
- package/dist/generated/Pallets.d.ts +146 -0
- package/dist/generated/data-contracts.d.ts +185 -0
- package/dist/generated/index.d.ts +1 -0
- package/dist/mock-data/index.d.ts +1 -0
- package/generated/data-contracts.ts +10 -0
- package/package.json +1 -1
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { ApiV21EntitiesPostResponse, ApiV2EntitiesCount, ApiV2EntitiesPackage, ApiV2EntitiesPallet, GetApiV21PalletsCountParams, GetApiV21PalletsIdPackagesParams, GetApiV21PalletsParams, GetApiV2PalletsCountParams, GetApiV2PalletsIdPackagesParams, GetApiV2PalletsParams, PutApiV21PalletsIdCallActionRequest, PutApiV21PalletsIdRequest, PutApiV2PalletsIdCallActionRequest, PutApiV2PalletsIdRequest } from "./data-contracts";
|
|
2
|
+
import { HttpClient, RequestParams } from "./http-client";
|
|
3
|
+
/**
|
|
4
|
+
* @description Get all pallets
|
|
5
|
+
*
|
|
6
|
+
* @tags pallets
|
|
7
|
+
* @name GetApiV2Pallets
|
|
8
|
+
* @summary List all pallets
|
|
9
|
+
* @request GET:/api/v2/pallets
|
|
10
|
+
*/
|
|
11
|
+
export declare const getApiV2Pallets: (client: HttpClient, query: GetApiV2PalletsParams, params?: RequestParams) => Promise<ApiV2EntitiesPallet[]>;
|
|
12
|
+
/**
|
|
13
|
+
* @description Create a pallet
|
|
14
|
+
*
|
|
15
|
+
* @tags pallets
|
|
16
|
+
* @name PostApiV2Pallets
|
|
17
|
+
* @summary Create a pallet
|
|
18
|
+
* @request POST:/api/v2/pallets
|
|
19
|
+
*/
|
|
20
|
+
export declare const postApiV2Pallets: (client: HttpClient, params?: RequestParams) => Promise<ApiV2EntitiesPallet>;
|
|
21
|
+
/**
|
|
22
|
+
* @description Returns count of pallets
|
|
23
|
+
*
|
|
24
|
+
* @tags pallets
|
|
25
|
+
* @name GetApiV2PalletsCount
|
|
26
|
+
* @summary Count pallets
|
|
27
|
+
* @request GET:/api/v2/pallets/count
|
|
28
|
+
*/
|
|
29
|
+
export declare const getApiV2PalletsCount: (client: HttpClient, query: GetApiV2PalletsCountParams, params?: RequestParams) => Promise<ApiV2EntitiesCount>;
|
|
30
|
+
/**
|
|
31
|
+
* @description Get a pallet
|
|
32
|
+
*
|
|
33
|
+
* @tags pallets
|
|
34
|
+
* @name GetApiV2PalletsId
|
|
35
|
+
* @summary Get a pallet by ID
|
|
36
|
+
* @request GET:/api/v2/pallets/{id}
|
|
37
|
+
*/
|
|
38
|
+
export declare const getApiV2PalletsId: (client: HttpClient, id: number, params?: RequestParams) => Promise<ApiV2EntitiesPallet>;
|
|
39
|
+
/**
|
|
40
|
+
* @description Update a pallet
|
|
41
|
+
*
|
|
42
|
+
* @tags pallets
|
|
43
|
+
* @name PutApiV2PalletsId
|
|
44
|
+
* @summary Update a pallet
|
|
45
|
+
* @request PUT:/api/v2/pallets/{id}
|
|
46
|
+
*/
|
|
47
|
+
export declare const putApiV2PalletsId: (client: HttpClient, id: number, data: PutApiV2PalletsIdRequest, params?: RequestParams) => Promise<ApiV2EntitiesPallet>;
|
|
48
|
+
/**
|
|
49
|
+
* @description Destroy a pallet
|
|
50
|
+
*
|
|
51
|
+
* @tags pallets
|
|
52
|
+
* @name DeleteApiV2PalletsId
|
|
53
|
+
* @summary Destroy a pallet
|
|
54
|
+
* @request DELETE:/api/v2/pallets/{id}
|
|
55
|
+
*/
|
|
56
|
+
export declare const deleteApiV2PalletsId: (client: HttpClient, id: number, params?: RequestParams) => Promise<void>;
|
|
57
|
+
/**
|
|
58
|
+
* @description Perform an action on a pallet
|
|
59
|
+
*
|
|
60
|
+
* @tags pallets
|
|
61
|
+
* @name PutApiV2PalletsIdCallAction
|
|
62
|
+
* @summary Perform an action on a pallet
|
|
63
|
+
* @request PUT:/api/v2/pallets/{id}/call/{action}
|
|
64
|
+
*/
|
|
65
|
+
export declare const putApiV2PalletsIdCallAction: (client: HttpClient, action: string, id: number, data: PutApiV2PalletsIdCallActionRequest, params?: RequestParams) => Promise<ApiV2EntitiesPallet>;
|
|
66
|
+
/**
|
|
67
|
+
* @description Get all packages for a Pallet
|
|
68
|
+
*
|
|
69
|
+
* @tags pallets
|
|
70
|
+
* @name GetApiV2PalletsIdPackages
|
|
71
|
+
* @summary List all packages for a pallet
|
|
72
|
+
* @request GET:/api/v2/pallets/{id}/packages
|
|
73
|
+
*/
|
|
74
|
+
export declare const getApiV2PalletsIdPackages: (client: HttpClient, { id, ...query }: GetApiV2PalletsIdPackagesParams, params?: RequestParams) => Promise<ApiV2EntitiesPackage[]>;
|
|
75
|
+
/**
|
|
76
|
+
* @description Get all pallets
|
|
77
|
+
*
|
|
78
|
+
* @tags pallets
|
|
79
|
+
* @name GetApiV21Pallets
|
|
80
|
+
* @summary List all pallets
|
|
81
|
+
* @request GET:/api/v2.1/pallets
|
|
82
|
+
*/
|
|
83
|
+
export declare const getApiV21Pallets: (client: HttpClient, query: GetApiV21PalletsParams, params?: RequestParams) => Promise<ApiV2EntitiesPallet[]>;
|
|
84
|
+
/**
|
|
85
|
+
* @description Create a pallet
|
|
86
|
+
*
|
|
87
|
+
* @tags pallets
|
|
88
|
+
* @name PostApiV21Pallets
|
|
89
|
+
* @summary Create a pallet
|
|
90
|
+
* @request POST:/api/v2.1/pallets
|
|
91
|
+
*/
|
|
92
|
+
export declare const postApiV21Pallets: (client: HttpClient, params?: RequestParams) => Promise<ApiV21EntitiesPostResponse>;
|
|
93
|
+
/**
|
|
94
|
+
* @description Returns count of pallets
|
|
95
|
+
*
|
|
96
|
+
* @tags pallets
|
|
97
|
+
* @name GetApiV21PalletsCount
|
|
98
|
+
* @summary Count pallets
|
|
99
|
+
* @request GET:/api/v2.1/pallets/count
|
|
100
|
+
*/
|
|
101
|
+
export declare const getApiV21PalletsCount: (client: HttpClient, query: GetApiV21PalletsCountParams, params?: RequestParams) => Promise<ApiV2EntitiesCount>;
|
|
102
|
+
/**
|
|
103
|
+
* @description Get a pallet
|
|
104
|
+
*
|
|
105
|
+
* @tags pallets
|
|
106
|
+
* @name GetApiV21PalletsId
|
|
107
|
+
* @summary Get a pallet by ID
|
|
108
|
+
* @request GET:/api/v2.1/pallets/{id}
|
|
109
|
+
*/
|
|
110
|
+
export declare const getApiV21PalletsId: (client: HttpClient, id: number, params?: RequestParams) => Promise<ApiV2EntitiesPallet>;
|
|
111
|
+
/**
|
|
112
|
+
* @description Update a pallet
|
|
113
|
+
*
|
|
114
|
+
* @tags pallets
|
|
115
|
+
* @name PutApiV21PalletsId
|
|
116
|
+
* @summary Update a pallet
|
|
117
|
+
* @request PUT:/api/v2.1/pallets/{id}
|
|
118
|
+
*/
|
|
119
|
+
export declare const putApiV21PalletsId: (client: HttpClient, id: number, data: PutApiV21PalletsIdRequest, params?: RequestParams) => Promise<void>;
|
|
120
|
+
/**
|
|
121
|
+
* @description Destroy a pallet
|
|
122
|
+
*
|
|
123
|
+
* @tags pallets
|
|
124
|
+
* @name DeleteApiV21PalletsId
|
|
125
|
+
* @summary Destroy a pallet
|
|
126
|
+
* @request DELETE:/api/v2.1/pallets/{id}
|
|
127
|
+
*/
|
|
128
|
+
export declare const deleteApiV21PalletsId: (client: HttpClient, id: number, params?: RequestParams) => Promise<void>;
|
|
129
|
+
/**
|
|
130
|
+
* @description Perform an action on a pallet
|
|
131
|
+
*
|
|
132
|
+
* @tags pallets
|
|
133
|
+
* @name PutApiV21PalletsIdCallAction
|
|
134
|
+
* @summary Perform an action on a pallet
|
|
135
|
+
* @request PUT:/api/v2.1/pallets/{id}/call/{action}
|
|
136
|
+
*/
|
|
137
|
+
export declare const putApiV21PalletsIdCallAction: (client: HttpClient, action: string, id: number, data: PutApiV21PalletsIdCallActionRequest, params?: RequestParams) => Promise<void>;
|
|
138
|
+
/**
|
|
139
|
+
* @description Get all packages for a Pallet
|
|
140
|
+
*
|
|
141
|
+
* @tags pallets
|
|
142
|
+
* @name GetApiV21PalletsIdPackages
|
|
143
|
+
* @summary List all packages for a pallet
|
|
144
|
+
* @request GET:/api/v2.1/pallets/{id}/packages
|
|
145
|
+
*/
|
|
146
|
+
export declare const getApiV21PalletsIdPackages: (client: HttpClient, { id, ...query }: GetApiV21PalletsIdPackagesParams, params?: RequestParams) => Promise<ApiV2EntitiesPackage[]>;
|
|
@@ -3790,8 +3790,18 @@ export interface ApiV2EntitiesPackage {
|
|
|
3790
3790
|
*/
|
|
3791
3791
|
order_id?: number | null;
|
|
3792
3792
|
order_item_ids?: number[];
|
|
3793
|
+
/**
|
|
3794
|
+
* the pallet id this package is on (staff only)
|
|
3795
|
+
* @format int32
|
|
3796
|
+
*/
|
|
3797
|
+
pallet_id?: number | null;
|
|
3793
3798
|
/** the package scan form url (staff only) */
|
|
3794
3799
|
scan_form_url?: string | null;
|
|
3800
|
+
/**
|
|
3801
|
+
* when the package was scanned to a pallet (staff only)
|
|
3802
|
+
* @format date-time
|
|
3803
|
+
*/
|
|
3804
|
+
scanned_to_pallet_at?: string | null;
|
|
3795
3805
|
/**
|
|
3796
3806
|
* the package shipping cost
|
|
3797
3807
|
* @format float
|
|
@@ -3838,6 +3848,59 @@ export interface ApiV2EntitiesPackingslipsArray {
|
|
|
3838
3848
|
packingslips_array?: object;
|
|
3839
3849
|
}
|
|
3840
3850
|
/** V2 */
|
|
3851
|
+
export interface ApiV2EntitiesPallet {
|
|
3852
|
+
/**
|
|
3853
|
+
* the pallet creation date and time
|
|
3854
|
+
* @format date-time
|
|
3855
|
+
*/
|
|
3856
|
+
created_at?: string;
|
|
3857
|
+
/**
|
|
3858
|
+
* the package id
|
|
3859
|
+
* @format int32
|
|
3860
|
+
*/
|
|
3861
|
+
id?: number;
|
|
3862
|
+
/**
|
|
3863
|
+
* the date and time when the LPN label was printed
|
|
3864
|
+
* @format date-time
|
|
3865
|
+
*/
|
|
3866
|
+
lpn_label_printed_at?: string | null;
|
|
3867
|
+
/**
|
|
3868
|
+
* the pallet number (LPN)
|
|
3869
|
+
* @format int32
|
|
3870
|
+
*/
|
|
3871
|
+
number?: number | null;
|
|
3872
|
+
/**
|
|
3873
|
+
* the order batch id associated with the pallet
|
|
3874
|
+
* @format int32
|
|
3875
|
+
*/
|
|
3876
|
+
order_batch_id?: number | null;
|
|
3877
|
+
/**
|
|
3878
|
+
* the total dimensional weight of the pallet
|
|
3879
|
+
* @format float
|
|
3880
|
+
*/
|
|
3881
|
+
total_dimensional_weight?: number | null;
|
|
3882
|
+
/**
|
|
3883
|
+
* the total number of items in the pallet
|
|
3884
|
+
* @format int32
|
|
3885
|
+
*/
|
|
3886
|
+
total_item_count?: number | null;
|
|
3887
|
+
/**
|
|
3888
|
+
* the total number of packages in the pallet
|
|
3889
|
+
* @format int32
|
|
3890
|
+
*/
|
|
3891
|
+
total_package_count?: number | null;
|
|
3892
|
+
/**
|
|
3893
|
+
* the pallet last update date and time
|
|
3894
|
+
* @format date-time
|
|
3895
|
+
*/
|
|
3896
|
+
updated_at?: string;
|
|
3897
|
+
/**
|
|
3898
|
+
* the pallet warehouse id
|
|
3899
|
+
* @format int32
|
|
3900
|
+
*/
|
|
3901
|
+
warehouse_id?: number | null;
|
|
3902
|
+
}
|
|
3903
|
+
/** V2 */
|
|
3841
3904
|
export interface ApiV2EntitiesPartner {
|
|
3842
3905
|
/** Partner billing address line 1. */
|
|
3843
3906
|
billing_address1?: string | null;
|
|
@@ -10733,6 +10796,55 @@ export interface GetApiV21PackagesParams {
|
|
|
10733
10796
|
/** Include prev/next links in response headers */
|
|
10734
10797
|
page_links?: boolean;
|
|
10735
10798
|
}
|
|
10799
|
+
export interface GetApiV21PalletsCountParams {
|
|
10800
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
10801
|
+
search?: string;
|
|
10802
|
+
}
|
|
10803
|
+
export interface GetApiV21PalletsIdPackagesParams {
|
|
10804
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
10805
|
+
search?: string;
|
|
10806
|
+
/** Comma-separated list of fields to include in the response */
|
|
10807
|
+
fields?: string;
|
|
10808
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
10809
|
+
sort?: string;
|
|
10810
|
+
/**
|
|
10811
|
+
* Page of results to fetch
|
|
10812
|
+
* @format int32
|
|
10813
|
+
*/
|
|
10814
|
+
page?: number;
|
|
10815
|
+
/**
|
|
10816
|
+
* Number of results to return per page
|
|
10817
|
+
* @format int32
|
|
10818
|
+
*/
|
|
10819
|
+
per_page?: number;
|
|
10820
|
+
/** Include total count of results */
|
|
10821
|
+
page_total?: boolean;
|
|
10822
|
+
/** Include prev/next links in response headers */
|
|
10823
|
+
page_links?: boolean;
|
|
10824
|
+
id: number;
|
|
10825
|
+
}
|
|
10826
|
+
export interface GetApiV21PalletsParams {
|
|
10827
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
10828
|
+
search?: string;
|
|
10829
|
+
/** Comma-separated list of fields to include in the response */
|
|
10830
|
+
fields?: string;
|
|
10831
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
10832
|
+
sort?: string;
|
|
10833
|
+
/**
|
|
10834
|
+
* Page of results to fetch
|
|
10835
|
+
* @format int32
|
|
10836
|
+
*/
|
|
10837
|
+
page?: number;
|
|
10838
|
+
/**
|
|
10839
|
+
* Number of results to return per page
|
|
10840
|
+
* @format int32
|
|
10841
|
+
*/
|
|
10842
|
+
per_page?: number;
|
|
10843
|
+
/** Include total count of results */
|
|
10844
|
+
page_total?: boolean;
|
|
10845
|
+
/** Include prev/next links in response headers */
|
|
10846
|
+
page_links?: boolean;
|
|
10847
|
+
}
|
|
10736
10848
|
export interface GetApiV21PartnersCountParams {
|
|
10737
10849
|
/** JSON search string like {"attribute_eq": "Term"} */
|
|
10738
10850
|
search?: string;
|
|
@@ -13375,6 +13487,55 @@ export interface GetApiV2PackagesParams {
|
|
|
13375
13487
|
/** Include prev/next links in response headers */
|
|
13376
13488
|
page_links?: boolean;
|
|
13377
13489
|
}
|
|
13490
|
+
export interface GetApiV2PalletsCountParams {
|
|
13491
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
13492
|
+
search?: string;
|
|
13493
|
+
}
|
|
13494
|
+
export interface GetApiV2PalletsIdPackagesParams {
|
|
13495
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
13496
|
+
search?: string;
|
|
13497
|
+
/** Comma-separated list of fields to include in the response */
|
|
13498
|
+
fields?: string;
|
|
13499
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
13500
|
+
sort?: string;
|
|
13501
|
+
/**
|
|
13502
|
+
* Page of results to fetch
|
|
13503
|
+
* @format int32
|
|
13504
|
+
*/
|
|
13505
|
+
page?: number;
|
|
13506
|
+
/**
|
|
13507
|
+
* Number of results to return per page
|
|
13508
|
+
* @format int32
|
|
13509
|
+
*/
|
|
13510
|
+
per_page?: number;
|
|
13511
|
+
/** Include total count of results */
|
|
13512
|
+
page_total?: boolean;
|
|
13513
|
+
/** Include prev/next links in response headers */
|
|
13514
|
+
page_links?: boolean;
|
|
13515
|
+
id: number;
|
|
13516
|
+
}
|
|
13517
|
+
export interface GetApiV2PalletsParams {
|
|
13518
|
+
/** JSON search string like {"attribute_eq": "Term"} */
|
|
13519
|
+
search?: string;
|
|
13520
|
+
/** Comma-separated list of fields to include in the response */
|
|
13521
|
+
fields?: string;
|
|
13522
|
+
/** A list of sort options (ex: name asc,created_at desc) */
|
|
13523
|
+
sort?: string;
|
|
13524
|
+
/**
|
|
13525
|
+
* Page of results to fetch
|
|
13526
|
+
* @format int32
|
|
13527
|
+
*/
|
|
13528
|
+
page?: number;
|
|
13529
|
+
/**
|
|
13530
|
+
* Number of results to return per page
|
|
13531
|
+
* @format int32
|
|
13532
|
+
*/
|
|
13533
|
+
per_page?: number;
|
|
13534
|
+
/** Include total count of results */
|
|
13535
|
+
page_total?: boolean;
|
|
13536
|
+
/** Include prev/next links in response headers */
|
|
13537
|
+
page_links?: boolean;
|
|
13538
|
+
}
|
|
13378
13539
|
export interface GetApiV2PartnersCountParams {
|
|
13379
13540
|
/** JSON search string like {"attribute_eq": "Term"} */
|
|
13380
13541
|
search?: string;
|
|
@@ -23456,6 +23617,18 @@ export interface PutApiV21PackagesIdRequest {
|
|
|
23456
23617
|
/** the package tracking number */
|
|
23457
23618
|
tracking?: string;
|
|
23458
23619
|
}
|
|
23620
|
+
export interface PutApiV21PalletsIdCallActionRequest {
|
|
23621
|
+
action?: string;
|
|
23622
|
+
/** Method params */
|
|
23623
|
+
args?: object;
|
|
23624
|
+
}
|
|
23625
|
+
export interface PutApiV21PalletsIdRequest {
|
|
23626
|
+
/**
|
|
23627
|
+
* the date and time when the LPN label was printed
|
|
23628
|
+
* @format date-time
|
|
23629
|
+
*/
|
|
23630
|
+
lpn_label_printed_at?: string;
|
|
23631
|
+
}
|
|
23459
23632
|
export interface PutApiV21PartnersIdRequest {
|
|
23460
23633
|
/** Partner billing address line 1. */
|
|
23461
23634
|
billing_address1?: string;
|
|
@@ -26418,6 +26591,18 @@ export interface PutApiV2PackagesIdRequest {
|
|
|
26418
26591
|
/** the package tracking number */
|
|
26419
26592
|
tracking?: string;
|
|
26420
26593
|
}
|
|
26594
|
+
export interface PutApiV2PalletsIdCallActionRequest {
|
|
26595
|
+
action?: string;
|
|
26596
|
+
/** Method params */
|
|
26597
|
+
args?: object;
|
|
26598
|
+
}
|
|
26599
|
+
export interface PutApiV2PalletsIdRequest {
|
|
26600
|
+
/**
|
|
26601
|
+
* the date and time when the LPN label was printed
|
|
26602
|
+
* @format date-time
|
|
26603
|
+
*/
|
|
26604
|
+
lpn_label_printed_at?: string;
|
|
26605
|
+
}
|
|
26421
26606
|
export interface PutApiV2PartnersIdRequest {
|
|
26422
26607
|
/** Partner billing address line 1. */
|
|
26423
26608
|
billing_address1?: string;
|
|
@@ -49,6 +49,7 @@ export * from './v2_1/order/processing';
|
|
|
49
49
|
export * from './v2_1/shipnotice/processing';
|
|
50
50
|
export * from './v2_1/originator/created';
|
|
51
51
|
export * from './v2_1/package/created';
|
|
52
|
+
export * from './v2_1/pallet/created';
|
|
52
53
|
export * from './v2_1/partner/created';
|
|
53
54
|
export * from './v2_1/prepack/created';
|
|
54
55
|
export * from './v2_1/project-task/created';
|
|
@@ -1901,8 +1901,18 @@ export interface ApiV2EntitiesPackage {
|
|
|
1901
1901
|
*/
|
|
1902
1902
|
order_id?: number | null;
|
|
1903
1903
|
order_item_ids?: number[];
|
|
1904
|
+
/**
|
|
1905
|
+
* the pallet id this package is on (staff only)
|
|
1906
|
+
* @format int32
|
|
1907
|
+
*/
|
|
1908
|
+
pallet_id?: number | null;
|
|
1904
1909
|
/** the package scan form url (staff only) */
|
|
1905
1910
|
scan_form_url?: string | null;
|
|
1911
|
+
/**
|
|
1912
|
+
* when the package was scanned to a pallet (staff only)
|
|
1913
|
+
* @format date-time
|
|
1914
|
+
*/
|
|
1915
|
+
scanned_to_pallet_at?: string | null;
|
|
1906
1916
|
/**
|
|
1907
1917
|
* the package shipping cost
|
|
1908
1918
|
* @format float
|