Typescript SDK Type Docs
    Preparing search index...

    Class ByProjectKeyInStoreKeyByStoreKeyCustomersRequestBuilder

    Index

    Constructors

    Properties

    args: {
        baseUri?: string;
        executeRequest: executeRequest;
        pathArgs: { projectKey: string; storeKey: string };
    }

    Methods

    • Parameters

      • OptionalmethodArgs: {
            headers?: { [key: string]: string | string[] };
            queryArgs?: {
                expand?: string | string[];
                limit?: number;
                offset?: number;
                sort?: string | string[];
                where?: string | string[];
                withTotal?: boolean;
                [key: string]: QueryParam;
            };
        }

      Returns ApiRequest<CustomerPagedQueryResponse>

    post

    • post(
          methodArgs: {
              body: CustomerDraft;
              headers?: { [key: string]: string | string[] };
              queryArgs?: { expand?: string | string[]; [key: string]: QueryParam };
          },
      ): ApiRequest<CustomerSignInResult>

      When using this endpoint, if omitted, the Customer stores field is set to the Store specified in the path parameter.

      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.
      
      Allows converting an anonymous Cart to the active Cart of a Customer with [cart merge](/../api/customers-overview#cart-merge-during-sign-in-and-sign-up).
      If the Customer has multiple active Carts, the anonymous Cart is merged into the most recently modified active Cart.
      
      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.
      

      Parameters

      • methodArgs: {
            body: CustomerDraft;
            headers?: { [key: string]: string | string[] };
            queryArgs?: { expand?: string | string[]; [key: string]: QueryParam };
        }

      Returns ApiRequest<CustomerSignInResult>