Constructors

Properties

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

Methods

  • Deletes the Customer in a Store. Returns a 200 OK status if successful.

    A [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned in the following scenarios:
    
    - If no Customer exists with the `id` specified in the [customer:{id}](/scopes#composable-commerce-oauth) scope.
    - If the Customer exists but is associated with a different Store than what is specified in the `manage_my_profile:{projectKey}:{storeKey}` scope.
    

    Parameters

    • methodArgs: {
          headers?: { [key: string]: string | string[] };
          queryArgs: { version: number; [key: string]: QueryParam };
      }

    Returns ApiRequest<Customer>

  • Returns a Customer for a given Query Predicate in a Store. Returns a 200 OK status if successful.

    A [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned in the following scenarios:
    
    - If no Customer exists in the Store for the given Query Predicate.
    - If a Customer exists in the Store for the given Query Predicate, but does not have an `id` value that matches the [customer:{id}](/scopes#composable-commerce-oauth) scope.
    - If a Customer exists for the given Query Predicate but is associated with a different Store than what is specified in the `manage_my_profile:{projectKey}:{storeKey}` scope.
    

    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<Customer>

  • Updates the Customer in a Store. Returns a 200 OK status if successful.

    A [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned in the following scenarios:
    
    - If no Customer exists with the `id` specified in the [customer:{id}](/scopes#composable-commerce-oauth) scope.
    - If the Customer exists but is associated with a different Store than what is specified in the `manage_my_profile:{projectKey}:{storeKey}` scope.
    

    Parameters

    • methodArgs: { body: MyCustomerUpdate; headers?: { [key: string]: string | string[] } }

    Returns ApiRequest<Customer>