Typescript SDK Type Docs
    Preparing search index...

    Class ByProjectKeyInStoreKeyByStoreKeyCartsCustomerIdByCustomerIdMergeRequestBuilder

    Index

    Constructors

    Properties

    Methods

    Constructors

    Properties

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

    Methods

    post

    • post(
          methodArgs: {
              body: MergeCartDraft;
              headers?: { [key: string]: string | string[] };
          },
      ): ApiRequest<Cart>

      Merges items from an anonymous Cart into the most recently modified active Cart of a Customer. If no active Cart exists, the anonymous Cart becomes the Customer's active Cart.

      If the Cart exists in the Project but does not have a `store` specified, or the `store` field references a different Store, a [ResourceNotFound](ctp:api:type:ResourceNotFoundError) error is returned.
      
      For more information about merge mode behaviors, merge rules, and tax recalculation, see [Merge a Cart](/../api/carts-orders-overview#merge-a-cart).
      

      Parameters

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

      Returns ApiRequest<Cart>