GET Get category pinning rules
GET /commerce/management/webstores/{webstoreId}/search/category-pinning-rules
Operation ID: getSearchCategoryPinningRules. Tags: CategoryPinningRulesCollection.
Collection of category pinning rules configured for a web store.
Returns a paginated list of category pinning rules for the specified web store.
To page through results, pass pageSize and pageToken. Get pageToken from the pageToken= query parameter in the previous response's nextPageUrl and use that value, not the full URL. Each response includes the count, currentPageUrl, nextPageUrl, and sortOrder fields alongside the categoryPinningRules array. On the last page, nextPageUrl is null.
A web store can have up to 100 category pinning rules, so a request with pageSize=100 returns a web store's rules in a single page.
Parameters
webstoreId(path, string (Id), required) The ID of the web store to operate on.
Example:0ZExx000000004sGAA.pageToken(query, string) Opaque cursor that identifies the page of results to return. To get the next page, use thepageTokenvalue from the previous response'snextPageUrl. If you don't specify a value, the first page is returned.pageSize(query, integer) Number of rules to return per page. Valid values are from 1 through 100. If you don't specify a value, the default size is 50.
Default:50. Minimum: 1. Maximum: 100. Example:50.
Responses
- 200
The web store's category pinning rules. Returns an empty
categoryPinningRulesarray when the web store has no rules.Media type:
application/json. Schema:SearchCategoryPinningRulesCollectionOutputRepresentation.Example: CollectionResponse Collection of category pinning rules
{ "categoryPinningRules": [ { "id": "1pJxx0000004C92EAE", "name": "Holiday Drill Promotion", "categoryId": "0ZGxx0000004CaGGAU", "locales": [ "en_US" ], "active": true, "startDate": "2026-12-01T00:00:00.000Z", "endDate": "2026-12-31T23:59:59.000Z", "pins": [ { "pinnedProductId": "01txx0000006i2SAAQ", "position": 1 }, { "pinnedProductId": "01txx0000006i2TAAQ", "position": 2 } ] } ], "count": 1, "currentPageUrl": "/services/data/v67.0/commerce/management/webstores/0ZExx000000004sGAA/search/category-pinning-rules?pageSize=50", "nextPageUrl": null, "sortOrder": "createdDate ASC" }Example: EmptyCollectionResponse Web store has no category pinning rules
{ "categoryPinningRules": [], "count": 0, "currentPageUrl": "/services/data/v67.0/commerce/management/webstores/0ZExx000000004sGAA/search/category-pinning-rules?pageSize=50", "nextPageUrl": null, "sortOrder": "createdDate ASC" } - 400
The request failed validation of a pagination parameter.
errorCodeisINVALID_API_INPUTwhenpageTokencan't be decoded, orLIMIT_EXCEEDEDwhenpageSizeis outside the range 1–100.Media type:
application/json. Schema:ErrorRepresentationList.Example: InvalidPageToken pageToken value isn't a valid pagination cursor
[ { "errorCode": "INVALID_API_INPUT", "message": "Specify a valid page token. The value 'not-base64!' isn't a valid pagination cursor; pass a token returned in a previous response's nextPageUrl, or omit the parameter to start from the first page." } ]Example: PageSizeOutOfRange pageSize is outside the range 1–100
[ { "errorCode": "LIMIT_EXCEEDED", "message": "Specify a pageSize from 1 through 100. The value specified was 0." } ] - 403
The user doesn't have merchandiser permission, or category pinning isn't enabled for the org.
Media type:
application/json. Schema:ErrorRepresentationList.Example: InsufficientAccess User isn't a store merchandiser
[ { "errorCode": "INSUFFICIENT_ACCESS", "message": "You or your org doesn't have the required privileges." } ]Example: FeatureNotEnabled Category pinning isn't enabled for the org
[ { "errorCode": "INSUFFICIENT_ACCESS", "message": "You or your org don't have access to this feature." } ] - 404
The specified web store ID wasn't found.
Media type:
application/json. Schema:ErrorRepresentationList.Example: WebStoreNotFound Web store ID not found
[ { "errorCode": "WEBSTORE_NOT_FOUND", "message": "Specify a valid WebStore ID." } ] - 500
An unexpected error occurred on the server.
Media type:
application/json. Schema:ErrorRepresentationList.Example: UnknownException Unexpected error
[ { "errorCode": "UNKNOWN_EXCEPTION", "message": "An internal error occurred while processing this request." } ]