openapi: 3.0.0
info:
  title: SAP API
  version: 1.0.0
servers:
- url: http://localhost:8080
paths:
  /rfc/RSOD_DOC_MAST_CHANGE:
    post:
      tags:
      - RSOD_API
      summary: 'Document API: Create Document for Master Date'
      operationId: /rfc/RSOD_DOC_MAST_CHANGE
      requestBody:
        content:
          application/json:
            schema:
              properties:
                I_CHANM:
                  type: string
                  maxLength: 30
                  description: Characteristic
                I_CHAVL:
                  type: string
                  maxLength: 60
                  description: Characteristic Value
                I_COPY_URL_CONTENT:
                  type: string
                  maxLength: 1
                  description: = 'X' Document read and copied. ' ' Link to URL (not yet functional)
                I_DESCRIPTION:
                  type: string
                  maxLength: 64
                  description: Short Description
                I_DOC_TYPE:
                  type: string
                  maxLength: 20
                  description: Document Type
                I_LANGU:
                  type: string
                  default: SY-LANGU
                  maxLength: 1
                  description: Language Key
                I_NAME:
                  type: string
                  maxLength: 40
                  description: Name
                I_OVERWRITE_MODE:
                  type: string
                  maxLength: 1
                  description: '0: New LOIO, 1: New PHIO, 2: Replace PHIO, 3: Delete LOIO'
                I_S_CONTENT_INFO:
                  type: object
                  properties:
                    FILE_NAME:
                      type: string
                      maxLength: 255
                      description: Relative storage location of physical document
                    MIMETYPE:
                      type: string
                      maxLength: 128
                      description: HTML content type
                    FILE_SIZE:
                      type: integer
                      format: int64
                      description: File size (in bytes)
                    ENCODING:
                      type: string
                      maxLength: 20
                      description: Identifier for Character Format (UTF-8, UCS-2, ...)
                    ENDIAN:
                      type: string
                      maxLength: 1
                      description: 'Flag for Byte Sequence (Big-Endian, Little-Endian)  enumValues: B=Big-Endian,L=Little-Endian,""=Default'
                      enum:
                      - B
                      - L
                      - ''
                    LANGUAGE:
                      type: string
                      maxLength: 2
                      description: Language (Acc. To ISO Standard 639)
                I_URL:
                  type: string
                  maxLength: 4096
                  description: URL
                I_WITH_CONTENT:
                  type: string
                  maxLength: 1
                  description: = 'X' Contents provided (I_T_FILE_CONTENT_ASCII / I_T_FILE_CONTENT_BINARY)
                I_WITH_URL:
                  type: string
                  maxLength: 1
                  description: = 'X' Document specified using URL
                I_T_FILE_CONTENT_ASCII:
                  type: array
                  items:
                    type: object
                    properties:
                      LINE:
                        type: string
                        maxLength: 1022
                        description: Line for text document contents, length as during upload
                I_T_FILE_CONTENT_BINARY:
                  type: array
                  items:
                    type: object
                    properties:
                      LINE:
                        type: string
                        format: byte
                        description: Line for binary document contents, length for upload
              required:
              - I_CHANM
              - I_CHAVL
              - I_DESCRIPTION
              - I_OVERWRITE_MODE
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                properties:
                  E_NAME:
                    type: string
                    maxLength: 64
                    description: Attribute Value
                  E_S_RETURN:
                    type: object
                    properties:
                      TYPE:
                        type: string
                        maxLength: 1
                        description: 'Message type: S Success, E Error, W Warning, I Info, A Abort'
                      ID:
                        type: string
                        maxLength: 20
                        description: Message Class
                      NUMBER:
                        type: integer
                        format: int64
                        description: Message Number
                      MESSAGE:
                        type: string
                        maxLength: 220
                        description: Message Text
                      LOG_NO:
                        type: string
                        maxLength: 20
                        description: 'Application log: log number'
                      LOG_MSG_NO:
                        type: integer
                        format: int64
                        description: 'Application log: Internal message serial number'
                      MESSAGE_V1:
                        type: string
                        maxLength: 50
                        description: Message Variable
                      MESSAGE_V2:
                        type: string
                        maxLength: 50
                        description: Message Variable
                      MESSAGE_V3:
                        type: string
                        maxLength: 50
                        description: Message Variable
                      MESSAGE_V4:
                        type: string
                        maxLength: 50
                        description: Message Variable
                      PARAMETER:
                        type: string
                        maxLength: 32
                        description: Parameter Name
                      ROW:
                        type: integer
                        format: int32
                        description: Lines in parameter
                      FIELD:
                        type: string
                        maxLength: 30
                        description: Field in parameter
                      SYSTEM:
                        type: string
                        maxLength: 10
                        description: Logical system from which message originates
                  I_T_FILE_CONTENT_ASCII:
                    type: array
                    items:
                      type: object
                      properties:
                        LINE:
                          type: string
                          maxLength: 1022
                          description: Line for text document contents, length as during upload
                  I_T_FILE_CONTENT_BINARY:
                    type: array
                    items:
                      type: object
                      properties:
                        LINE:
                          type: string
                          format: byte
                          description: Line for binary document contents, length for upload
        '400':
          description: Bad request.
        5XX:
          description: Unexpected error.
