openapi: 3.0.0

info:
  title: AIMLE Context Transfer Information Service
  version: 1.0.0-alpha.1
  description: |
    AIMLE Context Trnaser Information Service.  
    © 2025, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC).  
    All rights reserved.

externalDocs:
  description: >
    3GPP TS 29.482 v0.1.0; Artificial Intelligence Machine Learning Enablement 
    (AIMLE) Services; Stage 3.
  url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.482/

servers:
  - url: '{apiRoot}/aimles-ct/v1'
    variables:
      apiRoot:
        default: https://example.com
        description: apiRoot as defined in clause 5.2.4 of 3GPP TS 29.122

security:
  - {}
  - oAuth2ClientCredentials: []


paths:
  /request-trans:
    post:
      summary: Request to send AIMLE context transfer information.
      operationId: Request
      tags:
        - AIMLE Context Transfer Request
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TransReq'
      responses:
        '204':
          description: >
            No Content. The AIMLE context transfer information is successfully received and processed.
        '307':
          $ref: 'TS29122_CommonData.yaml#/components/responses/307'
        '308':
          $ref: 'TS29122_CommonData.yaml#/components/responses/308'
        '400':
          $ref: 'TS29122_CommonData.yaml#/components/responses/400'
        '401':
          $ref: 'TS29122_CommonData.yaml#/components/responses/401'
        '403':
          $ref: 'TS29122_CommonData.yaml#/components/responses/403'
        '404':
          $ref: 'TS29122_CommonData.yaml#/components/responses/404'
        '411':
          $ref: 'TS29122_CommonData.yaml#/components/responses/411'
        '413':
          $ref: 'TS29122_CommonData.yaml#/components/responses/413'
        '415':
          $ref: 'TS29122_CommonData.yaml#/components/responses/415'
        '429':
          $ref: 'TS29122_CommonData.yaml#/components/responses/429'
        '500':
          $ref: 'TS29122_CommonData.yaml#/components/responses/500'
        '503':
          $ref: 'TS29122_CommonData.yaml#/components/responses/503'
        default:
          $ref: 'TS29122_CommonData.yaml#/components/responses/default'

components:

  securitySchemes:
    oAuth2ClientCredentials:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: '{tokenUrl}'
          scopes: {}

  schemas:
    TransReq:
      description: >
        Represents the AIMLE context transfer information.
      type: object
      properties:
        aimleClientId:
          $ref: '#/components/schemas/AimleClientId'
        aimleServerId:
          type: string
        aimleServerIds:
          type: array
          items:
            type: string
          minItems: 1
        aimleServStatus:
          $ref: '#/components/schemas/AimleServStatus'
      required:
        - aimleClientId

    AimleServStatus:
      description: >
        Represents the AIMLE service status information.
      type: object
      properties:
        aimleServOpStatus:
          $ref: '#/components/schemas/AimleServOpStatus'
        aimleServOpPercent:
          type: integer
          minimum: 0
          maximum: 100
      required:
        - aimleServOpStatus


# SIMPLE DATA TYPES
#

    AimleClientId:
      description: Represents unique identifier of a AIMLE client.
      type: string

#
# ENUMERATIONS
#

    AimleServOpStatus:
      anyOf:
      - type: string
        enum:
          - ACTIVE
          - PAUSED
      - type: string
        description: >
          This string provides forward-compatibility with future extensions to the enumeration
          and is not used to encode content defined in the present version of this API.
      description: |
        Represents the AIMLE service operation status.  
        Possible values are:
        - ACTIVE: Indicates the status of the AIML operations at the AIMLE client is active.
        - PAUSED: Indicates the status of the AIML operations at the AIMLE client is paused.
