ce-storefront 0.3.4 → 0.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -37
- package/docs/sdks/{cestorefrontpayments → cestorefrontorderspayments}/README.md +1 -1
- package/docs/sdks/customers/README.md +236 -0
- package/docs/sdks/{paymentsapijuspay → juspay}/README.md +12 -12
- package/docs/sdks/orders/README.md +80 -1
- package/docs/sdks/payments/README.md +242 -2
- package/docs/sdks/products/README.md +1 -1
- package/esm/funcs/catalogProductsGet.d.ts +1 -1
- package/esm/funcs/catalogProductsGet.js +1 -1
- package/esm/funcs/{customersAPIGetCustomersId.d.ts → customersGetCustomersId.d.ts} +2 -2
- package/esm/funcs/customersGetCustomersId.d.ts.map +1 -0
- package/esm/funcs/{customersAPIGetCustomersId.js → customersGetCustomersId.js} +2 -2
- package/esm/funcs/customersGetCustomersId.js.map +1 -0
- package/esm/funcs/{customersAPIPostCustomers.d.ts → customersPostCustomers.d.ts} +2 -2
- package/esm/funcs/customersPostCustomers.d.ts.map +1 -0
- package/esm/funcs/{customersAPIPostCustomers.js → customersPostCustomers.js} +2 -2
- package/esm/funcs/customersPostCustomers.js.map +1 -0
- package/esm/funcs/{customersAPIPutCustomersId.d.ts → customersPutCustomersId.d.ts} +2 -2
- package/esm/funcs/customersPutCustomersId.d.ts.map +1 -0
- package/esm/funcs/{customersAPIPutCustomersId.js → customersPutCustomersId.js} +2 -2
- package/esm/funcs/{customersAPIPostCustomers.js.map → customersPutCustomersId.js.map} +1 -1
- package/esm/funcs/{paymentsAPIJuspayGetPaymentsJuspayCustomer.d.ts → juspayGetPaymentsJuspayCustomer.d.ts} +2 -2
- package/esm/funcs/juspayGetPaymentsJuspayCustomer.d.ts.map +1 -0
- package/esm/funcs/{paymentsAPIJuspayGetPaymentsJuspayCustomer.js → juspayGetPaymentsJuspayCustomer.js} +2 -2
- package/esm/funcs/juspayGetPaymentsJuspayCustomer.js.map +1 -0
- package/esm/funcs/{paymentsAPIJuspayPostPaymentsJuspayCreateCustomer.d.ts → juspayPostPaymentsJuspayCreateCustomer.d.ts} +2 -2
- package/esm/funcs/juspayPostPaymentsJuspayCreateCustomer.d.ts.map +1 -0
- package/esm/funcs/{paymentsAPIJuspayPostPaymentsJuspayCreateCustomer.js → juspayPostPaymentsJuspayCreateCustomer.js} +2 -2
- package/esm/funcs/juspayPostPaymentsJuspayCreateCustomer.js.map +1 -0
- package/esm/funcs/{paymentsAPIJuspayPostPaymentsJuspayCreateOrder.d.ts → juspayPostPaymentsJuspayCreateOrder.d.ts} +2 -2
- package/esm/funcs/juspayPostPaymentsJuspayCreateOrder.d.ts.map +1 -0
- package/esm/funcs/{paymentsAPIJuspayPostPaymentsJuspayCreateOrder.js → juspayPostPaymentsJuspayCreateOrder.js} +2 -2
- package/esm/funcs/juspayPostPaymentsJuspayCreateOrder.js.map +1 -0
- package/esm/funcs/{ordersAPIGetOrdersIdPaymentStatus.d.ts → ordersGetOrdersIdPaymentStatus.d.ts} +2 -2
- package/esm/funcs/ordersGetOrdersIdPaymentStatus.d.ts.map +1 -0
- package/esm/funcs/{ordersAPIGetOrdersIdPaymentStatus.js → ordersGetOrdersIdPaymentStatus.js} +2 -2
- package/esm/funcs/ordersGetOrdersIdPaymentStatus.js.map +1 -0
- package/esm/funcs/paymentsGetMethods.d.ts +1 -1
- package/esm/funcs/paymentsGetMethods.d.ts.map +1 -1
- package/esm/funcs/paymentsGetMethods.js +3 -3
- package/esm/funcs/paymentsGetMethods.js.map +1 -1
- package/esm/funcs/{paymentsAPIGetPaymentsCards.d.ts → paymentsGetPaymentsCards.d.ts} +2 -2
- package/esm/funcs/paymentsGetPaymentsCards.d.ts.map +1 -0
- package/esm/funcs/{paymentsAPIGetPaymentsCards.js → paymentsGetPaymentsCards.js} +2 -2
- package/esm/funcs/paymentsGetPaymentsCards.js.map +1 -0
- package/esm/funcs/{paymentsAPIGetPaymentsVerifyVpa.d.ts → paymentsGetPaymentsVerifyVpa.d.ts} +2 -2
- package/esm/funcs/paymentsGetPaymentsVerifyVpa.d.ts.map +1 -0
- package/esm/funcs/{paymentsAPIGetPaymentsVerifyVpa.js → paymentsGetPaymentsVerifyVpa.js} +2 -2
- package/esm/funcs/paymentsGetPaymentsVerifyVpa.js.map +1 -0
- package/esm/funcs/{paymentsAPIPostPaymentsCards.d.ts → paymentsPostPaymentsCards.d.ts} +2 -2
- package/esm/funcs/paymentsPostPaymentsCards.d.ts.map +1 -0
- package/esm/funcs/{paymentsAPIPostPaymentsCards.js → paymentsPostPaymentsCards.js} +2 -2
- package/esm/funcs/paymentsPostPaymentsCards.js.map +1 -0
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/models/components/cart.d.ts +1 -1
- package/esm/models/components/cart.d.ts.map +1 -1
- package/esm/models/components/cart.js +1 -1
- package/esm/models/components/cart.js.map +1 -1
- package/esm/models/components/createcustomer.d.ts +1 -1
- package/esm/models/components/createcustomer.d.ts.map +1 -1
- package/esm/models/components/createcustomer.js +1 -1
- package/esm/models/components/createcustomer.js.map +1 -1
- package/esm/models/components/{customeraddressinput.d.ts → customeraddress.d.ts} +33 -33
- package/esm/models/components/customeraddress.d.ts.map +1 -0
- package/esm/models/components/{customeraddressinput.js → customeraddress.js} +37 -37
- package/esm/models/components/customeraddress.js.map +1 -0
- package/esm/models/components/freegoodspromotion.d.ts +2 -2
- package/esm/models/components/freegoodspromotion.d.ts.map +1 -1
- package/esm/models/components/freegoodspromotion.js +2 -2
- package/esm/models/components/freegoodspromotion.js.map +1 -1
- package/esm/models/components/index.d.ts +2 -3
- package/esm/models/components/index.d.ts.map +1 -1
- package/esm/models/components/index.js +2 -3
- package/esm/models/components/index.js.map +1 -1
- package/esm/models/components/orderdetail.d.ts +1 -1
- package/esm/models/components/orderdetail.d.ts.map +1 -1
- package/esm/models/components/orderdetail.js +1 -1
- package/esm/models/components/orderdetail.js.map +1 -1
- package/esm/models/components/{productlist.d.ts → product.d.ts} +14 -16
- package/esm/models/components/product.d.ts.map +1 -0
- package/esm/models/components/{productlist.js → product.js} +16 -20
- package/esm/models/components/product.js.map +1 -0
- package/esm/models/components/productdetail.d.ts +4 -4
- package/esm/models/components/productdetail.d.ts.map +1 -1
- package/esm/models/components/productdetail.js +4 -4
- package/esm/models/components/productdetail.js.map +1 -1
- package/esm/models/components/productlistresponse.d.ts +3 -3
- package/esm/models/components/productlistresponse.d.ts.map +1 -1
- package/esm/models/components/productlistresponse.js +3 -3
- package/esm/models/components/productlistresponse.js.map +1 -1
- package/esm/models/components/productpromotion.d.ts +11 -5
- package/esm/models/components/productpromotion.d.ts.map +1 -1
- package/esm/models/operations/getpaymentmethods.d.ts +143 -0
- package/esm/models/operations/getpaymentmethods.d.ts.map +1 -0
- package/esm/models/operations/{getpaymentspaymentmethods.js → getpaymentmethods.js} +42 -44
- package/esm/models/operations/getpaymentmethods.js.map +1 -0
- package/esm/models/operations/getsimilar.d.ts +2 -27
- package/esm/models/operations/getsimilar.d.ts.map +1 -1
- package/esm/models/operations/getsimilar.js +2 -27
- package/esm/models/operations/getsimilar.js.map +1 -1
- package/esm/models/operations/index.d.ts +1 -2
- package/esm/models/operations/index.d.ts.map +1 -1
- package/esm/models/operations/index.js +1 -2
- package/esm/models/operations/index.js.map +1 -1
- package/esm/models/operations/postcartitemid.d.ts +15 -15
- package/esm/models/operations/postcartitemid.d.ts.map +1 -1
- package/esm/models/operations/postcartitemid.js +15 -15
- package/esm/models/operations/postcartitemid.js.map +1 -1
- package/esm/sdk/{cestorefrontpayments.d.ts → cestorefrontorderspayments.d.ts} +2 -2
- package/esm/sdk/cestorefrontorderspayments.d.ts.map +1 -0
- package/esm/sdk/{cestorefrontpayments.js → cestorefrontorderspayments.js} +2 -2
- package/esm/sdk/cestorefrontorderspayments.js.map +1 -0
- package/esm/sdk/customers.d.ts +24 -1
- package/esm/sdk/customers.d.ts.map +1 -1
- package/esm/sdk/customers.js +31 -0
- package/esm/sdk/customers.js.map +1 -1
- package/esm/sdk/{paymentsapijuspay.d.ts → juspay.d.ts} +2 -2
- package/esm/sdk/juspay.d.ts.map +1 -0
- package/esm/sdk/{paymentsapijuspay.js → juspay.js} +8 -8
- package/esm/sdk/juspay.js.map +1 -0
- package/esm/sdk/orders.d.ts +9 -2
- package/esm/sdk/orders.d.ts.map +1 -1
- package/esm/sdk/orders.js +12 -2
- package/esm/sdk/orders.js.map +1 -1
- package/esm/sdk/payments.d.ts +23 -1
- package/esm/sdk/payments.d.ts.map +1 -1
- package/esm/sdk/payments.js +31 -0
- package/esm/sdk/payments.js.map +1 -1
- package/esm/sdk/products.d.ts +1 -1
- package/esm/sdk/products.js +1 -1
- package/esm/sdk/sdk.d.ts +3 -12
- package/esm/sdk/sdk.d.ts.map +1 -1
- package/esm/sdk/sdk.js +3 -15
- package/esm/sdk/sdk.js.map +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/catalogProductsGet.ts +1 -1
- package/src/funcs/{customersAPIGetCustomersId.ts → customersGetCustomersId.ts} +1 -1
- package/src/funcs/{customersAPIPostCustomers.ts → customersPostCustomers.ts} +1 -1
- package/src/funcs/{customersAPIPutCustomersId.ts → customersPutCustomersId.ts} +1 -1
- package/src/funcs/{paymentsAPIJuspayGetPaymentsJuspayCustomer.ts → juspayGetPaymentsJuspayCustomer.ts} +1 -1
- package/src/funcs/{paymentsAPIJuspayPostPaymentsJuspayCreateCustomer.ts → juspayPostPaymentsJuspayCreateCustomer.ts} +1 -1
- package/src/funcs/{paymentsAPIJuspayPostPaymentsJuspayCreateOrder.ts → juspayPostPaymentsJuspayCreateOrder.ts} +1 -1
- package/src/funcs/{ordersAPIGetOrdersIdPaymentStatus.ts → ordersGetOrdersIdPaymentStatus.ts} +1 -1
- package/src/funcs/paymentsGetMethods.ts +6 -7
- package/src/funcs/{paymentsAPIGetPaymentsCards.ts → paymentsGetPaymentsCards.ts} +1 -1
- package/src/funcs/{paymentsAPIGetPaymentsVerifyVpa.ts → paymentsGetPaymentsVerifyVpa.ts} +1 -1
- package/src/funcs/{paymentsAPIPostPaymentsCards.ts → paymentsPostPaymentsCards.ts} +1 -1
- package/src/lib/config.ts +2 -2
- package/src/models/components/cart.ts +1 -1
- package/src/models/components/createcustomer.ts +1 -1
- package/src/models/components/freegoodspromotion.ts +4 -4
- package/src/models/components/index.ts +2 -3
- package/src/models/components/orderdetail.ts +1 -1
- package/src/models/components/{productlist.ts → product.ts} +73 -78
- package/src/models/components/productdetail.ts +8 -8
- package/src/models/components/productlistresponse.ts +9 -9
- package/src/models/operations/{getpaymentspaymentmethods.ts → getpaymentmethods.ts} +68 -77
- package/src/models/operations/getsimilar.ts +4 -62
- package/src/models/operations/index.ts +1 -2
- package/src/models/operations/postcartitemid.ts +27 -25
- package/src/sdk/{cestorefrontpayments.ts → cestorefrontorderspayments.ts} +1 -1
- package/src/sdk/customers.ts +58 -1
- package/src/sdk/{paymentsapijuspay.ts → juspay.ts} +7 -7
- package/src/sdk/orders.ts +22 -4
- package/src/sdk/payments.ts +57 -2
- package/src/sdk/products.ts +1 -1
- package/src/sdk/sdk.ts +4 -22
- package/docs/sdks/customersapi/README.md +0 -321
- package/docs/sdks/ordersapi/README.md +0 -86
- package/docs/sdks/paymentsapi/README.md +0 -247
- package/esm/funcs/customersAPIGetCustomersId.d.ts.map +0 -1
- package/esm/funcs/customersAPIGetCustomersId.js.map +0 -1
- package/esm/funcs/customersAPIGetRecommendedProducts.d.ts +0 -16
- package/esm/funcs/customersAPIGetRecommendedProducts.d.ts.map +0 -1
- package/esm/funcs/customersAPIGetRecommendedProducts.js +0 -80
- package/esm/funcs/customersAPIGetRecommendedProducts.js.map +0 -1
- package/esm/funcs/customersAPIPostCustomers.d.ts.map +0 -1
- package/esm/funcs/customersAPIPutCustomersId.d.ts.map +0 -1
- package/esm/funcs/customersAPIPutCustomersId.js.map +0 -1
- package/esm/funcs/ordersAPIGetOrdersIdPaymentStatus.d.ts.map +0 -1
- package/esm/funcs/ordersAPIGetOrdersIdPaymentStatus.js.map +0 -1
- package/esm/funcs/paymentsAPIGetPaymentsCards.d.ts.map +0 -1
- package/esm/funcs/paymentsAPIGetPaymentsCards.js.map +0 -1
- package/esm/funcs/paymentsAPIGetPaymentsVerifyVpa.d.ts.map +0 -1
- package/esm/funcs/paymentsAPIGetPaymentsVerifyVpa.js.map +0 -1
- package/esm/funcs/paymentsAPIJuspayGetPaymentsJuspayCustomer.d.ts.map +0 -1
- package/esm/funcs/paymentsAPIJuspayGetPaymentsJuspayCustomer.js.map +0 -1
- package/esm/funcs/paymentsAPIJuspayPostPaymentsJuspayCreateCustomer.d.ts.map +0 -1
- package/esm/funcs/paymentsAPIJuspayPostPaymentsJuspayCreateCustomer.js.map +0 -1
- package/esm/funcs/paymentsAPIJuspayPostPaymentsJuspayCreateOrder.d.ts.map +0 -1
- package/esm/funcs/paymentsAPIJuspayPostPaymentsJuspayCreateOrder.js.map +0 -1
- package/esm/funcs/paymentsAPIPostPaymentsCards.d.ts.map +0 -1
- package/esm/funcs/paymentsAPIPostPaymentsCards.js.map +0 -1
- package/esm/models/components/customeraddressinput.d.ts.map +0 -1
- package/esm/models/components/customeraddressinput.js.map +0 -1
- package/esm/models/components/productlist.d.ts.map +0 -1
- package/esm/models/components/productlist.js.map +0 -1
- package/esm/models/components/recommendedproduct.d.ts +0 -155
- package/esm/models/components/recommendedproduct.d.ts.map +0 -1
- package/esm/models/components/recommendedproduct.js +0 -193
- package/esm/models/components/recommendedproduct.js.map +0 -1
- package/esm/models/operations/getpaymentspaymentmethods.d.ts +0 -143
- package/esm/models/operations/getpaymentspaymentmethods.d.ts.map +0 -1
- package/esm/models/operations/getpaymentspaymentmethods.js.map +0 -1
- package/esm/models/operations/getrecommendedproducts.d.ts +0 -90
- package/esm/models/operations/getrecommendedproducts.d.ts.map +0 -1
- package/esm/models/operations/getrecommendedproducts.js +0 -87
- package/esm/models/operations/getrecommendedproducts.js.map +0 -1
- package/esm/sdk/cestorefrontpayments.d.ts.map +0 -1
- package/esm/sdk/cestorefrontpayments.js.map +0 -1
- package/esm/sdk/customersapi.d.ts +0 -34
- package/esm/sdk/customersapi.d.ts.map +0 -1
- package/esm/sdk/customersapi.js +0 -48
- package/esm/sdk/customersapi.js.map +0 -1
- package/esm/sdk/ordersapi.d.ts +0 -12
- package/esm/sdk/ordersapi.d.ts.map +0 -1
- package/esm/sdk/ordersapi.js +0 -18
- package/esm/sdk/ordersapi.js.map +0 -1
- package/esm/sdk/paymentsapi.d.ts +0 -27
- package/esm/sdk/paymentsapi.d.ts.map +0 -1
- package/esm/sdk/paymentsapi.js +0 -39
- package/esm/sdk/paymentsapi.js.map +0 -1
- package/esm/sdk/paymentsapijuspay.d.ts.map +0 -1
- package/esm/sdk/paymentsapijuspay.js.map +0 -1
- package/src/funcs/customersAPIGetRecommendedProducts.ts +0 -144
- package/src/models/components/recommendedproduct.ts +0 -385
- package/src/models/operations/getrecommendedproducts.ts +0 -206
- package/src/sdk/customersapi.ts +0 -82
- package/src/sdk/ordersapi.ts +0 -27
- package/src/sdk/paymentsapi.ts +0 -64
- package/src/models/components/{customeraddressinput.ts → customeraddress.ts} +60 -60
package/src/sdk/paymentsapi.ts
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { paymentsAPIGetPaymentsCards } from "../funcs/paymentsAPIGetPaymentsCards.js";
|
|
6
|
-
import { paymentsAPIGetPaymentsVerifyVpa } from "../funcs/paymentsAPIGetPaymentsVerifyVpa.js";
|
|
7
|
-
import { paymentsAPIPostPaymentsCards } from "../funcs/paymentsAPIPostPaymentsCards.js";
|
|
8
|
-
import { ClientSDK, RequestOptions } from "../lib/sdks.js";
|
|
9
|
-
import * as operations from "../models/operations/index.js";
|
|
10
|
-
import { unwrapAsync } from "../types/fp.js";
|
|
11
|
-
|
|
12
|
-
export class PaymentsAPI extends ClientSDK {
|
|
13
|
-
/**
|
|
14
|
-
* List all saved cards
|
|
15
|
-
*
|
|
16
|
-
* @remarks
|
|
17
|
-
* List all saved cards.
|
|
18
|
-
*/
|
|
19
|
-
async getPaymentsCards(
|
|
20
|
-
request: operations.GetPaymentsCardsRequest,
|
|
21
|
-
options?: RequestOptions,
|
|
22
|
-
): Promise<operations.GetPaymentsCardsResponseBody> {
|
|
23
|
-
return unwrapAsync(paymentsAPIGetPaymentsCards(
|
|
24
|
-
this,
|
|
25
|
-
request,
|
|
26
|
-
options,
|
|
27
|
-
));
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* Add card
|
|
32
|
-
*
|
|
33
|
-
* @remarks
|
|
34
|
-
* Add a new card
|
|
35
|
-
*/
|
|
36
|
-
async postPaymentsCards(
|
|
37
|
-
request: operations.PostPaymentsCardsRequestBody,
|
|
38
|
-
options?: RequestOptions,
|
|
39
|
-
): Promise<operations.PostPaymentsCardsResponseBody> {
|
|
40
|
-
return unwrapAsync(paymentsAPIPostPaymentsCards(
|
|
41
|
-
this,
|
|
42
|
-
request,
|
|
43
|
-
options,
|
|
44
|
-
));
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
/**
|
|
48
|
-
* Verify VPA
|
|
49
|
-
*
|
|
50
|
-
* @remarks
|
|
51
|
-
* The Virtual Payment Address or VPA is a unique ID given to an individual using the Unified Payment Interface (UPI) service to send or receive money. In the case of UPI collect VPA is the mandatory param and merchants are always advised to check if the VPA is valid or not.
|
|
52
|
-
* Validating the VPA will help in reducing the failure rate due to incorrect vpa.
|
|
53
|
-
*/
|
|
54
|
-
async getPaymentsVerifyVpa(
|
|
55
|
-
request: operations.GetPaymentsVerifyVpaRequest,
|
|
56
|
-
options?: RequestOptions,
|
|
57
|
-
): Promise<operations.GetPaymentsVerifyVpaResponseBody> {
|
|
58
|
-
return unwrapAsync(paymentsAPIGetPaymentsVerifyVpa(
|
|
59
|
-
this,
|
|
60
|
-
request,
|
|
61
|
-
options,
|
|
62
|
-
));
|
|
63
|
-
}
|
|
64
|
-
}
|
|
@@ -14,7 +14,8 @@ export const CustomerAddressCountry = {
|
|
|
14
14
|
} as const;
|
|
15
15
|
export type CustomerAddressCountry = ClosedEnum<typeof CustomerAddressCountry>;
|
|
16
16
|
|
|
17
|
-
export type
|
|
17
|
+
export type CustomerAddress = {
|
|
18
|
+
id?: string | undefined;
|
|
18
19
|
firstName: string;
|
|
19
20
|
lastName?: string | undefined;
|
|
20
21
|
/**
|
|
@@ -43,10 +44,11 @@ export type CustomerAddressInput = {
|
|
|
43
44
|
* Use in shipping details only.
|
|
44
45
|
*/
|
|
45
46
|
businessName?: string | null | undefined;
|
|
47
|
+
isPhoneVerified?: boolean | undefined;
|
|
48
|
+
isEmailVerified?: boolean | undefined;
|
|
46
49
|
};
|
|
47
50
|
|
|
48
|
-
export type
|
|
49
|
-
id?: string | undefined;
|
|
51
|
+
export type CustomerAddressInput = {
|
|
50
52
|
firstName: string;
|
|
51
53
|
lastName?: string | undefined;
|
|
52
54
|
/**
|
|
@@ -75,8 +77,6 @@ export type CustomerAddress = {
|
|
|
75
77
|
* Use in shipping details only.
|
|
76
78
|
*/
|
|
77
79
|
businessName?: string | null | undefined;
|
|
78
|
-
isPhoneVerified?: boolean | undefined;
|
|
79
|
-
isEmailVerified?: boolean | undefined;
|
|
80
80
|
};
|
|
81
81
|
|
|
82
82
|
/** @internal */
|
|
@@ -101,11 +101,12 @@ export namespace CustomerAddressCountry$ {
|
|
|
101
101
|
}
|
|
102
102
|
|
|
103
103
|
/** @internal */
|
|
104
|
-
export const
|
|
105
|
-
|
|
104
|
+
export const CustomerAddress$inboundSchema: z.ZodType<
|
|
105
|
+
CustomerAddress,
|
|
106
106
|
z.ZodTypeDef,
|
|
107
107
|
unknown
|
|
108
108
|
> = z.object({
|
|
109
|
+
id: z.string().optional(),
|
|
109
110
|
first_name: z.string(),
|
|
110
111
|
last_name: z.string().optional(),
|
|
111
112
|
country_code: z.string().optional(),
|
|
@@ -120,6 +121,8 @@ export const CustomerAddressInput$inboundSchema: z.ZodType<
|
|
|
120
121
|
country: CustomerAddressCountry$inboundSchema,
|
|
121
122
|
gstin: z.nullable(z.string()).optional(),
|
|
122
123
|
business_name: z.nullable(z.string()).optional(),
|
|
124
|
+
is_phone_verified: z.boolean().optional(),
|
|
125
|
+
is_email_verified: z.boolean().optional(),
|
|
123
126
|
}).transform((v) => {
|
|
124
127
|
return remap$(v, {
|
|
125
128
|
"first_name": "firstName",
|
|
@@ -128,11 +131,14 @@ export const CustomerAddressInput$inboundSchema: z.ZodType<
|
|
|
128
131
|
"address_line1": "addressLine1",
|
|
129
132
|
"address_line2": "addressLine2",
|
|
130
133
|
"business_name": "businessName",
|
|
134
|
+
"is_phone_verified": "isPhoneVerified",
|
|
135
|
+
"is_email_verified": "isEmailVerified",
|
|
131
136
|
});
|
|
132
137
|
});
|
|
133
138
|
|
|
134
139
|
/** @internal */
|
|
135
|
-
export type
|
|
140
|
+
export type CustomerAddress$Outbound = {
|
|
141
|
+
id?: string | undefined;
|
|
136
142
|
first_name: string;
|
|
137
143
|
last_name?: string | undefined;
|
|
138
144
|
country_code?: string | undefined;
|
|
@@ -147,14 +153,17 @@ export type CustomerAddressInput$Outbound = {
|
|
|
147
153
|
country: string;
|
|
148
154
|
gstin?: string | null | undefined;
|
|
149
155
|
business_name?: string | null | undefined;
|
|
156
|
+
is_phone_verified?: boolean | undefined;
|
|
157
|
+
is_email_verified?: boolean | undefined;
|
|
150
158
|
};
|
|
151
159
|
|
|
152
160
|
/** @internal */
|
|
153
|
-
export const
|
|
154
|
-
|
|
161
|
+
export const CustomerAddress$outboundSchema: z.ZodType<
|
|
162
|
+
CustomerAddress$Outbound,
|
|
155
163
|
z.ZodTypeDef,
|
|
156
|
-
|
|
164
|
+
CustomerAddress
|
|
157
165
|
> = z.object({
|
|
166
|
+
id: z.string().optional(),
|
|
158
167
|
firstName: z.string(),
|
|
159
168
|
lastName: z.string().optional(),
|
|
160
169
|
countryCode: z.string().optional(),
|
|
@@ -169,6 +178,8 @@ export const CustomerAddressInput$outboundSchema: z.ZodType<
|
|
|
169
178
|
country: CustomerAddressCountry$outboundSchema,
|
|
170
179
|
gstin: z.nullable(z.string()).optional(),
|
|
171
180
|
businessName: z.nullable(z.string()).optional(),
|
|
181
|
+
isPhoneVerified: z.boolean().optional(),
|
|
182
|
+
isEmailVerified: z.boolean().optional(),
|
|
172
183
|
}).transform((v) => {
|
|
173
184
|
return remap$(v, {
|
|
174
185
|
firstName: "first_name",
|
|
@@ -177,6 +188,8 @@ export const CustomerAddressInput$outboundSchema: z.ZodType<
|
|
|
177
188
|
addressLine1: "address_line1",
|
|
178
189
|
addressLine2: "address_line2",
|
|
179
190
|
businessName: "business_name",
|
|
191
|
+
isPhoneVerified: "is_phone_verified",
|
|
192
|
+
isEmailVerified: "is_email_verified",
|
|
180
193
|
});
|
|
181
194
|
});
|
|
182
195
|
|
|
@@ -184,40 +197,37 @@ export const CustomerAddressInput$outboundSchema: z.ZodType<
|
|
|
184
197
|
* @internal
|
|
185
198
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
186
199
|
*/
|
|
187
|
-
export namespace
|
|
188
|
-
/** @deprecated use `
|
|
189
|
-
export const inboundSchema =
|
|
190
|
-
/** @deprecated use `
|
|
191
|
-
export const outboundSchema =
|
|
192
|
-
/** @deprecated use `
|
|
193
|
-
export type Outbound =
|
|
200
|
+
export namespace CustomerAddress$ {
|
|
201
|
+
/** @deprecated use `CustomerAddress$inboundSchema` instead. */
|
|
202
|
+
export const inboundSchema = CustomerAddress$inboundSchema;
|
|
203
|
+
/** @deprecated use `CustomerAddress$outboundSchema` instead. */
|
|
204
|
+
export const outboundSchema = CustomerAddress$outboundSchema;
|
|
205
|
+
/** @deprecated use `CustomerAddress$Outbound` instead. */
|
|
206
|
+
export type Outbound = CustomerAddress$Outbound;
|
|
194
207
|
}
|
|
195
208
|
|
|
196
|
-
export function
|
|
197
|
-
|
|
209
|
+
export function customerAddressToJSON(
|
|
210
|
+
customerAddress: CustomerAddress,
|
|
198
211
|
): string {
|
|
199
|
-
return JSON.stringify(
|
|
200
|
-
CustomerAddressInput$outboundSchema.parse(customerAddressInput),
|
|
201
|
-
);
|
|
212
|
+
return JSON.stringify(CustomerAddress$outboundSchema.parse(customerAddress));
|
|
202
213
|
}
|
|
203
214
|
|
|
204
|
-
export function
|
|
215
|
+
export function customerAddressFromJSON(
|
|
205
216
|
jsonString: string,
|
|
206
|
-
): SafeParseResult<
|
|
217
|
+
): SafeParseResult<CustomerAddress, SDKValidationError> {
|
|
207
218
|
return safeParse(
|
|
208
219
|
jsonString,
|
|
209
|
-
(x) =>
|
|
210
|
-
`Failed to parse '
|
|
220
|
+
(x) => CustomerAddress$inboundSchema.parse(JSON.parse(x)),
|
|
221
|
+
`Failed to parse 'CustomerAddress' from JSON`,
|
|
211
222
|
);
|
|
212
223
|
}
|
|
213
224
|
|
|
214
225
|
/** @internal */
|
|
215
|
-
export const
|
|
216
|
-
|
|
226
|
+
export const CustomerAddressInput$inboundSchema: z.ZodType<
|
|
227
|
+
CustomerAddressInput,
|
|
217
228
|
z.ZodTypeDef,
|
|
218
229
|
unknown
|
|
219
230
|
> = z.object({
|
|
220
|
-
id: z.string().optional(),
|
|
221
231
|
first_name: z.string(),
|
|
222
232
|
last_name: z.string().optional(),
|
|
223
233
|
country_code: z.string().optional(),
|
|
@@ -232,8 +242,6 @@ export const CustomerAddress$inboundSchema: z.ZodType<
|
|
|
232
242
|
country: CustomerAddressCountry$inboundSchema,
|
|
233
243
|
gstin: z.nullable(z.string()).optional(),
|
|
234
244
|
business_name: z.nullable(z.string()).optional(),
|
|
235
|
-
is_phone_verified: z.boolean().optional(),
|
|
236
|
-
is_email_verified: z.boolean().optional(),
|
|
237
245
|
}).transform((v) => {
|
|
238
246
|
return remap$(v, {
|
|
239
247
|
"first_name": "firstName",
|
|
@@ -242,14 +250,11 @@ export const CustomerAddress$inboundSchema: z.ZodType<
|
|
|
242
250
|
"address_line1": "addressLine1",
|
|
243
251
|
"address_line2": "addressLine2",
|
|
244
252
|
"business_name": "businessName",
|
|
245
|
-
"is_phone_verified": "isPhoneVerified",
|
|
246
|
-
"is_email_verified": "isEmailVerified",
|
|
247
253
|
});
|
|
248
254
|
});
|
|
249
255
|
|
|
250
256
|
/** @internal */
|
|
251
|
-
export type
|
|
252
|
-
id?: string | undefined;
|
|
257
|
+
export type CustomerAddressInput$Outbound = {
|
|
253
258
|
first_name: string;
|
|
254
259
|
last_name?: string | undefined;
|
|
255
260
|
country_code?: string | undefined;
|
|
@@ -264,17 +269,14 @@ export type CustomerAddress$Outbound = {
|
|
|
264
269
|
country: string;
|
|
265
270
|
gstin?: string | null | undefined;
|
|
266
271
|
business_name?: string | null | undefined;
|
|
267
|
-
is_phone_verified?: boolean | undefined;
|
|
268
|
-
is_email_verified?: boolean | undefined;
|
|
269
272
|
};
|
|
270
273
|
|
|
271
274
|
/** @internal */
|
|
272
|
-
export const
|
|
273
|
-
|
|
275
|
+
export const CustomerAddressInput$outboundSchema: z.ZodType<
|
|
276
|
+
CustomerAddressInput$Outbound,
|
|
274
277
|
z.ZodTypeDef,
|
|
275
|
-
|
|
278
|
+
CustomerAddressInput
|
|
276
279
|
> = z.object({
|
|
277
|
-
id: z.string().optional(),
|
|
278
280
|
firstName: z.string(),
|
|
279
281
|
lastName: z.string().optional(),
|
|
280
282
|
countryCode: z.string().optional(),
|
|
@@ -289,8 +291,6 @@ export const CustomerAddress$outboundSchema: z.ZodType<
|
|
|
289
291
|
country: CustomerAddressCountry$outboundSchema,
|
|
290
292
|
gstin: z.nullable(z.string()).optional(),
|
|
291
293
|
businessName: z.nullable(z.string()).optional(),
|
|
292
|
-
isPhoneVerified: z.boolean().optional(),
|
|
293
|
-
isEmailVerified: z.boolean().optional(),
|
|
294
294
|
}).transform((v) => {
|
|
295
295
|
return remap$(v, {
|
|
296
296
|
firstName: "first_name",
|
|
@@ -299,8 +299,6 @@ export const CustomerAddress$outboundSchema: z.ZodType<
|
|
|
299
299
|
addressLine1: "address_line1",
|
|
300
300
|
addressLine2: "address_line2",
|
|
301
301
|
businessName: "business_name",
|
|
302
|
-
isPhoneVerified: "is_phone_verified",
|
|
303
|
-
isEmailVerified: "is_email_verified",
|
|
304
302
|
});
|
|
305
303
|
});
|
|
306
304
|
|
|
@@ -308,27 +306,29 @@ export const CustomerAddress$outboundSchema: z.ZodType<
|
|
|
308
306
|
* @internal
|
|
309
307
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
310
308
|
*/
|
|
311
|
-
export namespace
|
|
312
|
-
/** @deprecated use `
|
|
313
|
-
export const inboundSchema =
|
|
314
|
-
/** @deprecated use `
|
|
315
|
-
export const outboundSchema =
|
|
316
|
-
/** @deprecated use `
|
|
317
|
-
export type Outbound =
|
|
309
|
+
export namespace CustomerAddressInput$ {
|
|
310
|
+
/** @deprecated use `CustomerAddressInput$inboundSchema` instead. */
|
|
311
|
+
export const inboundSchema = CustomerAddressInput$inboundSchema;
|
|
312
|
+
/** @deprecated use `CustomerAddressInput$outboundSchema` instead. */
|
|
313
|
+
export const outboundSchema = CustomerAddressInput$outboundSchema;
|
|
314
|
+
/** @deprecated use `CustomerAddressInput$Outbound` instead. */
|
|
315
|
+
export type Outbound = CustomerAddressInput$Outbound;
|
|
318
316
|
}
|
|
319
317
|
|
|
320
|
-
export function
|
|
321
|
-
|
|
318
|
+
export function customerAddressInputToJSON(
|
|
319
|
+
customerAddressInput: CustomerAddressInput,
|
|
322
320
|
): string {
|
|
323
|
-
return JSON.stringify(
|
|
321
|
+
return JSON.stringify(
|
|
322
|
+
CustomerAddressInput$outboundSchema.parse(customerAddressInput),
|
|
323
|
+
);
|
|
324
324
|
}
|
|
325
325
|
|
|
326
|
-
export function
|
|
326
|
+
export function customerAddressInputFromJSON(
|
|
327
327
|
jsonString: string,
|
|
328
|
-
): SafeParseResult<
|
|
328
|
+
): SafeParseResult<CustomerAddressInput, SDKValidationError> {
|
|
329
329
|
return safeParse(
|
|
330
330
|
jsonString,
|
|
331
|
-
(x) =>
|
|
332
|
-
`Failed to parse '
|
|
331
|
+
(x) => CustomerAddressInput$inboundSchema.parse(JSON.parse(x)),
|
|
332
|
+
`Failed to parse 'CustomerAddressInput' from JSON`,
|
|
333
333
|
);
|
|
334
334
|
}
|