> ## Documentation Index
> Fetch the complete documentation index at: https://developer.jtl-software.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Global Attributes

> Create or update global attribute. Global attributes not depending on categories and are visible for offers in
a global scope. Use these kind of attributes to define channel specific needs.




## OpenAPI

````yaml /openapi/scx/channel.json put /v1/channel/attribute/global
openapi: 3.0.2
info:
  title: JTL-Channel API
  version: 1.0.0
  x-logo:
    url: https://scx-sandbox.ui.jtl-software.com/docs/scx.png
  description: >
    JTL-Channel API is a REST-based API that helps a Channel Integrator to
    connect Marketplace with the JTL-Wawi 

    ERP System.


    # Key Features


    With the JTL-Channel API, you can:

      * Describe connected Marketplace Data Structure by providing Category and Attribute Data
      * Manage Product and Offer Listings
      * Manage Orders 
      * Handle the Post Order Process

    # Development Guide


    There is a detailed development guide available at
    [developer.jtl-software.com](https://developer.jtl-software.com/products/marketplaces/scx-channel-api/change_log).
servers:
  - url: https://scx-sbx.api.jtl-software.com
    description: Sandbox
  - url: https://scx.api.jtl-software.com
    description: Production
security: []
tags:
  - name: Seller
    description: |
      Seller Management
  - name: Channel
    description: Meta channel routes
  - name: Notification
    description: Channel notifications
  - name: Supported Prices
    description: Price type management
  - name: Meta
    description: meta
  - name: Attributes
    description: Channel attributes
  - name: Categories
    description: Channel categories
  - name: Order
    description: Orders
  - name: Return
    description: Order returns
  - name: Events
    description: SCX events
  - name: Offer
    description: Channel offers
  - name: Report
    description: SCX reports
  - name: Ticket
    description: Channel tickets
  - name: Stock Updates
    description: Stock update operations
paths:
  /v1/channel/attribute/global:
    put:
      tags:
        - Attributes
      summary: Global Attributes
      description: >
        Create or update global attribute. Global attributes not depending on
        categories and are visible for offers in

        a global scope. Use these kind of attributes to define channel specific
        needs.
      operationId: CreateGlobalAttributes
      parameters:
        - $ref: '#/components/parameters/ContentEncodingGzip'
      requestBody:
        $ref: '#/components/requestBodies/GlobalAttributes'
      responses:
        '201':
          description: Global attribute created
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/AccessForbidden'
        '404':
          $ref: '#/components/responses/ResourceNotFound'
        '500':
          $ref: '#/components/responses/ServerError'
      security:
        - ChannelAuth: []
components:
  parameters:
    ContentEncodingGzip:
      in: header
      name: Content-Encoding
      description: >
        Use the Content-Encoding: gzip when sending JSON requestBody as
        compressed payload. This is recommended when

        creating huge category trees. There is a limit of 32 MB on this route.
      schema:
        type: string
        enum:
          - gzip
      required: false
  requestBodies:
    GlobalAttributes:
      description: >-
        List of attributes that apply to all sellers and listings on the channel
        (global scope).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/AttributeList'
  responses:
    BadRequest:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseList'
          example:
            errorList:
              - code: VAL100
                message: Required field sellerId not found
                severity: error
                hint: Check the field `sellerId` — it must be a non-empty string.
    AccessForbidden:
      description: Access forbidden, invalid or unknown Token was used.
    ResourceNotFound:
      description: Requested resource not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseList'
          example:
            errorList:
              - code: GEN404
                message: Not found
                severity: error
                hint: null
    ServerError:
      description: Unexpected Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseList'
          example:
            errorList:
              - code: GEN500
                message: Internal Server Error
                severity: error
                hint: null
  schemas:
    AttributeList:
      type: object
      properties:
        attributeList:
          type: array
          items:
            $ref: '#/components/schemas/Attribute'
    ErrorResponseList:
      type: object
      properties:
        errorList:
          nullable: true
          type: array
          example:
            - code: GEN700
              message: Seller SELLER_4711 does not exist on channel kaufland.
              severity: error
              hint: i9n-order22
          items:
            title: Error
            type: object
            properties:
              code:
                type: string
                example: GEN700
              message:
                type: string
                example: Seller SELLER_4711 does not exist on channel kaufland.
              severity:
                type: string
                enum:
                  - error
                  - warning
                  - info
                default: error
              hint:
                type: string
                nullable: true
                example: i9n-order22
    Attribute:
      type: object
      required:
        - attributeId
        - displayName
      properties:
        attributeId:
          $ref: '#/components/schemas/AttributeId'
        displayName:
          description: >
            Display name is used to display the attribute inside a User
            Interface.
          type: string
          example: Brand
          maxLength: 150
        isMultipleAllowed:
          description: |
            Define if there is more than one value allowed for this attribute.
          type: boolean
          example: false
          default: false
        type:
          description: >
            Attribute type decribe which kind of data is expecet for a
            particular attribute.


            * Type **smalltext** is considerd a plain text any may not exceed
            more than 255 characters.

            * Type **text** is considerd plain text and may not exceed a maximum
            length more than 50.000 characters.

            * Type **htmltext** may be used for text where HTML Markup is
            allowed. The maximum lengh schould not exceed

            more than 50.000 characters.

            * Type **date** must follow [ISO
            8601](https://en.wikipedia.org/wiki/ISO_8601) standard with
            Timezone.

            * Type **enum** may provide data with enumValues property

            * Type **image** a attribute with an existing remote File uploaded
            using `POST /v1/seller/offer/file`

            * Type **document** a attribute with an existing remote File
            uploaded using `POST /v1/seller/offer/file`

            * Type **url** must match a URL Schema

            * Type **label** can be used as help text. Requires description to
            be set
          type: string
          enum:
            - smalltext
            - htmltext
            - text
            - integer
            - decimal
            - enum
            - date
            - boolean
            - image
            - document
            - url
            - label
          example: text
          default: smalltext
        values:
          description: >
            A set of possible choices for this specific attribute, in the form
            of a list of possible enumerations.
          type: array
          items:
            $ref: '#/components/schemas/AllowedValue'
          example:
            - value: Beer
            - value: Tee
              display: Wine
        attributeValueValidation:
          description: |
            Regular expression to validate attribute value
          type: string
          example: /^[0-9]{13}$/
          maxLength: 1024
          default: null
        conditionalMandatoryBy:
          description: |
            This property defines conditional mandatory settings
          type: array
          nullable: true
          items:
            type: object
            properties:
              attributeId:
                $ref: '#/components/schemas/AttributeId'
              attributeValues:
                type: array
                items:
                  type: string
                  example: High
        conditionalOptionalBy:
          description: |
            This property defines conditional optional settings
          type: array
          nullable: true
          items:
            type: object
            properties:
              attributeId:
                $ref: '#/components/schemas/AttributeId'
              attributeValues:
                type: array
                items:
                  type: string
                  example: No Frame
        required:
          type: boolean
          example: true
          default: false
        recommended:
          description: >
            A Channel may recommend to have a attribute set when lisitng a offer
            on a certain markatplace to gain more

            visibility and potential transactions.
          type: boolean
          example: false
          default: false
        section:
          description: >
            Optinal attribute to assign a attribute to a specific section. A
            section can be used by a Seller Integration

            to show attributes grouped inside a identical section name.
          type: string
          example: Colors and Appearance
          default: null
        sectionPosition:
          description: >-
            Section position is used to sort attributes in descending order
            inside a section. This property may be used by a Seller Integration
            to determine display sequence in a User Interface.
          type: integer
          default: 0
        isRepeatableSubSection:
          description: >
            A repeatable subSection can be used to group related attributes
            together. Those related set of attributes is 

            repeatable as a group. When thoese attributes are transmitted to the
            SCX-Seller API as Channel Attributes they 

            must have the "group" property filled with a unique identifier. This
            attribute affect the subSection property.

            All subsections with the same name must have the same value
            isRepeatableSubSection and musst not be mixed with

            different settings.
          type: boolean
          example: true
          default: false
          nullable: true
        subSection:
          description: >
            A sub section can be used to build a group of attributes inside a
            section.
          type: string
          example: Length
          default: null
        subSectionPosition:
          description: >
            Sub section position is used to sort attributes in descending order.
            This property may be used by a Seller

            Integration to determine display sequence in a User Interface inside
            identicy **section**s
          type: integer
          example: 0
          default: 0
        description:
          description: |
            Describe the purpose of an Attribute.
          type: string
          example: null
          default: null
        isVariationDimension:
          type: boolean
          example: true
          default: null
        enumValues:
          deprecated: true
          description: |
            (DEPRECATED - use values property instead)
            If the attribte type equals to ENUM this propertie must be set.
          type: array
          items:
            type: string
            maxLength: 200
            example: Blue
    AttributeId:
      description: |
        AttributeId must be a category tree wide unique identifer.
      type: string
      example: '12323'
      minLength: 1
      maxLength: 512
    AllowedValue:
      type: object
      required:
        - value
      properties:
        value:
          description: >
            An enumeration to include in the set. The enumeration bust be
            string-based.

            Example: '1', 'green_l_st'
          type: string
          maxLength: 1024
          minLength: 1
        display:
          description: >
            An optional alias for the enumeration, which will be shown in the
            GUI. If left empty, the value will be shown instead.

            Example: 'Red', 'Light Green + Striped'
          type: string
          maxLength: 1024
          minLength: 1
        sort:
          description: Specifies the order of values
          type: integer
          default: 0
  securitySchemes:
    ChannelAuth:
      description: >
        As a Channel Integrator you will receive a API Refresh Token. With such
        a Refresh Token you

        need to request an Access Token with a limited Lifetime (see POST
        /v1/auth). This Access Token

        must be provided as a Bearer Token in the Authorization Header with
        every request.
      type: http
      scheme: bearer
      bearerFormat: JWT

````