fabric Attributes API

Item attributes are the objective and factual descriptions of items that shoppers see when they browse through your site. Attributes may be technical specifications like size, weight, etc., design specifications like color, material, etc., or basic specifications like name, description, and ID. Ites attributes are crucial as they directly influence purchasing decisions. Complete and correct item information help shoppers narrow down their search and filter items with minimal cognitive load.

OpenAPI Specification

fabric-com-attributes-api-openapi.yml Raw ↑
openapi: 3.0.1
info:
  title: Cart Actions Endpoints Attributes API
  description: fabric's **Cart API** lets you add, update, and remove items from your Storefront cart, either as a guest user or as a logged-in user. It also provides functionality to merge carts when you switch from guest user to logged-in user, and apply coupons and other attributes (for example, gift wrapping) to the line items. Additionally, the API supports more advanced tasks such as using multiple carts within a B2B organization, sharing carts, and supporting a unified cart experience for multi-region and multi-brand businesses.<p>The Cart API provides high performance, scalability, multi-tenancy, and configurability to the end-to-end order processing actions that start from the item being added to the cart; through the pre-checkout stage that includes billing, shipping, and payment details; to the checkout stage where the order is processed and confirmed by fabric's Order Management System (OMS)
  contact:
    name: Cart Support
    email: support.cnc@fabric.inc
  license:
    name: fabric API License
    url: https://fabric.inc/api-license
  version: 3.0.0
servers:
- url: https://api.fabric.inc/v3
security:
- bearerAuth: []
tags:
- name: Attributes
  description: Item attributes are the objective and factual descriptions of items that shoppers see when they browse through your site. Attributes may be technical specifications like size, weight, etc., design specifications like color, material, etc., or basic specifications like name, description, and ID. Ites attributes are crucial as they directly influence purchasing decisions. Complete and correct item information help shoppers narrow down their search and filter items with minimal cognitive load.
paths:
  /api-category/v1/category/attribute/bulk:
    post:
      tags:
      - Attributes
      summary: Create, Update and Delete Category Attributes
      description: 'Creates, updates and deletes category attributes. The primary purpose is to create and edit the attributes to be assigned to categories. <br /> **Note**: They are generic category attributes and not specific to a category.'
      operationId: postCategoryAttributeBulk
      security:
      - authorization: []
      - api_key: []
      parameters:
      - $ref: '#/components/parameters/xSiteContent'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BulkAttributeRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BulkAttributeResponse'
        '400':
          description: Client error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClientError'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerError'
  /api-product/v1/product/attribute/bulk:
    post:
      tags:
      - Attributes
      summary: Create Update and Delete Item Attributes
      description: 'Item attributes allow you to define specific characteristics for items. Common examples of attributes include size, color, and material. Well-defined attributes are important because they enable item discovery and make catalog management easier. <br /> This endpoint creates and updates item attributes to be assigned later. <br /> **Note**: <br /> 1) You can add and manage unlimited attributes for your items. Once they are created, they appear as a selectable option on product pages. <br /> 2) In addition, you can assign attributes to items on an individual level or in bulk.'
      operationId: postProductAttributeBulk
      security:
      - authorization: []
      parameters:
      - $ref: '#/components/parameters/xSiteContent'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BulkProductAttributeRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BulkAttributeResponse'
        '400':
          description: Client error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClientError'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerError'
  /api-product/v1/product/attribute-group:
    post:
      tags:
      - Attributes
      summary: Create, Update and Delete Attribute Groups
      description: 'Using attribute groups, you can group various attributes together to make it easier to manage large volume of item information. <br /> Use this endpoint to create, update, or delete attribute groups. <br /> **Note**: In the context of Product Catalog, attribute group is optional. When created, it must have at least one attribute.'
      operationId: modifyAttributeGroups
      security:
      - authorization: []
      parameters:
      - $ref: '#/components/parameters/xSiteContent'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AttributeGroupRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AttributeGroupResponse'
        '400':
          description: Client error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClientError'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerError'
  /api-product/v1/product/attribute-group/search:
    post:
      tags:
      - Attributes
      summary: Find Attribute Groups
      description: Find attribute groups based on the given search criteria. You will get a paginated response, which you can narrow down using filter criteria such as `page` and `size`.
      operationId: searchAttributeGroups
      security:
      - authorization: []
      parameters:
      - $ref: '#/components/parameters/xSiteContent'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AttributeGroupSearchRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AttributeGroupSearchResponse'
        '400':
          description: Client error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClientError'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerError'
  /api-product/v1/product/attribute/mapping/search:
    post:
      tags:
      - Attributes
      summary: Find Attribute Mapping
      description: Searches for attribute mapping based on the given search criteria. You will get a paginated response, which you can narrow down using filter criteria such as `page` and `size`.
      operationId: searchAttributeMappings
      security:
      - authorization: []
      parameters:
      - $ref: '#/components/parameters/xSiteContent'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AttributeMappingSearch'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AttributeMappingPaginationResponse'
        '400':
          description: Client error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClientError'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerError'
  /api-product/v1/product/attribute/mapping:
    post:
      tags:
      - Attributes
      summary: Create and Update Attribute Mappings
      description: Set your attribute mapping to begin configuring your catalog. You can update the mappings only if there are no SKUs present in the catalog.
      security:
      - authorization: []
      parameters:
      - $ref: '#/components/parameters/xSiteContent'
      operationId: modifyAttributeMappings
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AttributeMappingModify'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AttributeMappingResponse'
        '400':
          description: Client error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClientError'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerError'
  /v2/attributes/import:
    post:
      summary: Import Attributes from CSV
      description: 'Upload a CSV file to import attribute definitions for the specified brand/domain. The import is processed asynchronously.


        **Expected CSV columns**

        - **attribute_name** (required): Attribute display name

        - **attribute_key** (optional): Machine-readable key

        - **description** (optional): Attribute description

        - **data_type** (optional): Data type

        - **scope** (optional): Attribute scope

        - **enum_values** (optional): Allowed values, pipe-delimited (e.g. `S|M|L`)

        - **allow_ai_content** (optional): Allow AI to generate values (`true`/`false`)

        - **source** (optional): `MERCHANT` or `GOLD_STANDARD`

        - **guideline_reason** (optional): Guidance for AI enrichment

        '
      operationId: importAttributes
      parameters:
      - $ref: '#/components/parameters/DomainHeader'
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - file
              properties:
                file:
                  type: string
                  format: binary
                  description: CSV file containing attribute definitions.
                name:
                  type: string
                  description: Human-friendly import name.
                  example: Spring attributes import
      responses:
        '202':
          description: Import accepted for asynchronous processing
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AttributeImportAcceptedResponse'
              example:
                import_id: e2716438-b763-4be8-82d2-36abe0cb92b1
                name: attribute_test.csv
                status: PENDING
                total_rows: 36
                processed_rows: 0
                created_count: 0
                updated_count: 0
                skipped_count: 0
                failed_count: 0
                input_filename: attribute_test.csv
                input_file_url: null
                error_file_url: null
                error_message: null
                errors: []
                started_at: null
                completed_at: null
                created_at: '2026-03-12T18:04:03.879876Z'
        '400':
          description: Bad request - invalid CSV or missing file
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
        '401':
          description: Unauthorized - missing or invalid token
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
      tags:
      - Attributes
  /v2/attributes/import/{import_id}:
    get:
      summary: Get Attribute Import Status
      description: Retrieve the current status and results of an attribute import created using `POST /v2/attributes/import`.
      operationId: getAttributeImportStatus
      parameters:
      - $ref: '#/components/parameters/DomainHeader'
      - name: import_id
        in: path
        required: true
        description: Import ID returned from `POST /v2/attributes/import`.
        schema:
          type: string
          format: uuid
          example: e2716438-b763-4be8-82d2-36abe0cb92b1
      responses:
        '200':
          description: Import status
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AttributeImportStatusResponse'
              example:
                import_id: e2716438-b763-4be8-82d2-36abe0cb92b1
                name: attribute_test.csv
                status: COMPLETED
                total_rows: 36
                processed_rows: 36
                created_count: 35
                updated_count: 0
                skipped_count: 0
                failed_count: 1
                input_filename: attribute_test.csv
                input_file_url: https://example.com/input.csv
                error_file_url: https://example.com/errors.csv
                error_message: null
                errors:
                - 'Row 35: invalid data_type ''BOOLREAN'''
                started_at: '2026-03-12T18:04:03.998437Z'
                completed_at: '2026-03-12T18:04:04.724584Z'
                created_at: '2026-03-12T18:04:03.879876Z'
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
        '404':
          description: Import not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
      tags:
      - Attributes
components:
  schemas:
    AttributeGroupSearchRequest:
      type: object
      properties:
        page:
          description: Page number to be retrieved
          example: 0
          type: number
        size:
          description: Number of records (attribute groups) per page
          example: 10
          type: number
        include:
          type: object
          properties:
            attributes:
              type: boolean
              description: 'true: Includes attributes <br /> false: Excludes attributes'
        match:
          type: object
          properties:
            target:
              description: Search target. Currently, supports only ITEM.
              example: ITEM
              type: string
            or:
              type: array
              items:
                type: object
                properties:
                  name:
                    description: Attribute group name
                    example: weight
                    type: string
        sort:
          type: array
          items:
            type: object
            properties:
              field:
                description: Field on which the results must be sorted
                example: priorityOrder
                type: string
              direction:
                description: Direction (ascending or descending) or sorting the response
                example: DESC
                type: string
                enum:
                - ASC
                - DESC
    ClientError:
      type: object
      properties:
        code:
          description: Error code for machine consumption
          type: string
          example: 400
        message:
          description: Human-readable error description
          type: string
          example: Client error
    BulkProductAttributeRequest:
      type: array
      items:
        type: object
        properties:
          action:
            type: string
            description: 'Action to perform. `id` is required only for `UPDATE`, or `DELETE` (not for CREATE). <br /> **Note**: `CREATE` action replaces any existing item attribute with the same name, if one already exists.'
            enum:
            - CREATE
            - UPDATE
            - DELETE
            example: UPDATE
          id:
            description: A 24-character system-generated attribute ID
            type: string
            example: 621c1122ff2e4507c199b75d
          name:
            description: Attribute name, which is visible on all relevant Product Catalog pages.
            type: string
            example: Weight
          locales:
            type: array
            items:
              type: object
              properties:
                locale:
                  type: string
                  description: Language locale
                  example:
                  - fr-ca
                  - es-us
                name:
                  type: string
                  description: Localized value of 'name' for this attribute
                  example: le poids
          description:
            description: Attribute description
            type: string
            example: Example description.
          mapping:
            description: 'Attribute mapping of item. This corresponds to the `Attribute Mapping` settings of Product Catalog: `sku`, `title`, `image`, `active`, `isVariant`. <br /> **Note**: Most attributes do not have a mapping, in which case this will be null. <br /> **Warning**: Exercise caution while adding or removing mappings of attributes, as it could lead to bad data.'
            type: string
            example: title
          type:
            description: Attribute type
            type: string
            enum:
            - TEXT
            - BOOLEAN
            - SERIAL
            - DECIMAL
            - INTEGER
            - DATETIME
            - OPTIONS
          textSubType:
            description: Conditionally required sub-type for `TEXT` attribute type
            type: string
            enum:
            - SMALL_TEXT
            - TEXT_AREA
            - HTML
          serialStart:
            description: Conditionally required to indicate the starting value of `SERIAL` attribute type. When enabled, the subsequent attribute values increment by 1.
            type: number
            example: 1
          optionsType:
            description: Conditionally required to indicate the selectable values for the `OPTIONS` attribute type
            type: string
            enum:
            - TEXT
            - BOOLEAN
            - DECIMAL
            - INTEGER
            - DATETIME
          format:
            description: Attribute format. Currently used only for the attribute type `DATETIME`.
            type: string
            example: YYYY-MM-DD
          formula:
            description: 'JavaScript expression to dynamically compute the attribute''s value. The type returned must match the attribute''s type. If the attribute is weight, this formula helps calculate the weight. <br /> **Note**: When this is provided, `validation` is ignored.'
            type: string
            example: '`${item.weightValue} ${item.weightUnit}`'
          validation:
            type: object
            properties:
              required:
                description: 'true: Attribute is mandatory <br /> false: Attribute is optional'
                type: boolean
              inheritable:
                description: 'true: Parent attributes inherited to children items <br /> false: Parent attributes not inherited to children items'
                type: boolean
              inverse:
                description: 'true: Inverts existing validation (example - requires that the validation does not pass) <br /> false: Follows existing validation'
                type: boolean
              unique:
                description: 'true: Specified value is unique across all items or nodes <br /> false: Specified value is not unique'
                type: boolean
              exact:
                description: Specified value must exactly match this value
                oneOf:
                - type: string
                - type: number
                - type: boolean
              attributeTypes:
                description: Attribute types
                type: array
                example:
                - Serial
                - Integer
                items:
                  type: string
                  enum:
                  - TEXT
                  - BOOLEAN
                  - SERIAL
                  - DECIMAL
                  - INTEGER
                  - ASSET
                  - DATETIME
                  - RESOURCE
                  - DYNAMIC_LOV
              contains:
                description: Specified value must contain this string
                type: string
                example: Demo
              startWith:
                description: Sequence should start with this value
                type: number
                example: 1
              incrementBy:
                description: Sequence should increment by this value
                type: number
                example: 1
              range:
                description: Specified range of values must be between this min and/or max
                type: object
                properties:
                  min:
                    description: Specified value must be greater than or equal to this value
                    oneOf:
                    - type: string
                    - type: number
                  max:
                    description: Specified value must be less than or equal to this value
                    oneOf:
                    - type: string
                    - type: number
              formula:
                description: JavaScript expression to determine if the value matches
                type: string
                example: value < 10 || value > 20
              oneOf:
                description: Matches the value if it is one of these
                oneOf:
                - type: array
                  items:
                    type: string
                - type: array
                  items:
                    type: number
                - type: array
                  items:
                    type: boolean
    AttributeMappingModify:
      type: object
      properties:
        mappings:
          type: array
          items:
            type: object
            properties:
              attributeId:
                description: Attribute ID
                type: string
                example: ATTR1234
              mapping:
                description: Attribute mapping
                type: string
                example: SKU
              name:
                description: Name of the attribute mapping
                type: string
              description:
                description: Description of the attribute mapping
                type: string
                example: Item SKU
              validation:
                $ref: '#/components/schemas/AttributeValidation'
              required:
                description: 'true: Mapping is mandatory <br /> false: Mapping is optional'
                type: boolean
    StatusResponse:
      type: object
      properties:
        code:
          description: Status code
          type: string
        type:
          description: Status type
          type: string
          enum:
          - ATTRIBUTE
          - ATTRIBUTE_VALUE
          - ITEM
          - BUNDLE
          - NODE
          - HIERARCHY
        source:
          description: Status source
          type: string
          enum:
          - PIM
          - WAM
        name:
          description: Status name
          type: string
        description:
          description: Status description
          type: string
        createdOn:
          description: Time of file creation
          type: string
          format: date-time
        createdBy:
          description: User ID that created the file
          type: string
          example: broma0
        modifiedOn:
          type: string
          format: date-time
          description: Time when file was last modified
        modifiedBy:
          type: string
          example: broma0
          description: User ID that last modified the file
    AttributeMappingResponse:
      type: object
      properties:
        attributeId:
          description: A 24-character system-generated attribute ID
          type: string
          example: 62e2ae29c3004a000950ad5f
        attribute:
          $ref: '#/components/schemas/AttributeResponse'
          description: 'Represents the mapped attributes. Only populated when `include.attribute` is true. <br /> **Note**: Not applicable for an attribute mapping  modify request'
        mapping:
          description: Attribute mapping
          type: string
          example: SKU
        target:
          description: Returns attribute mapping for the specified target
          type: string
          example: ITEM
        name:
          description: Name of attribute mapping
          type: string
          example: Item SKU
        description:
          description: Description for attribute mapping
          type: string
          example: Item SKU
        required:
          description: 'true: Mapping is mandatory; <br /> false: mapping is optional'
          type: boolean
        validation:
          $ref: '#/components/schemas/AttributeValidation'
        createdOn:
          description: Time of attribute creation (UTC format)
          type: string
          format: date-time
          example: '2021-09-23T17:47:04.231Z'
        createdBy:
          description: User ID that created item attribute
          type: string
          example: broma0
        modifiedOn:
          description: Time of when the attribute was last modified
          type: string
          format: date-time
        modifiedBy:
          description: User ID that last modified item attribute
          type: string
          example: broma0
    AttributeMappingSort:
      description: Sorting preference
      type: array
      items:
        type: object
        description: Individual fields to sort
        properties:
          field:
            type: string
            enum:
            - createdOn
            - updatedOn
            - mapping
            description: The field to sort must be specified. Sorting is based on the attribute's *raw* value.
          direction:
            type: string
            enum:
            - ASC
            - DESC
            description: Sorting direction
    AttributeImportStatusResponse:
      type: object
      required:
      - import_id
      - status
      - total_rows
      - processed_rows
      - created_at
      properties:
        import_id:
          type: string
          format: uuid
        name:
          type: string
          example: attribute_test.csv
        status:
          type: string
          example: COMPLETED
        total_rows:
          type: integer
          example: 36
        processed_rows:
          type: integer
          example: 36
        created_count:
          type: integer
          example: 35
        updated_count:
          type: integer
          example: 0
        skipped_count:
          type: integer
          example: 0
        failed_count:
          type: integer
          example: 1
        input_filename:
          type: string
          example: attribute_test.csv
        input_file_url:
          type: string
          format: uri
          nullable: true
          example: https://example.com/input.csv
        error_file_url:
          type: string
          format: uri
          nullable: true
          example: https://example.com/errors.csv
        error_message:
          type: string
          nullable: true
          example: null
        errors:
          type: array
          items:
            type: string
          example:
          - 'Row 35: invalid data_type ''BOOLREAN'''
        started_at:
          type: string
          format: date-time
          nullable: true
        completed_at:
          type: string
          format: date-time
          nullable: true
        created_at:
          type: string
          format: date-time
    BulkAttributeRequest:
      type: array
      items:
        type: object
        required:
        - type
        - name
        - action
        properties:
          action:
            type: string
            enum:
            - CREATE
            - UPDATE
            - DELETE
            example: UPDATE
            description: 'Action type. <br /> **Note**: <br /> 1) Attribute ID is required only for `UPDATE` and `DELETE` actions (not for CREATE). <br /> 2) `CREATE` action replaces any existing category attribute with the same name.'
          id:
            description: A 24-character system-generated attribute ID
            example: 61ba11691a29d52cb2842541
            type: string
          name:
            description: Attribute name
            example: weight
            type: string
          description:
            description: Accurate description of the attribute and what it represents
            example: Item weight, in KG
            type: string
          type:
            description: Supported attribute types for the attribute
            example: INTEGER
            type: string
            enum:
            - TEXT
            - BOOLEAN
            - SERIAL
            - DECIMAL
            - INTEGER
            - DATETIME
            - OPTIONS
          textSubType:
            description: Conditionally required for `TEXT` attribute type
            example: HTML
            type: string
            enum:
            - SMALL_TEXT
            - TEXT_AREA
            - HTML
          serialStart:
            description: Conditionally required to indicate the starting value of `SERIAL` attribute type. When enabled, the subsequent attribute values increment by 1.
            example: 1000
            type: number
          optionsType:
            description: Conditionally required to indicate the selectable values for `OPTIONS` attribute type
            type: string
            example: DATETIME
            enum:
            - TEXT
            - BOOLEAN
            - DECIMAL
            - INTEGER
            - DATETIME
          format:
            description: Attribute format. Currently used only for `DATETIME` attribute type.
            type: string
            example: YYYY-MM-DD
          formula:
            description: 'JavaScript expression to dynamically compute the attribute value. The data type returned by this expression must match the attribute''s data type. <br /> **Note**: When this is provided, `validation` is ignored.'
            type: string
            example: '`${item.weightValue} ${item.weightUnit}`'
          validation:
            type: object
            properties:
              required:
                description: 'true: Attribute is mandatory <br /> false: Attribute is optional'
                type: boolean
              inheritable:
                description: 'true: Parent attributes inherited to children items <br /> false: Parent attributes not inherited to children items'
                type: boolean
                example: true
              inverse:
                description: 'true: Inverts existing validation (example - requires that the validation does not pass) <br /> false: Follows existing validation'
                type: boolean
              unique:


# --- truncated at 32 KB (59 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/fabric-com/refs/heads/main/openapi/fabric-com-attributes-api-openapi.yml