Skip to main content
POST
/
product-attribute-groups
/
search
Find Attribute Groups
curl --request POST \
  --url https://api.fabric.inc/v3/product-attribute-groups/search \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "match": {
    "id": {
      "op": "IN",
      "value": [
        "blue"
      ]
    },
    "name": {
      "op": "IN",
      "value": [
        "blue"
      ]
    },
    "priority": {
      "op": "GTE",
      "value": 1
    },
    "attributeIds": {
      "op": "IN",
      "value": [
        "blue"
      ]
    },
    "createdAt": {
      "op": "RANGE",
      "fromValue": "2022-04-20T10:24:36.162Z",
      "toValue": "2023-04-20T10:24:36.162Z"
    },
    "updatedAt": {
      "op": "RANGE",
      "fromValue": "2022-04-20T10:24:36.162Z",
      "toValue": "2023-04-20T10:24:36.162Z"
    }
  },
  "sort": "+name,-attributesCount",
  "offset": 2,
  "limit": 10
}
'
{
  "data": [
    {
      "id": "59328bf0b5f328bf0b5f3288",
      "name": "Dimensions",
      "description": "Dimensions of a product",
      "priority": 1,
      "attributes": [
        {
          "attributeId": "33328bf0b5f328bf0b5f3288",
          "name": "color",
          "type": "TEXT",
          "localizedProperties": {
            "en-US": {
              "name": "color"
            },
            "en-IN": {
              "name": "colour"
            }
          },
          "isLocalizable": true,
          "isReadOnly": true
        }
      ],
      "attributeCount": 20,
      "updatedBy": "[email protected]",
      "createdAt": "2021-04-20T10:24:36.162Z",
      "updatedAt": "2021-04-20T10:24:36.162Z"
    }
  ],
  "offset": 2,
  "limit": 10,
  "count": 1000
}

Authorizations

Authorization
string
header
required

S2S access token (JWT) from fabric Identity service (during Login)

Headers

x-fabric-tenant-id
string

A header used by fabric to identify the tenant making the request. You must include tenant id in the authentication header for an API request to access any of fabric’s endpoints. You can retrieve the tenant id , which is also called account id, from Copilot. This header is required.

Example:

"517fa9dfd42d8b00g1o3k312"

x-fabric-request-id
string

Unique request ID

Example:

"263e731c-45c8-11ed-b878-0242ac120002"

Body

application/json

Search criteria for attribute group

match
object
required

Specification for matching attributes

sort
string

Criteria to sort the response. Currently, sorting is only supported on createdAt, updatedAt, name, attributesCount and priority. - refers to descending while + refers to ascending order

Example:

"+name,-attributesCount"

offset
integer<int32>
default:0

Number of records to skip before returning records. For example, offset=20, limit=10 returns records 21-30.

Example:

2

limit
integer<int32>
default:10

Maximum number of records per page

Example:

10

Response

OK

Details of attribute groups

data
object[]
offset
integer<int32>
default:0

Number of records to skip before returning records. For example, offset=20, limit=10 returns records 21-30.

Example:

2

limit
integer<int32>
default:10

Maximum number of records per page

Example:

10

count
integer<int32>

Total number of records in the search results

Example:

1000