Typescript SDK Type Docs
    Preparing search index...

    Class ByProjectKeyProductProjectionsRequestBuilder

    Index

    Constructors

    Properties

    Methods

    Constructors

    Properties

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

    Methods

    • Retrieves the projected representation of Products by query predicates.

      By default, this endpoint returns the `current` representation of Products where the `published` flag is `true`.
      If a Product is unpublished (`published=false`), the endpoint returns a [Not Found](/../api/errors#404-not-found) error.
      
      Required access scopes:
      
      - To retrieve the current representation of published Products (published data), the `view_published_products:{projectKey}` scope is required.
      
      - To retrieve the staged representation of Products (draft data) or access unpublished Products, the API Client must have the `view_products:{projectKey}` scope.
      

      Parameters

      • OptionalmethodArgs: {
            headers?: { [key: string]: string | string[] };
            queryArgs?: {
                expand?: string | string[];
                "filter[attributes]"?: string | string[];
                limit?: number;
                localeProjection?: string | string[];
                offset?: number;
                priceChannel?: string;
                priceCountry?: string;
                priceCurrency?: string;
                priceCustomerGroup?: string;
                priceCustomerGroupAssignments?: string | string[];
                priceRecurrencePolicy?: string;
                sort?: string | string[];
                staged?: boolean;
                storeProjection?: string;
                where?: string | string[];
                withTotal?: boolean;
                [key: string]: QueryParam;
            };
        }

      Returns ApiRequest<ProductProjectionPagedQueryResponse>

    • Checks if the current or staged representation of a Product exists for the provided query predicate. Returns a 200 status if any ProductProjections match the query predicate, or a 404 status otherwise.

      Parameters

      • OptionalmethodArgs: {
            headers?: { [key: string]: string | string[] };
            queryArgs?: { where?: string | string[]; [key: string]: QueryParam };
        }

      Returns ApiRequest<void>