openapi: 3.0.0
info:
  title: SAP API
  version: 1.0.0
servers:
- url: http://localhost:8080
paths:
  /rfc/SKWR_SEARCH:
    post:
      tags:
      - SKWR_TEXT_MINING
      operationId: /rfc/SKWR_SEARCH
      requestBody:
        content:
          application/json:
            schema:
              properties:
                FOLDER:
                  type: object
                  properties:
                    OBJTYPE:
                      type: string
                      maxLength: 1
                      description: 'KW Framework: IO type  enumValues: R=Relationship,L=LOIO,P=PHIO,""=Undefined (= all),F=Directory'
                      enum:
                      - R
                      - L
                      - P
                      - ''
                      - F
                    CLASS:
                      type: string
                      maxLength: 10
                      description: Document class
                    OBJID:
                      type: string
                      maxLength: 32
                      description: ID for documents and relations
                INDICES:
                  type: array
                  items:
                    type: object
                    properties:
                      ID:
                        type: string
                        maxLength: 32
                        description: GUID in 'CHAR' Format in Uppercase
                      LAISO:
                        type: string
                        maxLength: 2
                        description: Language according to ISO 639
                      CODE_PAGE:
                        type: string
                        description: Character Set ID
                      EXT_ENGINE:
                        type: string
                        description: Alias for External Search Engine
                INTERVAL_FROM:
                  type: integer
                  format: int32
                  default: 1
                INTERVAL_TO:
                  type: integer
                  format: int32
                  default: 100
                QUERY_CODE_PAGE:
                  type: string
                QUERY_LAISO:
                  type: string
                  maxLength: 2
                QUERY_TERMS:
                  type: array
                  items:
                    type: object
                    properties:
                      ATTR_NAME:
                        type: string
                        maxLength: 64
                        description: Attribute Name
                      TERM_TYPE:
                        type: string
                        maxLength: 1
                        description: Content Type of Term
                      VALUE1:
                        type: string
                        description: Term Value
                      VALUE2:
                        type: string
                        description: Second Value, for Value Ranges
                      OPERATOR:
                        type: string
                        maxLength: 2
                        description: Operator
                      CONTENT_TYPE:
                        type: string
                        maxLength: 1
                        description: Content Type of Documents or Attributes
                      SEARCH_TYPE:
                        type: string
                        maxLength: 1
                        description: Search Method
                      TERM_WEIGHT:
                        type: integer
                        format: int64
                        description: 'Decimal Number: 0.0 to 1.0'
                REQ_ATTRIBUTES:
                  type: array
                  items:
                    type: object
                    properties:
                      ATTR_NAME:
                        type: string
                        maxLength: 64
                        description: Attribute Name
                      ATTR_TYPE:
                        type: string
                        maxLength: 1
                        description: Content Type of Documents or Attributes
                SORTED_BY:
                  type: object
                  properties:
                    ATTR_NAME:
                      type: string
                      maxLength: 64
                      description: Attribute Name
                    SORT_DIRECTION:
                      type: string
                      maxLength: 1
                      description: 'Sort Sequence  enumValues: D=Descending,A=Ascending'
                      enum:
                      - D
                      - A
              required:
              - QUERY_TERMS
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                properties:
                  NUM_OF_HITS:
                    type: integer
                    format: int32
                    description: No. documents found
                  RESULT_PROPERTIES:
                    type: array
                    items:
                      type: object
                      properties:
                        OBJTYPE:
                          type: string
                          maxLength: 1
                          description: 'KW Framework: IO type'
                        CLASS:
                          type: string
                          maxLength: 10
                          description: Document class
                        OBJID:
                          type: string
                          maxLength: 32
                          description: ID for documents and relations
                        ATTR_NAME:
                          type: string
                          maxLength: 64
                          description: Attribute Name
                        VALUE:
                          type: string
                          description: Attribute Value
                        ATTR_TYPE:
                          type: string
                          maxLength: 1
                          description: Content Type of Documents or Attributes
                  SEARCH_RESULTS:
                    type: array
                    items:
                      type: object
                      properties:
                        OBJTYPE:
                          type: string
                          maxLength: 1
                          description: 'KW Framework: IO type'
                        CLASS:
                          type: string
                          maxLength: 10
                          description: Document class
                        OBJID:
                          type: string
                          maxLength: 32
                          description: ID for documents and relations
                        RANK_VALUE:
                          type: integer
                          format: int64
                          description: 'Decimal Number: 0.0 to 1.0'
                        LAISO:
                          type: string
                          maxLength: 2
                          description: Language according to ISO 639
                        IDX:
                          type: object
                          properties:
                            ID:
                              type: string
                              maxLength: 32
                              description: GUID in 'CHAR' Format in Uppercase
                            LAISO:
                              type: string
                              maxLength: 2
                              description: Language according to ISO 639
                            CODE_PAGE:
                              type: string
                              description: Character Set ID
                            EXT_ENGINE:
                              type: string
                              description: Alias for External Search Engine
                        CODE_PAGE:
                          type: string
                          description: Character Set ID
        '400':
          description: Bad request.
        5XX:
          description: Unexpected error.
