Xentral Production API

Production resource management

OpenAPI Specification

xentral-production-api-openapi.yml Raw ↑
openapi: 3.0.0
info:
  title: Xentral Account Production 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: Production
  description: Production resource management
paths:
  /api/v1/productions:
    get:
      tags:
      - Production
      operationId: production.list
      summary: List productions
      description: List Productions
      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:
                  - id
                  - date
                  - createdAt
                  - updatedAt
                  - status
                  - salesOrderId
                  - projectId
                op:
                  type: string
                  enum:
                  - equals
                  - notEquals
                  - in
                  - notIn
                  - allIn
                  - allNotIn
                  - contains
                  - notContains
                  - startsWith
                  - endsWith
                  - greaterThan
                  - lessThan
                value:
                  oneOf:
                  - type: string
                  - type: array
                    items:
                      type: string
      - name: order
        in: query
        style: deepObject
        schema:
          type: array
          items:
            type: object
            additionalProperties: false
            properties:
              field:
                type: string
                enum:
                - id
                - date
                - createdAt
                - updatedAt
              dir:
                type: string
                enum:
                - asc
                - desc
      - 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.
      responses:
        '200':
          description: Productions list
          content:
            application/json:
              schema:
                type: object
                additionalProperties: false
                required:
                - data
                - extra
                properties:
                  data:
                    type: array
                    items:
                      description: An entity of production response
                      type: object
                      additionalProperties: false
                      required:
                      - id
                      - documentNumber
                      - bodyOutroduction
                      - date
                      - dateDelivery
                      - dateProvision
                      - dateProduction
                      - dateProductionEnd
                      - status
                      - customer
                      - project
                      - salesOrder
                      - internalDesignation
                      - preferredWarehouse
                      - reservationType
                      - retrievalType
                      - explodeSublists
                      - functionalTest
                      - displayWorkingStepTexts
                      - createSerialNumbers
                      - captureComponentSerialnumbers
                      - internalComment
                      - completed
                      - finalRemark
                      - customerCheckOk
                      - depletingOk
                      - partialProductionNumber
                      - partialProductionOf
                      - stockingOk
                      - stockOk
                      - log
                      properties:
                        id:
                          type: string
                          pattern: \d+
                          example: '17'
                          description: Resource identifier.
                        documentNumber:
                          type: string
                          description: documentNumber
                          example: DOC-123456
                        bodyOutroduction:
                          type: string
                          description: BodyOutroduction of the production
                          example: This is the conclusion section of the production document.
                        date:
                          type: string
                          format: date
                          description: Production Date
                          example: '2024-09-18'
                        dateDelivery:
                          type: string
                          format: date
                          nullable: true
                          description: Production Delivery Date
                          example: '2024-09-25'
                        dateProvision:
                          type: string
                          format: date
                          nullable: true
                          description: Provision Date
                          example: '2024-09-20'
                        dateProduction:
                          type: string
                          format: date
                          nullable: true
                          description: Production Date
                          example: '2024-09-21'
                        dateProductionEnd:
                          type: string
                          format: date
                          nullable: true
                          description: Production End Date
                          example: '2024-09-22'
                        status:
                          type: string
                          description: Production Status
                          example: In Progress
                        customer:
                          type: object
                          properties:
                            id:
                              type: string
                              pattern: \d+
                              example: '17'
                              description: Resource identifier.
                          nullable: true
                          description: Customer of the production
                          example:
                            id: '17'
                        project:
                          type: object
                          properties:
                            id:
                              type: string
                              pattern: \d+
                              example: '17'
                              description: Resource identifier.
                          nullable: true
                          description: Project of the production
                          example:
                            id: '17'
                        salesOrder:
                          type: object
                          properties:
                            id:
                              type: string
                              pattern: \d+
                              example: '17'
                              description: Resource identifier.
                          nullable: true
                          description: Sales Order of the production
                          example:
                            id: '17'
                        internalDesignation:
                          type: string
                          description: Internal Designation of the production
                          example: Batch A-123
                        preferredWarehouse:
                          type: object
                          properties:
                            id:
                              type: string
                              pattern: \d+
                              example: '17'
                              description: Resource identifier.
                          nullable: true
                          description: Preferred Warehouse of the production
                          example:
                            id: '17'
                        reservationType:
                          type: string
                          nullable: true
                          description: Reservation Type of the production
                          example: Standard
                        retrievalType:
                          type: string
                          description: Retrieval Type of the production
                          example: Automated
                        explodeSublists:
                          type: boolean
                          description: Explode Sublists of the production
                          example: true
                        functionalTest:
                          type: boolean
                          description: Functional Test of the production
                          example: true
                        displayWorkingStepTexts:
                          type: boolean
                          description: Display Working Step Texts of the production
                          example: true
                        createSerialNumbers:
                          type: boolean
                          description: Create Serial Numbers of the production
                          example: true
                        captureComponentSerialnumbers:
                          type: boolean
                          description: Capture Component Serialnumbers of the production
                          example: true
                        internalComment:
                          type: string
                          description: Internal Comment of the production
                          example: Process is completed
                        completed:
                          type: boolean
                          description: Completed of the production
                          example: true
                        finalRemark:
                          type: string
                          description: Final Remark of the production
                          example: Production is done
                        customerCheckOk:
                          type: boolean
                          description: Customer Check Ok of the production
                          example: true
                        depletingOk:
                          type: boolean
                          description: Depleting Ok of the production
                          example: true
                        partialProductionNumber:
                          type: integer
                          description: Partial Production Number of the production
                          example: 121
                        partialProductionOf:
                          type: integer
                          description: Partial Production of the production
                          example: 1
                        stockingOk:
                          type: boolean
                          description: Stocking Ok of the production
                          example: true
                        stockOk:
                          type: boolean
                          description: Stock Ok of the production
                          example: true
                        log:
                          type: object
                          properties:
                            createdAt:
                              type: string
                              format: date
                              example: '2024-09-18'
                            createdBy:
                              type: object
                              properties:
                                id:
                                  type: string
                                  example: USR123456
                                name:
                                  type: string
                                  example: John Doe
                          example:
                            createdAt: '2024-09-18'
                            createdBy:
                              id: USR123456
                              name: John Doe
                          description: log of the production
                      example:
                        id: '17'
                        documentNumber: DOC-123456
                        bodyOutroduction: This is the conclusion section of the production document.
                        date: '2024-09-18'
                        dateDelivery: '2024-09-25'
                        dateProvision: '2024-09-20'
                        dateProduction: '2024-09-21'
                        dateProductionEnd: '2024-09-22'
                        status: In Progress
                        customer:
                          id: '17'
                        project:
                          id: '17'
                        salesOrder:
                          id: '17'
                        internalDesignation: Batch A-123
                        preferredWarehouse:
                          id: '17'
                        reservationType: Standard
                        retrievalType: Automated
                        explodeSublists: true
                        functionalTest: true
                        displayWorkingStepTexts: true
                        createSerialNumbers: true
                        captureComponentSerialnumbers: true
                        internalComment: Process is completed
                        completed: true
                        finalRemark: Production is done
                        customerCheckOk: true
                        depletingOk: true
                        partialProductionNumber: 121
                        partialProductionOf: 1
                        stockingOk: true
                        stockOk: true
                        log:
                          createdAt: '2024-09-18'
                          createdBy:
                            id: USR123456
                            name: John Doe
                  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
                example:
                  data:
                  - id: '1'
                    documentNumber: ''
                    bodyOutroduction: ''
                    date: '2024-03-13'
                    dateDelivery: null
                    dateProvision: null
                    dateProduction: null
                    dateProductionEnd: null
                    status: released
                    customer: null
                    project:
                      id: '1'
                    salesOrder: null
                    internalDesignation: ''
                    preferredWarehouse: null
                    reservationType: abschluss
                    retrievalType: sammel
                    explodeSublists: true
                    functionalTest: false
                    displayWorkingStepTexts: true
                    createSerialNumbers: true
                    captureComponentSerialnumbers: false
                    internalComment: ''
                    completed: false
                    finalRemark: ''
                    customerCheckOk: true
                    depletingOk: false
                    partialProductionNumber: 0
                    partialProductionOf: 0
                    stockingOk: false
                    stockOk: true
                    log:
                      createdAt: '2024-03-13'
                      createdBy:
                        id: '1'
                        name: admin
                  - id: '2'
                    documentNumber: 2024-400000
                    bodyOutroduction: bodyOutroduction
                    date: '2024-03-14'
                    dateDelivery: '2024-03-15'
                    dateProvision: null
                    dateProduction: null
                    dateProductionEnd: null
                    status: released
                    customer:
                      id: '2'
                    project:
                      id: '1'
                    salesOrder:
                      id: '2'
                    internalDesignation: ''
                    preferredWarehouse:
                      id: '12'
                    reservationType: abschluss
                    retrievalType: sammel
                    explodeSublists: true
                    functionalTest: false
                    displayWorkingStepTexts: true
                    createSerialNumbers: true
                    captureComponentSerialnumbers: false
                    internalComment: 'This is internal comment '
                    completed: false
                    finalRemark: ''
                    customerCheckOk: true
                    depletingOk: false
                    partialProductionNumber: 0
                    partialProductionOf: 0
                    stockingOk: false
                    stockOk: true
                    log:
                      createdAt: '2024-03-14'
                      createdBy:
                        id: '1'
                        name: admin
                  extra:
                    totalCount: 20
                    page:
                      number: 1
                      size: 2
        '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: 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
        '406':
          description: Requested resource representation does not exist.
        '429':
          description: Too many API calls made.
  /api/v1/productions/{id}:
    get:
      tags:
      - Production
      operationId: production.view
      summary: View production
      description: View a production
      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: Productions view based on id
          content:
            application/json:
              schema:
                type: object
                additionalProperties: false
                required:
                - data
                properties:
                  data:
                    description: An entity of production response
                    type: object
                    additionalProperties: false
                    required:
                    - id
                    - documentNumber
                    - bodyOutroduction
                    - date
                    - dateDelivery
                    - dateProvision
                    - dateProduction
                    - dateProductionEnd
                    - status
                    - customer
                    - project
                    - salesOrder
                    - batch
                    - internalDesignation
                    - preferredWarehouse
                    - 

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