Skip to main content

Gets all authorized catalog rules

GET 

/catalogs/rules

Retrieves all authorized catalog rules.

Filtering

This endpoint supports filtering. For general filtering syntax, see Filtering. The following operators and attributes are supported.

OperatorDescriptionSupported AttributesExample
InChecks if the values are included in the specified string. If they are, the condition is true.idfilter=in(id,some-id)

Request

Query Parameters

    filter string

    This endpoint supports filtering. See Filtering.

    page[limit] int64

    Possible values: >= 1

    The maximum number of records per page for this response. You can set this value up to 100. If no page size is set, the page length store setting is used.

    page[offset] int64

    Possible values: <= 10000

    The current offset by number of records, not pages. Offset is zero-based. The maximum records you can offset is 10,000. If no page size is set, the page length store setting is used.

Responses

The list of catalog rules.

Schema
    meta object

    Contains the results for the entire collection.

    results object

    Total number of results for the entire collection.

    total int64

    Total number of results for the entire collection.

    page object
    limit int64

    The maximum number of records for all pages.

    offset int64

    The current offset by number of pages.

    current int64

    The current number of pages.

    total int64

    The total number of records for the entire collection.

    data object[]required
  • Array [
  • id stringrequired

    The catalog rule ID. Use this to get, modify, or delete the catalog rule.

    attributes objectrequired
    name stringrequired

    The name of a catalog rule. The name must not contain any spaces.

    description string

    A brief description of the purpose of a catalog rule.

    account_ids string[]

    The list of accounts who are eligible to see this catalog. If this field is empty, the rule matches all accounts.

    customer_ids string[]

    The list of customers who are eligible to see this catalog. If empty, the rule matches all customers.

    channels string[]

    The list of channels in which this catalog can be displayed. A channel is the shopping experience, such as a mobile app or web storefront. If empty, the catalog rule matches all channels. The channel will eventually be included in the bearer token that is used for authorization, but currently, you must set the EP-Channel header in your requests.

    tags string[]

    A list of user-defined tags that can be used to further restrict the eligibility criteria for this rule. Requests populate the catalog rule tag using the EP-Context-Tag header.

    schedules object[]

    Specifies a time period when a catalog is displayed, such as on a specific date or during summer. Requests populate the rule tag using the EP-Context-Tag header.

    The schedules attribute must include the following.

    • valid_from matches the date and time that the catalog is displayed from.
    • valid_to matches the date and time the catalog is displayed to.

    Commerce runs on UTC time.

    You can offset the timezone by adding the offset to the end of the date and time. For example, a catalog which contains a sale hierarchy that should appear for a set timeframe may be scheduled to publish on a given date and time within a given timezone. For instance, a sale that should begin on 1st of June 2022 05:00 ET and end on the 15th of June 2022 at 23:50 PT would have a valid schedule of "valid_from": "2022-06-01T05:00:00.000-05:00", "valid_to": "2022-06-15T11:59:99.000-08:00".

  • Array [
  • valid_from date-timenullable

    Matches the date and time that the catalog is displayed from.

    valid_to date-timenullable

    Matches the date and time the catalog is displayed to.

  • ]
  • catalog_id stringrequired

    The unique identifier of a catalog.

    created_at date-timerequired

    The date and time a catalog rule was created.

    updated_at date-timerequired

    The date and time a catalog release is updated.

    type stringrequired

    Possible values: [catalog_rule]

    This represents the type of object being returned. Always catalog_rule.

  • ]
  • links object

    Links allow you to move between requests.

    self urinullable

    Single entities use a self parameter with a link the specific resource.

    first urinullable

    Always the first page.

    last urinullable

    This is null if there is only one page.

    prev urinullable

    This is null if there is only one page.

    next urinullable

    This is null if there is only one page.

Loading...