Skip to content

Commit 26136fa

Browse files
authored
build(codegen): updating SDK (#1158)
Co-authored-by: ct-sdks[bot] <153784748+ct-sdks[bot]@users.noreply.github.com>
1 parent 976ea7e commit 26136fa

9 files changed

Lines changed: 21 additions & 28 deletions

packages/platform-sdk/src/generated/client/customers/by-project-key-customers-request-builder.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -207,9 +207,6 @@ export class ByProjectKeyCustomersRequestBuilder {
207207
)
208208
}
209209
/**
210-
* If the `anonymousCart` field is set on the [CustomerDraft](ctp:api:type:CustomerDraft), then the newly created Customer will be assigned to that [Cart](ctp:api:type:Cart).
211-
* Similarly, if the `anonymousId` field is set, the Customer will be set on all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList) and [Payments](ctp:api:type:Payment) with the same `anonymousId`.
212-
*
213210
* Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. Simultaneously creating two Customers with the same email address can return a [LockedField](ctp:api:type:LockedFieldError) error.
214211
*
215212
*/

packages/platform-sdk/src/generated/client/customers/by-project-key-in-store-key-by-store-key-customers-request-builder.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,10 +195,10 @@ export class ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder {
195195
/**
196196
* When using this endpoint, if omitted, the Customer `stores` field is set to the [Store](ctp:api:type:Store) specified in the path parameter.
197197
*
198-
* If the `anonymousCart` field is set on the [CustomerDraft](ctp:api:type:CustomerDraft), then the newly created Customer will be assigned to that [Cart](ctp:api:type:Cart).
199-
* Similarly, if the `anonymousId` field is set, the Customer will be set on all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList) and [Payments](ctp:api:type:Payment) with the same `anonymousId`.
200198
* If a Cart with a `store` field specified, the `store` field must reference the same [Store](ctp:api:type:Store) specified in the `{storeKey}` path parameter.
201199
*
200+
* If the Customer has multiple active Carts, the anonymous Cart is [merged](/../api/customers-overview#cart-merge-during-sign-in-and-sign-up) into the most recently modified active Cart.
201+
*
202202
* Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message. Simultaneously creating two Customers with the same email address can return a [LockedField](ctp:api:type:LockedFieldError) error.
203203
*
204204
*/

packages/platform-sdk/src/generated/client/login/by-project-key-in-store-key-by-store-key-login-request-builder.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,9 @@ export class ByProjectKeyInStoreKeyByStoreKeyLoginRequestBuilder {
2020
}
2121
) {}
2222
/**
23-
* Authenticates a Customer associated with a [Store](ctp:api:type:Store). For more information, see [Global versus Store-specific Customers](/../api/customers-overview#global-versus-store-specific-customers).
23+
* Authenticates a Customer associated with a [Store](ctp:api:type:Store).
2424
*
25-
* A Cart returned in the [CustomerSignInResult](ctp:api:type:CustomerSignInResult) has any invalid Line Items removed and is [updated](/api/carts-orders-overview#update-a-cart) with the latest prices, taxes, and discounts. During these updates, the following errors can be returned: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) and [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError).
26-
*
27-
* Triggers [Cart merge during sign-in](/../api/customers-overview#cart-merge-during-sign-in).
25+
* If the Customer has multiple active Carts, the anonymous Cart is [merged](/../api/customers-overview#cart-merge-during-sign-in-and-sign-up) into the most recently modified active Cart.
2826
*
2927
* If the Customer exists in the Project but the `stores` field references a different [Store](ctp:api:type:Store), this method returns an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error.
3028
*

packages/platform-sdk/src/generated/client/login/by-project-key-in-store-key-by-store-key-me-login-request-builder.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@ export class ByProjectKeyInStoreKeyByStoreKeyMeLoginRequestBuilder {
2828
* - If the Customer does not have a Cart, the most recently modified anonymous cart becomes the Customer's Cart.
2929
* - If the Customer already has a Cart, the most recently modified anonymous cart is handled according to [AnonymousCartSignInMode](ctp:api:type:AnonymousCartSignInMode).
3030
*
31-
* A Cart returned in the [CustomerSignInResult](ctp:api:type:CustomerSignInResult) has any invalid Line Items removed and is [updated](/api/carts-orders-overview#update-a-cart) with the latest prices, taxes, and discounts. During these updates, the following errors can be returned: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) and [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError).
32-
*
3331
* If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned.
3432
*
3533
*/

packages/platform-sdk/src/generated/client/login/by-project-key-login-request-builder.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,9 @@ export class ByProjectKeyLoginRequestBuilder {
1919
}
2020
) {}
2121
/**
22-
* Authenticates a global Customer not associated with a Store.
23-
* For more information, see [Global versus Store-specific Customers](/../api/customers-overview#global-versus-store-specific-customers).
24-
* If the Customer is registered in a Store, use the [Authenticate (sign in) Customer in Store](ctp:api:endpoint:/{projectKey}/in-store/key={storeKey}/login:POST) method.
22+
* Authenticates a global Customer.
2523
*
26-
* Triggers [Cart merge during sign-in](/../api/customers-overview#cart-merge-during-sign-in).
27-
*
28-
* A Cart returned in the [CustomerSignInResult](ctp:api:type:CustomerSignInResult) has any invalid Line Items removed and is [updated](/api/carts-orders-overview#update-a-cart) with the latest prices, taxes, and discounts. During these updates, the following errors can be returned: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) and [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError).
24+
* If the Customer has multiple active Carts, the anonymous Cart is [merged](/../api/customers-overview#cart-merge-during-sign-in-and-sign-up) into the most recently modified active Cart.
2925
*
3026
* If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned.
3127
*

packages/platform-sdk/src/generated/client/login/by-project-key-me-login-request-builder.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ export class ByProjectKeyMeLoginRequestBuilder {
2626
* - If the Customer does not have a Cart yet, the most recently modified anonymous cart becomes the Customer's Cart.
2727
* - If the Customer already has a Cart, the most recently modified anonymous cart is handled in accordance with [AnonymousCartSignInMode](ctp:api:type:AnonymousCartSignInMode).
2828
*
29-
* A Cart returned in the [CustomerSignInResult](ctp:api:type:CustomerSignInResult) has any invalid Line Items removed and is [updated](/api/carts-orders-overview#update-a-cart) with the latest prices, taxes, and discounts. During these updates, the following errors can be returned: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) and [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError).
30-
*
3129
* If an account with the given credentials is not found, an [InvalidCredentials](ctp:api:type:InvalidCredentialsError) error is returned.
3230
*
3331
*/

packages/platform-sdk/src/generated/client/signup/by-project-key-in-store-key-by-store-key-me-signup-request-builder.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,11 @@ export class ByProjectKeyInStoreKeyByStoreKeyMeSignupRequestBuilder {
2121
}
2222
) {}
2323
/**
24-
*
2524
* If used with an optional [access token for an anonymous session](ctp:api:type:AnonymousSession), all Orders and Carts that belong to the `anonymousId` are assigned to the newly created Customer.
2625
*
2726
* If omitted in the request body, the [Customer](ctp:api:type:Customer) `stores` field is set to the [Store](ctp:api:type:Store) specified in the path parameter.
2827
*
29-
* A Cart returned in the [CustomerSignInResult](ctp:api:type:CustomerSignInResult) has any invalid Line Items removed and is [updated](/api/carts-orders-overview#update-a-cart) with the latest prices, taxes, and discounts. During these updates, the following errors can be returned: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) and [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError).
28+
* If the Customer has multiple active Carts, the anonymous Cart is [merged](/../api/customers-overview#cart-merge-during-sign-in-and-sign-up) into the most recently modified active Cart.
3029
*
3130
* Creating a Customer produces the [CustomerCreated](ctp:api:type:CustomerCreatedMessage) Message.
3231
*

packages/platform-sdk/src/generated/models/customer.ts

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -383,13 +383,15 @@ export interface CustomerDraft {
383383
*/
384384
readonly anonymousCartId?: string
385385
/**
386-
* Identifies a [Cart](ctp:api:type:Cart) that will be assigned to the new Customer.
386+
* Assigns the Customer to the specified Cart.
387387
*
388388
*
389389
*/
390390
readonly anonymousCart?: CartResourceIdentifier
391391
/**
392-
* Identifies Carts and Orders belonging to an anonymous session that will be assigned to the new Customer.
392+
* Assigns the Customer to all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList), and [Payments](ctp:api:type:Payment) with the same `anonymousId`.
393+
*
394+
* If `anonymousCart` is provided, this value must match the `anonymousId` of the anonymous [Cart](ctp:api:type:Cart); otherwise, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned.
393395
*
394396
*
395397
*/
@@ -668,7 +670,11 @@ export interface CustomerSignInResult {
668670
readonly customer: Customer
669671
/**
670672
* Cart associated with the Customer.
671-
* If empty, the Customer does not have a Cart assigned.
673+
*
674+
* The Cart is recalculated to remove invalid Line Items and apply the latest prices, taxes, and discounts.
675+
* During these updates, the following errors can be returned: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) and [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError).
676+
*
677+
* For more information, see [Cart updates](/../api/carts-orders-overview#update-a-cart).
672678
*
673679
*
674680
*/
@@ -694,7 +700,7 @@ export interface CustomerSignin {
694700
*/
695701
readonly anonymousCartId?: string
696702
/**
697-
* Identifies a [Cart](ctp:api:type:Cart) that will be assigned to the Customer.
703+
* Assigns the Customer to the specified Cart.
698704
*
699705
*
700706
*/
@@ -707,9 +713,9 @@ export interface CustomerSignin {
707713
*/
708714
readonly anonymousCartSignInMode?: AnonymousCartSignInMode
709715
/**
710-
* If both `anonymousCart` and `anonymousId` are provided, the `anonymousId` on the CustomerSignin must match that of the anonymous [Cart](ctp:api:type:Cart).
711-
* Otherwise a [400 Bad Request](ctp:api:type:InvalidOperationError) `Invalid Operation` error is returned with the message:
712-
* "Cart with the ID cart-id does not have the expected anonymousId.".
716+
* Assigns the Customer to all [Carts](ctp:api:type:Cart), [Orders](ctp:api:type:Order), [ShoppingLists](ctp:api:type:ShoppingList), and [Payments](ctp:api:type:Payment) with the same `anonymousId`.
717+
*
718+
* If `anonymousCart` is provided, this value must match the `anonymousId` of the anonymous [Cart](ctp:api:type:Cart); otherwise, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned.
713719
*
714720
*
715721
*/

references.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -453,3 +453,4 @@ b6d7def74db12344b0e0821407b45a3f214b8bd9
453453
f8b027c8e1b5ba61ace3d3d358b9efc7ad4b93eb
454454
63488aa919cebb6a9a606b287cd525eb7c588e99
455455
12c86075166f683540662d5b7016fa7d48fe45e4
456+
91ef231b5881c329f1c3f405e250106f8473b57e

0 commit comments

Comments
 (0)