# Číselník typů externích čísel

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /codelist/externalNumber:
    get:
      summary: Číselník typů externích čísel
      deprecated: false
      description: >+
        ## Význam a použití

        Metoda slouží k získávání seznamů kódů a názvů, které se v CPL API
        používají k identifikaci externích čísel. externalNumbers jsou externí
        čísla pro zákaznické identifikace. Např. číslo objednávky, nebo třeba
        nějaký kód zboží. Nejčastěji se používá code CUST jako zákaznické. Toto
        číslo se následně tiskne i přímo na etiketu a zároveň se propisuje
        zákazníkovi do fakturace. Využití najde především jako:

        - **Externí reference**
             - V logistických procesech je běžné, že odesilatel či e-shop pracuje s vlastními identifikátory (např. číslo objednávky, číslo faktury, číslo klienta atd.).
            - PPL pak může potřebovat uvést, k jakému typu externího čísla se zadaný údaj vztahuje.
            - codelist/externalNumbers tedy poskytuje podporované kódy pro tyto typy číselných či alfanumerických referencí, aby bylo jasné, jak je v systému správně evidovat.

        - **Propojení se systémy**
            - Pokud existuje více různých typů čísel/ID, PPL chce vědět, které z nich e-shop/odesilatel poskytuje.
            - Tím pádem lze zvolit správný code při vytváření záznamu o zásilce.


      tags:
        - API Metody/Codelist
        - Codelist
      parameters:
        - name: Limit
          in: query
          description: ''
          required: true
          schema:
            maximum: 1000
            minimum: 1
            type: integer
            format: int32
        - name: Offset
          in: query
          description: ''
          required: true
          schema:
            maximum: 2147483647
            minimum: 0
            type: integer
            format: int32
        - name: Accept-Language
          in: header
          description: 'Language specification, default language: cs-CZ'
          required: false
          example: ''
          schema:
            $ref: '#/components/schemas/AcceptLanguageSchema'
        - name: X-Correlation-ID
          in: header
          description: Correlation Id of request
          required: false
          example: ''
          schema:
            $ref: '#/components/schemas/XCorrelationIdSchema'
        - name: X-LogLevel
          in: header
          description: The forced log level
          required: false
          example: ''
          schema:
            $ref: '#/components/schemas/XLogLevelSchema'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  x-apidog-refs:
                    01JJKT0DSMXNAVV9EZRR8X9C5C:
                      $ref: >-
                        #/components/schemas/Eps.Api.MyApi2.Web.Models.Codelist.ShipmentExternalNumberTypeModel
                      x-apidog-overrides:
                        code: &ref_0
                          type: string
                          description: >-
                            interní kód externího čísla (krátký identifikátor
                            používaný při objednávce, ve formulářích, v API)
                          nullable: true
                        name: &ref_1
                          type: string
                          description: čitelný text (popis druhu externího čísla)
                          nullable: true
                      required: []
                  x-apidog-orders:
                    - 01JJKT0DSMXNAVV9EZRR8X9C5C
                  properties:
                    code: *ref_0
                    name: *ref_1
                    allowInput:
                      type: boolean
                      description: AllowInput
                  x-apidog-ignore-properties:
                    - code
                    - name
                    - allowInput
          headers:
            X-Correlation-ID:
              description: Correlation Id of request otherwise id of response
              schema:
                $ref: '#/components/schemas/XCorrelationIdSchema'
            X-Paging-Total-Items-Count:
              description: Total items in result
              schema:
                $ref: '#/components/schemas/XPagingSchema'
            X-Paging-Offset:
              description: Paging offset
              schema:
                $ref: '#/components/schemas/XPagingSchema'
            X-Paging-Limit:
              description: Page size
              schema:
                $ref: '#/components/schemas/XPagingSchema'
          x-apidog-name: OK
        '400':
          description: BadRequest
          content:
            application/problem+json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    additionalProperties:
                      type: array
                      items:
                        type: string
                    x-apidog-orders: []
                    properties: {}
                    x-apidog-ignore-properties: []
                    nullable: true
                  type:
                    type: string
                    nullable: true
                  title:
                    type: string
                    nullable: true
                  status:
                    type: integer
                    format: int32
                    nullable: true
                  detail:
                    type: string
                    nullable: true
                  instance:
                    type: string
                    nullable: true
                x-apidog-orders:
                  - 01JJKSY27XSCQFCJQ0K889D46N
                x-apidog-refs:
                  01JJKSY27XSCQFCJQ0K889D46N: &ref_2
                    $ref: >-
                      #/components/schemas/Eps.Api.Infrastructure.WebApi.Model.ProblemJsonModel
                x-apidog-ignore-properties:
                  - errors
                  - type
                  - title
                  - status
                  - detail
                  - instance
          headers: {}
          x-apidog-name: Bad Request
        '500':
          description: InternalServerError
          content:
            application/problem+json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    additionalProperties:
                      type: array
                      items:
                        type: string
                    x-apidog-orders: []
                    properties: {}
                    x-apidog-ignore-properties: []
                    nullable: true
                  type:
                    type: string
                    nullable: true
                  title:
                    type: string
                    nullable: true
                  status:
                    type: integer
                    format: int32
                    nullable: true
                  detail:
                    type: string
                    nullable: true
                  instance:
                    type: string
                    nullable: true
                x-apidog-orders:
                  - 01JJKSYD0WRF4YEXQ9RHJKFRTN
                x-apidog-refs:
                  01JJKSYD0WRF4YEXQ9RHJKFRTN: *ref_2
                x-apidog-ignore-properties:
                  - errors
                  - type
                  - title
                  - status
                  - detail
                  - instance
          headers: {}
          x-apidog-name: Server Error
        '503':
          description: ServiceUnavailable
          content:
            application/problem+json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    additionalProperties:
                      type: array
                      items:
                        type: string
                    x-apidog-orders: []
                    properties: {}
                    x-apidog-ignore-properties: []
                    nullable: true
                  type:
                    type: string
                    nullable: true
                  title:
                    type: string
                    nullable: true
                  status:
                    type: integer
                    format: int32
                    nullable: true
                  detail:
                    type: string
                    nullable: true
                  instance:
                    type: string
                    nullable: true
                x-apidog-orders:
                  - 01JJKSYNKXP9Y6AWQFDTPV88XF
                x-apidog-refs:
                  01JJKSYNKXP9Y6AWQFDTPV88XF: *ref_2
                x-apidog-ignore-properties:
                  - errors
                  - type
                  - title
                  - status
                  - detail
                  - instance
          headers: {}
          x-apidog-name: Service Unavailable
      security: []
      x-apidog-folder: API Metody/Codelist
      x-apidog-status: released
      x-run-in-apidog: https://app.apidog.com/web/project/796227/apis/api-13465891-run
components:
  schemas:
    AcceptLanguageSchema:
      type: string
      description: Accept-Language header schema
      x-apidog-folder: ''
    XCorrelationIdSchema:
      type: string
      description: X-Correlation-ID header schema
      x-apidog-folder: ''
    XLogLevelSchema:
      enum:
        - Trace
        - Debug
        - Information
        - Warning
        - Error
        - Critical
      type: string
      description: X-LogLevel header schema
      x-apidog-folder: ''
    Eps.Api.MyApi2.Web.Models.Codelist.ShipmentExternalNumberTypeModel:
      type: object
      properties:
        code:
          type: string
          description: Code
          nullable: true
        name:
          type: string
          description: Name
          nullable: true
        allowInput:
          type: boolean
          description: AllowInput
      additionalProperties: false
      description: ShipmentExternalNumberTypeModel
      x-apidog-orders:
        - code
        - name
        - allowInput
      x-apidog-ignore-properties: []
      x-apidog-folder: ''
    Eps.Api.Infrastructure.WebApi.Model.ProblemJsonModel:
      type: object
      properties:
        errors:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          x-apidog-orders: []
          properties: {}
          x-apidog-ignore-properties: []
          nullable: true
        type:
          type: string
          nullable: true
        title:
          type: string
          nullable: true
        status:
          type: integer
          format: int32
          nullable: true
        detail:
          type: string
          nullable: true
        instance:
          type: string
          nullable: true
      additionalProperties:
        type: string
      x-apidog-orders:
        - errors
        - type
        - title
        - status
        - detail
        - instance
      x-apidog-ignore-properties: []
      x-apidog-folder: ''
  securitySchemes:
    oauth2:
      type: apikey
      description: Get access token from authentication server.
      name: Authorization
      in: header
    Bearer:
      type: jwt
      description: >-
        JWT Authorization header using the Bearer scheme. Example:
        "Authorization: Bearer {token}"
      scheme: bearer
      bearerFormat: JWT
servers: []
security: []

```
