@commercengine/pos 0.1.3 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +104 -34
- package/dist/index.d.ts +3454 -127
- package/dist/index.js +1422 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -683,6 +683,46 @@ interface paths {
|
|
|
683
683
|
patch?: never;
|
|
684
684
|
trace?: never;
|
|
685
685
|
};
|
|
686
|
+
"/pos/orders/{order_number}/payment-status": {
|
|
687
|
+
parameters: {
|
|
688
|
+
query?: never;
|
|
689
|
+
header?: never;
|
|
690
|
+
path?: never;
|
|
691
|
+
cookie?: never;
|
|
692
|
+
};
|
|
693
|
+
/**
|
|
694
|
+
* Retrieve payment status
|
|
695
|
+
* @description Retrieve payment status of a paricular order.
|
|
696
|
+
*/
|
|
697
|
+
get: operations["pos-get-payment-status"];
|
|
698
|
+
put?: never;
|
|
699
|
+
post?: never;
|
|
700
|
+
delete?: never;
|
|
701
|
+
options?: never;
|
|
702
|
+
head?: never;
|
|
703
|
+
patch?: never;
|
|
704
|
+
trace?: never;
|
|
705
|
+
};
|
|
706
|
+
"/pos/payments/payment-options": {
|
|
707
|
+
parameters: {
|
|
708
|
+
query?: never;
|
|
709
|
+
header?: never;
|
|
710
|
+
path?: never;
|
|
711
|
+
cookie?: never;
|
|
712
|
+
};
|
|
713
|
+
/**
|
|
714
|
+
* List all payment options
|
|
715
|
+
* @description List all payment options
|
|
716
|
+
*/
|
|
717
|
+
get: operations["pos-list-payment-options"];
|
|
718
|
+
put?: never;
|
|
719
|
+
post?: never;
|
|
720
|
+
delete?: never;
|
|
721
|
+
options?: never;
|
|
722
|
+
head?: never;
|
|
723
|
+
patch?: never;
|
|
724
|
+
trace?: never;
|
|
725
|
+
};
|
|
686
726
|
}
|
|
687
727
|
interface components {
|
|
688
728
|
schemas: {
|
|
@@ -1499,6 +1539,28 @@ interface components {
|
|
|
1499
1539
|
associated_options: components["schemas"]["AssociatedOption"] | null;
|
|
1500
1540
|
shipping?: components["schemas"]["ProductShipping"];
|
|
1501
1541
|
};
|
|
1542
|
+
/** JuspayPaymentGatewayParams */
|
|
1543
|
+
JuspayPaymentGatewayParams: {
|
|
1544
|
+
/**
|
|
1545
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1546
|
+
* @enum {string}
|
|
1547
|
+
*/
|
|
1548
|
+
payment_gateway: "JUSPAY";
|
|
1549
|
+
/**
|
|
1550
|
+
* @description `paymentPage` is the default option that you should select when using hyper-checkout
|
|
1551
|
+
* @enum {string}
|
|
1552
|
+
*/
|
|
1553
|
+
action: "paymentPage" | "paymentManagement";
|
|
1554
|
+
/**
|
|
1555
|
+
* @description Use `hyper-checkout` for Juspay hosted checkout
|
|
1556
|
+
* @enum {string}
|
|
1557
|
+
*/
|
|
1558
|
+
integration_type: "hyper-checkout" | "express-checkout";
|
|
1559
|
+
/** @description This is the URL that the gateway will redirect to once payment processing is complete. This will be a GET request by default */
|
|
1560
|
+
return_url: string;
|
|
1561
|
+
/** @description The exact gateway reference ID that was set up in the integration */
|
|
1562
|
+
gateway_reference_id: string;
|
|
1563
|
+
};
|
|
1502
1564
|
/**
|
|
1503
1565
|
* MultiSelectAttribute
|
|
1504
1566
|
* @description Attribute for multi-select values
|
|
@@ -1779,6 +1841,9 @@ interface components {
|
|
|
1779
1841
|
limit: number;
|
|
1780
1842
|
next_page: number | null;
|
|
1781
1843
|
};
|
|
1844
|
+
/** @enum {string} */
|
|
1845
|
+
PaymentGateway: "PAYU" | "JUSPAY";
|
|
1846
|
+
PaymentGatewayParams: components["schemas"]["PayuPaymentGatewayParams"] | components["schemas"]["JuspayPaymentGatewayParams"];
|
|
1782
1847
|
/**
|
|
1783
1848
|
* PaymentInfo
|
|
1784
1849
|
* @description Common fields in all types of payments.
|
|
@@ -1797,6 +1862,38 @@ interface components {
|
|
|
1797
1862
|
payment_method?: string | null;
|
|
1798
1863
|
icon_url?: string | null;
|
|
1799
1864
|
};
|
|
1865
|
+
/** PayuPaymentGatewayParams */
|
|
1866
|
+
PayuPaymentGatewayParams: {
|
|
1867
|
+
/**
|
|
1868
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1869
|
+
* @enum {string}
|
|
1870
|
+
*/
|
|
1871
|
+
payment_gateway: "PAYU";
|
|
1872
|
+
furl: string;
|
|
1873
|
+
surl: string;
|
|
1874
|
+
};
|
|
1875
|
+
/** PayWithCard */
|
|
1876
|
+
PayWithCard: {
|
|
1877
|
+
/** @constant */
|
|
1878
|
+
payment_mode: "CARD";
|
|
1879
|
+
};
|
|
1880
|
+
/** PayWithCash */
|
|
1881
|
+
PayWithCash: {
|
|
1882
|
+
/** @constant */
|
|
1883
|
+
payment_mode: "CASH";
|
|
1884
|
+
};
|
|
1885
|
+
/** PayWithPaymentGateway */
|
|
1886
|
+
PayWithPaymentGateway: {
|
|
1887
|
+
/** @constant */
|
|
1888
|
+
payment_mode: "PG";
|
|
1889
|
+
payment_gateway: components["schemas"]["PaymentGateway"];
|
|
1890
|
+
payment_gateway_params: components["schemas"]["PaymentGatewayParams"];
|
|
1891
|
+
};
|
|
1892
|
+
/** PayWithUPI */
|
|
1893
|
+
PayWithUpi: {
|
|
1894
|
+
/** @constant */
|
|
1895
|
+
payment_mode: "UPI";
|
|
1896
|
+
};
|
|
1800
1897
|
/** PercentageDiscountRule */
|
|
1801
1898
|
PercentageDiscountRule: {
|
|
1802
1899
|
/** @constant */
|
|
@@ -2454,7 +2551,7 @@ interface operations {
|
|
|
2454
2551
|
path?: never;
|
|
2455
2552
|
cookie?: never;
|
|
2456
2553
|
};
|
|
2457
|
-
requestBody
|
|
2554
|
+
requestBody: {
|
|
2458
2555
|
content: {
|
|
2459
2556
|
"application/json": {
|
|
2460
2557
|
device_id: string;
|
|
@@ -2491,7 +2588,7 @@ interface operations {
|
|
|
2491
2588
|
path?: never;
|
|
2492
2589
|
cookie?: never;
|
|
2493
2590
|
};
|
|
2494
|
-
requestBody
|
|
2591
|
+
requestBody: {
|
|
2495
2592
|
content: {
|
|
2496
2593
|
"application/json": {
|
|
2497
2594
|
device_id: string;
|
|
@@ -2534,7 +2631,7 @@ interface operations {
|
|
|
2534
2631
|
path?: never;
|
|
2535
2632
|
cookie?: never;
|
|
2536
2633
|
};
|
|
2537
|
-
requestBody
|
|
2634
|
+
requestBody: {
|
|
2538
2635
|
content: {
|
|
2539
2636
|
"application/json": {
|
|
2540
2637
|
device_id: string;
|
|
@@ -2601,7 +2698,7 @@ interface operations {
|
|
|
2601
2698
|
path?: never;
|
|
2602
2699
|
cookie?: never;
|
|
2603
2700
|
};
|
|
2604
|
-
requestBody
|
|
2701
|
+
requestBody: {
|
|
2605
2702
|
content: {
|
|
2606
2703
|
"application/json": {
|
|
2607
2704
|
pairing_code: string;
|
|
@@ -2616,10 +2713,10 @@ interface operations {
|
|
|
2616
2713
|
};
|
|
2617
2714
|
content: {
|
|
2618
2715
|
"application/json": {
|
|
2619
|
-
message
|
|
2620
|
-
success
|
|
2621
|
-
content
|
|
2622
|
-
device
|
|
2716
|
+
message: string;
|
|
2717
|
+
success: boolean;
|
|
2718
|
+
content: {
|
|
2719
|
+
device: components["schemas"]["PosDevice"];
|
|
2623
2720
|
};
|
|
2624
2721
|
};
|
|
2625
2722
|
};
|
|
@@ -2635,7 +2732,7 @@ interface operations {
|
|
|
2635
2732
|
path?: never;
|
|
2636
2733
|
cookie?: never;
|
|
2637
2734
|
};
|
|
2638
|
-
requestBody
|
|
2735
|
+
requestBody: {
|
|
2639
2736
|
content: {
|
|
2640
2737
|
"application/json": {
|
|
2641
2738
|
refresh_token: string;
|
|
@@ -2650,11 +2747,11 @@ interface operations {
|
|
|
2650
2747
|
};
|
|
2651
2748
|
content: {
|
|
2652
2749
|
"application/json": {
|
|
2653
|
-
message
|
|
2654
|
-
success
|
|
2655
|
-
content
|
|
2656
|
-
access_token
|
|
2657
|
-
refresh_token
|
|
2750
|
+
message: string;
|
|
2751
|
+
success: boolean;
|
|
2752
|
+
content: {
|
|
2753
|
+
access_token: string;
|
|
2754
|
+
refresh_token: string;
|
|
2658
2755
|
};
|
|
2659
2756
|
};
|
|
2660
2757
|
};
|
|
@@ -2669,7 +2766,7 @@ interface operations {
|
|
|
2669
2766
|
path?: never;
|
|
2670
2767
|
cookie?: never;
|
|
2671
2768
|
};
|
|
2672
|
-
requestBody
|
|
2769
|
+
requestBody: {
|
|
2673
2770
|
content: {
|
|
2674
2771
|
"application/json": {
|
|
2675
2772
|
/** @description A string representing the one-time password. */
|
|
@@ -2763,10 +2860,10 @@ interface operations {
|
|
|
2763
2860
|
};
|
|
2764
2861
|
content: {
|
|
2765
2862
|
"application/json": {
|
|
2766
|
-
message
|
|
2767
|
-
success
|
|
2768
|
-
content
|
|
2769
|
-
coupons
|
|
2863
|
+
message: string;
|
|
2864
|
+
success: boolean;
|
|
2865
|
+
content: {
|
|
2866
|
+
coupons: components["schemas"]["Coupon"][];
|
|
2770
2867
|
};
|
|
2771
2868
|
};
|
|
2772
2869
|
};
|
|
@@ -2795,10 +2892,10 @@ interface operations {
|
|
|
2795
2892
|
};
|
|
2796
2893
|
content: {
|
|
2797
2894
|
"application/json": {
|
|
2798
|
-
message
|
|
2799
|
-
success
|
|
2800
|
-
content
|
|
2801
|
-
promotions
|
|
2895
|
+
message: string;
|
|
2896
|
+
success: boolean;
|
|
2897
|
+
content: {
|
|
2898
|
+
promotions: components["schemas"]["Promotion"][];
|
|
2802
2899
|
};
|
|
2803
2900
|
};
|
|
2804
2901
|
};
|
|
@@ -3086,11 +3183,11 @@ interface operations {
|
|
|
3086
3183
|
};
|
|
3087
3184
|
content: {
|
|
3088
3185
|
"application/json": {
|
|
3089
|
-
message
|
|
3090
|
-
success
|
|
3091
|
-
content
|
|
3092
|
-
applicable_coupons
|
|
3093
|
-
inapplicable_coupons
|
|
3186
|
+
message: string;
|
|
3187
|
+
success: boolean;
|
|
3188
|
+
content: {
|
|
3189
|
+
applicable_coupons: components["schemas"]["ApplicableCoupon"][];
|
|
3190
|
+
inapplicable_coupons: components["schemas"]["InapplicableCoupon"][];
|
|
3094
3191
|
};
|
|
3095
3192
|
};
|
|
3096
3193
|
};
|
|
@@ -3117,11 +3214,11 @@ interface operations {
|
|
|
3117
3214
|
};
|
|
3118
3215
|
content: {
|
|
3119
3216
|
"application/json": {
|
|
3120
|
-
message
|
|
3121
|
-
success
|
|
3122
|
-
content
|
|
3123
|
-
applicable_promotions
|
|
3124
|
-
inapplicable_promotions
|
|
3217
|
+
message: string;
|
|
3218
|
+
success: boolean;
|
|
3219
|
+
content: {
|
|
3220
|
+
applicable_promotions: components["schemas"]["ApplicablePromotion"][];
|
|
3221
|
+
inapplicable_promotions: components["schemas"]["InapplicablePromotion"][];
|
|
3125
3222
|
};
|
|
3126
3223
|
};
|
|
3127
3224
|
};
|
|
@@ -3284,7 +3381,7 @@ interface operations {
|
|
|
3284
3381
|
};
|
|
3285
3382
|
cookie?: never;
|
|
3286
3383
|
};
|
|
3287
|
-
requestBody
|
|
3384
|
+
requestBody: {
|
|
3288
3385
|
content: {
|
|
3289
3386
|
"application/json": components["schemas"]["PosUpdateCustomerWithId"] | components["schemas"]["PosUpdateCustomerWithPhone"] | components["schemas"]["PosUpdateCustomerWithEmail"];
|
|
3290
3387
|
};
|
|
@@ -3297,10 +3394,10 @@ interface operations {
|
|
|
3297
3394
|
};
|
|
3298
3395
|
content: {
|
|
3299
3396
|
"application/json": {
|
|
3300
|
-
message
|
|
3301
|
-
success
|
|
3302
|
-
content
|
|
3303
|
-
cart
|
|
3397
|
+
message: string;
|
|
3398
|
+
success: boolean;
|
|
3399
|
+
content: {
|
|
3400
|
+
cart: components["schemas"]["Cart"];
|
|
3304
3401
|
};
|
|
3305
3402
|
};
|
|
3306
3403
|
};
|
|
@@ -3813,7 +3910,7 @@ interface operations {
|
|
|
3813
3910
|
content: {
|
|
3814
3911
|
"application/json": {
|
|
3815
3912
|
cart_id: string;
|
|
3816
|
-
};
|
|
3913
|
+
} & (components["schemas"]["PayWithCash"] | components["schemas"]["PayWithUpi"] | components["schemas"]["PayWithCard"] | components["schemas"]["PayWithPaymentGateway"]);
|
|
3817
3914
|
};
|
|
3818
3915
|
};
|
|
3819
3916
|
responses: {
|
|
@@ -3838,6 +3935,71 @@ interface operations {
|
|
|
3838
3935
|
401: components["responses"]["Unauthorized"];
|
|
3839
3936
|
};
|
|
3840
3937
|
};
|
|
3938
|
+
"pos-get-payment-status": {
|
|
3939
|
+
parameters: {
|
|
3940
|
+
query?: never;
|
|
3941
|
+
header?: never;
|
|
3942
|
+
path: {
|
|
3943
|
+
/** @description order number */
|
|
3944
|
+
order_number: string;
|
|
3945
|
+
};
|
|
3946
|
+
cookie?: never;
|
|
3947
|
+
};
|
|
3948
|
+
requestBody?: never;
|
|
3949
|
+
responses: {
|
|
3950
|
+
/** @description OK */
|
|
3951
|
+
200: {
|
|
3952
|
+
headers: {
|
|
3953
|
+
[name: string]: unknown;
|
|
3954
|
+
};
|
|
3955
|
+
content: {
|
|
3956
|
+
"application/json": {
|
|
3957
|
+
/** @default order details */
|
|
3958
|
+
readonly message: string;
|
|
3959
|
+
readonly success: boolean;
|
|
3960
|
+
content: {
|
|
3961
|
+
/** @enum {string} */
|
|
3962
|
+
status: "pending" | "success" | "failed" | "partially_paid";
|
|
3963
|
+
/** Format: double */
|
|
3964
|
+
amount_paid: number;
|
|
3965
|
+
/** Format: double */
|
|
3966
|
+
amount_unpaid: number;
|
|
3967
|
+
is_retry_available: boolean;
|
|
3968
|
+
};
|
|
3969
|
+
};
|
|
3970
|
+
};
|
|
3971
|
+
};
|
|
3972
|
+
401: components["responses"]["Unauthorized"];
|
|
3973
|
+
404: components["responses"]["NotFound"];
|
|
3974
|
+
};
|
|
3975
|
+
};
|
|
3976
|
+
"pos-list-payment-options": {
|
|
3977
|
+
parameters: {
|
|
3978
|
+
query?: never;
|
|
3979
|
+
header?: never;
|
|
3980
|
+
path?: never;
|
|
3981
|
+
cookie?: never;
|
|
3982
|
+
};
|
|
3983
|
+
requestBody?: never;
|
|
3984
|
+
responses: {
|
|
3985
|
+
/** @description OK */
|
|
3986
|
+
200: {
|
|
3987
|
+
headers: {
|
|
3988
|
+
[name: string]: unknown;
|
|
3989
|
+
};
|
|
3990
|
+
content: {
|
|
3991
|
+
"application/json": {
|
|
3992
|
+
message?: string;
|
|
3993
|
+
success?: boolean;
|
|
3994
|
+
content?: {
|
|
3995
|
+
payment_options?: ("CASH" | "UPI" | "CARD" | "PG")[];
|
|
3996
|
+
};
|
|
3997
|
+
};
|
|
3998
|
+
};
|
|
3999
|
+
};
|
|
4000
|
+
401: components["responses"]["Unauthorized"];
|
|
4001
|
+
};
|
|
4002
|
+
};
|
|
3841
4003
|
"order-created": {
|
|
3842
4004
|
parameters: {
|
|
3843
4005
|
query?: never;
|
|
@@ -4120,94 +4282,1826 @@ interface operations {
|
|
|
4120
4282
|
};
|
|
4121
4283
|
}
|
|
4122
4284
|
//#endregion
|
|
4123
|
-
//#region
|
|
4124
|
-
//#region src/types/api.d.ts
|
|
4125
|
-
|
|
4126
|
-
/**
|
|
4127
|
-
* Core API response types shared across Commerce Engine SDKs
|
|
4128
|
-
*/
|
|
4129
|
-
/**
|
|
4130
|
-
* Standard API error response structure
|
|
4131
|
-
*/
|
|
4132
|
-
interface ApiErrorResponse {
|
|
4133
|
-
success?: boolean;
|
|
4134
|
-
error?: any;
|
|
4135
|
-
code?: string;
|
|
4136
|
-
message?: string;
|
|
4137
|
-
}
|
|
4138
|
-
/**
|
|
4139
|
-
* Generic API result type that wraps all SDK responses
|
|
4140
|
-
* Provides consistent error handling and response structure
|
|
4141
|
-
*/
|
|
4142
|
-
type ApiResult<T> = {
|
|
4143
|
-
data: T;
|
|
4144
|
-
error: null;
|
|
4145
|
-
response: Response;
|
|
4146
|
-
} | {
|
|
4147
|
-
data: null;
|
|
4148
|
-
error: ApiErrorResponse;
|
|
4149
|
-
response: Response;
|
|
4150
|
-
};
|
|
4151
|
-
//#endregion
|
|
4152
|
-
//#region src/types/logger.d.ts
|
|
4153
|
-
/**
|
|
4154
|
-
* Logger-related types for Commerce Engine SDKs
|
|
4155
|
-
*/
|
|
4156
|
-
/**
|
|
4157
|
-
* Debug logger function interface
|
|
4158
|
-
*/
|
|
4159
|
-
interface DebugLoggerFn {
|
|
4160
|
-
(level: "info" | "warn" | "error", message: string, data?: any): void;
|
|
4161
|
-
}
|
|
4162
|
-
//#endregion
|
|
4163
|
-
//#region src/types/config.d.ts
|
|
4164
|
-
/**
|
|
4165
|
-
* Base SDK configuration options for any OpenAPI-based SDK
|
|
4166
|
-
* Completely generic - no assumptions about the underlying API
|
|
4167
|
-
*/
|
|
4168
|
-
interface BaseSDKOptions<TDefaultHeaders extends Record<string, any> = Record<string, any>> {
|
|
4169
|
-
/**
|
|
4170
|
-
* Base URL for the API
|
|
4171
|
-
*/
|
|
4172
|
-
baseUrl?: string;
|
|
4173
|
-
/**
|
|
4174
|
-
* Optional timeout in milliseconds
|
|
4175
|
-
*/
|
|
4176
|
-
timeout?: number;
|
|
4177
|
-
/**
|
|
4178
|
-
* Default headers to include with API requests
|
|
4179
|
-
* These can be overridden at the method level
|
|
4180
|
-
* Generic type allows each SDK to define its supported headers
|
|
4181
|
-
*/
|
|
4182
|
-
defaultHeaders?: TDefaultHeaders;
|
|
4183
|
-
/**
|
|
4184
|
-
* Enable debug mode for detailed request/response logging
|
|
4185
|
-
*/
|
|
4186
|
-
debug?: boolean;
|
|
4187
|
-
/**
|
|
4188
|
-
* Custom logger function for debug information
|
|
4189
|
-
*/
|
|
4190
|
-
logger?: DebugLoggerFn;
|
|
4191
|
-
}
|
|
4285
|
+
//#region src/types/admin-pos.d.ts
|
|
4192
4286
|
/**
|
|
4193
|
-
*
|
|
4194
|
-
*
|
|
4287
|
+
* This file was auto-generated by openapi-typescript.
|
|
4288
|
+
* Do not make direct changes to the file.
|
|
4195
4289
|
*/
|
|
4196
|
-
|
|
4197
|
-
|
|
4198
|
-
|
|
4199
|
-
|
|
4200
|
-
|
|
4201
|
-
|
|
4202
|
-
|
|
4203
|
-
|
|
4204
|
-
|
|
4205
|
-
|
|
4206
|
-
|
|
4207
|
-
|
|
4208
|
-
|
|
4209
|
-
|
|
4210
|
-
|
|
4290
|
+
|
|
4291
|
+
interface paths$1 {
|
|
4292
|
+
"/pos/catalog/inventories": {
|
|
4293
|
+
parameters: {
|
|
4294
|
+
query?: never;
|
|
4295
|
+
header?: never;
|
|
4296
|
+
path?: never;
|
|
4297
|
+
cookie?: never;
|
|
4298
|
+
};
|
|
4299
|
+
/**
|
|
4300
|
+
* List all inventories
|
|
4301
|
+
* @description List all inventories
|
|
4302
|
+
*/
|
|
4303
|
+
get: operations$1["pos-list-inventories"];
|
|
4304
|
+
put?: never;
|
|
4305
|
+
post?: never;
|
|
4306
|
+
delete?: never;
|
|
4307
|
+
options?: never;
|
|
4308
|
+
head?: never;
|
|
4309
|
+
patch?: never;
|
|
4310
|
+
trace?: never;
|
|
4311
|
+
};
|
|
4312
|
+
"/pos/catalog/inventories/activites": {
|
|
4313
|
+
parameters: {
|
|
4314
|
+
query?: never;
|
|
4315
|
+
header?: never;
|
|
4316
|
+
path?: never;
|
|
4317
|
+
cookie?: never;
|
|
4318
|
+
};
|
|
4319
|
+
/**
|
|
4320
|
+
* List all inventories activities
|
|
4321
|
+
* @description Lists all inventory related activities of stock movements. This provides a comprehensive audit trail of inventory operations such as receiving, reservations, adjustments, transfers, and sales.
|
|
4322
|
+
*/
|
|
4323
|
+
get: operations$1["pos-list-inventories-activities"];
|
|
4324
|
+
put?: never;
|
|
4325
|
+
post?: never;
|
|
4326
|
+
delete?: never;
|
|
4327
|
+
options?: never;
|
|
4328
|
+
head?: never;
|
|
4329
|
+
patch?: never;
|
|
4330
|
+
trace?: never;
|
|
4331
|
+
};
|
|
4332
|
+
"/pos/catalog/inventories/detail": {
|
|
4333
|
+
parameters: {
|
|
4334
|
+
query?: never;
|
|
4335
|
+
header?: never;
|
|
4336
|
+
path?: never;
|
|
4337
|
+
cookie?: never;
|
|
4338
|
+
};
|
|
4339
|
+
/**
|
|
4340
|
+
* Retrieve inventory detail
|
|
4341
|
+
* @description Retrieves inventory details for a specific product, product variant, or lot/batch based on the parameters provided.
|
|
4342
|
+
*/
|
|
4343
|
+
get: operations$1["pos-get-inventory-detail"];
|
|
4344
|
+
put?: never;
|
|
4345
|
+
post?: never;
|
|
4346
|
+
delete?: never;
|
|
4347
|
+
options?: never;
|
|
4348
|
+
head?: never;
|
|
4349
|
+
patch?: never;
|
|
4350
|
+
trace?: never;
|
|
4351
|
+
};
|
|
4352
|
+
"/pos/customers": {
|
|
4353
|
+
parameters: {
|
|
4354
|
+
query?: never;
|
|
4355
|
+
header?: never;
|
|
4356
|
+
path?: never;
|
|
4357
|
+
cookie?: never;
|
|
4358
|
+
};
|
|
4359
|
+
/**
|
|
4360
|
+
* List all customers
|
|
4361
|
+
* @description List all customers
|
|
4362
|
+
*/
|
|
4363
|
+
get: operations$1["pos-get-admin-customers"];
|
|
4364
|
+
put?: never;
|
|
4365
|
+
post?: never;
|
|
4366
|
+
delete?: never;
|
|
4367
|
+
options?: never;
|
|
4368
|
+
head?: never;
|
|
4369
|
+
patch?: never;
|
|
4370
|
+
trace?: never;
|
|
4371
|
+
};
|
|
4372
|
+
"/pos/customers/{id}": {
|
|
4373
|
+
parameters: {
|
|
4374
|
+
query?: never;
|
|
4375
|
+
header?: never;
|
|
4376
|
+
path?: never;
|
|
4377
|
+
cookie?: never;
|
|
4378
|
+
};
|
|
4379
|
+
/**
|
|
4380
|
+
* Retrieve customer detail
|
|
4381
|
+
* @description Retrieve customer detail
|
|
4382
|
+
*/
|
|
4383
|
+
get: operations$1["pos-get-admin-customers-id"];
|
|
4384
|
+
put?: never;
|
|
4385
|
+
post?: never;
|
|
4386
|
+
delete?: never;
|
|
4387
|
+
options?: never;
|
|
4388
|
+
head?: never;
|
|
4389
|
+
patch?: never;
|
|
4390
|
+
trace?: never;
|
|
4391
|
+
};
|
|
4392
|
+
"/pos/orders": {
|
|
4393
|
+
parameters: {
|
|
4394
|
+
query?: never;
|
|
4395
|
+
header?: never;
|
|
4396
|
+
path?: never;
|
|
4397
|
+
cookie?: never;
|
|
4398
|
+
};
|
|
4399
|
+
/**
|
|
4400
|
+
* List all orders
|
|
4401
|
+
* @description List all orders
|
|
4402
|
+
*/
|
|
4403
|
+
get: operations$1["pos-list-admin-orders"];
|
|
4404
|
+
put?: never;
|
|
4405
|
+
post?: never;
|
|
4406
|
+
delete?: never;
|
|
4407
|
+
options?: never;
|
|
4408
|
+
head?: never;
|
|
4409
|
+
patch?: never;
|
|
4410
|
+
trace?: never;
|
|
4411
|
+
};
|
|
4412
|
+
"/pos/orders/{order_number}": {
|
|
4413
|
+
parameters: {
|
|
4414
|
+
query?: never;
|
|
4415
|
+
header?: never;
|
|
4416
|
+
path?: never;
|
|
4417
|
+
cookie?: never;
|
|
4418
|
+
};
|
|
4419
|
+
/**
|
|
4420
|
+
* Retrieve order details
|
|
4421
|
+
* @description Retrieve order details
|
|
4422
|
+
*/
|
|
4423
|
+
get: operations$1["pos-get-admin-order"];
|
|
4424
|
+
put?: never;
|
|
4425
|
+
post?: never;
|
|
4426
|
+
delete?: never;
|
|
4427
|
+
options?: never;
|
|
4428
|
+
head?: never;
|
|
4429
|
+
patch?: never;
|
|
4430
|
+
trace?: never;
|
|
4431
|
+
};
|
|
4432
|
+
"/pos/orders/{order_number}/activity": {
|
|
4433
|
+
parameters: {
|
|
4434
|
+
query?: never;
|
|
4435
|
+
header?: never;
|
|
4436
|
+
path?: never;
|
|
4437
|
+
cookie?: never;
|
|
4438
|
+
};
|
|
4439
|
+
/**
|
|
4440
|
+
* List all order activity
|
|
4441
|
+
* @description List all order activity
|
|
4442
|
+
*/
|
|
4443
|
+
get: operations$1["pos-list-order-activity"];
|
|
4444
|
+
put?: never;
|
|
4445
|
+
post?: never;
|
|
4446
|
+
delete?: never;
|
|
4447
|
+
options?: never;
|
|
4448
|
+
head?: never;
|
|
4449
|
+
patch?: never;
|
|
4450
|
+
trace?: never;
|
|
4451
|
+
};
|
|
4452
|
+
"/pos/orders/{order_number}/invoice": {
|
|
4453
|
+
parameters: {
|
|
4454
|
+
query?: never;
|
|
4455
|
+
header?: never;
|
|
4456
|
+
path?: never;
|
|
4457
|
+
cookie?: never;
|
|
4458
|
+
};
|
|
4459
|
+
/**
|
|
4460
|
+
* Retrieve order invoice
|
|
4461
|
+
* @description Retrieve order invoice
|
|
4462
|
+
*/
|
|
4463
|
+
get: operations$1["pos-get-order-invoice"];
|
|
4464
|
+
put?: never;
|
|
4465
|
+
post?: never;
|
|
4466
|
+
delete?: never;
|
|
4467
|
+
options?: never;
|
|
4468
|
+
head?: never;
|
|
4469
|
+
patch?: never;
|
|
4470
|
+
trace?: never;
|
|
4471
|
+
};
|
|
4472
|
+
"/pos/orders/{order_number}/receipt": {
|
|
4473
|
+
parameters: {
|
|
4474
|
+
query?: never;
|
|
4475
|
+
header?: never;
|
|
4476
|
+
path?: never;
|
|
4477
|
+
cookie?: never;
|
|
4478
|
+
};
|
|
4479
|
+
/**
|
|
4480
|
+
* Retrieve order receipt
|
|
4481
|
+
* @description Retrieves a printable receipt for a specific order using the order number. This endpoint returns either structured JSON data or a formatted PDF, suitable for customer presentation. Response format (JSON or PDF) is determined by an optional query parameter (e.g. format=pdf or format=json).
|
|
4482
|
+
*/
|
|
4483
|
+
get: operations$1["pos-get-order-receipt"];
|
|
4484
|
+
put?: never;
|
|
4485
|
+
post?: never;
|
|
4486
|
+
delete?: never;
|
|
4487
|
+
options?: never;
|
|
4488
|
+
head?: never;
|
|
4489
|
+
patch?: never;
|
|
4490
|
+
trace?: never;
|
|
4491
|
+
};
|
|
4492
|
+
"/pos/orders/{order_number}/shipments": {
|
|
4493
|
+
parameters: {
|
|
4494
|
+
query?: never;
|
|
4495
|
+
header?: never;
|
|
4496
|
+
path?: never;
|
|
4497
|
+
cookie?: never;
|
|
4498
|
+
};
|
|
4499
|
+
/**
|
|
4500
|
+
* Retrieve order shipments
|
|
4501
|
+
* @description Retrieve order shipments
|
|
4502
|
+
*/
|
|
4503
|
+
get: operations$1["pos-get-order-shipments"];
|
|
4504
|
+
put?: never;
|
|
4505
|
+
post?: never;
|
|
4506
|
+
delete?: never;
|
|
4507
|
+
options?: never;
|
|
4508
|
+
head?: never;
|
|
4509
|
+
patch?: never;
|
|
4510
|
+
trace?: never;
|
|
4511
|
+
};
|
|
4512
|
+
"/pos/shipping/shipments": {
|
|
4513
|
+
parameters: {
|
|
4514
|
+
query?: never;
|
|
4515
|
+
header?: never;
|
|
4516
|
+
path?: never;
|
|
4517
|
+
cookie?: never;
|
|
4518
|
+
};
|
|
4519
|
+
/**
|
|
4520
|
+
* List all shipments
|
|
4521
|
+
* @description List all shipments
|
|
4522
|
+
*/
|
|
4523
|
+
get: operations$1["pos-list-shipments"];
|
|
4524
|
+
put?: never;
|
|
4525
|
+
post?: never;
|
|
4526
|
+
delete?: never;
|
|
4527
|
+
options?: never;
|
|
4528
|
+
head?: never;
|
|
4529
|
+
patch?: never;
|
|
4530
|
+
trace?: never;
|
|
4531
|
+
};
|
|
4532
|
+
"/pos/shipping/shipments/{order_number}/check-inventory": {
|
|
4533
|
+
parameters: {
|
|
4534
|
+
query?: never;
|
|
4535
|
+
header?: never;
|
|
4536
|
+
path?: never;
|
|
4537
|
+
cookie?: never;
|
|
4538
|
+
};
|
|
4539
|
+
/**
|
|
4540
|
+
* Check Inventory
|
|
4541
|
+
* @description Check Inventory
|
|
4542
|
+
*/
|
|
4543
|
+
get: operations$1["pos-check-inventory-for-order"];
|
|
4544
|
+
put?: never;
|
|
4545
|
+
post?: never;
|
|
4546
|
+
delete?: never;
|
|
4547
|
+
options?: never;
|
|
4548
|
+
head?: never;
|
|
4549
|
+
patch?: never;
|
|
4550
|
+
trace?: never;
|
|
4551
|
+
};
|
|
4552
|
+
"/pos/shipping/shipments/{order_number}/refund-shortfall": {
|
|
4553
|
+
parameters: {
|
|
4554
|
+
query?: never;
|
|
4555
|
+
header?: never;
|
|
4556
|
+
path?: never;
|
|
4557
|
+
cookie?: never;
|
|
4558
|
+
};
|
|
4559
|
+
get?: never;
|
|
4560
|
+
put?: never;
|
|
4561
|
+
/**
|
|
4562
|
+
* Refund shortfall
|
|
4563
|
+
* @description Refund shortfall
|
|
4564
|
+
*/
|
|
4565
|
+
post: operations$1["pos-refund-shortfall-for-order"];
|
|
4566
|
+
delete?: never;
|
|
4567
|
+
options?: never;
|
|
4568
|
+
head?: never;
|
|
4569
|
+
patch?: never;
|
|
4570
|
+
trace?: never;
|
|
4571
|
+
};
|
|
4572
|
+
"/pos/shipping/shipments/{reference_number}": {
|
|
4573
|
+
parameters: {
|
|
4574
|
+
query?: never;
|
|
4575
|
+
header?: never;
|
|
4576
|
+
path?: never;
|
|
4577
|
+
cookie?: never;
|
|
4578
|
+
};
|
|
4579
|
+
/**
|
|
4580
|
+
* Retrieve shipment detail
|
|
4581
|
+
* @description Retrieve shipment detail
|
|
4582
|
+
*/
|
|
4583
|
+
get: operations$1["pos-get-shipment"];
|
|
4584
|
+
put?: never;
|
|
4585
|
+
post?: never;
|
|
4586
|
+
delete?: never;
|
|
4587
|
+
options?: never;
|
|
4588
|
+
head?: never;
|
|
4589
|
+
patch?: never;
|
|
4590
|
+
trace?: never;
|
|
4591
|
+
};
|
|
4592
|
+
"/pos/shipping/shipments/{reference_number}/invoice": {
|
|
4593
|
+
parameters: {
|
|
4594
|
+
query?: never;
|
|
4595
|
+
header?: never;
|
|
4596
|
+
path?: never;
|
|
4597
|
+
cookie?: never;
|
|
4598
|
+
};
|
|
4599
|
+
/**
|
|
4600
|
+
* Retrieve shipment invoice
|
|
4601
|
+
* @description Retrieve shipment invoice
|
|
4602
|
+
*/
|
|
4603
|
+
get: operations$1["pos-get-shipment-invoice"];
|
|
4604
|
+
put?: never;
|
|
4605
|
+
post?: never;
|
|
4606
|
+
delete?: never;
|
|
4607
|
+
options?: never;
|
|
4608
|
+
head?: never;
|
|
4609
|
+
patch?: never;
|
|
4610
|
+
trace?: never;
|
|
4611
|
+
};
|
|
4612
|
+
"/pos/shipping/shipments/{reference_number}/manual-update": {
|
|
4613
|
+
parameters: {
|
|
4614
|
+
query?: never;
|
|
4615
|
+
header?: never;
|
|
4616
|
+
path?: never;
|
|
4617
|
+
cookie?: never;
|
|
4618
|
+
};
|
|
4619
|
+
get?: never;
|
|
4620
|
+
/**
|
|
4621
|
+
* Update shipment detail
|
|
4622
|
+
* @description Update shipment detail
|
|
4623
|
+
*/
|
|
4624
|
+
put: operations$1["pos-update-shipment"];
|
|
4625
|
+
post?: never;
|
|
4626
|
+
delete?: never;
|
|
4627
|
+
options?: never;
|
|
4628
|
+
head?: never;
|
|
4629
|
+
patch?: never;
|
|
4630
|
+
trace?: never;
|
|
4631
|
+
};
|
|
4632
|
+
}
|
|
4633
|
+
interface components$1 {
|
|
4634
|
+
schemas: {
|
|
4635
|
+
/**
|
|
4636
|
+
* BankTransfer
|
|
4637
|
+
* @description Bank transfer payment - IMPS, NEFT, RTGS
|
|
4638
|
+
*/
|
|
4639
|
+
BankTransfer: components$1["schemas"]["OrderPaymentInfo"] & {
|
|
4640
|
+
/** @description masked account number
|
|
4641
|
+
* e.g. ************1234 */
|
|
4642
|
+
bank_account_number?: string;
|
|
4643
|
+
bank_name?: string;
|
|
4644
|
+
};
|
|
4645
|
+
/** BusinessInfo */
|
|
4646
|
+
BusinessInfo: {
|
|
4647
|
+
name?: string;
|
|
4648
|
+
business_type?: string;
|
|
4649
|
+
pan_number?: string;
|
|
4650
|
+
gstin?: string;
|
|
4651
|
+
is_registered_under_gst?: boolean;
|
|
4652
|
+
};
|
|
4653
|
+
/**
|
|
4654
|
+
* CardPayment
|
|
4655
|
+
* @description Payments using credit card, debit card
|
|
4656
|
+
*/
|
|
4657
|
+
CardPayment: components$1["schemas"]["OrderPaymentInfo"] & {
|
|
4658
|
+
/** @description masked card number
|
|
4659
|
+
* e.g. ************1111 */
|
|
4660
|
+
card_number?: string;
|
|
4661
|
+
/** @enum {unknown} */
|
|
4662
|
+
card_type?: "Visa" | "Master Card" | "Rupay";
|
|
4663
|
+
};
|
|
4664
|
+
/** Customer */
|
|
4665
|
+
Customer: components$1["schemas"]["CustomerInfo"] & {
|
|
4666
|
+
business?: components$1["schemas"]["BusinessInfo"];
|
|
4667
|
+
segments?: components$1["schemas"]["CustomerSegment"][];
|
|
4668
|
+
};
|
|
4669
|
+
/** CustomerAddress */
|
|
4670
|
+
CustomerAddress: {
|
|
4671
|
+
readonly id?: string;
|
|
4672
|
+
first_name: string;
|
|
4673
|
+
last_name?: string;
|
|
4674
|
+
/** @description Two-letter code begin with a plus sign prefix that identifies different countries. By default it will be +91 if not provided.
|
|
4675
|
+
* */
|
|
4676
|
+
country_code?: string;
|
|
4677
|
+
/** @description 10 digit phone number without country code. */
|
|
4678
|
+
phone: string;
|
|
4679
|
+
email: string;
|
|
4680
|
+
address_line1: string;
|
|
4681
|
+
address_line2?: string | null;
|
|
4682
|
+
landmark?: string | null;
|
|
4683
|
+
pincode: string;
|
|
4684
|
+
city: string;
|
|
4685
|
+
state: string;
|
|
4686
|
+
/** @enum {unknown} */
|
|
4687
|
+
country: "India";
|
|
4688
|
+
/** @description Use in shipping details only for third party. */
|
|
4689
|
+
gstin?: string | null;
|
|
4690
|
+
/** @description Use in shipping details only for third party. */
|
|
4691
|
+
business_name?: string | null;
|
|
4692
|
+
readonly is_phone_verified?: boolean;
|
|
4693
|
+
readonly is_email_verified?: boolean;
|
|
4694
|
+
};
|
|
4695
|
+
/** CustomerDetail */
|
|
4696
|
+
CustomerDetail: components$1["schemas"]["Customer"] & {
|
|
4697
|
+
loyalty?: components$1["schemas"]["CustomerLoyalty"];
|
|
4698
|
+
notification_preferences?: components$1["schemas"]["NotificationPreferences"];
|
|
4699
|
+
};
|
|
4700
|
+
/** CustomerInfo */
|
|
4701
|
+
CustomerInfo: {
|
|
4702
|
+
/** @description user id */
|
|
4703
|
+
readonly id?: string;
|
|
4704
|
+
first_name?: string;
|
|
4705
|
+
last_name?: string;
|
|
4706
|
+
readonly full_name?: string;
|
|
4707
|
+
readonly profile_image_url?: string;
|
|
4708
|
+
country_code?: string;
|
|
4709
|
+
phone?: string;
|
|
4710
|
+
email?: string;
|
|
4711
|
+
readonly is_phone_verified?: boolean;
|
|
4712
|
+
readonly is_email_verified?: boolean;
|
|
4713
|
+
readonly is_whatsapp_verified?: boolean;
|
|
4714
|
+
/** @enum {unknown} */
|
|
4715
|
+
status?: "active" | "inactive" | "suspended" | "blocked";
|
|
4716
|
+
/** Format: date-time */
|
|
4717
|
+
readonly created_at?: string;
|
|
4718
|
+
/** Format: date-time */
|
|
4719
|
+
readonly modified_at?: string;
|
|
4720
|
+
/** Format: date-time */
|
|
4721
|
+
readonly last_seen?: string;
|
|
4722
|
+
readonly kyc_status?: boolean;
|
|
4723
|
+
readonly is_verified?: boolean;
|
|
4724
|
+
tags?: string[];
|
|
4725
|
+
};
|
|
4726
|
+
/** CustomerLoyalty */
|
|
4727
|
+
CustomerLoyalty: {
|
|
4728
|
+
membership_number?: string;
|
|
4729
|
+
/** @description total points earned within the current loyalty program. */
|
|
4730
|
+
points_earned?: number;
|
|
4731
|
+
/** @description total points redeemed within the current loyalty program. */
|
|
4732
|
+
points_redeemed?: number;
|
|
4733
|
+
/** @description total points available. */
|
|
4734
|
+
points_balance?: number;
|
|
4735
|
+
/** @description The total amount a customer has spent within the current loyalty program, excluding taxes, promotional discounts, and redeemed loyalty points. This value is used to determine tier eligibility and earning points calculation. */
|
|
4736
|
+
total_spent?: number;
|
|
4737
|
+
/** @description The total number of completed orders counted in the current loyalty program. */
|
|
4738
|
+
total_orders?: number;
|
|
4739
|
+
/** @description The total amount a customer has spent across all time, regardless of loyalty program participation. This includes all completed orders and excludes taxes, promotional discounts, and redeemed points. */
|
|
4740
|
+
lifetime_spent?: number;
|
|
4741
|
+
/** @description The total number of completed orders across all time, regardless of loyalty program. */
|
|
4742
|
+
lifetime_orders?: number;
|
|
4743
|
+
/**
|
|
4744
|
+
* Format: date-time
|
|
4745
|
+
* @description The date and time when the customer first enrolled in the loyalty program.
|
|
4746
|
+
*/
|
|
4747
|
+
date_of_join?: string;
|
|
4748
|
+
/**
|
|
4749
|
+
* Format: date-time
|
|
4750
|
+
* @description The date and time when the customer's current loyalty tier or program instance was assigned. This may change when tiers are upgraded, downgraded, or reassigned.
|
|
4751
|
+
*/
|
|
4752
|
+
date_of_assign?: string | null;
|
|
4753
|
+
/**
|
|
4754
|
+
* Format: date-time
|
|
4755
|
+
* @description The date and time when the customer’s current loyalty program cycle will reset, at which points earned, points redeemed, balance points, total spent, total orders will be cleared.
|
|
4756
|
+
*/
|
|
4757
|
+
date_of_reset?: string | null;
|
|
4758
|
+
current_tier?: {
|
|
4759
|
+
id?: string;
|
|
4760
|
+
name?: string;
|
|
4761
|
+
};
|
|
4762
|
+
next_tier?: {
|
|
4763
|
+
id?: string;
|
|
4764
|
+
name?: string;
|
|
4765
|
+
total_spent_threshold?: number | null;
|
|
4766
|
+
total_orders_threshold?: number | null;
|
|
4767
|
+
};
|
|
4768
|
+
};
|
|
4769
|
+
/** CustomerSegment */
|
|
4770
|
+
CustomerSegment: {
|
|
4771
|
+
id?: string;
|
|
4772
|
+
name?: string;
|
|
4773
|
+
};
|
|
4774
|
+
/** InventoryActivity */
|
|
4775
|
+
InventoryActivity: {
|
|
4776
|
+
product_id?: string;
|
|
4777
|
+
product_name?: string;
|
|
4778
|
+
variant_id?: string;
|
|
4779
|
+
variant_name?: string;
|
|
4780
|
+
sku?: string;
|
|
4781
|
+
warehouse_id?: string;
|
|
4782
|
+
warehouse?: components$1["schemas"]["WarehouseBasicDetail"];
|
|
4783
|
+
/** @enum {unknown} */
|
|
4784
|
+
activity_type?: "add" | "reserve" | "reduce" | "adjust" | "update";
|
|
4785
|
+
quantity?: number;
|
|
4786
|
+
reason?: string;
|
|
4787
|
+
lot_batch?: string;
|
|
4788
|
+
/** Format: date */
|
|
4789
|
+
mfg_date?: string;
|
|
4790
|
+
/** Format: date */
|
|
4791
|
+
exp_date?: string;
|
|
4792
|
+
manufacturer?: string;
|
|
4793
|
+
/** Format: date-time */
|
|
4794
|
+
created_at?: string;
|
|
4795
|
+
/** Format: date-time */
|
|
4796
|
+
modified_at?: string;
|
|
4797
|
+
};
|
|
4798
|
+
/** InventoryDetail */
|
|
4799
|
+
InventoryDetail: components$1["schemas"]["ItemWiseInventory"] & {
|
|
4800
|
+
details?: components$1["schemas"]["WarehouseWiseInventory"][];
|
|
4801
|
+
};
|
|
4802
|
+
/**
|
|
4803
|
+
* Invoice
|
|
4804
|
+
* @description Invoice model
|
|
4805
|
+
*/
|
|
4806
|
+
Invoice: {
|
|
4807
|
+
invoice_number?: string;
|
|
4808
|
+
/** Format: date-time */
|
|
4809
|
+
invoice_date?: string;
|
|
4810
|
+
/** @description Invoice Reference Number */
|
|
4811
|
+
irn_number?: string;
|
|
4812
|
+
/** @description Acknowledgement Number */
|
|
4813
|
+
ack_number?: string;
|
|
4814
|
+
/**
|
|
4815
|
+
* Format: date-time
|
|
4816
|
+
* @description Acknowledgement Date
|
|
4817
|
+
*/
|
|
4818
|
+
ack_date?: string;
|
|
4819
|
+
signed_qr_code?: string;
|
|
4820
|
+
gatepass_barcode?: string;
|
|
4821
|
+
seller_details?: components$1["schemas"]["Warehouse"];
|
|
4822
|
+
billing_address?: components$1["schemas"]["CustomerAddress"];
|
|
4823
|
+
shipping_address?: components$1["schemas"]["CustomerAddress"];
|
|
4824
|
+
subtotal?: number;
|
|
4825
|
+
shipping_amount?: number;
|
|
4826
|
+
coupon_code?: string;
|
|
4827
|
+
coupon_discount_percent?: number;
|
|
4828
|
+
coupon_discount_amount?: number;
|
|
4829
|
+
total_tax?: number;
|
|
4830
|
+
grand_total?: number;
|
|
4831
|
+
tax_summary?: {
|
|
4832
|
+
tax_rate?: number;
|
|
4833
|
+
taxable_value?: number;
|
|
4834
|
+
igst?: number;
|
|
4835
|
+
cgst?: number;
|
|
4836
|
+
sgst?: number;
|
|
4837
|
+
}[];
|
|
4838
|
+
/** Format: date-time */
|
|
4839
|
+
created_at?: string;
|
|
4840
|
+
/** Format: date-time */
|
|
4841
|
+
modified_at?: string;
|
|
4842
|
+
};
|
|
4843
|
+
/**
|
|
4844
|
+
* InvoiceDetail
|
|
4845
|
+
* @description InvoiceDetail model
|
|
4846
|
+
*/
|
|
4847
|
+
InvoiceDetail: components$1["schemas"]["Invoice"] & {
|
|
4848
|
+
items?: components$1["schemas"]["InvoiceItem"][];
|
|
4849
|
+
};
|
|
4850
|
+
/**
|
|
4851
|
+
* InvoiceItem
|
|
4852
|
+
* @description InvoiceItem model
|
|
4853
|
+
*/
|
|
4854
|
+
InvoiceItem: {
|
|
4855
|
+
sku?: string;
|
|
4856
|
+
product_name?: string;
|
|
4857
|
+
product_image_url?: string;
|
|
4858
|
+
listing_price?: number;
|
|
4859
|
+
selling_price?: number;
|
|
4860
|
+
qty?: number;
|
|
4861
|
+
free_qty?: number;
|
|
4862
|
+
tax_type?: string;
|
|
4863
|
+
tax_rate?: number;
|
|
4864
|
+
hsncode?: string;
|
|
4865
|
+
batch_number?: string;
|
|
4866
|
+
expiry?: string;
|
|
4867
|
+
amount?: number;
|
|
4868
|
+
};
|
|
4869
|
+
/** ItemWiseInventory */
|
|
4870
|
+
ItemWiseInventory: {
|
|
4871
|
+
product_id?: string;
|
|
4872
|
+
product_name?: string;
|
|
4873
|
+
variant_id?: string;
|
|
4874
|
+
variant_name?: string;
|
|
4875
|
+
sku?: string;
|
|
4876
|
+
track_quantity?: boolean;
|
|
4877
|
+
allow_backorder?: boolean;
|
|
4878
|
+
track_lot_bacth?: boolean;
|
|
4879
|
+
received_quantity?: number;
|
|
4880
|
+
reserved_quantity?: number;
|
|
4881
|
+
sold_quantity?: number;
|
|
4882
|
+
adjusted_quantity?: number;
|
|
4883
|
+
stock_quantity?: number;
|
|
4884
|
+
};
|
|
4885
|
+
/** LotBatchWiseInventory */
|
|
4886
|
+
LotBatchWiseInventory: components$1["schemas"]["ItemWiseInventory"] & {
|
|
4887
|
+
lot_batch?: string;
|
|
4888
|
+
/** Format: date */
|
|
4889
|
+
mfg_date?: string;
|
|
4890
|
+
/** Format: date */
|
|
4891
|
+
exp_date?: string;
|
|
4892
|
+
manufacturer?: string;
|
|
4893
|
+
};
|
|
4894
|
+
/**
|
|
4895
|
+
* LoyaltyPointPayment
|
|
4896
|
+
* @description Loyalty point redemption.
|
|
4897
|
+
*/
|
|
4898
|
+
LoyaltyPointPayment: components$1["schemas"]["OrderPaymentInfo"];
|
|
4899
|
+
/**
|
|
4900
|
+
* NetbankingPayment
|
|
4901
|
+
* @description Payments using payment gateway netbanking option.
|
|
4902
|
+
*/
|
|
4903
|
+
NetbankingPayment: components$1["schemas"]["OrderPaymentInfo"] & {
|
|
4904
|
+
bank_name?: string;
|
|
4905
|
+
};
|
|
4906
|
+
/**
|
|
4907
|
+
* NotificationChannelPreferences
|
|
4908
|
+
* @description Set specific channel preferences
|
|
4909
|
+
*/
|
|
4910
|
+
NotificationChannelPreferences: {
|
|
4911
|
+
/**
|
|
4912
|
+
* @description Indicates whether the user has opted to receive notifications via email.
|
|
4913
|
+
* @default true
|
|
4914
|
+
*/
|
|
4915
|
+
email: boolean;
|
|
4916
|
+
/**
|
|
4917
|
+
* @description Indicates whether the user has opted to receive notifications via SMS.
|
|
4918
|
+
* @default true
|
|
4919
|
+
*/
|
|
4920
|
+
sms: boolean;
|
|
4921
|
+
/**
|
|
4922
|
+
* @description Indicates whether the user has opted to receive notifications via WhatsApp.
|
|
4923
|
+
* @default true
|
|
4924
|
+
*/
|
|
4925
|
+
whatsapp: boolean;
|
|
4926
|
+
};
|
|
4927
|
+
/**
|
|
4928
|
+
* NotificationPreferences
|
|
4929
|
+
* @description Set channel preferences for each type of
|
|
4930
|
+
*/
|
|
4931
|
+
NotificationPreferences: {
|
|
4932
|
+
/** @description These notifications are typically critical for user engagement, providing updates, confirmations, or alerts related to their account activities. */
|
|
4933
|
+
transactional?: components$1["schemas"]["NotificationChannelPreferences"];
|
|
4934
|
+
/** @description These notifications aim to engage users with promotional content and enhance their overall experience with the platform. */
|
|
4935
|
+
promotional?: components$1["schemas"]["NotificationChannelPreferences"];
|
|
4936
|
+
/** @description These notifications are often sent periodically as part of a subscription service.
|
|
4937
|
+
* */
|
|
4938
|
+
newsletter?: components$1["schemas"]["NotificationChannelPreferences"];
|
|
4939
|
+
};
|
|
4940
|
+
/** Order */
|
|
4941
|
+
Order: {
|
|
4942
|
+
order_number?: string;
|
|
4943
|
+
/** Format: date-time */
|
|
4944
|
+
order_date?: string;
|
|
4945
|
+
/** @enum {string} */
|
|
4946
|
+
status?: "draft" | "awaiting_approval" | "cancelled" | "shipped" | "delivered" | "awaiting_shipment";
|
|
4947
|
+
/** @enum {string} */
|
|
4948
|
+
payment_status?: "pending" | "success" | "failed" | "partially_paid" | "refunded";
|
|
4949
|
+
/** Format: date-time */
|
|
4950
|
+
payment_success_date?: string;
|
|
4951
|
+
customer_id?: string;
|
|
4952
|
+
customer_email?: string | null;
|
|
4953
|
+
customer_phone?: string | null;
|
|
4954
|
+
customer_note?: string | null;
|
|
4955
|
+
is_promotion_applied?: boolean;
|
|
4956
|
+
promotion_discount_amount?: number | null;
|
|
4957
|
+
is_coupon_applied?: boolean;
|
|
4958
|
+
coupon_code?: string | null;
|
|
4959
|
+
/** Format: double */
|
|
4960
|
+
coupon_discount_amount?: number | null;
|
|
4961
|
+
on_subscription?: boolean;
|
|
4962
|
+
/** Format: double */
|
|
4963
|
+
subtotal?: number;
|
|
4964
|
+
/** Format: double */
|
|
4965
|
+
item_total_tax?: number;
|
|
4966
|
+
/** Format: double */
|
|
4967
|
+
subtotal_including_tax?: number;
|
|
4968
|
+
/** Format: double */
|
|
4969
|
+
shipping_amount?: number;
|
|
4970
|
+
/** Format: double */
|
|
4971
|
+
shipping_total_tax?: number;
|
|
4972
|
+
/** Format: double */
|
|
4973
|
+
shipping_amount_including_tax?: number;
|
|
4974
|
+
/** Format: double */
|
|
4975
|
+
total_tax?: number;
|
|
4976
|
+
/** Format: double */
|
|
4977
|
+
grand_total?: number;
|
|
4978
|
+
loyalty_point_redeemed?: number;
|
|
4979
|
+
credit_balance_used?: number;
|
|
4980
|
+
/** Format: double */
|
|
4981
|
+
to_be_paid?: number;
|
|
4982
|
+
loyalty_point_earned?: number;
|
|
4983
|
+
order_items_count?: number;
|
|
4984
|
+
currency?: {
|
|
4985
|
+
name?: string;
|
|
4986
|
+
code?: string;
|
|
4987
|
+
symbol?: string;
|
|
4988
|
+
};
|
|
4989
|
+
/** Format: date-time */
|
|
4990
|
+
created_at?: string;
|
|
4991
|
+
/** Format: date-time */
|
|
4992
|
+
modified_at?: string;
|
|
4993
|
+
};
|
|
4994
|
+
/** OrderActivity */
|
|
4995
|
+
OrderActivity: {
|
|
4996
|
+
readonly activity_type?: string;
|
|
4997
|
+
readonly order_status?: string;
|
|
4998
|
+
comment: string;
|
|
4999
|
+
/** @enum {unknown} */
|
|
5000
|
+
readonly user_type?: "customer" | "admin" | "system";
|
|
5001
|
+
readonly user_name?: string;
|
|
5002
|
+
/** Format: date-time */
|
|
5003
|
+
readonly created_at?: string;
|
|
5004
|
+
/** Format: date-time */
|
|
5005
|
+
readonly modified_at?: string;
|
|
5006
|
+
};
|
|
5007
|
+
/** OrderDetail */
|
|
5008
|
+
OrderDetail: {
|
|
5009
|
+
order_number?: string;
|
|
5010
|
+
/** Format: date-time */
|
|
5011
|
+
order_date?: string;
|
|
5012
|
+
/** @enum {string} */
|
|
5013
|
+
status?: "draft" | "awaiting_approval" | "cancelled" | "shipped" | "delivered" | "awaiting_shipment";
|
|
5014
|
+
/** @enum {string} */
|
|
5015
|
+
payment_status?: "pending" | "success" | "failed" | "partially_paid" | "refunded";
|
|
5016
|
+
/** Format: date-time */
|
|
5017
|
+
payment_success_date?: string;
|
|
5018
|
+
customer_id?: string;
|
|
5019
|
+
customer_email?: string | null;
|
|
5020
|
+
customer_phone?: string | null;
|
|
5021
|
+
customer_note?: string | null;
|
|
5022
|
+
is_promotion_applied?: boolean;
|
|
5023
|
+
promotion_discount_amount?: number | null;
|
|
5024
|
+
is_coupon_applied?: boolean;
|
|
5025
|
+
coupon_code?: string | null;
|
|
5026
|
+
/** Format: double */
|
|
5027
|
+
coupon_discount_amount?: number | null;
|
|
5028
|
+
on_subscription?: boolean;
|
|
5029
|
+
/** Format: double */
|
|
5030
|
+
subtotal?: number;
|
|
5031
|
+
/** Format: double */
|
|
5032
|
+
item_total_tax?: number;
|
|
5033
|
+
/** Format: double */
|
|
5034
|
+
subtotal_including_tax?: number;
|
|
5035
|
+
/** Format: double */
|
|
5036
|
+
shipping_amount?: number;
|
|
5037
|
+
/** Format: double */
|
|
5038
|
+
shipping_total_tax?: number;
|
|
5039
|
+
/** Format: double */
|
|
5040
|
+
shipping_amount_including_tax?: number;
|
|
5041
|
+
/** Format: double */
|
|
5042
|
+
total_tax?: number;
|
|
5043
|
+
/** Format: double */
|
|
5044
|
+
grand_total?: number;
|
|
5045
|
+
loyalty_point_redeemed?: number;
|
|
5046
|
+
credit_balance_used?: number;
|
|
5047
|
+
/** Format: double */
|
|
5048
|
+
to_be_paid?: number;
|
|
5049
|
+
loyalty_point_earned?: number;
|
|
5050
|
+
order_items_count?: number;
|
|
5051
|
+
order_items?: components$1["schemas"]["OrderItem"][];
|
|
5052
|
+
billing_address?: components$1["schemas"]["CustomerAddress"];
|
|
5053
|
+
shipping_address?: components$1["schemas"]["CustomerAddress"];
|
|
5054
|
+
currency?: {
|
|
5055
|
+
name?: string;
|
|
5056
|
+
code?: string;
|
|
5057
|
+
symbol?: string;
|
|
5058
|
+
};
|
|
5059
|
+
payments?: components$1["schemas"]["OrderPayment"][];
|
|
5060
|
+
shipments?: components$1["schemas"]["OrderShipment"][];
|
|
5061
|
+
/** Format: date-time */
|
|
5062
|
+
created_at?: string;
|
|
5063
|
+
/** Format: date-time */
|
|
5064
|
+
modified_at?: string;
|
|
5065
|
+
};
|
|
5066
|
+
/** OrderItem */
|
|
5067
|
+
OrderItem: {
|
|
5068
|
+
readonly product_id?: string;
|
|
5069
|
+
readonly product_name?: string;
|
|
5070
|
+
readonly product_image_url?: string | null;
|
|
5071
|
+
sku: string;
|
|
5072
|
+
readonly on_offer?: boolean;
|
|
5073
|
+
readonly on_promotion?: boolean;
|
|
5074
|
+
on_subscription?: boolean;
|
|
5075
|
+
subscription_plan?: string | null;
|
|
5076
|
+
readonly subscription_interval?: number | null;
|
|
5077
|
+
readonly subscription_frequency?: string | null;
|
|
5078
|
+
quantity: number;
|
|
5079
|
+
readonly free_quantity?: number;
|
|
5080
|
+
readonly is_free_item?: boolean;
|
|
5081
|
+
/** Format: double */
|
|
5082
|
+
readonly selling_price?: number;
|
|
5083
|
+
/** Format: double */
|
|
5084
|
+
readonly listing_price?: number;
|
|
5085
|
+
/** Format: double */
|
|
5086
|
+
readonly promotion_discount_amount?: number;
|
|
5087
|
+
/** Format: double */
|
|
5088
|
+
readonly coupon_discount_amount?: number;
|
|
5089
|
+
/** @enum {unknown} */
|
|
5090
|
+
readonly tax_type?: "GST";
|
|
5091
|
+
/** Format: float */
|
|
5092
|
+
readonly tax_rate?: number;
|
|
5093
|
+
/** Format: double */
|
|
5094
|
+
readonly tax_amount?: number;
|
|
5095
|
+
/** Format: double */
|
|
5096
|
+
readonly shipping_additional_cost?: number;
|
|
5097
|
+
};
|
|
5098
|
+
/**
|
|
5099
|
+
* OrderList
|
|
5100
|
+
* @description order list model
|
|
5101
|
+
*/
|
|
5102
|
+
OrderList: {
|
|
5103
|
+
/** @description Unique number associated with the order. */
|
|
5104
|
+
order_number?: string;
|
|
5105
|
+
/**
|
|
5106
|
+
* Format: date-time
|
|
5107
|
+
* @description Date and time when the order was placed.
|
|
5108
|
+
*/
|
|
5109
|
+
order_date?: string;
|
|
5110
|
+
/**
|
|
5111
|
+
* @description Current status of the order (e.g., "pending," "processing," "shipped," etc.).
|
|
5112
|
+
* @enum {string}
|
|
5113
|
+
*/
|
|
5114
|
+
status?: "draft" | "awaiting_approval" | "cancelled" | "shipped" | "delivered" | "awaiting_shipment" | "pending" | "payment_failed" | "schedule_requested";
|
|
5115
|
+
/**
|
|
5116
|
+
* @description Current payment status of the order (e.g., "pending," "success," "failed").
|
|
5117
|
+
* @enum {string}
|
|
5118
|
+
*/
|
|
5119
|
+
payment_status?: "pending" | "success" | "failed" | "partially_paid" | "refunded";
|
|
5120
|
+
/** @description Date and time when the payment for the order was successfully processed. */
|
|
5121
|
+
payment_success_date?: string | null;
|
|
5122
|
+
/** @description Indicates whether the order has a refund associated with it or not. */
|
|
5123
|
+
has_refund?: boolean;
|
|
5124
|
+
/** @description Indicates whether the order includes subscription items. */
|
|
5125
|
+
on_subscription?: boolean;
|
|
5126
|
+
/**
|
|
5127
|
+
* Format: double
|
|
5128
|
+
* @description Total amount for the order, including all items, taxes, and discounts.
|
|
5129
|
+
*/
|
|
5130
|
+
grand_total?: number;
|
|
5131
|
+
/** @description Number of loyalty points redeemed in the order. */
|
|
5132
|
+
loyalty_point_redeemed?: number;
|
|
5133
|
+
/** @description Amount of credit balance used in the order. */
|
|
5134
|
+
credit_balance_used?: number;
|
|
5135
|
+
/**
|
|
5136
|
+
* Format: double
|
|
5137
|
+
* @description Amount remaining to be paid for the order.
|
|
5138
|
+
*/
|
|
5139
|
+
to_be_paid?: number;
|
|
5140
|
+
/** @description Total count of items included in the order. */
|
|
5141
|
+
order_items_count?: number;
|
|
5142
|
+
order_items?: components$1["schemas"]["OrderItem"][];
|
|
5143
|
+
customer_id?: string;
|
|
5144
|
+
customer_note?: string | null;
|
|
5145
|
+
billing_address?: components$1["schemas"]["CustomerAddress"];
|
|
5146
|
+
shipping_address?: components$1["schemas"]["CustomerAddress"];
|
|
5147
|
+
loyalty_point_earned?: number;
|
|
5148
|
+
currency?: {
|
|
5149
|
+
name?: string;
|
|
5150
|
+
code?: string;
|
|
5151
|
+
symbol?: string;
|
|
5152
|
+
};
|
|
5153
|
+
/** Format: date-time */
|
|
5154
|
+
created_at?: string;
|
|
5155
|
+
/** Format: date-time */
|
|
5156
|
+
modified_at?: string;
|
|
5157
|
+
};
|
|
5158
|
+
/**
|
|
5159
|
+
* OrderPayment
|
|
5160
|
+
* @description Order Payment
|
|
5161
|
+
*/
|
|
5162
|
+
OrderPayment: components$1["schemas"]["CardPayment"] | components$1["schemas"]["NetbankingPayment"] | components$1["schemas"]["UpiPayment"] | components$1["schemas"]["WalletPayment"] | components$1["schemas"]["BankTransfer"] | components$1["schemas"]["LoyaltyPointPayment"];
|
|
5163
|
+
/**
|
|
5164
|
+
* OrderPaymentInfo
|
|
5165
|
+
* @description Common fields in all types of payments.
|
|
5166
|
+
*/
|
|
5167
|
+
OrderPaymentInfo: {
|
|
5168
|
+
/** @enum {unknown} */
|
|
5169
|
+
transaction_type?: "payment" | "refund";
|
|
5170
|
+
request_number?: string;
|
|
5171
|
+
/** Format: double */
|
|
5172
|
+
amount?: number;
|
|
5173
|
+
/** @enum {unknown} */
|
|
5174
|
+
payment_status?: "pending" | "success" | "failed" | "partially_paid" | "refund_initiated";
|
|
5175
|
+
/** Format: date-time */
|
|
5176
|
+
payment_date?: string;
|
|
5177
|
+
payment_reference_number?: string | null;
|
|
5178
|
+
/** @enum {unknown} */
|
|
5179
|
+
payment_method?: "Credit Card" | "Debit Card" | "Netbanking" | "UPI" | "Wallet" | "Loyalty Point" | "IMPS" | "NEFT" | "RTGS";
|
|
5180
|
+
icon_url?: string;
|
|
5181
|
+
};
|
|
5182
|
+
/** OrderReceiptJsonFormat */
|
|
5183
|
+
OrderReceiptJsonFormat: components$1["schemas"]["Order"] & {
|
|
5184
|
+
billing_address?: components$1["schemas"]["CustomerAddress"];
|
|
5185
|
+
shipping_address?: components$1["schemas"]["CustomerAddress"];
|
|
5186
|
+
order_items?: components$1["schemas"]["OrderItem"][];
|
|
5187
|
+
payments?: components$1["schemas"]["OrderPayment"][];
|
|
5188
|
+
};
|
|
5189
|
+
/**
|
|
5190
|
+
* OrderShipment
|
|
5191
|
+
* @description Order shipment model
|
|
5192
|
+
*/
|
|
5193
|
+
OrderShipment: {
|
|
5194
|
+
reference_number?: string;
|
|
5195
|
+
/** @enum {unknown} */
|
|
5196
|
+
status?: "pending" | "approved" | "shipped" | "delivered" | "cancelled";
|
|
5197
|
+
total_weight?: number;
|
|
5198
|
+
total_boxes?: number;
|
|
5199
|
+
shipment_items_count?: number;
|
|
5200
|
+
shipment_items?: components$1["schemas"]["ShipmentItem"][];
|
|
5201
|
+
/** Format: double */
|
|
5202
|
+
shipping_amount?: number;
|
|
5203
|
+
/** Format: double */
|
|
5204
|
+
shipping_tax_amount?: number;
|
|
5205
|
+
/** Format: double */
|
|
5206
|
+
shipping_amount_including_tax?: number;
|
|
5207
|
+
courier_company_id?: string;
|
|
5208
|
+
courier_company_name?: string;
|
|
5209
|
+
shipping_label_url?: string;
|
|
5210
|
+
awb_no?: string;
|
|
5211
|
+
eta_delivery?: string;
|
|
5212
|
+
/** Format: date-time */
|
|
5213
|
+
shipped_date?: string;
|
|
5214
|
+
/** Format: date-time */
|
|
5215
|
+
delivered_date?: string;
|
|
5216
|
+
cancellation_reason?: string;
|
|
5217
|
+
/** Format: date-time */
|
|
5218
|
+
created_at?: string;
|
|
5219
|
+
/** Format: date-time */
|
|
5220
|
+
modified_at?: string;
|
|
5221
|
+
};
|
|
5222
|
+
/** @description pagination metadata structure */
|
|
5223
|
+
Pagination: {
|
|
5224
|
+
total_records?: number;
|
|
5225
|
+
total_pages?: number;
|
|
5226
|
+
previous_page?: ((number | null) | null) | null;
|
|
5227
|
+
/** @default 25 */
|
|
5228
|
+
limit: number;
|
|
5229
|
+
next_page?: ((number | null) | null) | null;
|
|
5230
|
+
};
|
|
5231
|
+
/** Shipment */
|
|
5232
|
+
Shipment: components$1["schemas"]["ShipmentInfo"] & {
|
|
5233
|
+
shipment_items?: components$1["schemas"]["ShipmentItem"][];
|
|
5234
|
+
} & {
|
|
5235
|
+
packing?: components$1["schemas"]["ShipmentPackaging"];
|
|
5236
|
+
} & {
|
|
5237
|
+
progression?: components$1["schemas"]["ShipmentProgression"][];
|
|
5238
|
+
};
|
|
5239
|
+
/** ShipmentBox */
|
|
5240
|
+
ShipmentBox: {
|
|
5241
|
+
box_name?: string;
|
|
5242
|
+
box_length?: number;
|
|
5243
|
+
box_width?: number;
|
|
5244
|
+
box_height?: number;
|
|
5245
|
+
box_weight?: number;
|
|
5246
|
+
items_count?: number | null;
|
|
5247
|
+
box_count?: number | null;
|
|
5248
|
+
};
|
|
5249
|
+
/** ShipmentDetail */
|
|
5250
|
+
ShipmentDetail: {
|
|
5251
|
+
order_number?: string;
|
|
5252
|
+
/** Format: date-time */
|
|
5253
|
+
order_date?: string;
|
|
5254
|
+
order_status?: string;
|
|
5255
|
+
/** @enum {unknown} */
|
|
5256
|
+
payment_status?: "pending" | "success" | "failed";
|
|
5257
|
+
customer_name?: string;
|
|
5258
|
+
shipments?: components$1["schemas"]["Shipment"][];
|
|
5259
|
+
/** @description dynamic values as per current status of the shipment. */
|
|
5260
|
+
allowed_actions?: string[];
|
|
5261
|
+
};
|
|
5262
|
+
/** ShipmentInfo */
|
|
5263
|
+
ShipmentInfo: {
|
|
5264
|
+
order_number?: string;
|
|
5265
|
+
order_status?: string;
|
|
5266
|
+
shipment_number?: string;
|
|
5267
|
+
warehouse_id?: string;
|
|
5268
|
+
warehouse_name?: string;
|
|
5269
|
+
status?: string;
|
|
5270
|
+
total_weight?: number;
|
|
5271
|
+
total_boxes?: number;
|
|
5272
|
+
shipment_items_count?: number;
|
|
5273
|
+
/** Format: double */
|
|
5274
|
+
shipping_amount?: number;
|
|
5275
|
+
/** Format: double */
|
|
5276
|
+
shipping_tax_amount?: number;
|
|
5277
|
+
/** Format: double */
|
|
5278
|
+
shipping_amount_including_tax?: number;
|
|
5279
|
+
courier_company_id?: string | null;
|
|
5280
|
+
courier_company_name?: string | null;
|
|
5281
|
+
courier_company_image_url?: string | null;
|
|
5282
|
+
awb_no?: string | null;
|
|
5283
|
+
shipping_label_url?: string | null;
|
|
5284
|
+
eta_delivery?: string | null;
|
|
5285
|
+
shipped_date?: string | null;
|
|
5286
|
+
delivered_date?: string | null;
|
|
5287
|
+
slo?: {
|
|
5288
|
+
/** Format: date */
|
|
5289
|
+
expected_date?: string;
|
|
5290
|
+
/** Format: date */
|
|
5291
|
+
actual_date?: string;
|
|
5292
|
+
difference?: string;
|
|
5293
|
+
};
|
|
5294
|
+
cancellation_reason?: string | null;
|
|
5295
|
+
customer_id?: string;
|
|
5296
|
+
customer_name?: string;
|
|
5297
|
+
shipping_address_line1?: string;
|
|
5298
|
+
shipping_address_line2?: string;
|
|
5299
|
+
shipping_landmark?: string;
|
|
5300
|
+
shipping_pincode?: string;
|
|
5301
|
+
shipping_city?: string;
|
|
5302
|
+
shipping_state?: string;
|
|
5303
|
+
created_at?: string;
|
|
5304
|
+
modified_at?: string;
|
|
5305
|
+
};
|
|
5306
|
+
/**
|
|
5307
|
+
* ShipmentItem
|
|
5308
|
+
* @description Shipment item model
|
|
5309
|
+
*/
|
|
5310
|
+
ShipmentItem: {
|
|
5311
|
+
product_id: string;
|
|
5312
|
+
readonly product_name?: string;
|
|
5313
|
+
variant_id: string | null;
|
|
5314
|
+
readonly variant_name?: string | null;
|
|
5315
|
+
readonly product_image_url?: string | null;
|
|
5316
|
+
readonly sku?: string;
|
|
5317
|
+
quantity: number;
|
|
5318
|
+
free_quantity?: number;
|
|
5319
|
+
readonly is_free_item?: boolean;
|
|
5320
|
+
};
|
|
5321
|
+
/** ShipmentList */
|
|
5322
|
+
ShipmentList: {
|
|
5323
|
+
order_number?: string;
|
|
5324
|
+
} & components$1["schemas"]["ShipmentInfo"];
|
|
5325
|
+
/** ShipmentPackaging */
|
|
5326
|
+
ShipmentPackaging: {
|
|
5327
|
+
/** @enum {unknown} */
|
|
5328
|
+
package_option?: "Automatic" | "Custom";
|
|
5329
|
+
boxes_count?: number;
|
|
5330
|
+
boxes?: components$1["schemas"]["ShipmentBox"][];
|
|
5331
|
+
};
|
|
5332
|
+
/** ShipmentProgression */
|
|
5333
|
+
ShipmentProgression: {
|
|
5334
|
+
readonly status?: string;
|
|
5335
|
+
readonly is_current?: boolean;
|
|
5336
|
+
readonly is_completed?: boolean;
|
|
5337
|
+
/** Format: date-time */
|
|
5338
|
+
readonly completion_date?: string;
|
|
5339
|
+
};
|
|
5340
|
+
/**
|
|
5341
|
+
* UpiPayment
|
|
5342
|
+
* @description UPI Payment
|
|
5343
|
+
*/
|
|
5344
|
+
UpiPayment: components$1["schemas"]["OrderPaymentInfo"] & {
|
|
5345
|
+
upi_id?: string;
|
|
5346
|
+
};
|
|
5347
|
+
/** WalletPayment */
|
|
5348
|
+
WalletPayment: components$1["schemas"]["OrderPaymentInfo"] & {
|
|
5349
|
+
wallet_name?: string;
|
|
5350
|
+
};
|
|
5351
|
+
/** Warehouse */
|
|
5352
|
+
Warehouse: {
|
|
5353
|
+
/** @description warehouse ulid */
|
|
5354
|
+
readonly id: string;
|
|
5355
|
+
/** @description legal name */
|
|
5356
|
+
readonly name: string;
|
|
5357
|
+
readonly gstin?: string;
|
|
5358
|
+
readonly city: string;
|
|
5359
|
+
readonly address_line1: string;
|
|
5360
|
+
readonly address_line2?: string;
|
|
5361
|
+
readonly larndmark?: string;
|
|
5362
|
+
pincode: string;
|
|
5363
|
+
state: string;
|
|
5364
|
+
/** @description 10 digit number without country code. */
|
|
5365
|
+
contact_phone: number;
|
|
5366
|
+
/** Format: email */
|
|
5367
|
+
contact_email: string;
|
|
5368
|
+
/** @default false */
|
|
5369
|
+
is_default: boolean;
|
|
5370
|
+
};
|
|
5371
|
+
/** WarehouseBasicDetail */
|
|
5372
|
+
WarehouseBasicDetail: {
|
|
5373
|
+
id?: string;
|
|
5374
|
+
name?: string;
|
|
5375
|
+
address_line1?: string;
|
|
5376
|
+
pincode?: string;
|
|
5377
|
+
city?: string;
|
|
5378
|
+
state?: string;
|
|
5379
|
+
is_default?: boolean;
|
|
5380
|
+
};
|
|
5381
|
+
/** WarehouseWiseInventory */
|
|
5382
|
+
WarehouseWiseInventory: {
|
|
5383
|
+
lot_bacth?: string;
|
|
5384
|
+
/** Format: date */
|
|
5385
|
+
mfg_date?: string;
|
|
5386
|
+
/** Format: date */
|
|
5387
|
+
exp_date?: string;
|
|
5388
|
+
manufacturer?: string;
|
|
5389
|
+
warehouse_id?: string;
|
|
5390
|
+
warehouse?: components$1["schemas"]["WarehouseBasicDetail"];
|
|
5391
|
+
received_quantity?: number;
|
|
5392
|
+
reserved_quantity?: number;
|
|
5393
|
+
sold_quantity?: number;
|
|
5394
|
+
adjusted_quantity?: number;
|
|
5395
|
+
stock_quantity?: number;
|
|
5396
|
+
};
|
|
5397
|
+
};
|
|
5398
|
+
responses: never;
|
|
5399
|
+
parameters: {
|
|
5400
|
+
/** @description JSON object */
|
|
5401
|
+
columnBasedFilters: string;
|
|
5402
|
+
/** @description no of rows per page */
|
|
5403
|
+
pageLimit: number;
|
|
5404
|
+
/** @description page number of pagination list */
|
|
5405
|
+
pageNumber: number;
|
|
5406
|
+
/** @description search keyword */
|
|
5407
|
+
searchKeyword: string;
|
|
5408
|
+
/** @description JSON string format: {"field1":"asc", "field2":"desc"} */
|
|
5409
|
+
sortByOptions: string;
|
|
5410
|
+
};
|
|
5411
|
+
requestBodies: never;
|
|
5412
|
+
headers: never;
|
|
5413
|
+
pathItems: never;
|
|
5414
|
+
}
|
|
5415
|
+
interface operations$1 {
|
|
5416
|
+
"pos-list-inventories": {
|
|
5417
|
+
parameters: {
|
|
5418
|
+
query?: {
|
|
5419
|
+
/** @description page number of pagination list */
|
|
5420
|
+
page?: components$1["parameters"]["pageNumber"];
|
|
5421
|
+
/** @description no of rows per page */
|
|
5422
|
+
limit?: components$1["parameters"]["pageLimit"];
|
|
5423
|
+
/** @description JSON string format: {"field1":"asc", "field2":"desc"} */
|
|
5424
|
+
sort_by?: components$1["parameters"]["sortByOptions"];
|
|
5425
|
+
/** @description JSON object */
|
|
5426
|
+
filters?: components$1["parameters"]["columnBasedFilters"];
|
|
5427
|
+
};
|
|
5428
|
+
header?: never;
|
|
5429
|
+
path?: never;
|
|
5430
|
+
cookie?: never;
|
|
5431
|
+
};
|
|
5432
|
+
requestBody?: never;
|
|
5433
|
+
responses: {
|
|
5434
|
+
/** @description OK */
|
|
5435
|
+
200: {
|
|
5436
|
+
headers: {
|
|
5437
|
+
[name: string]: unknown;
|
|
5438
|
+
};
|
|
5439
|
+
content: {
|
|
5440
|
+
"application/json": {
|
|
5441
|
+
message?: string;
|
|
5442
|
+
success?: boolean;
|
|
5443
|
+
content?: {
|
|
5444
|
+
inventories?: (components$1["schemas"]["ItemWiseInventory"] | components$1["schemas"]["LotBatchWiseInventory"])[];
|
|
5445
|
+
};
|
|
5446
|
+
};
|
|
5447
|
+
};
|
|
5448
|
+
};
|
|
5449
|
+
};
|
|
5450
|
+
};
|
|
5451
|
+
"pos-list-inventories-activities": {
|
|
5452
|
+
parameters: {
|
|
5453
|
+
query?: {
|
|
5454
|
+
/** @description page number of pagination list */
|
|
5455
|
+
page?: components$1["parameters"]["pageNumber"];
|
|
5456
|
+
/** @description no of rows per page */
|
|
5457
|
+
limit?: components$1["parameters"]["pageLimit"];
|
|
5458
|
+
/** @description JSON string format: {"field1":"asc", "field2":"desc"} */
|
|
5459
|
+
sort_by?: components$1["parameters"]["sortByOptions"];
|
|
5460
|
+
/** @description JSON object */
|
|
5461
|
+
filters?: components$1["parameters"]["columnBasedFilters"];
|
|
5462
|
+
};
|
|
5463
|
+
header?: never;
|
|
5464
|
+
path?: never;
|
|
5465
|
+
cookie?: never;
|
|
5466
|
+
};
|
|
5467
|
+
requestBody?: never;
|
|
5468
|
+
responses: {
|
|
5469
|
+
/** @description OK */
|
|
5470
|
+
200: {
|
|
5471
|
+
headers: {
|
|
5472
|
+
[name: string]: unknown;
|
|
5473
|
+
};
|
|
5474
|
+
content: {
|
|
5475
|
+
"application/json": {
|
|
5476
|
+
message?: string;
|
|
5477
|
+
success?: boolean;
|
|
5478
|
+
content?: {
|
|
5479
|
+
activities?: components$1["schemas"]["InventoryActivity"][];
|
|
5480
|
+
};
|
|
5481
|
+
};
|
|
5482
|
+
};
|
|
5483
|
+
};
|
|
5484
|
+
};
|
|
5485
|
+
};
|
|
5486
|
+
"pos-get-inventory-detail": {
|
|
5487
|
+
parameters: {
|
|
5488
|
+
query: {
|
|
5489
|
+
/** @description lot batch of selected productor or variant. */
|
|
5490
|
+
lot_batch?: string;
|
|
5491
|
+
/** @description Product Id */
|
|
5492
|
+
product_id: string;
|
|
5493
|
+
/** @description Variant Id */
|
|
5494
|
+
variant_id?: string;
|
|
5495
|
+
};
|
|
5496
|
+
header?: never;
|
|
5497
|
+
path?: never;
|
|
5498
|
+
cookie?: never;
|
|
5499
|
+
};
|
|
5500
|
+
requestBody?: never;
|
|
5501
|
+
responses: {
|
|
5502
|
+
/** @description OK */
|
|
5503
|
+
200: {
|
|
5504
|
+
headers: {
|
|
5505
|
+
[name: string]: unknown;
|
|
5506
|
+
};
|
|
5507
|
+
content: {
|
|
5508
|
+
"application/json": {
|
|
5509
|
+
message?: string;
|
|
5510
|
+
success?: boolean;
|
|
5511
|
+
content?: {
|
|
5512
|
+
inventory?: components$1["schemas"]["InventoryDetail"];
|
|
5513
|
+
};
|
|
5514
|
+
};
|
|
5515
|
+
};
|
|
5516
|
+
};
|
|
5517
|
+
};
|
|
5518
|
+
};
|
|
5519
|
+
"pos-get-admin-customers": {
|
|
5520
|
+
parameters: {
|
|
5521
|
+
query?: {
|
|
5522
|
+
/** @description page number of pagination list */
|
|
5523
|
+
page?: components$1["parameters"]["pageNumber"];
|
|
5524
|
+
/** @description no of rows per page */
|
|
5525
|
+
limit?: components$1["parameters"]["pageLimit"];
|
|
5526
|
+
/** @description JSON object */
|
|
5527
|
+
filters?: components$1["parameters"]["columnBasedFilters"];
|
|
5528
|
+
/** @description JSON string format: {"field1":"asc", "field2":"desc"} */
|
|
5529
|
+
sort_by?: components$1["parameters"]["sortByOptions"];
|
|
5530
|
+
/** @description search keyword */
|
|
5531
|
+
search?: components$1["parameters"]["searchKeyword"];
|
|
5532
|
+
};
|
|
5533
|
+
header?: never;
|
|
5534
|
+
path?: never;
|
|
5535
|
+
cookie?: never;
|
|
5536
|
+
};
|
|
5537
|
+
requestBody?: never;
|
|
5538
|
+
responses: {
|
|
5539
|
+
/** @description OK */
|
|
5540
|
+
200: {
|
|
5541
|
+
headers: {
|
|
5542
|
+
[name: string]: unknown;
|
|
5543
|
+
};
|
|
5544
|
+
content: {
|
|
5545
|
+
"application/json": {
|
|
5546
|
+
message?: string;
|
|
5547
|
+
success?: boolean;
|
|
5548
|
+
content?: {
|
|
5549
|
+
customers?: components$1["schemas"]["Customer"][];
|
|
5550
|
+
pagination?: components$1["schemas"]["Pagination"];
|
|
5551
|
+
};
|
|
5552
|
+
};
|
|
5553
|
+
};
|
|
5554
|
+
};
|
|
5555
|
+
};
|
|
5556
|
+
};
|
|
5557
|
+
"pos-get-admin-customers-id": {
|
|
5558
|
+
parameters: {
|
|
5559
|
+
query?: never;
|
|
5560
|
+
header?: never;
|
|
5561
|
+
path: {
|
|
5562
|
+
/** @description Customer Id */
|
|
5563
|
+
id: string;
|
|
5564
|
+
};
|
|
5565
|
+
cookie?: never;
|
|
5566
|
+
};
|
|
5567
|
+
requestBody?: never;
|
|
5568
|
+
responses: {
|
|
5569
|
+
/** @description OK */
|
|
5570
|
+
200: {
|
|
5571
|
+
headers: {
|
|
5572
|
+
[name: string]: unknown;
|
|
5573
|
+
};
|
|
5574
|
+
content: {
|
|
5575
|
+
"application/json": {
|
|
5576
|
+
message?: string;
|
|
5577
|
+
success?: boolean;
|
|
5578
|
+
content?: {
|
|
5579
|
+
customer?: components$1["schemas"]["CustomerDetail"];
|
|
5580
|
+
};
|
|
5581
|
+
};
|
|
5582
|
+
};
|
|
5583
|
+
};
|
|
5584
|
+
};
|
|
5585
|
+
};
|
|
5586
|
+
"pos-list-admin-orders": {
|
|
5587
|
+
parameters: {
|
|
5588
|
+
query?: {
|
|
5589
|
+
/** @description page number of pagination list */
|
|
5590
|
+
page?: components$1["parameters"]["pageNumber"];
|
|
5591
|
+
/** @description no of rows per page */
|
|
5592
|
+
limit?: components$1["parameters"]["pageLimit"];
|
|
5593
|
+
/** @description JSON object */
|
|
5594
|
+
filters?: components$1["parameters"]["columnBasedFilters"];
|
|
5595
|
+
/** @description JSON string format: {"field1":"asc", "field2":"desc"} */
|
|
5596
|
+
sort_by?: components$1["parameters"]["sortByOptions"];
|
|
5597
|
+
/** @description search keyword */
|
|
5598
|
+
search?: components$1["parameters"]["searchKeyword"];
|
|
5599
|
+
};
|
|
5600
|
+
header?: never;
|
|
5601
|
+
path?: never;
|
|
5602
|
+
cookie?: never;
|
|
5603
|
+
};
|
|
5604
|
+
requestBody?: never;
|
|
5605
|
+
responses: {
|
|
5606
|
+
/** @description OK */
|
|
5607
|
+
200: {
|
|
5608
|
+
headers: {
|
|
5609
|
+
[name: string]: unknown;
|
|
5610
|
+
};
|
|
5611
|
+
content: {
|
|
5612
|
+
"application/json": {
|
|
5613
|
+
message?: string;
|
|
5614
|
+
success?: boolean;
|
|
5615
|
+
content?: {
|
|
5616
|
+
orders?: components$1["schemas"]["OrderList"][];
|
|
5617
|
+
pagination?: components$1["schemas"]["Pagination"];
|
|
5618
|
+
};
|
|
5619
|
+
};
|
|
5620
|
+
};
|
|
5621
|
+
};
|
|
5622
|
+
};
|
|
5623
|
+
};
|
|
5624
|
+
"pos-get-admin-order": {
|
|
5625
|
+
parameters: {
|
|
5626
|
+
query?: never;
|
|
5627
|
+
header?: never;
|
|
5628
|
+
path: {
|
|
5629
|
+
/** @description order number */
|
|
5630
|
+
order_number: string;
|
|
5631
|
+
};
|
|
5632
|
+
cookie?: never;
|
|
5633
|
+
};
|
|
5634
|
+
requestBody?: never;
|
|
5635
|
+
responses: {
|
|
5636
|
+
/** @description OK */
|
|
5637
|
+
200: {
|
|
5638
|
+
headers: {
|
|
5639
|
+
[name: string]: unknown;
|
|
5640
|
+
};
|
|
5641
|
+
content: {
|
|
5642
|
+
"application/json": {
|
|
5643
|
+
message?: string;
|
|
5644
|
+
success?: boolean;
|
|
5645
|
+
content?: {
|
|
5646
|
+
order?: components$1["schemas"]["OrderDetail"];
|
|
5647
|
+
};
|
|
5648
|
+
};
|
|
5649
|
+
};
|
|
5650
|
+
};
|
|
5651
|
+
};
|
|
5652
|
+
};
|
|
5653
|
+
"pos-list-order-activity": {
|
|
5654
|
+
parameters: {
|
|
5655
|
+
query?: never;
|
|
5656
|
+
header?: never;
|
|
5657
|
+
path: {
|
|
5658
|
+
/** @description order number */
|
|
5659
|
+
order_number: string;
|
|
5660
|
+
};
|
|
5661
|
+
cookie?: never;
|
|
5662
|
+
};
|
|
5663
|
+
requestBody?: never;
|
|
5664
|
+
responses: {
|
|
5665
|
+
/** @description OK */
|
|
5666
|
+
200: {
|
|
5667
|
+
headers: {
|
|
5668
|
+
[name: string]: unknown;
|
|
5669
|
+
};
|
|
5670
|
+
content: {
|
|
5671
|
+
"application/json": {
|
|
5672
|
+
message?: string;
|
|
5673
|
+
success?: boolean;
|
|
5674
|
+
content?: {
|
|
5675
|
+
activity?: components$1["schemas"]["OrderActivity"][];
|
|
5676
|
+
pagination?: components$1["schemas"]["Pagination"];
|
|
5677
|
+
};
|
|
5678
|
+
};
|
|
5679
|
+
};
|
|
5680
|
+
};
|
|
5681
|
+
};
|
|
5682
|
+
};
|
|
5683
|
+
"pos-get-order-invoice": {
|
|
5684
|
+
parameters: {
|
|
5685
|
+
query?: {
|
|
5686
|
+
/** @description Response data format */
|
|
5687
|
+
format?: "json" | "pdf";
|
|
5688
|
+
};
|
|
5689
|
+
header?: never;
|
|
5690
|
+
path: {
|
|
5691
|
+
/** @description order number */
|
|
5692
|
+
order_number: string;
|
|
5693
|
+
};
|
|
5694
|
+
cookie?: never;
|
|
5695
|
+
};
|
|
5696
|
+
requestBody?: never;
|
|
5697
|
+
responses: {
|
|
5698
|
+
/** @description OK */
|
|
5699
|
+
200: {
|
|
5700
|
+
headers: {
|
|
5701
|
+
[name: string]: unknown;
|
|
5702
|
+
};
|
|
5703
|
+
content: {
|
|
5704
|
+
"application/json": {
|
|
5705
|
+
message?: string;
|
|
5706
|
+
success?: boolean;
|
|
5707
|
+
content?: {
|
|
5708
|
+
invoices?: components$1["schemas"]["InvoiceDetail"][];
|
|
5709
|
+
};
|
|
5710
|
+
};
|
|
5711
|
+
"application/pdf": Record<string, never>;
|
|
5712
|
+
};
|
|
5713
|
+
};
|
|
5714
|
+
};
|
|
5715
|
+
};
|
|
5716
|
+
"pos-get-order-receipt": {
|
|
5717
|
+
parameters: {
|
|
5718
|
+
query?: {
|
|
5719
|
+
/** @description Response data format */
|
|
5720
|
+
format?: "json" | "pdf";
|
|
5721
|
+
};
|
|
5722
|
+
header?: never;
|
|
5723
|
+
path: {
|
|
5724
|
+
/** @description order number */
|
|
5725
|
+
order_number: string;
|
|
5726
|
+
};
|
|
5727
|
+
cookie?: never;
|
|
5728
|
+
};
|
|
5729
|
+
requestBody?: never;
|
|
5730
|
+
responses: {
|
|
5731
|
+
/** @description OK */
|
|
5732
|
+
200: {
|
|
5733
|
+
headers: {
|
|
5734
|
+
[name: string]: unknown;
|
|
5735
|
+
};
|
|
5736
|
+
content: {
|
|
5737
|
+
"application/json": {
|
|
5738
|
+
message?: string;
|
|
5739
|
+
success?: boolean;
|
|
5740
|
+
content?: {
|
|
5741
|
+
order_receipt?: components$1["schemas"]["OrderReceiptJsonFormat"];
|
|
5742
|
+
};
|
|
5743
|
+
};
|
|
5744
|
+
"application/pdf": Record<string, never>;
|
|
5745
|
+
};
|
|
5746
|
+
};
|
|
5747
|
+
};
|
|
5748
|
+
};
|
|
5749
|
+
"pos-get-order-shipments": {
|
|
5750
|
+
parameters: {
|
|
5751
|
+
query?: never;
|
|
5752
|
+
header?: never;
|
|
5753
|
+
path: {
|
|
5754
|
+
/** @description order number */
|
|
5755
|
+
order_number: string;
|
|
5756
|
+
};
|
|
5757
|
+
cookie?: never;
|
|
5758
|
+
};
|
|
5759
|
+
requestBody?: never;
|
|
5760
|
+
responses: {
|
|
5761
|
+
/** @description OK */
|
|
5762
|
+
200: {
|
|
5763
|
+
headers: {
|
|
5764
|
+
[name: string]: unknown;
|
|
5765
|
+
};
|
|
5766
|
+
content: {
|
|
5767
|
+
"application/json": {
|
|
5768
|
+
message?: string;
|
|
5769
|
+
success?: boolean;
|
|
5770
|
+
content?: {
|
|
5771
|
+
shipment?: components$1["schemas"]["ShipmentDetail"];
|
|
5772
|
+
};
|
|
5773
|
+
};
|
|
5774
|
+
};
|
|
5775
|
+
};
|
|
5776
|
+
};
|
|
5777
|
+
};
|
|
5778
|
+
"pos-list-shipments": {
|
|
5779
|
+
parameters: {
|
|
5780
|
+
query?: {
|
|
5781
|
+
/** @description page number of pagination list */
|
|
5782
|
+
page?: components$1["parameters"]["pageNumber"];
|
|
5783
|
+
/** @description no of rows per page */
|
|
5784
|
+
limit?: components$1["parameters"]["pageLimit"];
|
|
5785
|
+
/** @description JSON object */
|
|
5786
|
+
filters?: components$1["parameters"]["columnBasedFilters"];
|
|
5787
|
+
/** @description JSON string format: {"field1":"asc", "field2":"desc"} */
|
|
5788
|
+
sort_by?: components$1["parameters"]["sortByOptions"];
|
|
5789
|
+
/** @description search keyword */
|
|
5790
|
+
search?: components$1["parameters"]["searchKeyword"];
|
|
5791
|
+
};
|
|
5792
|
+
header?: never;
|
|
5793
|
+
path?: never;
|
|
5794
|
+
cookie?: never;
|
|
5795
|
+
};
|
|
5796
|
+
requestBody?: never;
|
|
5797
|
+
responses: {
|
|
5798
|
+
/** @description OK */
|
|
5799
|
+
200: {
|
|
5800
|
+
headers: {
|
|
5801
|
+
[name: string]: unknown;
|
|
5802
|
+
};
|
|
5803
|
+
content: {
|
|
5804
|
+
"application/json": {
|
|
5805
|
+
message?: string;
|
|
5806
|
+
success?: boolean;
|
|
5807
|
+
content?: {
|
|
5808
|
+
shipments?: components$1["schemas"]["ShipmentList"][];
|
|
5809
|
+
pagination?: components$1["schemas"]["Pagination"];
|
|
5810
|
+
};
|
|
5811
|
+
};
|
|
5812
|
+
};
|
|
5813
|
+
};
|
|
5814
|
+
};
|
|
5815
|
+
};
|
|
5816
|
+
"pos-check-inventory-for-order": {
|
|
5817
|
+
parameters: {
|
|
5818
|
+
query?: never;
|
|
5819
|
+
header?: never;
|
|
5820
|
+
path: {
|
|
5821
|
+
/** @description Order number */
|
|
5822
|
+
order_number: string;
|
|
5823
|
+
};
|
|
5824
|
+
cookie?: never;
|
|
5825
|
+
};
|
|
5826
|
+
requestBody?: never;
|
|
5827
|
+
responses: {
|
|
5828
|
+
/** @description OK */
|
|
5829
|
+
200: {
|
|
5830
|
+
headers: {
|
|
5831
|
+
[name: string]: unknown;
|
|
5832
|
+
};
|
|
5833
|
+
content: {
|
|
5834
|
+
"application/json": {
|
|
5835
|
+
message?: string;
|
|
5836
|
+
success?: boolean;
|
|
5837
|
+
content?: {
|
|
5838
|
+
/** @enum {unknown} */
|
|
5839
|
+
inventory_status?: "fulfilled" | "partially-fulfilled" | "not-fulfilled";
|
|
5840
|
+
shipment_items?: components$1["schemas"]["ShipmentItem"][];
|
|
5841
|
+
recommended_warehouses?: {
|
|
5842
|
+
id?: string;
|
|
5843
|
+
name?: string;
|
|
5844
|
+
/** @enum {unknown} */
|
|
5845
|
+
inventory_status?: "fulfilled" | "partially-fulfilled" | "not-fulfilled";
|
|
5846
|
+
}[];
|
|
5847
|
+
inventory_detail?: {
|
|
5848
|
+
sku?: string;
|
|
5849
|
+
total_quantity?: number;
|
|
5850
|
+
warehouses?: {
|
|
5851
|
+
warehouse_id?: string;
|
|
5852
|
+
warehouse_name?: string;
|
|
5853
|
+
quantity?: number;
|
|
5854
|
+
}[];
|
|
5855
|
+
}[];
|
|
5856
|
+
allowed_action?: string[];
|
|
5857
|
+
};
|
|
5858
|
+
};
|
|
5859
|
+
};
|
|
5860
|
+
};
|
|
5861
|
+
};
|
|
5862
|
+
};
|
|
5863
|
+
"pos-refund-shortfall-for-order": {
|
|
5864
|
+
parameters: {
|
|
5865
|
+
query?: never;
|
|
5866
|
+
header?: never;
|
|
5867
|
+
path: {
|
|
5868
|
+
/** @description Order Number */
|
|
5869
|
+
order_number: string;
|
|
5870
|
+
};
|
|
5871
|
+
cookie?: never;
|
|
5872
|
+
};
|
|
5873
|
+
requestBody?: {
|
|
5874
|
+
content: {
|
|
5875
|
+
"application/json": {
|
|
5876
|
+
items: {
|
|
5877
|
+
sku: string;
|
|
5878
|
+
quantity: number;
|
|
5879
|
+
/** @default 0 */
|
|
5880
|
+
free_quantity?: number;
|
|
5881
|
+
}[];
|
|
5882
|
+
/** @enum {unknown} */
|
|
5883
|
+
payment_method: "original-payment-mode" | "bank-transfer";
|
|
5884
|
+
/** @description required if payment_method = bank-transfer */
|
|
5885
|
+
bank_account_id?: string | null;
|
|
5886
|
+
};
|
|
5887
|
+
};
|
|
5888
|
+
};
|
|
5889
|
+
responses: {
|
|
5890
|
+
/** @description OK */
|
|
5891
|
+
200: {
|
|
5892
|
+
headers: {
|
|
5893
|
+
[name: string]: unknown;
|
|
5894
|
+
};
|
|
5895
|
+
content: {
|
|
5896
|
+
"application/json": {
|
|
5897
|
+
message?: string;
|
|
5898
|
+
success?: boolean;
|
|
5899
|
+
};
|
|
5900
|
+
};
|
|
5901
|
+
};
|
|
5902
|
+
};
|
|
5903
|
+
};
|
|
5904
|
+
"pos-get-shipment": {
|
|
5905
|
+
parameters: {
|
|
5906
|
+
query?: never;
|
|
5907
|
+
header?: never;
|
|
5908
|
+
path: {
|
|
5909
|
+
/** @description Shipment reference number */
|
|
5910
|
+
reference_number: string;
|
|
5911
|
+
};
|
|
5912
|
+
cookie?: never;
|
|
5913
|
+
};
|
|
5914
|
+
requestBody?: never;
|
|
5915
|
+
responses: {
|
|
5916
|
+
/** @description OK */
|
|
5917
|
+
200: {
|
|
5918
|
+
headers: {
|
|
5919
|
+
[name: string]: unknown;
|
|
5920
|
+
};
|
|
5921
|
+
content: {
|
|
5922
|
+
"application/json": {
|
|
5923
|
+
message?: string;
|
|
5924
|
+
success?: boolean;
|
|
5925
|
+
content?: {
|
|
5926
|
+
shipment?: components$1["schemas"]["ShipmentDetail"];
|
|
5927
|
+
};
|
|
5928
|
+
};
|
|
5929
|
+
};
|
|
5930
|
+
};
|
|
5931
|
+
};
|
|
5932
|
+
};
|
|
5933
|
+
"pos-get-shipment-invoice": {
|
|
5934
|
+
parameters: {
|
|
5935
|
+
query?: {
|
|
5936
|
+
/** @description Response data format */
|
|
5937
|
+
format?: "json" | "pdf";
|
|
5938
|
+
};
|
|
5939
|
+
header?: never;
|
|
5940
|
+
path: {
|
|
5941
|
+
/** @description Shipment reference number */
|
|
5942
|
+
reference_number: string;
|
|
5943
|
+
};
|
|
5944
|
+
cookie?: never;
|
|
5945
|
+
};
|
|
5946
|
+
requestBody?: never;
|
|
5947
|
+
responses: {
|
|
5948
|
+
/** @description OK */
|
|
5949
|
+
200: {
|
|
5950
|
+
headers: {
|
|
5951
|
+
[name: string]: unknown;
|
|
5952
|
+
};
|
|
5953
|
+
content: {
|
|
5954
|
+
"application/json": {
|
|
5955
|
+
message?: string;
|
|
5956
|
+
success?: boolean;
|
|
5957
|
+
content?: {
|
|
5958
|
+
invoice?: components$1["schemas"]["InvoiceDetail"];
|
|
5959
|
+
};
|
|
5960
|
+
};
|
|
5961
|
+
"application/pdf": Record<string, never>;
|
|
5962
|
+
};
|
|
5963
|
+
};
|
|
5964
|
+
};
|
|
5965
|
+
};
|
|
5966
|
+
"pos-update-shipment": {
|
|
5967
|
+
parameters: {
|
|
5968
|
+
query?: never;
|
|
5969
|
+
header?: never;
|
|
5970
|
+
path: {
|
|
5971
|
+
/** @description Shipment reference number */
|
|
5972
|
+
reference_number: string;
|
|
5973
|
+
};
|
|
5974
|
+
cookie?: never;
|
|
5975
|
+
};
|
|
5976
|
+
requestBody?: {
|
|
5977
|
+
content: {
|
|
5978
|
+
"application/json": {
|
|
5979
|
+
status?: string;
|
|
5980
|
+
warehouse_id?: string;
|
|
5981
|
+
awb_no?: string;
|
|
5982
|
+
courier_company_name?: string;
|
|
5983
|
+
shipping_label_url?: string;
|
|
5984
|
+
tracking_url?: string;
|
|
5985
|
+
manual_shipping_charges?: number;
|
|
5986
|
+
/** Format: date-time */
|
|
5987
|
+
eta_delivery?: string;
|
|
5988
|
+
/** Format: date-time */
|
|
5989
|
+
shipped_date?: string;
|
|
5990
|
+
/** Format: date-time */
|
|
5991
|
+
out_for_delivery_date?: string;
|
|
5992
|
+
/** Format: date-time */
|
|
5993
|
+
delivered_date?: string;
|
|
5994
|
+
};
|
|
5995
|
+
};
|
|
5996
|
+
};
|
|
5997
|
+
responses: {
|
|
5998
|
+
/** @description OK */
|
|
5999
|
+
200: {
|
|
6000
|
+
headers: {
|
|
6001
|
+
[name: string]: unknown;
|
|
6002
|
+
};
|
|
6003
|
+
content: {
|
|
6004
|
+
"application/json": {
|
|
6005
|
+
message?: string;
|
|
6006
|
+
success?: boolean;
|
|
6007
|
+
content?: {
|
|
6008
|
+
shipment?: components$1["schemas"]["ShipmentDetail"];
|
|
6009
|
+
};
|
|
6010
|
+
};
|
|
6011
|
+
};
|
|
6012
|
+
};
|
|
6013
|
+
};
|
|
6014
|
+
};
|
|
6015
|
+
}
|
|
6016
|
+
//#endregion
|
|
6017
|
+
//#region ../sdk-core/dist/index.d.ts
|
|
6018
|
+
//#region src/types/api.d.ts
|
|
6019
|
+
|
|
6020
|
+
/**
|
|
6021
|
+
* Core API response types shared across Commerce Engine SDKs
|
|
6022
|
+
*/
|
|
6023
|
+
/**
|
|
6024
|
+
* Standard API error response structure
|
|
6025
|
+
*/
|
|
6026
|
+
interface ApiErrorResponse {
|
|
6027
|
+
success?: boolean;
|
|
6028
|
+
error?: any;
|
|
6029
|
+
code?: string;
|
|
6030
|
+
message?: string;
|
|
6031
|
+
}
|
|
6032
|
+
/**
|
|
6033
|
+
* Generic API result type that wraps all SDK responses
|
|
6034
|
+
* Provides consistent error handling and response structure
|
|
6035
|
+
*/
|
|
6036
|
+
type ApiResult<T> = {
|
|
6037
|
+
data: T;
|
|
6038
|
+
error: null;
|
|
6039
|
+
response: Response;
|
|
6040
|
+
} | {
|
|
6041
|
+
data: null;
|
|
6042
|
+
error: ApiErrorResponse;
|
|
6043
|
+
response: Response;
|
|
6044
|
+
};
|
|
6045
|
+
//#endregion
|
|
6046
|
+
//#region src/types/logger.d.ts
|
|
6047
|
+
/**
|
|
6048
|
+
* Logger-related types for Commerce Engine SDKs
|
|
6049
|
+
*/
|
|
6050
|
+
/**
|
|
6051
|
+
* Debug logger function interface
|
|
6052
|
+
*/
|
|
6053
|
+
interface DebugLoggerFn {
|
|
6054
|
+
(level: "info" | "warn" | "error", message: string, data?: any): void;
|
|
6055
|
+
}
|
|
6056
|
+
//#endregion
|
|
6057
|
+
//#region src/types/config.d.ts
|
|
6058
|
+
/**
|
|
6059
|
+
* Base SDK configuration options for any OpenAPI-based SDK
|
|
6060
|
+
* Completely generic - no assumptions about the underlying API
|
|
6061
|
+
*/
|
|
6062
|
+
interface BaseSDKOptions<TDefaultHeaders extends Record<string, any> = Record<string, any>> {
|
|
6063
|
+
/**
|
|
6064
|
+
* Base URL for the API
|
|
6065
|
+
*/
|
|
6066
|
+
baseUrl?: string;
|
|
6067
|
+
/**
|
|
6068
|
+
* Optional timeout in milliseconds
|
|
6069
|
+
*/
|
|
6070
|
+
timeout?: number;
|
|
6071
|
+
/**
|
|
6072
|
+
* Default headers to include with API requests
|
|
6073
|
+
* These can be overridden at the method level
|
|
6074
|
+
* Generic type allows each SDK to define its supported headers
|
|
6075
|
+
*/
|
|
6076
|
+
defaultHeaders?: TDefaultHeaders;
|
|
6077
|
+
/**
|
|
6078
|
+
* Enable debug mode for detailed request/response logging
|
|
6079
|
+
*/
|
|
6080
|
+
debug?: boolean;
|
|
6081
|
+
/**
|
|
6082
|
+
* Custom logger function for debug information
|
|
6083
|
+
*/
|
|
6084
|
+
logger?: DebugLoggerFn;
|
|
6085
|
+
}
|
|
6086
|
+
/**
|
|
6087
|
+
* Header configuration for SDK clients
|
|
6088
|
+
* Defines supported headers and optional transformations
|
|
6089
|
+
*/
|
|
6090
|
+
interface HeaderConfig<T extends Record<string, any>> {
|
|
6091
|
+
/**
|
|
6092
|
+
* Default headers from SDK configuration
|
|
6093
|
+
*/
|
|
6094
|
+
defaultHeaders?: T;
|
|
6095
|
+
/**
|
|
6096
|
+
* Optional transformations to apply to header names
|
|
6097
|
+
* Maps SDK parameter names to HTTP header names
|
|
6098
|
+
*/
|
|
6099
|
+
transformations?: Record<keyof T, string>;
|
|
6100
|
+
}
|
|
6101
|
+
//#endregion
|
|
6102
|
+
//#region src/base-client.d.ts
|
|
6103
|
+
/**
|
|
6104
|
+
* Generic base API client that all Commerce Engine SDKs can extend
|
|
4211
6105
|
* Handles common functionality like middleware setup, request execution, and header management
|
|
4212
6106
|
* Does NOT include token management - that's SDK-specific
|
|
4213
6107
|
*
|
|
@@ -4274,6 +6168,13 @@ declare class BaseAPIClient<TPaths extends Record<string, any>, THeaders extends
|
|
|
4274
6168
|
* @returns Current default headers
|
|
4275
6169
|
*/
|
|
4276
6170
|
getDefaultHeaders(): THeaders | undefined;
|
|
6171
|
+
/**
|
|
6172
|
+
* Add middleware to the client
|
|
6173
|
+
* This allows SDK extensions to add custom middleware like authentication
|
|
6174
|
+
*
|
|
6175
|
+
* @param middleware - Middleware to add to the client
|
|
6176
|
+
*/
|
|
6177
|
+
use(middleware: any): void;
|
|
4277
6178
|
}
|
|
4278
6179
|
//#endregion
|
|
4279
6180
|
//#region src/utils/url.d.ts
|
|
@@ -4449,11 +6350,12 @@ declare function mergeAndTransformHeaders<T extends Record<string, any> = Record
|
|
|
4449
6350
|
//#endregion
|
|
4450
6351
|
//#endregion
|
|
4451
6352
|
//#region src/lib/client.d.ts
|
|
6353
|
+
type CombinedPaths = paths & paths$1;
|
|
4452
6354
|
/**
|
|
4453
6355
|
* POS API client that extends the generic BaseAPIClient
|
|
4454
6356
|
* Adds Commerce Engine POS specific authentication and token management
|
|
4455
6357
|
*/
|
|
4456
|
-
declare class PosAPIClient extends BaseAPIClient<
|
|
6358
|
+
declare class PosAPIClient extends BaseAPIClient<CombinedPaths, SupportedDefaultHeaders> {
|
|
4457
6359
|
protected config: PosSDKOptions;
|
|
4458
6360
|
private initializationPromise;
|
|
4459
6361
|
/**
|
|
@@ -4515,6 +6417,16 @@ declare class PosAPIClient extends BaseAPIClient<paths, SupportedDefaultHeaders>
|
|
|
4515
6417
|
* Initialize tokens in storage (private helper method)
|
|
4516
6418
|
*/
|
|
4517
6419
|
private initializeTokens;
|
|
6420
|
+
/**
|
|
6421
|
+
* Get client typed for storefront POS operations (paths schema)
|
|
6422
|
+
* This provides proper typing for storefront POS endpoints
|
|
6423
|
+
*/
|
|
6424
|
+
get storefrontClient(): BaseAPIClient<paths, SupportedDefaultHeaders>["client"];
|
|
6425
|
+
/**
|
|
6426
|
+
* Get client typed for admin POS operations (AdminPaths schema)
|
|
6427
|
+
* This provides proper typing for admin POS endpoints
|
|
6428
|
+
*/
|
|
6429
|
+
get adminClient(): BaseAPIClient<paths$1, SupportedDefaultHeaders>["client"];
|
|
4518
6430
|
}
|
|
4519
6431
|
//#endregion
|
|
4520
6432
|
//#region src/lib/utils/url.d.ts
|
|
@@ -4581,6 +6493,7 @@ type FreeShipingCouponPromotion = components['schemas']['FreeShipingCouponPromot
|
|
|
4581
6493
|
type InapplicableCoupon = components['schemas']['InapplicableCoupon'];
|
|
4582
6494
|
type InapplicablePromotion = components['schemas']['InapplicablePromotion'];
|
|
4583
6495
|
type Item = components['schemas']['Item'];
|
|
6496
|
+
type JuspayPaymentGatewayParams = components['schemas']['JuspayPaymentGatewayParams'];
|
|
4584
6497
|
type MultiSelectAttribute = components['schemas']['MultiSelectAttribute'];
|
|
4585
6498
|
type NetbankingPayment = components['schemas']['NetbankingPayment'];
|
|
4586
6499
|
type NumberAttribute = components['schemas']['NumberAttribute'];
|
|
@@ -4591,7 +6504,14 @@ type OrderPayment = components['schemas']['OrderPayment'];
|
|
|
4591
6504
|
type OrderRefund = components['schemas']['OrderRefund'];
|
|
4592
6505
|
type OrderShipment = components['schemas']['OrderShipment'];
|
|
4593
6506
|
type Pagination = components['schemas']['Pagination'];
|
|
6507
|
+
type PayWithCard = components['schemas']['PayWithCard'];
|
|
6508
|
+
type PayWithCash = components['schemas']['PayWithCash'];
|
|
6509
|
+
type PayWithPaymentGateway = components['schemas']['PayWithPaymentGateway'];
|
|
6510
|
+
type PayWithUpi = components['schemas']['PayWithUpi'];
|
|
6511
|
+
type PaymentGateway = components['schemas']['PaymentGateway'];
|
|
6512
|
+
type PaymentGatewayParams = components['schemas']['PaymentGatewayParams'];
|
|
4594
6513
|
type PaymentInfo = components['schemas']['PaymentInfo'];
|
|
6514
|
+
type PayuPaymentGatewayParams = components['schemas']['PayuPaymentGatewayParams'];
|
|
4595
6515
|
type PercentageDiscountRule = components['schemas']['PercentageDiscountRule'];
|
|
4596
6516
|
type PincodeServiceability = components['schemas']['PincodeServiceability'];
|
|
4597
6517
|
type PosDevice = components['schemas']['PosDevice'];
|
|
@@ -4752,6 +6672,68 @@ type GetPosFulfillmentOptionsBody = NonNullable<paths['/pos/fulfillment-options'
|
|
|
4752
6672
|
type CreatePosOrderResponse = paths['/pos/orders']['post']['responses'][200]['content']['application/json'];
|
|
4753
6673
|
type CreatePosOrderContent = CreatePosOrderResponse['content'];
|
|
4754
6674
|
type CreatePosOrderBody = NonNullable<paths['/pos/orders']['post']['requestBody']>['content']['application/json'];
|
|
6675
|
+
type PosGetPaymentStatusResponse = paths['/pos/orders/{order_number}/payment-status']['get']['responses'][200]['content']['application/json'];
|
|
6676
|
+
type PosGetPaymentStatusContent = PosGetPaymentStatusResponse['content'];
|
|
6677
|
+
type PosGetPaymentStatusPathParams = paths['/pos/orders/{order_number}/payment-status']['get']['parameters']['path'];
|
|
6678
|
+
type PosListPaymentOptionsResponse = paths['/pos/payments/payment-options']['get']['responses'][200]['content']['application/json'];
|
|
6679
|
+
type PosListPaymentOptionsContent = PosListPaymentOptionsResponse['content'];
|
|
6680
|
+
//#endregion
|
|
6681
|
+
//#region src/types/admin-pos-api-types.d.ts
|
|
6682
|
+
type PosListInventoriesResponse = paths$1['/pos/catalog/inventories']['get']['responses'][200]['content']['application/json'];
|
|
6683
|
+
type PosListInventoriesContent = PosListInventoriesResponse['content'];
|
|
6684
|
+
type PosListInventoriesQuery = paths$1['/pos/catalog/inventories']['get']['parameters']['query'];
|
|
6685
|
+
type PosListInventoriesActivitiesResponse = paths$1['/pos/catalog/inventories/activites']['get']['responses'][200]['content']['application/json'];
|
|
6686
|
+
type PosListInventoriesActivitiesContent = PosListInventoriesActivitiesResponse['content'];
|
|
6687
|
+
type PosListInventoriesActivitiesQuery = paths$1['/pos/catalog/inventories/activites']['get']['parameters']['query'];
|
|
6688
|
+
type PosGetInventoryDetailResponse = paths$1['/pos/catalog/inventories/detail']['get']['responses'][200]['content']['application/json'];
|
|
6689
|
+
type PosGetInventoryDetailContent = PosGetInventoryDetailResponse['content'];
|
|
6690
|
+
type PosGetInventoryDetailQuery = paths$1['/pos/catalog/inventories/detail']['get']['parameters']['query'];
|
|
6691
|
+
type PosGetAdminCustomersResponse = paths$1['/pos/customers']['get']['responses'][200]['content']['application/json'];
|
|
6692
|
+
type PosGetAdminCustomersContent = PosGetAdminCustomersResponse['content'];
|
|
6693
|
+
type PosGetAdminCustomersQuery = paths$1['/pos/customers']['get']['parameters']['query'];
|
|
6694
|
+
type PosGetAdminCustomersIdResponse = paths$1['/pos/customers/{id}']['get']['responses'][200]['content']['application/json'];
|
|
6695
|
+
type PosGetAdminCustomersIdContent = PosGetAdminCustomersIdResponse['content'];
|
|
6696
|
+
type PosGetAdminCustomersIdPathParams = paths$1['/pos/customers/{id}']['get']['parameters']['path'];
|
|
6697
|
+
type PosListAdminOrdersResponse = paths$1['/pos/orders']['get']['responses'][200]['content']['application/json'];
|
|
6698
|
+
type PosListAdminOrdersContent = PosListAdminOrdersResponse['content'];
|
|
6699
|
+
type PosListAdminOrdersQuery = paths$1['/pos/orders']['get']['parameters']['query'];
|
|
6700
|
+
type PosGetAdminOrderResponse = paths$1['/pos/orders/{order_number}']['get']['responses'][200]['content']['application/json'];
|
|
6701
|
+
type PosGetAdminOrderContent = PosGetAdminOrderResponse['content'];
|
|
6702
|
+
type PosGetAdminOrderPathParams = paths$1['/pos/orders/{order_number}']['get']['parameters']['path'];
|
|
6703
|
+
type PosListOrderActivityResponse = paths$1['/pos/orders/{order_number}/activity']['get']['responses'][200]['content']['application/json'];
|
|
6704
|
+
type PosListOrderActivityContent = PosListOrderActivityResponse['content'];
|
|
6705
|
+
type PosListOrderActivityPathParams = paths$1['/pos/orders/{order_number}/activity']['get']['parameters']['path'];
|
|
6706
|
+
type PosGetOrderInvoiceResponse = paths$1['/pos/orders/{order_number}/invoice']['get']['responses'][200]['content']['application/json'];
|
|
6707
|
+
type PosGetOrderInvoiceContent = PosGetOrderInvoiceResponse['content'];
|
|
6708
|
+
type PosGetOrderInvoiceQuery = paths$1['/pos/orders/{order_number}/invoice']['get']['parameters']['query'];
|
|
6709
|
+
type PosGetOrderInvoicePathParams = paths$1['/pos/orders/{order_number}/invoice']['get']['parameters']['path'];
|
|
6710
|
+
type PosGetOrderReceiptResponse = paths$1['/pos/orders/{order_number}/receipt']['get']['responses'][200]['content']['application/json'];
|
|
6711
|
+
type PosGetOrderReceiptContent = PosGetOrderReceiptResponse['content'];
|
|
6712
|
+
type PosGetOrderReceiptQuery = paths$1['/pos/orders/{order_number}/receipt']['get']['parameters']['query'];
|
|
6713
|
+
type PosGetOrderReceiptPathParams = paths$1['/pos/orders/{order_number}/receipt']['get']['parameters']['path'];
|
|
6714
|
+
type PosGetOrderShipmentsResponse = paths$1['/pos/orders/{order_number}/shipments']['get']['responses'][200]['content']['application/json'];
|
|
6715
|
+
type PosGetOrderShipmentsContent = PosGetOrderShipmentsResponse['content'];
|
|
6716
|
+
type PosGetOrderShipmentsPathParams = paths$1['/pos/orders/{order_number}/shipments']['get']['parameters']['path'];
|
|
6717
|
+
type PosListShipmentsResponse = paths$1['/pos/shipping/shipments']['get']['responses'][200]['content']['application/json'];
|
|
6718
|
+
type PosListShipmentsContent = PosListShipmentsResponse['content'];
|
|
6719
|
+
type PosListShipmentsQuery = paths$1['/pos/shipping/shipments']['get']['parameters']['query'];
|
|
6720
|
+
type PosCheckInventoryForOrderResponse = paths$1['/pos/shipping/shipments/{order_number}/check-inventory']['get']['responses'][200]['content']['application/json'];
|
|
6721
|
+
type PosCheckInventoryForOrderContent = PosCheckInventoryForOrderResponse['content'];
|
|
6722
|
+
type PosCheckInventoryForOrderPathParams = paths$1['/pos/shipping/shipments/{order_number}/check-inventory']['get']['parameters']['path'];
|
|
6723
|
+
type PosRefundShortfallForOrderResponse = paths$1['/pos/shipping/shipments/{order_number}/refund-shortfall']['post']['responses'][200]['content']['application/json'];
|
|
6724
|
+
type PosRefundShortfallForOrderPathParams = paths$1['/pos/shipping/shipments/{order_number}/refund-shortfall']['post']['parameters']['path'];
|
|
6725
|
+
type PosRefundShortfallForOrderBody = NonNullable<paths$1['/pos/shipping/shipments/{order_number}/refund-shortfall']['post']['requestBody']>['content']['application/json'];
|
|
6726
|
+
type PosGetShipmentResponse = paths$1['/pos/shipping/shipments/{reference_number}']['get']['responses'][200]['content']['application/json'];
|
|
6727
|
+
type PosGetShipmentContent = PosGetShipmentResponse['content'];
|
|
6728
|
+
type PosGetShipmentPathParams = paths$1['/pos/shipping/shipments/{reference_number}']['get']['parameters']['path'];
|
|
6729
|
+
type PosGetShipmentInvoiceResponse = paths$1['/pos/shipping/shipments/{reference_number}/invoice']['get']['responses'][200]['content']['application/json'];
|
|
6730
|
+
type PosGetShipmentInvoiceContent = PosGetShipmentInvoiceResponse['content'];
|
|
6731
|
+
type PosGetShipmentInvoiceQuery = paths$1['/pos/shipping/shipments/{reference_number}/invoice']['get']['parameters']['query'];
|
|
6732
|
+
type PosGetShipmentInvoicePathParams = paths$1['/pos/shipping/shipments/{reference_number}/invoice']['get']['parameters']['path'];
|
|
6733
|
+
type PosUpdateShipmentResponse = paths$1['/pos/shipping/shipments/{reference_number}/manual-update']['put']['responses'][200]['content']['application/json'];
|
|
6734
|
+
type PosUpdateShipmentContent = PosUpdateShipmentResponse['content'];
|
|
6735
|
+
type PosUpdateShipmentPathParams = paths$1['/pos/shipping/shipments/{reference_number}/manual-update']['put']['parameters']['path'];
|
|
6736
|
+
type PosUpdateShipmentBody = NonNullable<paths$1['/pos/shipping/shipments/{reference_number}/manual-update']['put']['requestBody']>['content']['application/json'];
|
|
4755
6737
|
//#endregion
|
|
4756
6738
|
//#region src/lib/pos.d.ts
|
|
4757
6739
|
/**
|
|
@@ -4763,59 +6745,217 @@ declare class PosClient extends PosAPIClient {
|
|
|
4763
6745
|
* Login with email address for POS device
|
|
4764
6746
|
* @param body - Login credentials containing device ID and email
|
|
4765
6747
|
* @returns Promise with OTP token and action
|
|
6748
|
+
* @example
|
|
6749
|
+
* ```typescript
|
|
6750
|
+
* const { data, error } = await pos.loginWithEmail({
|
|
6751
|
+
* device_id: "pos-device-123",
|
|
6752
|
+
* email: "staff@example.com"
|
|
6753
|
+
* });
|
|
6754
|
+
*
|
|
6755
|
+
* if (error) {
|
|
6756
|
+
* console.error("Login failed:", error.message);
|
|
6757
|
+
* } else {
|
|
6758
|
+
* console.log("OTP sent:", data.otp_token);
|
|
6759
|
+
* console.log("Action:", data.otp_action);
|
|
6760
|
+
* // Use the otp_token to verify OTP
|
|
6761
|
+
* }
|
|
6762
|
+
* ```
|
|
4766
6763
|
*/
|
|
4767
6764
|
loginWithEmail(body: LoginPosDeviceWithEmailBody): Promise<ApiResult<LoginPosDeviceWithEmailContent>>;
|
|
4768
6765
|
/**
|
|
4769
6766
|
* Login with phone number for POS device
|
|
4770
6767
|
* @param body - Login credentials containing device ID and phone
|
|
4771
6768
|
* @returns Promise with OTP token and action
|
|
6769
|
+
* @example
|
|
6770
|
+
* ```typescript
|
|
6771
|
+
* const { data, error } = await pos.loginWithPhone({
|
|
6772
|
+
* device_id: "pos-device-123",
|
|
6773
|
+
* phone: "234567890",
|
|
6774
|
+
* country_code: "+91" // default is +91
|
|
6775
|
+
* });
|
|
6776
|
+
*
|
|
6777
|
+
* if (error) {
|
|
6778
|
+
* console.error("Login failed:", error.message);
|
|
6779
|
+
* } else {
|
|
6780
|
+
* console.log("OTP sent:", data.otp_token);
|
|
6781
|
+
* console.log("Action:", data.otp_action);
|
|
6782
|
+
* // Use the otp_token to verify OTP
|
|
6783
|
+
* }
|
|
6784
|
+
* ```
|
|
4772
6785
|
*/
|
|
4773
6786
|
loginWithPhone(body: LoginPosDeviceWithPhoneBody): Promise<ApiResult<LoginPosDeviceWithPhoneContent>>;
|
|
4774
6787
|
/**
|
|
4775
6788
|
* Login with WhatsApp for POS device
|
|
4776
6789
|
* @param body - Login credentials containing device ID and phone
|
|
4777
6790
|
* @returns Promise with OTP token and action
|
|
6791
|
+
* @example
|
|
6792
|
+
* ```typescript
|
|
6793
|
+
* const { data, error } = await pos.loginWithWhatsapp({
|
|
6794
|
+
* device_id: "pos-device-123",
|
|
6795
|
+
* phone: "234567890",
|
|
6796
|
+
* country_code: "+91" // default is +91
|
|
6797
|
+
* });
|
|
6798
|
+
*
|
|
6799
|
+
* if (error) {
|
|
6800
|
+
* console.error("WhatsApp login failed:", error.message);
|
|
6801
|
+
* } else {
|
|
6802
|
+
* console.log("WhatsApp OTP sent:", data.otp_token);
|
|
6803
|
+
* console.log("Action:", data.otp_action);
|
|
6804
|
+
* // Use the otp_token to verify OTP
|
|
6805
|
+
* }
|
|
6806
|
+
* ```
|
|
4778
6807
|
*/
|
|
4779
6808
|
loginWithWhatsapp(body: LoginPosDeviceWithWhatsappBody): Promise<ApiResult<LoginPosDeviceWithWhatsappContent>>;
|
|
4780
6809
|
/**
|
|
4781
6810
|
* Pair POS device with pairing code
|
|
4782
6811
|
* @param body - Pairing code received via phone/email
|
|
4783
6812
|
* @returns Promise with device information
|
|
6813
|
+
* @example
|
|
6814
|
+
* ```typescript
|
|
6815
|
+
* const { data, error } = await pos.pairDevice({
|
|
6816
|
+
* pairing_code: "ABC123"
|
|
6817
|
+
* });
|
|
6818
|
+
*
|
|
6819
|
+
* if (error) {
|
|
6820
|
+
* console.error("Device pairing failed:", error.message);
|
|
6821
|
+
* } else {
|
|
6822
|
+
* console.log("Device paired:", data.device.id);
|
|
6823
|
+
* console.log("Device name:", data.device.name);
|
|
6824
|
+
* // Store device_id for future use
|
|
6825
|
+
* }
|
|
6826
|
+
* ```
|
|
4784
6827
|
*/
|
|
4785
6828
|
pairDevice(body: PairPosDeviceBody): Promise<ApiResult<PairPosDeviceContent>>;
|
|
4786
6829
|
/**
|
|
4787
6830
|
* Verify OTP for POS login
|
|
4788
6831
|
* @param body - OTP verification data
|
|
4789
6832
|
* @returns Promise with user info and tokens
|
|
6833
|
+
* @example
|
|
6834
|
+
* ```typescript
|
|
6835
|
+
* const { data, error } = await pos.verifyOtp({
|
|
6836
|
+
* otp_token: "otp-token-from-login",
|
|
6837
|
+
* otp: "123456",
|
|
6838
|
+
* otp_action: "login"
|
|
6839
|
+
* });
|
|
6840
|
+
*
|
|
6841
|
+
* if (error) {
|
|
6842
|
+
* console.error("OTP verification failed:", error.message);
|
|
6843
|
+
* } else {
|
|
6844
|
+
* console.log("Login successful:", data.user);
|
|
6845
|
+
* console.log("Access token:", data.access_token);
|
|
6846
|
+
* console.log("Refresh token:", data.refresh_token);
|
|
6847
|
+
* // Tokens are automatically stored by the SDK
|
|
6848
|
+
* }
|
|
6849
|
+
* ```
|
|
4790
6850
|
*/
|
|
4791
6851
|
verifyOtp(body: VerifyPosLoginOtpBody): Promise<ApiResult<VerifyPosLoginOtpContent>>;
|
|
4792
6852
|
/**
|
|
4793
6853
|
* Refresh POS access token
|
|
4794
6854
|
* @param body - Refresh token data
|
|
4795
6855
|
* @returns Promise with new tokens
|
|
6856
|
+
* @example
|
|
6857
|
+
* ```typescript
|
|
6858
|
+
* const { data, error } = await pos.refreshAccessToken({
|
|
6859
|
+
* refresh_token: "refresh-token-here"
|
|
6860
|
+
* });
|
|
6861
|
+
*
|
|
6862
|
+
* if (error) {
|
|
6863
|
+
* console.error("Token refresh failed:", error.message);
|
|
6864
|
+
* } else {
|
|
6865
|
+
* console.log("New access token:", data.access_token);
|
|
6866
|
+
* console.log("New refresh token:", data.refresh_token);
|
|
6867
|
+
* // New tokens are automatically stored by the SDK
|
|
6868
|
+
* }
|
|
6869
|
+
* ```
|
|
4796
6870
|
*/
|
|
4797
6871
|
refreshAccessToken(body: RefreshPosAccessTokenBody): Promise<ApiResult<RefreshPosAccessTokenContent>>;
|
|
4798
6872
|
/**
|
|
4799
6873
|
* Logout from POS device
|
|
4800
6874
|
* @returns Promise with logout confirmation
|
|
6875
|
+
* @example
|
|
6876
|
+
* ```typescript
|
|
6877
|
+
* const { data, error } = await pos.logout();
|
|
6878
|
+
*
|
|
6879
|
+
* if (error) {
|
|
6880
|
+
* console.error("Logout failed:", error.message);
|
|
6881
|
+
* } else {
|
|
6882
|
+
* console.log("Logout message:", data.message);
|
|
6883
|
+
* console.log("Success:", data.success);
|
|
6884
|
+
* // Tokens are automatically cleared by the SDK
|
|
6885
|
+
* }
|
|
6886
|
+
* ```
|
|
4801
6887
|
*/
|
|
4802
6888
|
logout(): Promise<ApiResult<LogoutFromPosDeviceResponse>>;
|
|
4803
6889
|
/**
|
|
4804
6890
|
* Create a new cart
|
|
4805
6891
|
* @param body - Cart creation data with items
|
|
4806
6892
|
* @returns Promise with created cart
|
|
6893
|
+
* @example
|
|
6894
|
+
* ```typescript
|
|
6895
|
+
* const { data, error } = await pos.createCart({
|
|
6896
|
+
* items: [
|
|
6897
|
+
* {
|
|
6898
|
+
* product_id: "01H9XYZ12345ABCDE",
|
|
6899
|
+
* variant_id: null,
|
|
6900
|
+
* quantity: 2
|
|
6901
|
+
* },
|
|
6902
|
+
* {
|
|
6903
|
+
* product_id: "01H9ABC67890FGHIJ",
|
|
6904
|
+
* variant_id: "01H9XYZ67890KLMNO",
|
|
6905
|
+
* quantity: 1
|
|
6906
|
+
* }
|
|
6907
|
+
* ],
|
|
6908
|
+
* metadata: {
|
|
6909
|
+
* "source": "pos-terminal-1",
|
|
6910
|
+
* "staff_id": "staff-123"
|
|
6911
|
+
* }
|
|
6912
|
+
* });
|
|
6913
|
+
*
|
|
6914
|
+
* if (error) {
|
|
6915
|
+
* console.error("Failed to create cart:", error.message);
|
|
6916
|
+
* } else {
|
|
6917
|
+
* console.log("Cart created:", data.cart.id);
|
|
6918
|
+
* console.log("Cart total:", data.cart.grand_total);
|
|
6919
|
+
* }
|
|
6920
|
+
* ```
|
|
4807
6921
|
*/
|
|
4808
6922
|
createCart(body: PosCreateCartBody): Promise<ApiResult<PosCreateCartContent>>;
|
|
4809
6923
|
/**
|
|
4810
6924
|
* Get cart details
|
|
4811
6925
|
* @param pathParams - Cart ID
|
|
4812
6926
|
* @returns Promise with cart details
|
|
6927
|
+
* @example
|
|
6928
|
+
* ```typescript
|
|
6929
|
+
* const { data, error } = await pos.getCart({
|
|
6930
|
+
* id: "01H9CART12345ABCDE"
|
|
6931
|
+
* });
|
|
6932
|
+
*
|
|
6933
|
+
* if (error) {
|
|
6934
|
+
* console.error("Failed to get cart:", error.message);
|
|
6935
|
+
* } else {
|
|
6936
|
+
* const cart = data.cart;
|
|
6937
|
+
* console.log("Cart total:", cart.grand_total);
|
|
6938
|
+
* console.log("Items count:", cart.cart_items.length);
|
|
6939
|
+
* }
|
|
6940
|
+
* ```
|
|
4813
6941
|
*/
|
|
4814
6942
|
getCart(pathParams: PosGetCartPathParams): Promise<ApiResult<PosGetCartContent>>;
|
|
4815
6943
|
/**
|
|
4816
6944
|
* Delete cart (remove all items)
|
|
4817
6945
|
* @param pathParams - Cart ID
|
|
4818
6946
|
* @returns Promise with deletion confirmation
|
|
6947
|
+
* @example
|
|
6948
|
+
* ```typescript
|
|
6949
|
+
* const { data, error } = await pos.deleteCart({
|
|
6950
|
+
* id: "01H9CART12345ABCDE"
|
|
6951
|
+
* });
|
|
6952
|
+
*
|
|
6953
|
+
* if (error) {
|
|
6954
|
+
* console.error("Failed to delete cart:", error.message);
|
|
6955
|
+
* } else {
|
|
6956
|
+
* console.log("Cart deleted:", data.message);
|
|
6957
|
+
* }
|
|
6958
|
+
* ```
|
|
4819
6959
|
*/
|
|
4820
6960
|
deleteCart(pathParams: PosDeleteCartPathParams): Promise<ApiResult<PosDeleteCartResponse>>;
|
|
4821
6961
|
/**
|
|
@@ -4823,6 +6963,34 @@ declare class PosClient extends PosAPIClient {
|
|
|
4823
6963
|
* @param pathParams - Cart ID
|
|
4824
6964
|
* @param body - Item update data
|
|
4825
6965
|
* @returns Promise with updated cart
|
|
6966
|
+
* @example
|
|
6967
|
+
* ```typescript
|
|
6968
|
+
* // Add item to cart
|
|
6969
|
+
* const { data, error } = await pos.updateCart(
|
|
6970
|
+
* { id: "01H9CART12345ABCDE" },
|
|
6971
|
+
* {
|
|
6972
|
+
* product_id: "01H9XYZ12345ABCDE",
|
|
6973
|
+
* variant_id: null,
|
|
6974
|
+
* quantity: 3
|
|
6975
|
+
* }
|
|
6976
|
+
* );
|
|
6977
|
+
*
|
|
6978
|
+
* if (error) {
|
|
6979
|
+
* console.error("Failed to update cart:", error.message);
|
|
6980
|
+
* } else {
|
|
6981
|
+
* console.log("Cart updated:", data.cart.cart_items.length);
|
|
6982
|
+
* }
|
|
6983
|
+
*
|
|
6984
|
+
* // Remove item from cart (set quantity to 0)
|
|
6985
|
+
* const { data: removeData, error: removeError } = await pos.updateCart(
|
|
6986
|
+
* { id: "01H9CART12345ABCDE" },
|
|
6987
|
+
* {
|
|
6988
|
+
* product_id: "01H9XYZ12345ABCDE",
|
|
6989
|
+
* variant_id: null,
|
|
6990
|
+
* quantity: 0
|
|
6991
|
+
* }
|
|
6992
|
+
* );
|
|
6993
|
+
* ```
|
|
4826
6994
|
*/
|
|
4827
6995
|
updateCart(pathParams: PosUpdateCartPathParams, body: PosUpdateCartBody): Promise<ApiResult<PosUpdateCartContent>>;
|
|
4828
6996
|
/**
|
|
@@ -4830,18 +6998,114 @@ declare class PosClient extends PosAPIClient {
|
|
|
4830
6998
|
* @param pathParams - Cart ID
|
|
4831
6999
|
* @param body - Address data (registered user IDs or guest addresses)
|
|
4832
7000
|
* @returns Promise with updated cart
|
|
7001
|
+
* @example
|
|
7002
|
+
* ```typescript
|
|
7003
|
+
* // For registered users with saved addresses
|
|
7004
|
+
* const { data, error } = await pos.createCartAddress(
|
|
7005
|
+
* { id: "01H9CART12345ABCDE" },
|
|
7006
|
+
* {
|
|
7007
|
+
* billing_address_id: "01H9ADDR12345BILL",
|
|
7008
|
+
* shipping_address_id: "01H9ADDR12345SHIP"
|
|
7009
|
+
* }
|
|
7010
|
+
* );
|
|
7011
|
+
*
|
|
7012
|
+
* if (error) {
|
|
7013
|
+
* console.error("Failed to update cart address:", error.message);
|
|
7014
|
+
* } else {
|
|
7015
|
+
* console.log("Addresses updated:", data.message);
|
|
7016
|
+
* }
|
|
7017
|
+
*
|
|
7018
|
+
* // For guest checkout with new addresses
|
|
7019
|
+
* const { data: guestData, error: guestError } = await pos.createCartAddress(
|
|
7020
|
+
* { id: "01H9CART12345ABCDE" },
|
|
7021
|
+
* {
|
|
7022
|
+
* billing_address: {
|
|
7023
|
+
* first_name: "John",
|
|
7024
|
+
* last_name: "Doe",
|
|
7025
|
+
* email: "john@example.com",
|
|
7026
|
+
* phone: "9876543210",
|
|
7027
|
+
* country_code: "+91",
|
|
7028
|
+
* address_line1: "123 Main Street",
|
|
7029
|
+
* address_line2: "Apt 4B",
|
|
7030
|
+
* city: "Mumbai",
|
|
7031
|
+
* state: "Maharashtra",
|
|
7032
|
+
* pincode: "400001",
|
|
7033
|
+
* country: "India",
|
|
7034
|
+
* landmark: "Near Station",
|
|
7035
|
+
* tax_identification_number: null,
|
|
7036
|
+
* business_name: null
|
|
7037
|
+
* },
|
|
7038
|
+
* shipping_address: {
|
|
7039
|
+
* first_name: "John",
|
|
7040
|
+
* last_name: "Doe",
|
|
7041
|
+
* email: "john@example.com",
|
|
7042
|
+
* phone: "9876543210",
|
|
7043
|
+
* country_code: "+91",
|
|
7044
|
+
* address_line1: "456 Oak Avenue",
|
|
7045
|
+
* address_line2: null,
|
|
7046
|
+
* city: "Pune",
|
|
7047
|
+
* state: "Maharashtra",
|
|
7048
|
+
* pincode: "411001",
|
|
7049
|
+
* country: "India",
|
|
7050
|
+
* landmark: "Near Mall",
|
|
7051
|
+
* tax_identification_number: null,
|
|
7052
|
+
* business_name: null
|
|
7053
|
+
* }
|
|
7054
|
+
* }
|
|
7055
|
+
* );
|
|
7056
|
+
* ```
|
|
4833
7057
|
*/
|
|
4834
7058
|
createCartAddress(pathParams: PosCreateCartAddressPathParams, body: PosCreateCartAddressBody): Promise<ApiResult<PosCreateCartAddressContent>>;
|
|
4835
7059
|
/**
|
|
4836
7060
|
* List all available coupons
|
|
4837
7061
|
* @param headers - Optional header parameters (customer_group_id, etc.)
|
|
4838
7062
|
* @returns Promise with available coupons
|
|
7063
|
+
* @example
|
|
7064
|
+
* ```typescript
|
|
7065
|
+
* // Get all available coupons
|
|
7066
|
+
* const { data, error } = await pos.listCoupons();
|
|
7067
|
+
*
|
|
7068
|
+
* if (error) {
|
|
7069
|
+
* console.error("Failed to get available coupons:", error.message);
|
|
7070
|
+
* } else {
|
|
7071
|
+
* const coupons = data.coupons || [];
|
|
7072
|
+
* console.log("Available coupons:", coupons.length);
|
|
7073
|
+
* coupons.forEach(coupon => {
|
|
7074
|
+
* console.log("Coupon:", coupon.code, "Discount:", coupon.discount_amount);
|
|
7075
|
+
* });
|
|
7076
|
+
* }
|
|
7077
|
+
*
|
|
7078
|
+
* // Override customer group ID for this specific request
|
|
7079
|
+
* const { data: overrideData, error: overrideError } = await pos.listCoupons({
|
|
7080
|
+
* "x-customer-group-id": "01H9GROUP12345ABC" // Override default SDK config
|
|
7081
|
+
* });
|
|
7082
|
+
* ```
|
|
4839
7083
|
*/
|
|
4840
7084
|
listCoupons(headers?: PosListCouponsHeaderParams): Promise<ApiResult<PosListCouponsContent>>;
|
|
4841
7085
|
/**
|
|
4842
7086
|
* List all available promotions
|
|
4843
7087
|
* @param headers - Optional header parameters (customer_group_id, etc.)
|
|
4844
7088
|
* @returns Promise with available promotions
|
|
7089
|
+
* @example
|
|
7090
|
+
* ```typescript
|
|
7091
|
+
* // Get all available promotions
|
|
7092
|
+
* const { data, error } = await pos.listPromotions();
|
|
7093
|
+
*
|
|
7094
|
+
* if (error) {
|
|
7095
|
+
* console.error("Failed to get available promotions:", error.message);
|
|
7096
|
+
* } else {
|
|
7097
|
+
* const promotions = data.promotions || [];
|
|
7098
|
+
* console.log("Available promotions:", promotions.length);
|
|
7099
|
+
* promotions.forEach(promotion => {
|
|
7100
|
+
* console.log("Promotion:", promotion.name, "Type:", promotion.promotion_type);
|
|
7101
|
+
* });
|
|
7102
|
+
* }
|
|
7103
|
+
*
|
|
7104
|
+
* // Override customer group ID for this specific request
|
|
7105
|
+
* const { data: overrideData, error: overrideError } = await pos.listPromotions({
|
|
7106
|
+
* "x-customer-group-id": "01H9GROUP12345ABC" // Override default SDK config
|
|
7107
|
+
* });
|
|
7108
|
+
* ```
|
|
4845
7109
|
*/
|
|
4846
7110
|
listPromotions(headers?: PosListPromotionsHeaderParams): Promise<ApiResult<PosListPromotionsContent>>;
|
|
4847
7111
|
/**
|
|
@@ -4849,24 +7113,96 @@ declare class PosClient extends PosAPIClient {
|
|
|
4849
7113
|
* @param pathParams - Cart ID
|
|
4850
7114
|
* @param body - Coupon code
|
|
4851
7115
|
* @returns Promise with updated cart
|
|
7116
|
+
* @example
|
|
7117
|
+
* ```typescript
|
|
7118
|
+
* const { data, error } = await pos.applyCoupon(
|
|
7119
|
+
* { id: "01H9CART12345ABCDE" },
|
|
7120
|
+
* { coupon_code: "FLAT100OFF" }
|
|
7121
|
+
* );
|
|
7122
|
+
*
|
|
7123
|
+
* if (error) {
|
|
7124
|
+
* console.error("Failed to apply coupon:", error.message);
|
|
7125
|
+
* } else {
|
|
7126
|
+
* console.log("Coupon applied, new total:", data.cart.grand_total);
|
|
7127
|
+
* console.log("Discount amount:", data.cart.coupon_discount_amount);
|
|
7128
|
+
* }
|
|
7129
|
+
* ```
|
|
4852
7130
|
*/
|
|
4853
7131
|
applyCoupon(pathParams: PosApplyCouponPathParams, body: PosApplyCouponBody): Promise<ApiResult<PosApplyCouponContent>>;
|
|
4854
7132
|
/**
|
|
4855
7133
|
* Remove coupon from cart
|
|
4856
7134
|
* @param pathParams - Cart ID
|
|
4857
7135
|
* @returns Promise with updated cart
|
|
7136
|
+
* @example
|
|
7137
|
+
* ```typescript
|
|
7138
|
+
* const { data, error } = await pos.removeCoupon({
|
|
7139
|
+
* id: "01H9CART12345ABCDE"
|
|
7140
|
+
* });
|
|
7141
|
+
*
|
|
7142
|
+
* if (error) {
|
|
7143
|
+
* console.error("Failed to remove coupon:", error.message);
|
|
7144
|
+
* } else {
|
|
7145
|
+
* console.log("Coupon removed, new total:", data.cart.grand_total);
|
|
7146
|
+
* }
|
|
7147
|
+
* ```
|
|
4858
7148
|
*/
|
|
4859
7149
|
removeCoupon(pathParams: PosRemoveCouponPathParams): Promise<ApiResult<PosRemoveCouponContent>>;
|
|
4860
7150
|
/**
|
|
4861
7151
|
* Evaluate applicable/inapplicable coupons for cart
|
|
4862
7152
|
* @param pathParams - Cart ID
|
|
4863
7153
|
* @returns Promise with coupon evaluation results
|
|
7154
|
+
* @example
|
|
7155
|
+
* ```typescript
|
|
7156
|
+
* const { data, error } = await pos.evaluateCoupons({
|
|
7157
|
+
* id: "01H9CART12345ABCDE"
|
|
7158
|
+
* });
|
|
7159
|
+
*
|
|
7160
|
+
* if (error) {
|
|
7161
|
+
* console.error("Failed to evaluate coupons:", error.message);
|
|
7162
|
+
* } else {
|
|
7163
|
+
* const applicable = data.applicable_coupons || [];
|
|
7164
|
+
* const inapplicable = data.inapplicable_coupons || [];
|
|
7165
|
+
*
|
|
7166
|
+
* console.log("Applicable coupons:", applicable.length);
|
|
7167
|
+
* applicable.forEach(coupon => {
|
|
7168
|
+
* console.log(`- ${coupon.code}: Save $${coupon.estimated_discount}`);
|
|
7169
|
+
* });
|
|
7170
|
+
*
|
|
7171
|
+
* console.log("Inapplicable coupons:", inapplicable.length);
|
|
7172
|
+
* inapplicable.forEach(coupon => {
|
|
7173
|
+
* console.log(`- ${coupon.code}: ${coupon.reason}`);
|
|
7174
|
+
* });
|
|
7175
|
+
* }
|
|
7176
|
+
* ```
|
|
4864
7177
|
*/
|
|
4865
7178
|
evaluateCoupons(pathParams: PosEvaluateCouponsPathParams): Promise<ApiResult<PosEvaluateCouponsContent>>;
|
|
4866
7179
|
/**
|
|
4867
7180
|
* Evaluate applicable/inapplicable promotions for cart
|
|
4868
7181
|
* @param pathParams - Cart ID
|
|
4869
7182
|
* @returns Promise with promotion evaluation results
|
|
7183
|
+
* @example
|
|
7184
|
+
* ```typescript
|
|
7185
|
+
* const { data, error } = await pos.evaluatePromotions({
|
|
7186
|
+
* id: "01H9CART12345ABCDE"
|
|
7187
|
+
* });
|
|
7188
|
+
*
|
|
7189
|
+
* if (error) {
|
|
7190
|
+
* console.error("Failed to evaluate promotions:", error.message);
|
|
7191
|
+
* } else {
|
|
7192
|
+
* const applicable = data.applicable_promotions || [];
|
|
7193
|
+
* const inapplicable = data.inapplicable_promotions || [];
|
|
7194
|
+
*
|
|
7195
|
+
* console.log("Applicable promotions:", applicable.length);
|
|
7196
|
+
* applicable.forEach(promo => {
|
|
7197
|
+
* console.log(`- ${promo.name}: ${promo.savings_message}`);
|
|
7198
|
+
* });
|
|
7199
|
+
*
|
|
7200
|
+
* console.log("Inapplicable promotions:", inapplicable.length);
|
|
7201
|
+
* inapplicable.forEach(promo => {
|
|
7202
|
+
* console.log(`- ${promo.name}: ${promo.reason}`);
|
|
7203
|
+
* });
|
|
7204
|
+
* }
|
|
7205
|
+
* ```
|
|
4870
7206
|
*/
|
|
4871
7207
|
evaluatePromotions(pathParams: PosEvaluatePromotionsPathParams): Promise<ApiResult<PosEvaluatePromotionsContent>>;
|
|
4872
7208
|
/**
|
|
@@ -4874,12 +7210,38 @@ declare class PosClient extends PosAPIClient {
|
|
|
4874
7210
|
* @param pathParams - Cart ID
|
|
4875
7211
|
* @param body - Credit balance amount to use
|
|
4876
7212
|
* @returns Promise with updated cart
|
|
7213
|
+
* @example
|
|
7214
|
+
* ```typescript
|
|
7215
|
+
* const { data, error } = await pos.redeemCreditBalance(
|
|
7216
|
+
* { id: "01H9CART12345ABCDE" },
|
|
7217
|
+
* { credit_balance_used: 250.00 }
|
|
7218
|
+
* );
|
|
7219
|
+
*
|
|
7220
|
+
* if (error) {
|
|
7221
|
+
* console.error("Failed to redeem credit balance:", error.message);
|
|
7222
|
+
* } else {
|
|
7223
|
+
* console.log("Credit applied, new total:", data.cart.grand_total);
|
|
7224
|
+
* console.log("Credit used:", data.cart.credit_balance_used);
|
|
7225
|
+
* }
|
|
7226
|
+
* ```
|
|
4877
7227
|
*/
|
|
4878
7228
|
redeemCreditBalance(pathParams: PosRedeemCreditBalancePathParams, body: PosRedeemCreditBalanceBody): Promise<ApiResult<PosRedeemCreditBalanceContent>>;
|
|
4879
7229
|
/**
|
|
4880
7230
|
* Remove credit balance from cart
|
|
4881
7231
|
* @param pathParams - Cart ID
|
|
4882
7232
|
* @returns Promise with updated cart
|
|
7233
|
+
* @example
|
|
7234
|
+
* ```typescript
|
|
7235
|
+
* const { data, error } = await pos.removeCreditBalance({
|
|
7236
|
+
* id: "01H9CART12345ABCDE"
|
|
7237
|
+
* });
|
|
7238
|
+
*
|
|
7239
|
+
* if (error) {
|
|
7240
|
+
* console.error("Failed to remove credit balance:", error.message);
|
|
7241
|
+
* } else {
|
|
7242
|
+
* console.log("Credit balance removed, new total:", data.cart.grand_total);
|
|
7243
|
+
* }
|
|
7244
|
+
* ```
|
|
4883
7245
|
*/
|
|
4884
7246
|
removeCreditBalance(pathParams: PosRemoveCreditBalancePathParams): Promise<ApiResult<PosRemoveCreditBalanceContent>>;
|
|
4885
7247
|
/**
|
|
@@ -4887,12 +7249,38 @@ declare class PosClient extends PosAPIClient {
|
|
|
4887
7249
|
* @param pathParams - Cart ID
|
|
4888
7250
|
* @param body - Loyalty points to redeem
|
|
4889
7251
|
* @returns Promise with updated cart
|
|
7252
|
+
* @example
|
|
7253
|
+
* ```typescript
|
|
7254
|
+
* const { data, error } = await pos.redeemLoyaltyPoints(
|
|
7255
|
+
* { id: "01H9CART12345ABCDE" },
|
|
7256
|
+
* { loyalty_point_redeemed: 500 }
|
|
7257
|
+
* );
|
|
7258
|
+
*
|
|
7259
|
+
* if (error) {
|
|
7260
|
+
* console.error("Failed to redeem loyalty points:", error.message);
|
|
7261
|
+
* } else {
|
|
7262
|
+
* console.log("Points redeemed, new total:", data.cart.grand_total);
|
|
7263
|
+
* console.log("Points redeemed:", data.cart.loyalty_points_redeemed);
|
|
7264
|
+
* }
|
|
7265
|
+
* ```
|
|
4890
7266
|
*/
|
|
4891
7267
|
redeemLoyaltyPoints(pathParams: PosRedeemLoyaltyPointsPathParams, body: PosRedeemLoyaltyPointsBody): Promise<ApiResult<PosRedeemLoyaltyPointsContent>>;
|
|
4892
7268
|
/**
|
|
4893
7269
|
* Remove loyalty points from cart
|
|
4894
7270
|
* @param pathParams - Cart ID
|
|
4895
7271
|
* @returns Promise with updated cart
|
|
7272
|
+
* @example
|
|
7273
|
+
* ```typescript
|
|
7274
|
+
* const { data, error } = await pos.removeLoyaltyPoints({
|
|
7275
|
+
* id: "01H9CART12345ABCDE"
|
|
7276
|
+
* });
|
|
7277
|
+
*
|
|
7278
|
+
* if (error) {
|
|
7279
|
+
* console.error("Failed to remove loyalty points:", error.message);
|
|
7280
|
+
* } else {
|
|
7281
|
+
* console.log("Loyalty points removed, new total:", data.cart.grand_total);
|
|
7282
|
+
* }
|
|
7283
|
+
* ```
|
|
4896
7284
|
*/
|
|
4897
7285
|
removeLoyaltyPoints(pathParams: PosRemoveLoyaltyPointsPathParams): Promise<ApiResult<PosRemoveLoyaltyPointsContent>>;
|
|
4898
7286
|
/**
|
|
@@ -4900,12 +7288,51 @@ declare class PosClient extends PosAPIClient {
|
|
|
4900
7288
|
* @param pathParams - Cart ID
|
|
4901
7289
|
* @param body - Fulfillment preference data
|
|
4902
7290
|
* @returns Promise with confirmation
|
|
7291
|
+
* @example
|
|
7292
|
+
* ```typescript
|
|
7293
|
+
* const { data, error } = await pos.updateFulfillmentPreference(
|
|
7294
|
+
* { id: "01H9CART12345ABCDE" },
|
|
7295
|
+
* {
|
|
7296
|
+
* fulfillment_type: "delivery",
|
|
7297
|
+
* delivery_address_id: "01H9ADDR12345ABCDE"
|
|
7298
|
+
* }
|
|
7299
|
+
* );
|
|
7300
|
+
*
|
|
7301
|
+
* if (error) {
|
|
7302
|
+
* console.error("Failed to update fulfillment preference:", error.message);
|
|
7303
|
+
* } else {
|
|
7304
|
+
* console.log("Fulfillment preference updated:", data.message);
|
|
7305
|
+
* console.log("Success:", data.success);
|
|
7306
|
+
* }
|
|
7307
|
+
* ```
|
|
4903
7308
|
*/
|
|
4904
7309
|
updateFulfillmentPreference(pathParams: PosUpdateFulfillmentPreferencePathParams, body: PosUpdateFulfillmentPreferenceBody): Promise<ApiResult<PosUpdateFulfillmentPreferenceResponse>>;
|
|
4905
7310
|
/**
|
|
4906
7311
|
* Get fulfillment options for cart
|
|
4907
7312
|
* @param body - Cart data for fulfillment calculation
|
|
4908
7313
|
* @returns Promise with fulfillment options
|
|
7314
|
+
* @example
|
|
7315
|
+
* ```typescript
|
|
7316
|
+
* const { data, error } = await pos.getFulfillmentOptions({
|
|
7317
|
+
* cart_id: "01H9CART12345ABCDE",
|
|
7318
|
+
* delivery_address: {
|
|
7319
|
+
* street: "123 Main St",
|
|
7320
|
+
* city: "New York",
|
|
7321
|
+
* state: "NY",
|
|
7322
|
+
* zip_code: "10001",
|
|
7323
|
+
* country: "US"
|
|
7324
|
+
* }
|
|
7325
|
+
* });
|
|
7326
|
+
*
|
|
7327
|
+
* if (error) {
|
|
7328
|
+
* console.error("Failed to get fulfillment options:", error.message);
|
|
7329
|
+
* } else {
|
|
7330
|
+
* console.log("Available fulfillment options:", data.options.length);
|
|
7331
|
+
* data.options.forEach(option => {
|
|
7332
|
+
* console.log(`${option.type}: ${option.name} - $${option.cost}`);
|
|
7333
|
+
* });
|
|
7334
|
+
* }
|
|
7335
|
+
* ```
|
|
4909
7336
|
*/
|
|
4910
7337
|
getFulfillmentOptions(body: GetPosFulfillmentOptionsBody): Promise<ApiResult<GetPosFulfillmentOptionsContent>>;
|
|
4911
7338
|
/**
|
|
@@ -4913,18 +7340,103 @@ declare class PosClient extends PosAPIClient {
|
|
|
4913
7340
|
* @param pathParams - Cart ID
|
|
4914
7341
|
* @param body - Customer update data
|
|
4915
7342
|
* @returns Promise with updated cart
|
|
7343
|
+
* @example
|
|
7344
|
+
* ```typescript
|
|
7345
|
+
* const { data, error } = await pos.updateCartCustomer(
|
|
7346
|
+
* { id: "01H9CART12345ABCDE" },
|
|
7347
|
+
* {
|
|
7348
|
+
* customer_id: "01H9CUST12345ABCDE",
|
|
7349
|
+
* customer_group_id: "01H9GROUP12345ABCDE"
|
|
7350
|
+
* }
|
|
7351
|
+
* );
|
|
7352
|
+
*
|
|
7353
|
+
* if (error) {
|
|
7354
|
+
* console.error("Failed to update cart customer:", error.message);
|
|
7355
|
+
* } else {
|
|
7356
|
+
* console.log("Cart customer updated:", data.cart.id);
|
|
7357
|
+
* console.log("Customer ID:", data.cart.customer_id);
|
|
7358
|
+
* console.log("Customer group:", data.cart.customer_group_id);
|
|
7359
|
+
* }
|
|
7360
|
+
* ```
|
|
4916
7361
|
*/
|
|
4917
7362
|
updateCartCustomer(pathParams: UpdatePosCartCustomerPathParams, body: UpdatePosCartCustomerBody): Promise<ApiResult<UpdatePosCartCustomerContent>>;
|
|
4918
7363
|
/**
|
|
4919
7364
|
* Create order from cart
|
|
4920
7365
|
* @param body - Order creation data
|
|
4921
7366
|
* @returns Promise with created order
|
|
7367
|
+
* @example
|
|
7368
|
+
* ```typescript
|
|
7369
|
+
* const { data, error } = await pos.createOrder({
|
|
7370
|
+
* cart_id: "01H9CART12345ABCDE"
|
|
7371
|
+
* });
|
|
7372
|
+
*
|
|
7373
|
+
* if (error) {
|
|
7374
|
+
* console.error("Failed to create order:", error.message);
|
|
7375
|
+
* } else {
|
|
7376
|
+
* console.log("Order created:", data.order.id);
|
|
7377
|
+
* console.log("Payment required:", data.payment_required);
|
|
7378
|
+
* }
|
|
7379
|
+
* ```
|
|
4922
7380
|
*/
|
|
4923
7381
|
createOrder(body: CreatePosOrderBody): Promise<ApiResult<CreatePosOrderContent>>;
|
|
7382
|
+
/**
|
|
7383
|
+
* List payment options
|
|
7384
|
+
* @returns Promise with list of payment options
|
|
7385
|
+
* @example
|
|
7386
|
+
* ```typescript
|
|
7387
|
+
* const { data, error } = await pos.listPaymentOptions();
|
|
7388
|
+
*
|
|
7389
|
+
* if (error) {
|
|
7390
|
+
* console.error("Failed to list payment options:", error.message);
|
|
7391
|
+
* } else {
|
|
7392
|
+
* console.log("Payment options:", data.payment_options);
|
|
7393
|
+
* }
|
|
7394
|
+
* ```
|
|
7395
|
+
*/
|
|
7396
|
+
listPaymentOptions(): Promise<ApiResult<PosListPaymentOptionsContent>>;
|
|
7397
|
+
/**
|
|
7398
|
+
* Get payment status
|
|
7399
|
+
* @param pathParams - Order number
|
|
7400
|
+
* @returns Promise with payment status
|
|
7401
|
+
* @example
|
|
7402
|
+
* ```typescript
|
|
7403
|
+
* const { data, error } = await pos.getPaymentStatus({ order_number: "1234567890" });
|
|
7404
|
+
*
|
|
7405
|
+
* if (error) {
|
|
7406
|
+
* console.error("Failed to get payment status:", error.message);
|
|
7407
|
+
* } else {
|
|
7408
|
+
* console.log("Payment status:", data.status);
|
|
7409
|
+
* console.log("Amount paid:", data.amount_paid);
|
|
7410
|
+
* console.log("Amount unpaid:", data.amount_unpaid);
|
|
7411
|
+
* console.log("Retry available:", data.is_retry_available);
|
|
7412
|
+
* }
|
|
7413
|
+
* ```
|
|
7414
|
+
*/
|
|
7415
|
+
getPaymentStatus(pathParams: PosGetPaymentStatusPathParams): Promise<ApiResult<PosGetPaymentStatusContent>>;
|
|
4924
7416
|
/**
|
|
4925
7417
|
* List all categories
|
|
4926
7418
|
* @param query - Optional query parameters for filtering categories
|
|
4927
7419
|
* @returns Promise with list of categories
|
|
7420
|
+
* @example
|
|
7421
|
+
* ```typescript
|
|
7422
|
+
* // Basic category listing
|
|
7423
|
+
* const { data, error } = await pos.listCategories();
|
|
7424
|
+
*
|
|
7425
|
+
* if (error) {
|
|
7426
|
+
* console.error("Failed to list categories:", error.message);
|
|
7427
|
+
* } else {
|
|
7428
|
+
* console.log("Categories found:", data.categories?.length || 0);
|
|
7429
|
+
* data.categories?.forEach(category => {
|
|
7430
|
+
* console.log(`Category: ${category.name} - ${category.description}`);
|
|
7431
|
+
* });
|
|
7432
|
+
* }
|
|
7433
|
+
*
|
|
7434
|
+
* // With pagination
|
|
7435
|
+
* const { data: catData, error: catError } = await pos.listCategories({
|
|
7436
|
+
* page: 1,
|
|
7437
|
+
* limit: 10
|
|
7438
|
+
* });
|
|
7439
|
+
* ```
|
|
4928
7440
|
*/
|
|
4929
7441
|
listCategories(query?: PosListCategoriesQuery): Promise<ApiResult<PosListCategoriesContent>>;
|
|
4930
7442
|
/**
|
|
@@ -4932,6 +7444,42 @@ declare class PosClient extends PosAPIClient {
|
|
|
4932
7444
|
* @param query - Optional query parameters for filtering products
|
|
4933
7445
|
* @param headers - Optional header parameters
|
|
4934
7446
|
* @returns Promise with list of products
|
|
7447
|
+
* @example
|
|
7448
|
+
* ```typescript
|
|
7449
|
+
* // Basic product listing
|
|
7450
|
+
* const { data, error } = await pos.listProducts();
|
|
7451
|
+
*
|
|
7452
|
+
* if (error) {
|
|
7453
|
+
* console.error("Failed to list products:", error.message);
|
|
7454
|
+
* } else {
|
|
7455
|
+
* console.log("Products found:", data.products?.length || 0);
|
|
7456
|
+
* console.log("Pagination:", data.pagination);
|
|
7457
|
+
* data.products?.forEach(product => {
|
|
7458
|
+
* console.log(`Product: ${product.name} - $${product.price}`);
|
|
7459
|
+
* });
|
|
7460
|
+
* }
|
|
7461
|
+
*
|
|
7462
|
+
* // With filtering and pagination
|
|
7463
|
+
* const { data: filteredData, error: filteredError } = await pos.listProducts({
|
|
7464
|
+
* page: 1,
|
|
7465
|
+
* limit: 20,
|
|
7466
|
+
* sort_by: JSON.stringify({ "created_at": "desc" }),
|
|
7467
|
+
* category_slug: ["electronics", "smartphones"]
|
|
7468
|
+
* });
|
|
7469
|
+
*
|
|
7470
|
+
* // Override customer group ID for this specific request
|
|
7471
|
+
* const { data: overrideData, error: overrideError } = await pos.listProducts(
|
|
7472
|
+
* {
|
|
7473
|
+
* page: 1,
|
|
7474
|
+
* limit: 20,
|
|
7475
|
+
* sort_by: JSON.stringify({ "created_at": "desc" }),
|
|
7476
|
+
* category_slug: ["electronics", "smartphones"]
|
|
7477
|
+
* },
|
|
7478
|
+
* {
|
|
7479
|
+
* "x-customer-group-id": "01H9XYZ12345USERID" // Override default SDK config
|
|
7480
|
+
* }
|
|
7481
|
+
* );
|
|
7482
|
+
* ```
|
|
4935
7483
|
*/
|
|
4936
7484
|
listProducts(query?: PosListProductsQuery, headers?: PosListProductsHeaderParams): Promise<ApiResult<PosListProductsContent>>;
|
|
4937
7485
|
/**
|
|
@@ -4939,6 +7487,43 @@ declare class PosClient extends PosAPIClient {
|
|
|
4939
7487
|
* @param query - Query parameters with product IDs for cross-sell recommendations
|
|
4940
7488
|
* @param headers - Optional header parameters
|
|
4941
7489
|
* @returns Promise with cross-sell products
|
|
7490
|
+
* @example
|
|
7491
|
+
* ```typescript
|
|
7492
|
+
* // Basic usage - get cross-sell products for cart items
|
|
7493
|
+
* const { data, error } = await pos.listCrosssellProducts({
|
|
7494
|
+
* product_ids: ["prod_01H9XYZ12345ABCDE", "prod_01H9ABC67890FGHIJ"]
|
|
7495
|
+
* });
|
|
7496
|
+
*
|
|
7497
|
+
* // Advanced usage with pagination and custom sorting
|
|
7498
|
+
* const { data, error } = await pos.listCrosssellProducts({
|
|
7499
|
+
* product_ids: ["prod_01H9XYZ12345ABCDE"],
|
|
7500
|
+
* page: 1,
|
|
7501
|
+
* limit: 10,
|
|
7502
|
+
* sort_by: '{"price":"asc"}'
|
|
7503
|
+
* });
|
|
7504
|
+
*
|
|
7505
|
+
* // Override customer group ID for this specific request
|
|
7506
|
+
* const { data, error } = await pos.listCrosssellProducts(
|
|
7507
|
+
* {
|
|
7508
|
+
* product_ids: ["prod_01H9XYZ12345ABCDE"],
|
|
7509
|
+
* page: 1,
|
|
7510
|
+
* limit: 10
|
|
7511
|
+
* },
|
|
7512
|
+
* {
|
|
7513
|
+
* "x-customer-group-id": "01H9XYZ12345USERID" // Override default SDK config
|
|
7514
|
+
* }
|
|
7515
|
+
* );
|
|
7516
|
+
*
|
|
7517
|
+
* if (error) {
|
|
7518
|
+
* console.error("Failed to get cross-sell products:", error.message);
|
|
7519
|
+
* } else {
|
|
7520
|
+
* console.log("Cross-sell products found:", data.products.length);
|
|
7521
|
+
* console.log("Pagination:", data.pagination);
|
|
7522
|
+
* data.products.forEach(product => {
|
|
7523
|
+
* console.log(`Product: ${product.name} - ${product.price}`);
|
|
7524
|
+
* });
|
|
7525
|
+
* }
|
|
7526
|
+
* ```
|
|
4942
7527
|
*/
|
|
4943
7528
|
listCrosssellProducts(query: PosListCrosssellProductsQuery, headers?: PosListCrosssellProductsHeaderParams): Promise<ApiResult<PosListCrosssellProductsContent>>;
|
|
4944
7529
|
/**
|
|
@@ -4946,6 +7531,41 @@ declare class PosClient extends PosAPIClient {
|
|
|
4946
7531
|
* @param body - Search criteria and parameters
|
|
4947
7532
|
* @param headers - Optional header parameters
|
|
4948
7533
|
* @returns Promise with search results
|
|
7534
|
+
* @example
|
|
7535
|
+
* ```typescript
|
|
7536
|
+
* const { data, error } = await pos.searchProducts({
|
|
7537
|
+
* query: "smartphone",
|
|
7538
|
+
* filters: {
|
|
7539
|
+
* category: ["electronics", "mobile"],
|
|
7540
|
+
* price_range: { min: 100, max: 1000 },
|
|
7541
|
+
* brand: ["Apple", "Samsung"] // facet names depend on product configuration
|
|
7542
|
+
* },
|
|
7543
|
+
* page: 1,
|
|
7544
|
+
* limit: 20
|
|
7545
|
+
* });
|
|
7546
|
+
*
|
|
7547
|
+
* if (error) {
|
|
7548
|
+
* console.error("Failed to search products:", error.message);
|
|
7549
|
+
* } else {
|
|
7550
|
+
* console.log("Search results:", data.skus?.length || 0, "products found");
|
|
7551
|
+
* console.log("Facet distribution:", data.facet_distribution);
|
|
7552
|
+
* console.log("Price range:", data.facet_stats.price_range);
|
|
7553
|
+
* data.skus?.forEach(sku => {
|
|
7554
|
+
* console.log(`Found: ${sku.name} - ${sku.price}`);
|
|
7555
|
+
* });
|
|
7556
|
+
* }
|
|
7557
|
+
*
|
|
7558
|
+
* // Override customer group ID for this specific request
|
|
7559
|
+
* const { data: overrideData, error: overrideError } = await pos.searchProducts(
|
|
7560
|
+
* {
|
|
7561
|
+
* query: "laptop",
|
|
7562
|
+
* filters: { category: ["computers"] }
|
|
7563
|
+
* },
|
|
7564
|
+
* {
|
|
7565
|
+
* "x-customer-group-id": "01H9XYZ12345USERID" // Override default SDK config
|
|
7566
|
+
* }
|
|
7567
|
+
* );
|
|
7568
|
+
* ```
|
|
4949
7569
|
*/
|
|
4950
7570
|
searchProducts(body: PosSearchProductsBody, headers?: PosSearchProductsHeaderParams): Promise<ApiResult<PosSearchProductsContent>>;
|
|
4951
7571
|
/**
|
|
@@ -4953,6 +7573,43 @@ declare class PosClient extends PosAPIClient {
|
|
|
4953
7573
|
* @param query - Query parameters with product ID for similarity recommendations
|
|
4954
7574
|
* @param headers - Optional header parameters
|
|
4955
7575
|
* @returns Promise with similar products
|
|
7576
|
+
* @example
|
|
7577
|
+
* ```typescript
|
|
7578
|
+
* // Basic usage - get similar products for a specific product
|
|
7579
|
+
* const { data, error } = await pos.listSimilarProducts({
|
|
7580
|
+
* product_id: "prod_01H9XYZ12345ABCDE"
|
|
7581
|
+
* });
|
|
7582
|
+
*
|
|
7583
|
+
* // Advanced usage with pagination and custom sorting
|
|
7584
|
+
* const { data, error } = await pos.listSimilarProducts({
|
|
7585
|
+
* product_id: "prod_01H9XYZ12345ABCDE",
|
|
7586
|
+
* page: 1,
|
|
7587
|
+
* limit: 20,
|
|
7588
|
+
* sort_by: '{"relevance":"desc"}'
|
|
7589
|
+
* });
|
|
7590
|
+
*
|
|
7591
|
+
* // Override customer group ID for this specific request
|
|
7592
|
+
* const { data, error } = await pos.listSimilarProducts(
|
|
7593
|
+
* {
|
|
7594
|
+
* product_id: "prod_01H9XYZ12345ABCDE",
|
|
7595
|
+
* page: 1,
|
|
7596
|
+
* limit: 20
|
|
7597
|
+
* },
|
|
7598
|
+
* {
|
|
7599
|
+
* "x-customer-group-id": "01H9XYZ12345USERID" // Override default SDK config
|
|
7600
|
+
* }
|
|
7601
|
+
* );
|
|
7602
|
+
*
|
|
7603
|
+
* if (error) {
|
|
7604
|
+
* console.error("Failed to get similar products:", error.message);
|
|
7605
|
+
* } else {
|
|
7606
|
+
* console.log("Similar products found:", data.products.length);
|
|
7607
|
+
* console.log("Pagination:", data.pagination);
|
|
7608
|
+
* data.products.forEach(product => {
|
|
7609
|
+
* console.log(`Similar: ${product.name} - ${product.price}`);
|
|
7610
|
+
* });
|
|
7611
|
+
* }
|
|
7612
|
+
* ```
|
|
4956
7613
|
*/
|
|
4957
7614
|
listSimilarProducts(query: PosListSimilarProductsQuery, headers?: PosListSimilarProductsHeaderParams): Promise<ApiResult<PosListSimilarProductsContent>>;
|
|
4958
7615
|
/**
|
|
@@ -4960,6 +7617,43 @@ declare class PosClient extends PosAPIClient {
|
|
|
4960
7617
|
* @param query - Query parameters with product IDs for up-sell recommendations
|
|
4961
7618
|
* @param headers - Optional header parameters
|
|
4962
7619
|
* @returns Promise with up-sell products
|
|
7620
|
+
* @example
|
|
7621
|
+
* ```typescript
|
|
7622
|
+
* // Basic usage - get up-sell products for cart items
|
|
7623
|
+
* const { data, error } = await pos.listUpsellProducts({
|
|
7624
|
+
* product_ids: ["prod_01H9XYZ12345ABCDE"]
|
|
7625
|
+
* });
|
|
7626
|
+
*
|
|
7627
|
+
* // Advanced usage with pagination and custom sorting
|
|
7628
|
+
* const { data, error } = await pos.listUpsellProducts({
|
|
7629
|
+
* product_ids: ["prod_01H9XYZ12345ABCDE"],
|
|
7630
|
+
* page: 1,
|
|
7631
|
+
* limit: 15,
|
|
7632
|
+
* sort_by: '{"relevance":"desc"}'
|
|
7633
|
+
* });
|
|
7634
|
+
*
|
|
7635
|
+
* // Override customer group ID for this specific request
|
|
7636
|
+
* const { data, error } = await pos.listUpsellProducts(
|
|
7637
|
+
* {
|
|
7638
|
+
* product_ids: ["prod_01H9XYZ12345ABCDE"],
|
|
7639
|
+
* page: 1,
|
|
7640
|
+
* limit: 15
|
|
7641
|
+
* },
|
|
7642
|
+
* {
|
|
7643
|
+
* "x-customer-group-id": "01H9XYZ12345USERID" // Override default SDK config
|
|
7644
|
+
* }
|
|
7645
|
+
* );
|
|
7646
|
+
*
|
|
7647
|
+
* if (error) {
|
|
7648
|
+
* console.error("Failed to get up-sell products:", error.message);
|
|
7649
|
+
* } else {
|
|
7650
|
+
* console.log("Up-sell products found:", data.products.length);
|
|
7651
|
+
* console.log("Pagination:", data.pagination);
|
|
7652
|
+
* data.products.forEach(product => {
|
|
7653
|
+
* console.log(`Up-sell: ${product.name} - ${product.price}`);
|
|
7654
|
+
* });
|
|
7655
|
+
* }
|
|
7656
|
+
* ```
|
|
4963
7657
|
*/
|
|
4964
7658
|
listUpsellProducts(query: PosListUpsellProductsQuery, headers?: PosListUpsellProductsHeaderParams): Promise<ApiResult<PosListUpsellProductsContent>>;
|
|
4965
7659
|
/**
|
|
@@ -4967,6 +7661,34 @@ declare class PosClient extends PosAPIClient {
|
|
|
4967
7661
|
* @param pathParams - Product ID or slug
|
|
4968
7662
|
* @param headers - Optional header parameters
|
|
4969
7663
|
* @returns Promise with product details
|
|
7664
|
+
* @example
|
|
7665
|
+
* ```typescript
|
|
7666
|
+
* // Get product by ID
|
|
7667
|
+
* const { data, error } = await pos.getProductDetail(
|
|
7668
|
+
* { product_id_or_slug: "prod_123" }
|
|
7669
|
+
* );
|
|
7670
|
+
*
|
|
7671
|
+
* if (error) {
|
|
7672
|
+
* console.error("Failed to get product details:", error.message);
|
|
7673
|
+
* } else {
|
|
7674
|
+
* console.log("Product:", data.product.name);
|
|
7675
|
+
* console.log("Price:", data.product.price);
|
|
7676
|
+
* console.log("Description:", data.product.description);
|
|
7677
|
+
* }
|
|
7678
|
+
*
|
|
7679
|
+
* // Get product by slug
|
|
7680
|
+
* const { data: slugData, error: slugError } = await pos.getProductDetail({
|
|
7681
|
+
* product_id_or_slug: "detox-candy"
|
|
7682
|
+
* });
|
|
7683
|
+
*
|
|
7684
|
+
* // Override customer group ID for this specific request
|
|
7685
|
+
* const { data: overrideData, error: overrideError } = await pos.getProductDetail(
|
|
7686
|
+
* { product_id_or_slug: "detox-candy" },
|
|
7687
|
+
* {
|
|
7688
|
+
* "x-customer-group-id": "premium_customers" // Override default SDK config
|
|
7689
|
+
* }
|
|
7690
|
+
* );
|
|
7691
|
+
* ```
|
|
4970
7692
|
*/
|
|
4971
7693
|
getProductDetail(pathParams: PosGetProductDetailPathParams, headers?: PosGetProductDetailHeaderParams): Promise<ApiResult<PosGetProductDetailContent>>;
|
|
4972
7694
|
/**
|
|
@@ -4974,6 +7696,31 @@ declare class PosClient extends PosAPIClient {
|
|
|
4974
7696
|
* @param pathParams - Product ID
|
|
4975
7697
|
* @param query - Optional query parameters for filtering reviews
|
|
4976
7698
|
* @returns Promise with product reviews
|
|
7699
|
+
* @example
|
|
7700
|
+
* ```typescript
|
|
7701
|
+
* const { data, error } = await pos.listProductReviews(
|
|
7702
|
+
* { product_id: "prod_123" }
|
|
7703
|
+
* );
|
|
7704
|
+
*
|
|
7705
|
+
* if (error) {
|
|
7706
|
+
* console.error("Failed to list product reviews:", error.message);
|
|
7707
|
+
* } else {
|
|
7708
|
+
* console.log("Reviews found:", data.reviews?.length || 0);
|
|
7709
|
+
* data.reviews?.forEach(review => {
|
|
7710
|
+
* console.log(`Review by ${review.customer_name}: ${review.rating}/5`);
|
|
7711
|
+
* console.log("Comment:", review.comment);
|
|
7712
|
+
* });
|
|
7713
|
+
* }
|
|
7714
|
+
*
|
|
7715
|
+
* // With pagination
|
|
7716
|
+
* const { data: reviewData, error: reviewError } = await pos.listProductReviews(
|
|
7717
|
+
* { product_id: "prod_123" },
|
|
7718
|
+
* {
|
|
7719
|
+
* page: 1,
|
|
7720
|
+
* limit: 5
|
|
7721
|
+
* }
|
|
7722
|
+
* );
|
|
7723
|
+
* ```
|
|
4977
7724
|
*/
|
|
4978
7725
|
listProductReviews(pathParams: PosListProductReviewsPathParams, query?: PosListProductReviewsQuery): Promise<ApiResult<PosListProductReviewsContent>>;
|
|
4979
7726
|
/**
|
|
@@ -4981,6 +7728,29 @@ declare class PosClient extends PosAPIClient {
|
|
|
4981
7728
|
* @param pathParams - Product ID
|
|
4982
7729
|
* @param headers - Optional header parameters
|
|
4983
7730
|
* @returns Promise with product variants
|
|
7731
|
+
* @example
|
|
7732
|
+
* ```typescript
|
|
7733
|
+
* const { data, error } = await pos.listProductVariants(
|
|
7734
|
+
* { product_id: "prod_123" }
|
|
7735
|
+
* );
|
|
7736
|
+
*
|
|
7737
|
+
* if (error) {
|
|
7738
|
+
* console.error("Failed to list product variants:", error.message);
|
|
7739
|
+
* } else {
|
|
7740
|
+
* console.log("Variants found:", data.variants?.length || 0);
|
|
7741
|
+
* data.variants?.forEach(variant => {
|
|
7742
|
+
* console.log(`Variant: ${variant.name} - SKU: ${variant.sku} - Price: ${variant.price}`);
|
|
7743
|
+
* });
|
|
7744
|
+
* }
|
|
7745
|
+
*
|
|
7746
|
+
* // Override customer group ID for this specific request
|
|
7747
|
+
* const { data: overrideData, error: overrideError } = await pos.listProductVariants(
|
|
7748
|
+
* { product_id: "prod_123" },
|
|
7749
|
+
* {
|
|
7750
|
+
* "x-customer-group-id": "wholesale_customers" // Override default SDK config
|
|
7751
|
+
* }
|
|
7752
|
+
* );
|
|
7753
|
+
* ```
|
|
4984
7754
|
*/
|
|
4985
7755
|
listProductVariants(pathParams: PosListProductVariantsPathParams, headers?: PosListProductVariantsHeaderParams): Promise<ApiResult<PosListProductVariantsContent>>;
|
|
4986
7756
|
/**
|
|
@@ -4988,6 +7758,35 @@ declare class PosClient extends PosAPIClient {
|
|
|
4988
7758
|
* @param pathParams - Product ID and variant ID
|
|
4989
7759
|
* @param headers - Optional header parameters
|
|
4990
7760
|
* @returns Promise with variant details
|
|
7761
|
+
* @example
|
|
7762
|
+
* ```typescript
|
|
7763
|
+
* const { data, error } = await pos.getVariantDetail(
|
|
7764
|
+
* {
|
|
7765
|
+
* product_id: "prod_123",
|
|
7766
|
+
* variant_id: "var_456"
|
|
7767
|
+
* }
|
|
7768
|
+
* );
|
|
7769
|
+
*
|
|
7770
|
+
* if (error) {
|
|
7771
|
+
* console.error("Failed to get variant details:", error.message);
|
|
7772
|
+
* } else {
|
|
7773
|
+
* console.log("Variant:", data.variant.name);
|
|
7774
|
+
* console.log("SKU:", data.variant.sku);
|
|
7775
|
+
* console.log("Price:", data.variant.price);
|
|
7776
|
+
* console.log("Stock:", data.variant.stock);
|
|
7777
|
+
* }
|
|
7778
|
+
*
|
|
7779
|
+
* // Override customer group ID for this specific request
|
|
7780
|
+
* const { data: overrideData, error: overrideError } = await pos.getVariantDetail(
|
|
7781
|
+
* {
|
|
7782
|
+
* product_id: "prod_123",
|
|
7783
|
+
* variant_id: "var_456"
|
|
7784
|
+
* },
|
|
7785
|
+
* {
|
|
7786
|
+
* "x-customer-group-id": "wholesale_customers" // Override default SDK config
|
|
7787
|
+
* }
|
|
7788
|
+
* );
|
|
7789
|
+
* ```
|
|
4991
7790
|
*/
|
|
4992
7791
|
getVariantDetail(pathParams: PosGetVariantDetailPathParams, headers?: PosGetVariantDetailHeaderParams): Promise<ApiResult<PosGetVariantDetailContent>>;
|
|
4993
7792
|
/**
|
|
@@ -4995,8 +7794,536 @@ declare class PosClient extends PosAPIClient {
|
|
|
4995
7794
|
* @param query - Optional query parameters for filtering SKUs
|
|
4996
7795
|
* @param headers - Optional header parameters
|
|
4997
7796
|
* @returns Promise with list of SKUs
|
|
7797
|
+
* @example
|
|
7798
|
+
* ```typescript
|
|
7799
|
+
* // Basic SKU listing
|
|
7800
|
+
* const { data, error } = await pos.listSkus();
|
|
7801
|
+
*
|
|
7802
|
+
* if (error) {
|
|
7803
|
+
* console.error("Failed to list SKUs:", error.message);
|
|
7804
|
+
* } else {
|
|
7805
|
+
* console.log("SKUs found:", data.skus?.length || 0);
|
|
7806
|
+
* console.log("Pagination:", data.pagination);
|
|
7807
|
+
* data.skus?.forEach(sku => {
|
|
7808
|
+
* console.log(`SKU: ${sku.sku} - Price: ${sku.price}`);
|
|
7809
|
+
* });
|
|
7810
|
+
* }
|
|
7811
|
+
*
|
|
7812
|
+
* // With pagination
|
|
7813
|
+
* const { data: skuData, error: skuError } = await pos.listSkus({
|
|
7814
|
+
* page: 1,
|
|
7815
|
+
* limit: 50
|
|
7816
|
+
* });
|
|
7817
|
+
*
|
|
7818
|
+
* // Override customer group ID for this specific request
|
|
7819
|
+
* const { data: overrideData, error: overrideError } = await pos.listSkus(
|
|
7820
|
+
* {
|
|
7821
|
+
* page: 1,
|
|
7822
|
+
* limit: 50
|
|
7823
|
+
* },
|
|
7824
|
+
* {
|
|
7825
|
+
* "x-customer-group-id": "01H9XYZ12345USERID" // Override default SDK config
|
|
7826
|
+
* }
|
|
7827
|
+
* );
|
|
7828
|
+
* ```
|
|
4998
7829
|
*/
|
|
4999
7830
|
listSkus(query?: PosListSkusQuery, headers?: PosListSkusHeaderParams): Promise<ApiResult<PosListSkusContent>>;
|
|
7831
|
+
/**
|
|
7832
|
+
* List all inventories (Admin)
|
|
7833
|
+
* @param query - Optional query parameters for filtering inventories
|
|
7834
|
+
* @returns Promise with list of inventories
|
|
7835
|
+
* @example
|
|
7836
|
+
* ```typescript
|
|
7837
|
+
* // Basic inventory listing
|
|
7838
|
+
* const { data, error } = await pos.listInventories();
|
|
7839
|
+
*
|
|
7840
|
+
* if (error) {
|
|
7841
|
+
* console.error("Failed to list inventories:", error.message);
|
|
7842
|
+
* } else {
|
|
7843
|
+
* console.log("Inventories found:", data.content?.inventories?.length || 0);
|
|
7844
|
+
* data.content?.inventories?.forEach(inventory => {
|
|
7845
|
+
* console.log(`Product: ${inventory.product_name} - Stock: ${inventory.stock_quantity}`);
|
|
7846
|
+
* });
|
|
7847
|
+
* }
|
|
7848
|
+
*
|
|
7849
|
+
* // With pagination and filters
|
|
7850
|
+
* const { data: filteredData, error: filteredError } = await pos.listInventories({
|
|
7851
|
+
* page: 1,
|
|
7852
|
+
* limit: 20,
|
|
7853
|
+
* sort_by: JSON.stringify({ "stock_quantity": "desc" }),
|
|
7854
|
+
* filters: JSON.stringify({ "product_name": "smartphone" })
|
|
7855
|
+
* });
|
|
7856
|
+
* ```
|
|
7857
|
+
*/
|
|
7858
|
+
listInventories(query?: PosListInventoriesQuery): Promise<ApiResult<PosListInventoriesContent>>;
|
|
7859
|
+
/**
|
|
7860
|
+
* List all inventory activities (Admin)
|
|
7861
|
+
* @param query - Optional query parameters for filtering inventory activities
|
|
7862
|
+
* @returns Promise with list of inventory activities
|
|
7863
|
+
* @example
|
|
7864
|
+
* ```typescript
|
|
7865
|
+
* // Basic inventory activities listing
|
|
7866
|
+
* const { data, error } = await pos.listInventoryActivities();
|
|
7867
|
+
*
|
|
7868
|
+
* if (error) {
|
|
7869
|
+
* console.error("Failed to list inventory activities:", error.message);
|
|
7870
|
+
* } else {
|
|
7871
|
+
* console.log("Activities found:", data.content?.activities?.length || 0);
|
|
7872
|
+
* data.content?.activities?.forEach(activity => {
|
|
7873
|
+
* console.log(`Activity: ${activity.activity_type} - Product: ${activity.product_name} - Quantity: ${activity.quantity}`);
|
|
7874
|
+
* });
|
|
7875
|
+
* }
|
|
7876
|
+
*
|
|
7877
|
+
* // With pagination and filters
|
|
7878
|
+
* const { data: filteredData, error: filteredError } = await pos.listInventoryActivities({
|
|
7879
|
+
* page: 1,
|
|
7880
|
+
* limit: 50,
|
|
7881
|
+
* sort_by: JSON.stringify({ "created_at": "desc" }),
|
|
7882
|
+
* filters: JSON.stringify({ "activity_type": "add" })
|
|
7883
|
+
* });
|
|
7884
|
+
* ```
|
|
7885
|
+
*/
|
|
7886
|
+
listInventoryActivities(query?: PosListInventoriesActivitiesQuery): Promise<ApiResult<PosListInventoriesActivitiesContent>>;
|
|
7887
|
+
/**
|
|
7888
|
+
* Get inventory detail (Admin)
|
|
7889
|
+
* @param query - Query parameters with product/variant information
|
|
7890
|
+
* @returns Promise with inventory details
|
|
7891
|
+
* @example
|
|
7892
|
+
* ```typescript
|
|
7893
|
+
* // Get inventory detail for a product
|
|
7894
|
+
* const { data, error } = await pos.getInventoryDetail({
|
|
7895
|
+
* product_id: "01H9XYZ12345ABCDE"
|
|
7896
|
+
* });
|
|
7897
|
+
*
|
|
7898
|
+
* if (error) {
|
|
7899
|
+
* console.error("Failed to get inventory detail:", error.message);
|
|
7900
|
+
* } else {
|
|
7901
|
+
* const inventory = data.content?.inventory;
|
|
7902
|
+
* console.log(`Product: ${inventory?.product_name}`);
|
|
7903
|
+
* console.log(`Stock: ${inventory?.stock_quantity}`);
|
|
7904
|
+
* console.log(`Warehouse details:`, inventory?.details);
|
|
7905
|
+
* }
|
|
7906
|
+
*
|
|
7907
|
+
* // Get inventory detail for a product variant
|
|
7908
|
+
* const { data: variantData, error: variantError } = await pos.getInventoryDetail({
|
|
7909
|
+
* product_id: "01H9XYZ12345ABCDE",
|
|
7910
|
+
* variant_id: "01H9ABC67890FGHIJ"
|
|
7911
|
+
* });
|
|
7912
|
+
*
|
|
7913
|
+
* // Get inventory detail for a specific lot/batch
|
|
7914
|
+
* const { data: batchData, error: batchError } = await pos.getInventoryDetail({
|
|
7915
|
+
* product_id: "01H9XYZ12345ABCDE",
|
|
7916
|
+
* lot_batch: "BATCH001"
|
|
7917
|
+
* });
|
|
7918
|
+
* ```
|
|
7919
|
+
*/
|
|
7920
|
+
getInventoryDetail(query: PosGetInventoryDetailQuery): Promise<ApiResult<PosGetInventoryDetailContent>>;
|
|
7921
|
+
/**
|
|
7922
|
+
* List all customers (Admin)
|
|
7923
|
+
* @param query - Optional query parameters for filtering customers
|
|
7924
|
+
* @returns Promise with list of customers
|
|
7925
|
+
* @example
|
|
7926
|
+
* ```typescript
|
|
7927
|
+
* // Basic customer listing
|
|
7928
|
+
* const { data, error } = await pos.getCustomers();
|
|
7929
|
+
*
|
|
7930
|
+
* if (error) {
|
|
7931
|
+
* console.error("Failed to list customers:", error.message);
|
|
7932
|
+
* } else {
|
|
7933
|
+
* console.log("Customers found:", data.content?.customers?.length || 0);
|
|
7934
|
+
* console.log("Pagination:", data.content?.pagination);
|
|
7935
|
+
* data.content?.customers?.forEach(customer => {
|
|
7936
|
+
* console.log(`Customer: ${customer.full_name} - Email: ${customer.email}`);
|
|
7937
|
+
* });
|
|
7938
|
+
* }
|
|
7939
|
+
*
|
|
7940
|
+
* // With search and pagination
|
|
7941
|
+
* const { data: searchData, error: searchError } = await pos.getCustomers({
|
|
7942
|
+
* page: 1,
|
|
7943
|
+
* limit: 20,
|
|
7944
|
+
* search: "john@example.com",
|
|
7945
|
+
* sort_by: JSON.stringify({ "created_at": "desc" })
|
|
7946
|
+
* });
|
|
7947
|
+
* ```
|
|
7948
|
+
*/
|
|
7949
|
+
getCustomers(query?: PosGetAdminCustomersQuery): Promise<ApiResult<PosGetAdminCustomersContent>>;
|
|
7950
|
+
/**
|
|
7951
|
+
* Get customer details (Admin)
|
|
7952
|
+
* @param pathParams - Customer ID
|
|
7953
|
+
* @returns Promise with customer details
|
|
7954
|
+
* @example
|
|
7955
|
+
* ```typescript
|
|
7956
|
+
* const { data, error } = await pos.getCustomer({
|
|
7957
|
+
* id: "01H9CUST12345ABCDE"
|
|
7958
|
+
* });
|
|
7959
|
+
*
|
|
7960
|
+
* if (error) {
|
|
7961
|
+
* console.error("Failed to get customer:", error.message);
|
|
7962
|
+
* } else {
|
|
7963
|
+
* const customer = data.content?.customer;
|
|
7964
|
+
* console.log(`Customer: ${customer?.full_name}`);
|
|
7965
|
+
* console.log(`Email: ${customer?.email}`);
|
|
7966
|
+
* console.log(`Phone: ${customer?.phone}`);
|
|
7967
|
+
* console.log(`Loyalty points: ${customer?.loyalty?.points_balance}`);
|
|
7968
|
+
* console.log(`Total spent: ${customer?.loyalty?.lifetime_spent}`);
|
|
7969
|
+
* }
|
|
7970
|
+
* ```
|
|
7971
|
+
*/
|
|
7972
|
+
getCustomer(pathParams: PosGetAdminCustomersIdPathParams): Promise<ApiResult<PosGetAdminCustomersIdContent>>;
|
|
7973
|
+
/**
|
|
7974
|
+
* List all orders (Admin)
|
|
7975
|
+
* @param query - Optional query parameters for filtering orders
|
|
7976
|
+
* @returns Promise with list of orders
|
|
7977
|
+
* @example
|
|
7978
|
+
* ```typescript
|
|
7979
|
+
* // Basic order listing
|
|
7980
|
+
* const { data, error } = await pos.listOrders();
|
|
7981
|
+
*
|
|
7982
|
+
* if (error) {
|
|
7983
|
+
* console.error("Failed to list orders:", error.message);
|
|
7984
|
+
* } else {
|
|
7985
|
+
* console.log("Orders found:", data.content?.orders?.length || 0);
|
|
7986
|
+
* console.log("Pagination:", data.content?.pagination);
|
|
7987
|
+
* data.content?.orders?.forEach(order => {
|
|
7988
|
+
* console.log(`Order: ${order.order_number} - Status: ${order.status} - Total: ${order.grand_total}`);
|
|
7989
|
+
* });
|
|
7990
|
+
* }
|
|
7991
|
+
*
|
|
7992
|
+
* // With filters and pagination
|
|
7993
|
+
* const { data: filteredData, error: filteredError } = await pos.listOrders({
|
|
7994
|
+
* page: 1,
|
|
7995
|
+
* limit: 50,
|
|
7996
|
+
* search: "ORD-2024",
|
|
7997
|
+
* filters: JSON.stringify({ "status": "delivered", "payment_status": "success" }),
|
|
7998
|
+
* sort_by: JSON.stringify({ "order_date": "desc" })
|
|
7999
|
+
* });
|
|
8000
|
+
* ```
|
|
8001
|
+
*/
|
|
8002
|
+
listOrders(query?: PosListAdminOrdersQuery): Promise<ApiResult<PosListAdminOrdersContent>>;
|
|
8003
|
+
/**
|
|
8004
|
+
* Get order details (Admin)
|
|
8005
|
+
* @param pathParams - Order number
|
|
8006
|
+
* @returns Promise with order details
|
|
8007
|
+
* @example
|
|
8008
|
+
* ```typescript
|
|
8009
|
+
* const { data, error } = await pos.getOrderDetail({
|
|
8010
|
+
* order_number: "ORD-2024-001234"
|
|
8011
|
+
* });
|
|
8012
|
+
*
|
|
8013
|
+
* if (error) {
|
|
8014
|
+
* console.error("Failed to get order:", error.message);
|
|
8015
|
+
* } else {
|
|
8016
|
+
* const order = data.content?.order;
|
|
8017
|
+
* console.log(`Order: ${order?.order_number}`);
|
|
8018
|
+
* console.log(`Status: ${order?.status}`);
|
|
8019
|
+
* console.log(`Payment Status: ${order?.payment_status}`);
|
|
8020
|
+
* console.log(`Total: ${order?.grand_total}`);
|
|
8021
|
+
* console.log(`Items:`, order?.order_items);
|
|
8022
|
+
* console.log(`Billing Address:`, order?.billing_address);
|
|
8023
|
+
* console.log(`Payments:`, order?.payments);
|
|
8024
|
+
* }
|
|
8025
|
+
* ```
|
|
8026
|
+
*/
|
|
8027
|
+
getOrderDetail(pathParams: PosGetAdminOrderPathParams): Promise<ApiResult<PosGetAdminOrderContent>>;
|
|
8028
|
+
/**
|
|
8029
|
+
* List order activity (Admin)
|
|
8030
|
+
* @param pathParams - Order number
|
|
8031
|
+
* @returns Promise with order activities
|
|
8032
|
+
* @example
|
|
8033
|
+
* ```typescript
|
|
8034
|
+
* const { data, error } = await pos.listOrderActivity({
|
|
8035
|
+
* order_number: "ORD-2024-001234"
|
|
8036
|
+
* });
|
|
8037
|
+
*
|
|
8038
|
+
* if (error) {
|
|
8039
|
+
* console.error("Failed to get order activity:", error.message);
|
|
8040
|
+
* } else {
|
|
8041
|
+
* console.log("Activities found:", data.content?.activity?.length || 0);
|
|
8042
|
+
* data.content?.activity?.forEach(activity => {
|
|
8043
|
+
* console.log(`${activity.created_at}: ${activity.activity_type} - ${activity.comment}`);
|
|
8044
|
+
* console.log(`By: ${activity.user_name} (${activity.user_type})`);
|
|
8045
|
+
* });
|
|
8046
|
+
* }
|
|
8047
|
+
* ```
|
|
8048
|
+
*/
|
|
8049
|
+
listOrderActivity(pathParams: PosListOrderActivityPathParams): Promise<ApiResult<PosListOrderActivityContent>>;
|
|
8050
|
+
/**
|
|
8051
|
+
* Get order invoice (Admin)
|
|
8052
|
+
* @param pathParams - Order number
|
|
8053
|
+
* @param query - Optional format parameter
|
|
8054
|
+
* @returns Promise with order invoice
|
|
8055
|
+
* @example
|
|
8056
|
+
* ```typescript
|
|
8057
|
+
* // Get invoice as JSON
|
|
8058
|
+
* const { data, error } = await pos.getOrderInvoice(
|
|
8059
|
+
* { order_number: "ORD-2024-001234" },
|
|
8060
|
+
* { format: "json" }
|
|
8061
|
+
* );
|
|
8062
|
+
*
|
|
8063
|
+
* if (error) {
|
|
8064
|
+
* console.error("Failed to get order invoice:", error.message);
|
|
8065
|
+
* } else {
|
|
8066
|
+
* data.content?.invoices?.forEach(invoice => {
|
|
8067
|
+
* console.log(`Invoice: ${invoice.invoice_number}`);
|
|
8068
|
+
* console.log(`Date: ${invoice.invoice_date}`);
|
|
8069
|
+
* console.log(`Total: ${invoice.grand_total}`);
|
|
8070
|
+
* console.log(`Items:`, invoice.items);
|
|
8071
|
+
* });
|
|
8072
|
+
* }
|
|
8073
|
+
*
|
|
8074
|
+
* // Get invoice as PDF
|
|
8075
|
+
* const { data: pdfData, error: pdfError } = await pos.getOrderInvoice(
|
|
8076
|
+
* { order_number: "ORD-2024-001234" },
|
|
8077
|
+
* { format: "pdf" }
|
|
8078
|
+
* );
|
|
8079
|
+
* ```
|
|
8080
|
+
*/
|
|
8081
|
+
getOrderInvoice(pathParams: PosGetOrderInvoicePathParams, query?: PosGetOrderInvoiceQuery): Promise<ApiResult<PosGetOrderInvoiceContent>>;
|
|
8082
|
+
/**
|
|
8083
|
+
* Get order receipt (Admin)
|
|
8084
|
+
* @param pathParams - Order number
|
|
8085
|
+
* @param query - Optional format parameter
|
|
8086
|
+
* @returns Promise with order receipt
|
|
8087
|
+
* @example
|
|
8088
|
+
* ```typescript
|
|
8089
|
+
* // Get receipt as JSON
|
|
8090
|
+
* const { data, error } = await pos.getOrderReceipt(
|
|
8091
|
+
* { order_number: "ORD-2024-001234" },
|
|
8092
|
+
* { format: "json" }
|
|
8093
|
+
* );
|
|
8094
|
+
*
|
|
8095
|
+
* if (error) {
|
|
8096
|
+
* console.error("Failed to get order receipt:", error.message);
|
|
8097
|
+
* } else {
|
|
8098
|
+
* const receipt = data.content?.order_receipt;
|
|
8099
|
+
* console.log(`Order: ${receipt?.order_number}`);
|
|
8100
|
+
* console.log(`Date: ${receipt?.order_date}`);
|
|
8101
|
+
* console.log(`Total: ${receipt?.grand_total}`);
|
|
8102
|
+
* console.log(`Items:`, receipt?.order_items);
|
|
8103
|
+
* console.log(`Payments:`, receipt?.payments);
|
|
8104
|
+
* }
|
|
8105
|
+
*
|
|
8106
|
+
* // Get receipt as PDF
|
|
8107
|
+
* const { data: pdfData, error: pdfError } = await pos.getOrderReceipt(
|
|
8108
|
+
* { order_number: "ORD-2024-001234" },
|
|
8109
|
+
* { format: "pdf" }
|
|
8110
|
+
* );
|
|
8111
|
+
* ```
|
|
8112
|
+
*/
|
|
8113
|
+
getOrderReceipt(pathParams: PosGetOrderReceiptPathParams, query?: PosGetOrderReceiptQuery): Promise<ApiResult<PosGetOrderReceiptContent>>;
|
|
8114
|
+
/**
|
|
8115
|
+
* Get order shipments (Admin)
|
|
8116
|
+
* @param pathParams - Order number
|
|
8117
|
+
* @returns Promise with order shipments
|
|
8118
|
+
* @example
|
|
8119
|
+
* ```typescript
|
|
8120
|
+
* const { data, error } = await pos.getOrderShipments({
|
|
8121
|
+
* order_number: "ORD-2024-001234"
|
|
8122
|
+
* });
|
|
8123
|
+
*
|
|
8124
|
+
* if (error) {
|
|
8125
|
+
* console.error("Failed to get order shipments:", error.message);
|
|
8126
|
+
* } else {
|
|
8127
|
+
* const shipment = data.content?.shipment;
|
|
8128
|
+
* console.log(`Order: ${shipment?.order_number}`);
|
|
8129
|
+
* console.log(`Order Status: ${shipment?.order_status}`);
|
|
8130
|
+
* console.log(`Payment Status: ${shipment?.payment_status}`);
|
|
8131
|
+
* console.log(`Customer: ${shipment?.customer_name}`);
|
|
8132
|
+
* console.log(`Shipments:`, shipment?.shipments);
|
|
8133
|
+
* console.log(`Allowed Actions:`, shipment?.allowed_actions);
|
|
8134
|
+
* }
|
|
8135
|
+
* ```
|
|
8136
|
+
*/
|
|
8137
|
+
getOrderShipments(pathParams: PosGetOrderShipmentsPathParams): Promise<ApiResult<PosGetOrderShipmentsContent>>;
|
|
8138
|
+
/**
|
|
8139
|
+
* List all shipments (Admin)
|
|
8140
|
+
* @param query - Optional query parameters for filtering shipments
|
|
8141
|
+
* @returns Promise with list of shipments
|
|
8142
|
+
* @example
|
|
8143
|
+
* ```typescript
|
|
8144
|
+
* // Basic shipment listing
|
|
8145
|
+
* const { data, error } = await pos.listShipments();
|
|
8146
|
+
*
|
|
8147
|
+
* if (error) {
|
|
8148
|
+
* console.error("Failed to list shipments:", error.message);
|
|
8149
|
+
* } else {
|
|
8150
|
+
* console.log("Shipments found:", data.content?.shipments?.length || 0);
|
|
8151
|
+
* console.log("Pagination:", data.content?.pagination);
|
|
8152
|
+
* data.content?.shipments?.forEach(shipment => {
|
|
8153
|
+
* console.log(`Shipment: ${shipment.shipment_number} - Status: ${shipment.status}`);
|
|
8154
|
+
* console.log(`Order: ${shipment.order_number} - AWB: ${shipment.awb_no}`);
|
|
8155
|
+
* });
|
|
8156
|
+
* }
|
|
8157
|
+
*
|
|
8158
|
+
* // With filters and search
|
|
8159
|
+
* const { data: filteredData, error: filteredError } = await pos.listShipments({
|
|
8160
|
+
* page: 1,
|
|
8161
|
+
* limit: 25,
|
|
8162
|
+
* search: "SHIP-2024",
|
|
8163
|
+
* filters: JSON.stringify({ "status": "shipped" }),
|
|
8164
|
+
* sort_by: JSON.stringify({ "shipped_date": "desc" })
|
|
8165
|
+
* });
|
|
8166
|
+
* ```
|
|
8167
|
+
*/
|
|
8168
|
+
listShipments(query?: PosListShipmentsQuery): Promise<ApiResult<PosListShipmentsContent>>;
|
|
8169
|
+
/**
|
|
8170
|
+
* Check inventory for order (Admin)
|
|
8171
|
+
* @param pathParams - Order number
|
|
8172
|
+
* @returns Promise with inventory check results
|
|
8173
|
+
* @example
|
|
8174
|
+
* ```typescript
|
|
8175
|
+
* const { data, error } = await pos.checkInventory({
|
|
8176
|
+
* order_number: "ORD-2024-001234"
|
|
8177
|
+
* });
|
|
8178
|
+
*
|
|
8179
|
+
* if (error) {
|
|
8180
|
+
* console.error("Failed to check inventory:", error.message);
|
|
8181
|
+
* } else {
|
|
8182
|
+
* const inventory = data.content;
|
|
8183
|
+
* console.log(`Inventory Status: ${inventory?.inventory_status}`);
|
|
8184
|
+
* console.log(`Shipment Items:`, inventory?.shipment_items);
|
|
8185
|
+
* console.log(`Recommended Warehouses:`, inventory?.recommended_warehouses);
|
|
8186
|
+
* console.log(`Inventory Detail:`, inventory?.inventory_detail);
|
|
8187
|
+
* console.log(`Allowed Actions:`, inventory?.allowed_action);
|
|
8188
|
+
* }
|
|
8189
|
+
* ```
|
|
8190
|
+
*/
|
|
8191
|
+
checkInventory(pathParams: PosCheckInventoryForOrderPathParams): Promise<ApiResult<PosCheckInventoryForOrderContent>>;
|
|
8192
|
+
/**
|
|
8193
|
+
* Refund shortfall for order (Admin)
|
|
8194
|
+
* @param pathParams - Order number
|
|
8195
|
+
* @param body - Refund details
|
|
8196
|
+
* @returns Promise with refund confirmation
|
|
8197
|
+
* @example
|
|
8198
|
+
* ```typescript
|
|
8199
|
+
* const { data, error } = await pos.refundShortfall(
|
|
8200
|
+
* { order_number: "ORD-2024-001234" },
|
|
8201
|
+
* {
|
|
8202
|
+
* items: [
|
|
8203
|
+
* {
|
|
8204
|
+
* sku: "SKU-123",
|
|
8205
|
+
* quantity: 2,
|
|
8206
|
+
* free_quantity: 0
|
|
8207
|
+
* }
|
|
8208
|
+
* ],
|
|
8209
|
+
* payment_method: "original-payment-mode"
|
|
8210
|
+
* }
|
|
8211
|
+
* );
|
|
8212
|
+
*
|
|
8213
|
+
* if (error) {
|
|
8214
|
+
* console.error("Failed to process refund:", error.message);
|
|
8215
|
+
* } else {
|
|
8216
|
+
* console.log("Refund processed:", data.message);
|
|
8217
|
+
* console.log("Success:", data.success);
|
|
8218
|
+
* }
|
|
8219
|
+
*
|
|
8220
|
+
* // Refund to bank transfer
|
|
8221
|
+
* const { data: bankData, error: bankError } = await pos.refundShortfall(
|
|
8222
|
+
* { order_number: "ORD-2024-001234" },
|
|
8223
|
+
* {
|
|
8224
|
+
* items: [{ sku: "SKU-123", quantity: 1 }],
|
|
8225
|
+
* payment_method: "bank-transfer",
|
|
8226
|
+
* bank_account_id: "BANK_ACC_123"
|
|
8227
|
+
* }
|
|
8228
|
+
* );
|
|
8229
|
+
* ```
|
|
8230
|
+
*/
|
|
8231
|
+
refundShortfall(pathParams: PosRefundShortfallForOrderPathParams, body: PosRefundShortfallForOrderBody): Promise<ApiResult<PosRefundShortfallForOrderResponse>>;
|
|
8232
|
+
/**
|
|
8233
|
+
* Get shipment details (Admin)
|
|
8234
|
+
* @param pathParams - Shipment reference number
|
|
8235
|
+
* @returns Promise with shipment details
|
|
8236
|
+
* @example
|
|
8237
|
+
* ```typescript
|
|
8238
|
+
* const { data, error } = await pos.getShipment({
|
|
8239
|
+
* reference_number: "SHIP-2024-001234"
|
|
8240
|
+
* });
|
|
8241
|
+
*
|
|
8242
|
+
* if (error) {
|
|
8243
|
+
* console.error("Failed to get shipment:", error.message);
|
|
8244
|
+
* } else {
|
|
8245
|
+
* const shipment = data.content?.shipment;
|
|
8246
|
+
* console.log(`Order: ${shipment?.order_number}`);
|
|
8247
|
+
* console.log(`Shipments:`, shipment?.shipments);
|
|
8248
|
+
* shipment?.shipments?.forEach(s => {
|
|
8249
|
+
* console.log(` Shipment: ${s.shipment_number} - Status: ${s.status}`);
|
|
8250
|
+
* console.log(` AWB: ${s.awb_no} - Courier: ${s.courier_company_name}`);
|
|
8251
|
+
* console.log(` Items:`, s.shipment_items);
|
|
8252
|
+
* });
|
|
8253
|
+
* }
|
|
8254
|
+
* ```
|
|
8255
|
+
*/
|
|
8256
|
+
getShipment(pathParams: PosGetShipmentPathParams): Promise<ApiResult<PosGetShipmentContent>>;
|
|
8257
|
+
/**
|
|
8258
|
+
* Get shipment invoice (Admin)
|
|
8259
|
+
* @param pathParams - Shipment reference number
|
|
8260
|
+
* @param query - Optional format parameter
|
|
8261
|
+
* @returns Promise with shipment invoice
|
|
8262
|
+
* @example
|
|
8263
|
+
* ```typescript
|
|
8264
|
+
* // Get shipment invoice as JSON
|
|
8265
|
+
* const { data, error } = await pos.getShipmentInvoice(
|
|
8266
|
+
* { reference_number: "SHIP-2024-001234" },
|
|
8267
|
+
* { format: "json" }
|
|
8268
|
+
* );
|
|
8269
|
+
*
|
|
8270
|
+
* if (error) {
|
|
8271
|
+
* console.error("Failed to get shipment invoice:", error.message);
|
|
8272
|
+
* } else {
|
|
8273
|
+
* const invoice = data.content?.invoice;
|
|
8274
|
+
* console.log(`Invoice: ${invoice?.invoice_number}`);
|
|
8275
|
+
* console.log(`Date: ${invoice?.invoice_date}`);
|
|
8276
|
+
* console.log(`Total: ${invoice?.grand_total}`);
|
|
8277
|
+
* console.log(`Items:`, invoice?.items);
|
|
8278
|
+
* }
|
|
8279
|
+
*
|
|
8280
|
+
* // Get shipment invoice as PDF
|
|
8281
|
+
* const { data: pdfData, error: pdfError } = await pos.getShipmentInvoice(
|
|
8282
|
+
* { reference_number: "SHIP-2024-001234" },
|
|
8283
|
+
* { format: "pdf" }
|
|
8284
|
+
* );
|
|
8285
|
+
* ```
|
|
8286
|
+
*/
|
|
8287
|
+
getShipmentInvoice(pathParams: PosGetShipmentInvoicePathParams, query?: PosGetShipmentInvoiceQuery): Promise<ApiResult<PosGetShipmentInvoiceContent>>;
|
|
8288
|
+
/**
|
|
8289
|
+
* Update shipment details (Admin)
|
|
8290
|
+
* @param pathParams - Shipment reference number
|
|
8291
|
+
* @param body - Shipment update data
|
|
8292
|
+
* @returns Promise with updated shipment
|
|
8293
|
+
* @example
|
|
8294
|
+
* ```typescript
|
|
8295
|
+
* const { data, error } = await pos.updateShipment(
|
|
8296
|
+
* { reference_number: "SHIP-2024-001234" },
|
|
8297
|
+
* {
|
|
8298
|
+
* status: "shipped",
|
|
8299
|
+
* awb_no: "AWB123456789",
|
|
8300
|
+
* courier_company_name: "BlueDart",
|
|
8301
|
+
* shipping_label_url: "https://example.com/label.pdf",
|
|
8302
|
+
* tracking_url: "https://tracking.example.com/AWB123456789",
|
|
8303
|
+
* eta_delivery: "2024-01-15T10:00:00Z",
|
|
8304
|
+
* shipped_date: "2024-01-10T14:30:00Z"
|
|
8305
|
+
* }
|
|
8306
|
+
* );
|
|
8307
|
+
*
|
|
8308
|
+
* if (error) {
|
|
8309
|
+
* console.error("Failed to update shipment:", error.message);
|
|
8310
|
+
* } else {
|
|
8311
|
+
* console.log("Shipment updated successfully:", data.message);
|
|
8312
|
+
* const shipment = data.content?.shipment;
|
|
8313
|
+
* console.log(`Updated shipment status:`, shipment?.shipments?.[0]?.status);
|
|
8314
|
+
* }
|
|
8315
|
+
*
|
|
8316
|
+
* // Update delivery status
|
|
8317
|
+
* const { data: deliveryData, error: deliveryError } = await pos.updateShipment(
|
|
8318
|
+
* { reference_number: "SHIP-2024-001234" },
|
|
8319
|
+
* {
|
|
8320
|
+
* status: "delivered",
|
|
8321
|
+
* delivered_date: "2024-01-15T16:45:00Z"
|
|
8322
|
+
* }
|
|
8323
|
+
* );
|
|
8324
|
+
* ```
|
|
8325
|
+
*/
|
|
8326
|
+
updateShipment(pathParams: PosUpdateShipmentPathParams, body: PosUpdateShipmentBody): Promise<ApiResult<PosUpdateShipmentContent>>;
|
|
5000
8327
|
}
|
|
5001
8328
|
//#endregion
|
|
5002
8329
|
//#region src/lib/middleware/auth.d.ts
|
|
@@ -5254,5 +8581,5 @@ declare class PosSDK {
|
|
|
5254
8581
|
getTenantId(): Promise<string | null>;
|
|
5255
8582
|
}
|
|
5256
8583
|
//#endregion
|
|
5257
|
-
export { AcceleratedRewardCouponPromotion, AcceleratedRewardRule, AdditionalProductDetails, ApiErrorResponse, ApiResult, ApplicableCoupon, ApplicablePromotion, AppliedCoupon, AppliedPromotion, AssociatedOption, AutoScaleBasedOnAmount, AutoScaleBasedOnQuantity, BankTransfer, BaseAPIClient, BaseSDKOptions, BooleanAttribute, BrowserTokenStorage, BuyXGetYCouponPromotion, BuyXGetYRule, BuyXGetYRuleBasedOnAmount, BuyXGetYRuleBasedOnQuantity, CardPayment, Cart, CartBasedServiceabilityCheck, CartItem, Category, CollectInStore, CollectInStoreFulfillment, ColorAttribute, ColorOption, Coupon, CouponPromotionCommonDetail, CouponType, CreatePosOrderBody, CreatePosOrderContent, CreatePosOrderResponse, Currency, CustomSlabsBasedOnAmount, CustomSlabsBasedOnQuantity, CustomerAddress, DateAttribute, DebugLogger, DebugLoggerFn, DeliveryFulfillment, DiscountBasedPromotion, DiscountCouponPromotion, DiscountRule, Environment, FixedAmountDiscountRule, FixedPriceCouponPromotion, FixedPricePromotion, FixedPriceRule, FixedPriceRuleBasedAmount, FixedPriceRuleBasedQuantity, FreeGoodCouponPromotion, FreeGoodsPromotion, FreeGoodsRule, FreeShipingCouponPromotion, GetPosFulfillmentOptionsBody, GetPosFulfillmentOptionsContent, GetPosFulfillmentOptionsResponse, HeaderConfig, InapplicableCoupon, InapplicablePromotion, Item, LoginPosDeviceWithEmailBody, LoginPosDeviceWithEmailContent, LoginPosDeviceWithEmailResponse, LoginPosDeviceWithPhoneBody, LoginPosDeviceWithPhoneContent, LoginPosDeviceWithPhoneResponse, LoginPosDeviceWithWhatsappBody, LoginPosDeviceWithWhatsappContent, LoginPosDeviceWithWhatsappResponse, LogoutFromPosDeviceResponse, MemoryTokenStorage, MultiSelectAttribute, NetbankingPayment, NumberAttribute, Order, OrderDetail, OrderItem, OrderPayment, OrderRefund, OrderShipment, Pagination, PairPosDeviceBody, PairPosDeviceContent, PairPosDeviceResponse, PaymentInfo, PercentageDiscountRule, PincodeServiceability, PosAPIClient, PosApplyCouponBody, PosApplyCouponContent, PosApplyCouponPathParams, PosApplyCouponResponse, PosClient, PosCreateCartAddressBody, PosCreateCartAddressContent, PosCreateCartAddressPathParams, PosCreateCartAddressResponse, PosCreateCartBody, PosCreateCartContent, PosCreateCartResponse, PosDeleteCartPathParams, PosDeleteCartResponse, PosDevice, PosEvaluateCouponsContent, PosEvaluateCouponsPathParams, PosEvaluateCouponsResponse, PosEvaluatePromotionsContent, PosEvaluatePromotionsPathParams, PosEvaluatePromotionsResponse, PosGetCartContent, PosGetCartPathParams, PosGetCartResponse, PosGetProductDetailContent, PosGetProductDetailHeaderParams, PosGetProductDetailPathParams, PosGetProductDetailResponse, PosGetVariantDetailContent, PosGetVariantDetailHeaderParams, PosGetVariantDetailPathParams, PosGetVariantDetailResponse, PosListCategoriesContent, PosListCategoriesQuery, PosListCategoriesResponse, PosListCouponsContent, PosListCouponsHeaderParams, PosListCouponsResponse, PosListCrosssellProductsContent, PosListCrosssellProductsHeaderParams, PosListCrosssellProductsQuery, PosListCrosssellProductsResponse, PosListProductReviewsContent, PosListProductReviewsPathParams, PosListProductReviewsQuery, PosListProductReviewsResponse, PosListProductVariantsContent, PosListProductVariantsHeaderParams, PosListProductVariantsPathParams, PosListProductVariantsResponse, PosListProductsContent, PosListProductsHeaderParams, PosListProductsQuery, PosListProductsResponse, PosListPromotionsContent, PosListPromotionsHeaderParams, PosListPromotionsResponse, PosListSimilarProductsContent, PosListSimilarProductsHeaderParams, PosListSimilarProductsQuery, PosListSimilarProductsResponse, PosListSkusContent, PosListSkusHeaderParams, PosListSkusQuery, PosListSkusResponse, PosListUpsellProductsContent, PosListUpsellProductsHeaderParams, PosListUpsellProductsQuery, PosListUpsellProductsResponse, PosRedeemCreditBalanceBody, PosRedeemCreditBalanceContent, PosRedeemCreditBalancePathParams, PosRedeemCreditBalanceResponse, PosRedeemLoyaltyPointsBody, PosRedeemLoyaltyPointsContent, PosRedeemLoyaltyPointsPathParams, PosRedeemLoyaltyPointsResponse, PosRemoveCouponContent, PosRemoveCouponPathParams, PosRemoveCouponResponse, PosRemoveCreditBalanceContent, PosRemoveCreditBalancePathParams, PosRemoveCreditBalanceResponse, PosRemoveLoyaltyPointsContent, PosRemoveLoyaltyPointsPathParams, PosRemoveLoyaltyPointsResponse, PosSDK, PosSDK as default, PosSDKOptions, PosSearchProductsBody, PosSearchProductsContent, PosSearchProductsHeaderParams, PosSearchProductsResponse, PosUpdateCartBody, PosUpdateCartContent, PosUpdateCartPathParams, PosUpdateCartResponse, PosUpdateCustomerWithEmail, PosUpdateCustomerWithId, PosUpdateCustomerWithPhone, PosUpdateFulfillmentPreferenceBody, PosUpdateFulfillmentPreferencePathParams, PosUpdateFulfillmentPreferenceResponse, PosUser, Product, ProductAttribute, ProductBundleItem, ProductCategory, ProductDetail, ProductImage, ProductPricing, ProductPromotion, ProductReview, ProductShipping, ProductSubscription, ProductVideo, Promotion, PromotionType, RefreshPosAccessTokenBody, RefreshPosAccessTokenContent, RefreshPosAccessTokenResponse, ResponseUtils, SearchProduct, Seo, ShipmentItem, SingleSelectAttribute, SingleSelectOption, SupportedDefaultHeaders, TextAttribute, type TokenStorage, UpdateCartItem, UpdatePosCartCustomerBody, UpdatePosCartCustomerContent, UpdatePosCartCustomerPathParams, UpdatePosCartCustomerResponse, UpiPayment, type UserInfo, Variant, VariantDetail, VariantOption, VerifyPosLoginOtpBody, VerifyPosLoginOtpContent, VerifyPosLoginOtpResponse, VolumeBasedCouponPromotion, VolumeBasedPromotion, VolumeBasedRule, WalletPayment, type components, createDebugMiddleware, createTimeoutMiddleware, executeRequest, extractRequestBody, getPathnameFromUrl, mergeAndTransformHeaders, mergeHeaders, type operations, type paths, transformHeaders };
|
|
8584
|
+
export { AcceleratedRewardCouponPromotion, AcceleratedRewardRule, AdditionalProductDetails, ApiErrorResponse, ApiResult, ApplicableCoupon, ApplicablePromotion, AppliedCoupon, AppliedPromotion, AssociatedOption, AutoScaleBasedOnAmount, AutoScaleBasedOnQuantity, BankTransfer, BaseAPIClient, BaseSDKOptions, BooleanAttribute, BrowserTokenStorage, BuyXGetYCouponPromotion, BuyXGetYRule, BuyXGetYRuleBasedOnAmount, BuyXGetYRuleBasedOnQuantity, CardPayment, Cart, CartBasedServiceabilityCheck, CartItem, Category, CollectInStore, CollectInStoreFulfillment, ColorAttribute, ColorOption, Coupon, CouponPromotionCommonDetail, CouponType, CreatePosOrderBody, CreatePosOrderContent, CreatePosOrderResponse, Currency, CustomSlabsBasedOnAmount, CustomSlabsBasedOnQuantity, CustomerAddress, DateAttribute, DebugLogger, DebugLoggerFn, DeliveryFulfillment, DiscountBasedPromotion, DiscountCouponPromotion, DiscountRule, Environment, FixedAmountDiscountRule, FixedPriceCouponPromotion, FixedPricePromotion, FixedPriceRule, FixedPriceRuleBasedAmount, FixedPriceRuleBasedQuantity, FreeGoodCouponPromotion, FreeGoodsPromotion, FreeGoodsRule, FreeShipingCouponPromotion, GetPosFulfillmentOptionsBody, GetPosFulfillmentOptionsContent, GetPosFulfillmentOptionsResponse, HeaderConfig, InapplicableCoupon, InapplicablePromotion, Item, JuspayPaymentGatewayParams, LoginPosDeviceWithEmailBody, LoginPosDeviceWithEmailContent, LoginPosDeviceWithEmailResponse, LoginPosDeviceWithPhoneBody, LoginPosDeviceWithPhoneContent, LoginPosDeviceWithPhoneResponse, LoginPosDeviceWithWhatsappBody, LoginPosDeviceWithWhatsappContent, LoginPosDeviceWithWhatsappResponse, LogoutFromPosDeviceResponse, MemoryTokenStorage, MultiSelectAttribute, NetbankingPayment, NumberAttribute, Order, OrderDetail, OrderItem, OrderPayment, OrderRefund, OrderShipment, Pagination, PairPosDeviceBody, PairPosDeviceContent, PairPosDeviceResponse, PayWithCard, PayWithCash, PayWithPaymentGateway, PayWithUpi, PaymentGateway, PaymentGatewayParams, PaymentInfo, PayuPaymentGatewayParams, PercentageDiscountRule, PincodeServiceability, PosAPIClient, PosApplyCouponBody, PosApplyCouponContent, PosApplyCouponPathParams, PosApplyCouponResponse, PosClient, PosCreateCartAddressBody, PosCreateCartAddressContent, PosCreateCartAddressPathParams, PosCreateCartAddressResponse, PosCreateCartBody, PosCreateCartContent, PosCreateCartResponse, PosDeleteCartPathParams, PosDeleteCartResponse, PosDevice, PosEvaluateCouponsContent, PosEvaluateCouponsPathParams, PosEvaluateCouponsResponse, PosEvaluatePromotionsContent, PosEvaluatePromotionsPathParams, PosEvaluatePromotionsResponse, PosGetCartContent, PosGetCartPathParams, PosGetCartResponse, PosGetPaymentStatusContent, PosGetPaymentStatusPathParams, PosGetPaymentStatusResponse, PosGetProductDetailContent, PosGetProductDetailHeaderParams, PosGetProductDetailPathParams, PosGetProductDetailResponse, PosGetVariantDetailContent, PosGetVariantDetailHeaderParams, PosGetVariantDetailPathParams, PosGetVariantDetailResponse, PosListCategoriesContent, PosListCategoriesQuery, PosListCategoriesResponse, PosListCouponsContent, PosListCouponsHeaderParams, PosListCouponsResponse, PosListCrosssellProductsContent, PosListCrosssellProductsHeaderParams, PosListCrosssellProductsQuery, PosListCrosssellProductsResponse, PosListPaymentOptionsContent, PosListPaymentOptionsResponse, PosListProductReviewsContent, PosListProductReviewsPathParams, PosListProductReviewsQuery, PosListProductReviewsResponse, PosListProductVariantsContent, PosListProductVariantsHeaderParams, PosListProductVariantsPathParams, PosListProductVariantsResponse, PosListProductsContent, PosListProductsHeaderParams, PosListProductsQuery, PosListProductsResponse, PosListPromotionsContent, PosListPromotionsHeaderParams, PosListPromotionsResponse, PosListSimilarProductsContent, PosListSimilarProductsHeaderParams, PosListSimilarProductsQuery, PosListSimilarProductsResponse, PosListSkusContent, PosListSkusHeaderParams, PosListSkusQuery, PosListSkusResponse, PosListUpsellProductsContent, PosListUpsellProductsHeaderParams, PosListUpsellProductsQuery, PosListUpsellProductsResponse, PosRedeemCreditBalanceBody, PosRedeemCreditBalanceContent, PosRedeemCreditBalancePathParams, PosRedeemCreditBalanceResponse, PosRedeemLoyaltyPointsBody, PosRedeemLoyaltyPointsContent, PosRedeemLoyaltyPointsPathParams, PosRedeemLoyaltyPointsResponse, PosRemoveCouponContent, PosRemoveCouponPathParams, PosRemoveCouponResponse, PosRemoveCreditBalanceContent, PosRemoveCreditBalancePathParams, PosRemoveCreditBalanceResponse, PosRemoveLoyaltyPointsContent, PosRemoveLoyaltyPointsPathParams, PosRemoveLoyaltyPointsResponse, PosSDK, PosSDK as default, PosSDKOptions, PosSearchProductsBody, PosSearchProductsContent, PosSearchProductsHeaderParams, PosSearchProductsResponse, PosUpdateCartBody, PosUpdateCartContent, PosUpdateCartPathParams, PosUpdateCartResponse, PosUpdateCustomerWithEmail, PosUpdateCustomerWithId, PosUpdateCustomerWithPhone, PosUpdateFulfillmentPreferenceBody, PosUpdateFulfillmentPreferencePathParams, PosUpdateFulfillmentPreferenceResponse, PosUser, Product, ProductAttribute, ProductBundleItem, ProductCategory, ProductDetail, ProductImage, ProductPricing, ProductPromotion, ProductReview, ProductShipping, ProductSubscription, ProductVideo, Promotion, PromotionType, RefreshPosAccessTokenBody, RefreshPosAccessTokenContent, RefreshPosAccessTokenResponse, ResponseUtils, SearchProduct, Seo, ShipmentItem, SingleSelectAttribute, SingleSelectOption, SupportedDefaultHeaders, TextAttribute, type TokenStorage, UpdateCartItem, UpdatePosCartCustomerBody, UpdatePosCartCustomerContent, UpdatePosCartCustomerPathParams, UpdatePosCartCustomerResponse, UpiPayment, type UserInfo, Variant, VariantDetail, VariantOption, VerifyPosLoginOtpBody, VerifyPosLoginOtpContent, VerifyPosLoginOtpResponse, VolumeBasedCouponPromotion, VolumeBasedPromotion, VolumeBasedRule, WalletPayment, type components, createDebugMiddleware, createTimeoutMiddleware, executeRequest, extractRequestBody, getPathnameFromUrl, mergeAndTransformHeaders, mergeHeaders, type operations, type paths, transformHeaders };
|
|
5258
8585
|
//# sourceMappingURL=index.d.ts.map
|