INTERFACE zif_em_messaging PUBLIC.
* Generated by abap-openapi-client
* SAP Event Mesh - REST APIs Messaging, 0.1.0

* Component schema: ErrorMessage, object
  TYPES: BEGIN OF errormessage,
           message TYPE string,
         END OF errormessage.

* Component schema: QOS, integer
  TYPES qos TYPE i.

* Component schema: bodycreate_subscription, object
  TYPES: BEGIN OF subbodycreate_subscription_pus,
           type TYPE string,
           endpoint TYPE string,
           excempthandshake TYPE string,
         END OF subbodycreate_subscription_pus.
  TYPES: BEGIN OF bodycreate_subscription,
           name TYPE string,
           address TYPE string,
           qos TYPE qos,
           pushconfig TYPE subbodycreate_subscription_pus,
         END OF bodycreate_subscription.

* Component schema: response_create_subscription, object
  TYPES: BEGIN OF response_create_subscription,
           href TYPE string,
         END OF response_create_subscription.

* POST - "Publish message to a queue"
* Operation id: publish-message-to-queue
* Parameter: queue-name, required, path
* Parameter: x-qos, required, header
* Parameter: x-message-expiration, optional, header
* Response: 204
* Response: 400
*     application/json, #/components/schemas/ErrorMessage
* Response: 404
*     application/json, #/components/schemas/ErrorMessage
* Body schema: string
  METHODS publish_message_to_queue
    IMPORTING
      queue_name TYPE string
      x_qos TYPE qos
      x_message_expiration TYPE i OPTIONAL
      body TYPE string
    RAISING cx_static_check.

* POST - "Publish message to a topic"
* Operation id: publish-message-to-topic
* Parameter: topic-name, required, path
* Parameter: x-qos, required, header
* Parameter: x-message-expiration, optional, header
* Response: 204
* Response: 400
*     application/json, #/components/schemas/ErrorMessage
* Body schema: string
  METHODS publish_message_to_topic
    IMPORTING
      topic_name TYPE string
      x_qos TYPE qos
      x_message_expiration TYPE i OPTIONAL
      body TYPE string
    RAISING cx_static_check.

* POST - "Consume message from queue"
* Operation id: consume-from-queue
* Parameter: queue-name, required, path
* Parameter: x-qos, required, header
* Response: 200
*     application/json, string
* Response: 204
* Response: 404
*     application/json, #/components/schemas/ErrorMessage
  METHODS consume_from_queue
    IMPORTING
      queue_name TYPE string
      x_qos TYPE qos
    RAISING cx_static_check.

* POST - "Acknowledge message consumption"
* Operation id: acknowledge-message
* Parameter: queue-name, required, path
* Parameter: message-id, required, path
* Response: 202
* Response: 400
*     application/json, #/components/schemas/ErrorMessage
  METHODS acknowledge_message
    IMPORTING
      queue_name TYPE string
      message_id TYPE string
    RAISING cx_static_check.

* POST - "Create subscription"
* Operation id: create-subscription
* Response: 202
*     application/json, #/components/schemas/response_create_subscription
* Response: 400
*     application/json, #/components/schemas/ErrorMessage
* Response: 409
*     application/json, #/components/schemas/ErrorMessage
* Body ref: #/components/schemas/bodycreate_subscription
  METHODS create_subscription
    IMPORTING
      body TYPE bodycreate_subscription
    RAISING cx_static_check.

ENDINTERFACE.
