Xentral Supplier API

Suppliers represents an information related to providers of goods the company is managing.

OpenAPI Specification

xentral-supplier-api-openapi.yml Raw ↑
openapi: 3.0.0
info:
  title: Xentral Account Supplier API
  version: v0.1
  description: Xentral is an ERP platform.
  contact:
    name: Xentral
    url: https://xentral.com
    email: api@xentral.com
servers:
- url: https://{xentralId}.xentral.biz
  description: Your Xentral Instance
  variables:
    xentralId:
      default: xentral
- url: https://{domain}
  description: Xentral at a custom domain
  variables:
    domain:
      default: xentral.com
security:
- BearerAuth: []
tags:
- name: Supplier
  description: Suppliers represents an information related to providers of goods the company is managing.
paths:
  /api/v1/suppliers:
    get:
      tags:
      - Supplier
      operationId: supplier.list
      summary: List suppliers
      description: Lists existing suppliers
      parameters:
      - name: filter
        in: query
        style: deepObject
        schema:
          oneOf:
          - type: object
            additionalProperties: false
            properties:
              id:
                type: array
                items:
                  type: string
                  pattern: \d+
                  example: '17'
                  description: Resource identifier.
          - type: array
            items:
              type: object
              additionalProperties: false
              properties:
                key:
                  type: string
                  enum:
                  - search
                  - id
                  - name
                  - number
                  - country
                  - zip
                  - city
                  - project
                  - projectName
                  - phone
                  - fax
                  - mobile
                  - email
                  - addressNote
                  - department
                  - subdivision
                  - vatNumber
                  - taxNumber
                  - gln
                  - tag
                  - tagName
                op:
                  type: string
                  enum:
                  - equals
                  - notEquals
                  - in
                  - notIn
                  - exactlyIn
                  - allIn
                  - allNotIn
                  - contains
                  - notContains
                  - startsWith
                  - endsWith
                  - greaterThan
                  - lessThan
                  - is
                  - lessThanOrEquals
                  - greaterThanOrEquals
                value:
                  oneOf:
                  - type: string
                    description: Used for the operations 'equals', 'notEquals', 'contains', 'notContains', 'startsWith', 'endsWith' and 'is'.
                    title: String
                  - type: array
                    description: Used for the operations 'in', 'notIn', 'exactlyIn', 'allIn' and 'allNotIn'.
                    title: Array
                    items:
                      type: string
      - in: query
        name: page
        required: false
        style: deepObject
        schema:
          type: object
          additionalProperties: false
          required:
          - number
          - size
          properties:
            number:
              type: string
              pattern: \d+
              description: Page number should be an integer greater than or equal to 1
            size:
              type: string
              pattern: \d+
              description: Page size should usually be an integer between 10 and 50.
      - name: order
        in: query
        style: deepObject
        schema:
          type: array
          items:
            type: object
            additionalProperties: false
            properties:
              field:
                type: string
                enum:
                - id
                - name
                - number
                - country
                - zip
                - city
                - project
                - projectName
                - telephone
                - fax
                - mobile
                - email
                - addressNote
                - department
                - subdivision
                - vatNumber
                - taxNumber
                - gln
                - tag
                - tagName
              dir:
                type: string
                enum:
                - asc
                - desc
      responses:
        '200':
          description: Supplier list.
          content:
            application/json:
              schema:
                type: object
                additionalProperties: false
                required:
                - data
                - extra
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      additionalProperties: false
                      required:
                      - id
                      - type
                      - general
                      properties:
                        id:
                          type: string
                          pattern: \d+
                          example: '17'
                          description: Resource identifier.
                        type:
                          description: The type of the supplier
                          type: string
                          example: Regular supplier
                        project:
                          description: An optional object with id and name
                          type: object
                          additionalProperties: false
                          required:
                          - id
                          - name
                          nullable: true
                          properties:
                            id:
                              type: string
                              pattern: \d+
                              example: '17'
                              description: Resource identifier.
                            name:
                              type: string
                          example:
                            id: '1337'
                            name: Diamond
                        general:
                          description: The general information of the supplier
                          type: object
                          additionalProperties: false
                          required:
                          - name
                          - address
                          properties:
                            number:
                              type: string
                            fax:
                              type: string
                              nullable: true
                            mobile:
                              type: string
                              nullable: true
                            department:
                              type: string
                            subdivision:
                              type: string
                            vatNumber:
                              type: string
                            taxNumber:
                              type: string
                              nullable: true
                            gln:
                              type: string
                            employeeNumber:
                              type: string
                            honorific:
                              type: string
                            title:
                              type: string
                            name:
                              type: string
                            birthday:
                              type: string
                              nullable: true
                              format: date
                            tags:
                              description: A list of tags
                              type: array
                              items:
                                type: object
                                additionalProperties: false
                                properties:
                                  id:
                                    description: The identifier of the tag
                                    type: string
                                    pattern: \d+
                                    example: '1337'
                                  name:
                                    description: The name of the tag
                                    type: string
                                    example: Active
                                  color:
                                    type: string
                                    pattern: '[a-fA-F0-9]{6}'
                                    example: ff0000
                                    description: 'Hexadecimal color value in 6-digit format without the leading # character.'
                            supplierNumber:
                              type: string
                            phone:
                              type: string
                              nullable: true
                            email:
                              type: string
                            address:
                              type: object
                              additionalProperties: false
                              required:
                              - street
                              - zip
                              - city
                              - state
                              - country
                              - note
                              properties:
                                street:
                                  type: string
                                zip:
                                  type: string
                                city:
                                  type: string
                                state:
                                  type: string
                                  nullable: true
                                country:
                                  type: string
                                note:
                                  type: string
                          example:
                            number: '123456789'
                            fax: null
                            mobile: '987654321'
                            department: Sales
                            subdivision: North Region
                            vatNumber: VAT123456
                            taxNumber: null
                            gln: GLN123456789
                            employeeNumber: EMP001
                            honorific: Mr.
                            title: Sales Manager
                            name: John Doe
                            birthday: null
                            tags:
                            - id: tag1
                              name: Active
                              color: ff0000
                            - id: tag2
                              name: Active
                              color: ff0000
                            supplierNumber: SUP123456
                            phone: null
                            email: johndoe@example.com
                            address:
                              street: Hauptstraße 15
                              zip: '10115'
                              city: Berlin
                              state: null
                              country: DE
                              note: Hauptsitz
                        tags:
                          description: A list of tags
                          type: array
                          items:
                            type: object
                            additionalProperties: false
                            properties:
                              id:
                                type: string
                                pattern: \d+
                                description: Either ID or name and key.
                              key:
                                description: The key of the tag
                                type: string
                              name:
                                description: The name of the tag
                                type: string
                              color:
                                type: string
                                pattern: '[a-fA-F0-9]{6}'
                                example: ff0000
                                description: 'Hexadecimal color value in 6-digit format without the leading # character.'
                        freeFields:
                          description: a list of free fields and their values
                          type: array
                          items:
                            type: object
                            additionalProperties: false
                            properties:
                              id:
                                type: string
                                pattern: \d+
                                example: '17'
                                description: Resource identifier.
                              value:
                                description: The value of the free field
                                type: string
                  extra:
                    type: object
                    required:
                    - totalCount
                    - page
                    additionalProperties: false
                    x-description-ignore: true
                    properties:
                      totalCount:
                        description: the total count of all items
                        type: integer
                        example: 1
                      page:
                        description: The pagination object containing the current page number and size
                        type: object
                        required:
                        - number
                        - size
                        additionalProperties: false
                        properties:
                          number:
                            description: The current page number
                            type: integer
                            example: 1
                          size:
                            description: The size of the pages
                            type: integer
                            example: 10
                        example:
                          number: 1
                          size: 10
                    example:
                      totalCount: 1
                      page:
                        number: 1
                        size: 10
            text/csv:
              schema:
                type: string
        '400':
          description: IETF RFC 9457 Problem API compliant response
          content:
            application/problem+json:
              schema:
                oneOf:
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - violations
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/request-validation
                    title:
                      type: string
                      minLength: 1
                      example: Request payload validation failed.
                    violations:
                      oneOf:
                      - type: array
                        items:
                          type: object
                          example:
                            username:
                            - This value should not be blank.
                            email:
                            - This value is not a valid email address.
                        description: This field will be a mirrored request payload with only invalid fields and values replaced by error messages.
                      - type: object
                        example:
                          _:
                          - This value should contain at most `9` elements.
                        description: This field will be a mirrored request payload with only invalid fields and values replaced by error messages.
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - messages
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/generic-validation
                    title:
                      type: string
                      minLength: 1
                    messages:
                      type: array
                      items:
                        type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - messages
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/conflict
                    title:
                      type: string
                      minLength: 1
                    messages:
                      type: array
                      items:
                        type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - items
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/conflictItems
                    title:
                      type: string
                      minLength: 1
                    items:
                      type: array
                      items:
                        type: object
                        additionalProperties: false
                        required:
                        - id
                        - title
                        - messages
                        properties:
                          id:
                            type: integer
                          title:
                            type: string
                            minLength: 1
                          messages:
                            type: array
                            items:
                              type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - scopes
                  properties:
                    type:
                      type: string
                      enum:
                      - https://developer.xentral.com/reference/problems#token-scopes
                    title:
                      type: string
                      minLength: 1
                    scopes:
                      type: array
                      items:
                        type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - messages
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/generic-validation
                    title:
                      type: string
                      minLength: 1
                    messages:
                      type: object
                      additionalProperties:
                        type: array
                        items:
                          type: string
        '401':
          description: Unable to authenticate the client
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Error message explaining why the request failed.
                    example: 'Missing required scopes: customer:create.'
              example:
                message: 'Missing required scopes: customer:create.'
            text/html:
              schema:
                type: string
                example: Unauthorized
        '403':
          description: Unable to authorize the client
        '404':
          description: Resource was not found or not enough access privileges
        '415':
          description: Resource representation send in the request is not supported.
        '429':
          description: Too many API calls made.
    patch:
      deprecated: true
      tags:
      - Supplier
      operationId: supplier.updateMultiple
      summary: Update multiple suppliers tags
      description: Updates tags for multiple suppliers
      requestBody:
        description: Supplier update multiple request payload
        content:
          application/json:
            schema:
              type: array
              minItems: 1
              items:
                type: object
                additionalProperties: false
                properties:
                  id:
                    type: string
                    pattern: \d+
                    example: '17'
                    description: Resource identifier.
                  tags:
                    description: A list of tags
                    type: array
                    items:
                      type: object
                      additionalProperties: false
                      properties:
                        id:
                          type: string
                          pattern: \d+
                          description: Either ID or name and key.
                          example: '12345'
                        key:
                          description: The key of the tag
                          type: string
                          example: absg378d
                        name:
                          description: The name of the tag
                          type: string
                          example: New
                        color:
                          type: string
                          pattern: '[a-fA-F0-9]{6}'
                          example: ff0000
                          description: 'Hexadecimal color value in 6-digit format without the leading # character.'
            examples:
              Add existing tags to suppliers:
                value:
                - id: '5'
                  tags:
                  - id: '33'
                  - id: '34'
                - id: '6'
                  tags:
                  - id: '39'
                  - id: '40'
      responses:
        '204':
          description: Operation completed successfully, no response body
        '400':
          description: IETF RFC 9457 Problem API compliant response
          content:
            application/problem+json:
              schema:
                oneOf:
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - violations
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/request-validation
                    title:
                      type: string
                      minLength: 1
                      example: Request payload validation failed.
                    violations:
                      oneOf:
                      - type: array
                        items:
                          type: object
                          example:
                            username:
                            - This value should not be blank.
                            email:
                            - This value is not a valid email address.
                        description: This field will be a mirrored request payload with only invalid fields and values replaced by error messages.
                      - type: object
                        example:
                          _:
                          - This value should contain at most `9` elements.
                        description: This field will be a mirrored request payload with only invalid fields and values replaced by error messages.
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - messages
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/generic-validation
                    title:
                      type: string
                      minLength: 1
                    messages:
                      type: array
                      items:
                        type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - messages
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/conflict
                    title:
                      type: string
                      minLength: 1
                    messages:
                      type: array
                      items:
                        type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - items
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/conflictItems
                    title:
                      type: string
                      minLength: 1
                    items:
                      type: array
                      items:
                        type: object
                        additionalProperties: false
                        required:
                        - id
                        - title
                        - messages
                        properties:
                          id:
                            type: integer
                          title:
                            type: string
                            minLength: 1
                          messages:
                            type: array
                            items:
                              type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - scopes
                  properties:
                    type:
                      type: string
                      enum:
                      - https://developer.xentral.com/reference/problems#token-scopes
                    title:
                      type: string
                      minLength: 1
                    scopes:
                      type: array
                      items:
                        type: string
                - type: object
                  additionalProperties: false
                  required:
                  - type
                  - title
                  - messages
                  properties:
                    type:
                      type: string
                      enum:
                      - https://api.xentral.biz/problems/generic-validation
                    title:
                      type: string
                      minLength: 1
                    messages:
                      type: object
                      additionalProperties:
                        type: array
                        items:
                          type: string
        '429':
          description: Too many API calls made.
  /api/v1/suppliers/{id}:
    get:
      tags:
      - Supplier
      operationId: supplier.view
      summary: View supplier
      description: Shows an existing supplier details
      parameters:
      - in: path
        name: id
        required: true
        description: The resource's identifier.
        schema:
          type: string
          pattern: \d+
          example: '17'
          description: Resource identifier.
      responses:
        '200':
          description: Supplier view.
          content:
            application/json:
              schema:
                type: object
                additionalProperties: false
                required:
                - data
                properties:
                  data:
                    description: A supplier resource
                    type: object
                    additionalProperties: false
                    required:
                    - id
                    - type
                    - general
                    properties:
                      id:
                        type: string
                        pattern: \d+
                        example: '17'
                        description: Resource identifier.
                      type:
                        description: The type of the supplier
                        type: string
                        example: Regular supplier
                      general:
                        description: The general information of the supplier
                        type: object
                        additionalProperties: false
                        required:
                        - name
                        - address
                        properties:
                          honorific:
                            description: The honorific of the supplier
                            type: string
                          title:
                            description: The title of the supplier
                            type: string
                          name:
                            description: The name of the supplier
                            type: string
                          birthday:
                            description: The birthday of the supplier
                            type: string
                            format: date
                          address:
                            type: object
                            additionalProperties: false
                            required:
                            - street
                            - zip
                            - city
                            - state
                            - country
                            - note
                            properties:
                              street:
                                type: string
                              zip:
                                type: string
                              city:
                                type: string
                              state:
                                type: string
                                nullable: true
                              country:
                                type: string
                              note:
                                type: string
                        example:
                          honorific: Dr.
                          title: CEO
                          name: Alice Johnson
                          birthday: '1980-05-15'
                          address:
                            street: Hauptstraße 15
                            zip: '10115'
                            city: Berlin
                            state: null
                            country: DE
                            note: Hauptsitz
                      tags:
                        description: A list of tags
                        type: array
                        items:
                       

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