REST API

Action Automation Connector REST API documentation version v1

{schema}://{host}/api/{version}

  • schema: required(one of http, https - default: http)
  • host: required(string - default: localhost)
  • version: required(v1)

Automations

Available service automations.

/automations get

get /automations

Returns automations handled by the service.

HTTP status code 200

Automations are successfully retrieved.

Body

Media type: application/json

Type: array of AutomationResponse

Items: AutomationResponse

  • automationType: required(string)

    Automation type.

  • schema: optional (object)

    Automation body JSON schema.

    Example:

    [
      {
        "automationType": "command-invocation"
      },
      {
        "automationType": "email-notification",
        "schema": {
          "$schema": "http://json-schema.org/draft-06/schema",
          "title": "Email",
          "description": "Email notification automation",
          "type": "object",
          "properties": {
            "recipient": {
              "description": "Email recipient",
              "type": "string"
            },
            "subject": {
              "description": "Email subject",
              "type": "string"
            },
            "text": {
              "description": "Email text",
              "type": "string"
            },
            "sender": {
              "description": "Email sender",
              "type": "string"
            }
          },
          "required": ["recipient", "subject", "text", "sender"]
        }
      }
    ]
    

    Notification types

    Operations on notification types.

    /notification-types/{notificationType}/recipients get post

    get /notification-types/{notificationType}/recipients

    Returns available email notification recipients.

    Secured by oauth_2_0 with scopes:
    • tenant:notification-recipient:read

    AAC supports OAuth 2.0 for authenticating all API requests.

    URI Parameters

    • notificationType: required(string)

      Notification type

      Example:

      email

    Headers

    • Authorization: required(string)

      Used to send an OAuth 2.0 JWT.

      Example:

      Authorization: bearer {your-access-token}

    Query Parameters

    • state: optional (one of VERIFIED, UNVERIFIED)

      Email notification recipient verification state.

    HTTP status code 200

    Email notification recipients are successfully retrieved.

    Body

    Media type: application/json

    Type: array of EmailNotificationRecipient

    Items: EmailNotificationRecipient

    • id: required(integer)

      Email notification recipient unique identifier.

    • recipient: required(string)

      Email notification recipient.

    • state: required(one of VERIFIED, UNVERIFIED)

      Email notification recipient verification state.

    Example:

    [
      {
        "id": 159,
        "recipient": "usb@auto.logistic.com",
        "state": "VERIFIED"
      },
      {
        "id": 246,
        "recipient": "krsn.company@gmail.com",
        "state": "UNVERIFIED"
      }
    ]

    HTTP status code 400

    Invalid request.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.

    Secured by oauth_2_0

    Headers

    • Authorization: optional (string)

      Used to send a valid OAuth 2 access token. Example: "Authorization: Bearer 'access_token'" where 'access_token' must be replaced by a valid OAuth access token. This header is needed only if API authentication is enabled for the service.

    post /notification-types/{notificationType}/recipients

    Creates new email notification recipient.

    Secured by oauth_2_0 with scopes:
    • tenant:notification-recipient:create

    AAC supports OAuth 2.0 for authenticating all API requests.

    URI Parameters

    • notificationType: required(string)

      Notification type

      Example:

      email

    Headers

    • Authorization: required(string)

      Used to send an OAuth 2.0 JWT.

      Example:

      Authorization: bearer {your-access-token}

    Body

    Media type: application/json

    Type: object

    Properties

    • recipient: required(string)

      Email notification recipient.

    Example:

    {
      "recipient": "usb@auto.logistic.com"
    }

    HTTP status code 201

    Unverified email notification recipient was successfully created. The verification email was sent to the specified email.

    Headers

    • Location: required(string)

      URI in format {schema}://{host}:{port}/api/v1/notification-types/email/recipients/{id}

      Example:

      http://example.com/api/v1/notification-types/email/recipients/267

    HTTP status code 400

    Invalid request.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.

    HTTP status code 403

    User does not have permissions to perform this operation.

    Secured by oauth_2_0

    Headers

    • Authorization: optional (string)

      Used to send a valid OAuth 2 access token. Example: "Authorization: Bearer 'access_token'" where 'access_token' must be replaced by a valid OAuth access token. This header is needed only if API authentication is enabled for the service.

    /notification-types/{notificationType}/recipients/{recipientId} get delete

    get /notification-types/{notificationType}/recipients/{recipientId}

    Returns email notification recipient.

    Secured by oauth_2_0 with scopes:
    • tenant:notification-recipient:read

    AAC supports OAuth 2.0 for authenticating all API requests.

    URI Parameters

    • notificationType: required(string)

      Notification type

      Example:

      email
    • recipientId: required(integer)

      Email recipient ID

      Example:

      351

    Headers

    • Authorization: required(string)

      Used to send an OAuth 2.0 JWT.

      Example:

      Authorization: bearer {your-access-token}

    HTTP status code 200

    Email notification recipient is successfully retrieved.

    Body

    Media type: application/json

    Type: object

    Properties

    • id: required(integer)

      Email notification recipient unique identifier.

    • recipient: required(string)

      Email notification recipient.

    • state: required(one of VERIFIED, UNVERIFIED)

      Email notification recipient verification state.

    Example:

    {
      "id": 159,
      "recipient": "usb@auto.logistic.com",
      "state": "VERIFIED"
    }

    HTTP status code 404

    Resource not found or querying user is not authorized for it.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.

    Secured by oauth_2_0

    Headers

    • Authorization: optional (string)

      Used to send a valid OAuth 2 access token. Example: "Authorization: Bearer 'access_token'" where 'access_token' must be replaced by a valid OAuth access token. This header is needed only if API authentication is enabled for the service.

    delete /notification-types/{notificationType}/recipients/{recipientId}

    Deletes email notification recipient.

    Secured by oauth_2_0 with scopes:
    • tenant:notification-recipient:update

    AAC supports OAuth 2.0 for authenticating all API requests.

    URI Parameters

    • notificationType: required(string)

      Notification type

      Example:

      email
    • recipientId: required(integer)

      Email recipient ID

      Example:

      351

    Headers

    • Authorization: required(string)

      Used to send an OAuth 2.0 JWT.

      Example:

      Authorization: bearer {your-access-token}

    HTTP status code 204

    Email notification recipient successfully deleted.

    HTTP status code 404

    Resource not found or querying user is not authorized for it.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.

    Secured by oauth_2_0

    Headers

    • Authorization: optional (string)

      Used to send a valid OAuth 2 access token. Example: "Authorization: Bearer 'access_token'" where 'access_token' must be replaced by a valid OAuth access token. This header is needed only if API authentication is enabled for the service.

    /notification-types/{notificationType}/recipients/{recipientId}/verification post

    post /notification-types/{notificationType}/recipients/{recipientId}/verification

    Resends notification recipient verification email.

    Secured by oauth_2_0 with scopes:
    • tenant:notification-recipient:read

    AAC supports OAuth 2.0 for authenticating all API requests.

    URI Parameters

    • notificationType: required(string)

      Notification type

      Example:

      email
    • recipientId: required(integer)

      Email recipient ID

      Example:

      351

    Headers

    • Authorization: required(string)

      Used to send an OAuth 2.0 JWT.

      Example:

      Authorization: bearer {your-access-token}

    HTTP status code 200

    A verification email has been successfully sent.

    HTTP status code 400

    Invalid request.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.

    HTTP status code 404

    Resource not found or querying user is not authorized for it.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.

    Secured by oauth_2_0

    Headers

    • Authorization: optional (string)

      Used to send a valid OAuth 2 access token. Example: "Authorization: Bearer 'access_token'" where 'access_token' must be replaced by a valid OAuth access token. This header is needed only if API authentication is enabled for the service.

    /notification-types/{notificationType}/recipients/{recipientId}/verification/{token} get

    get /notification-types/{notificationType}/recipients/{recipientId}/verification/{token}

    Verifies email notification recipient.

    URI Parameters

    • notificationType: required(string)

      Notification type

      Example:

      email
    • recipientId: required(integer)

      Email recipient ID

      Example:

      351
    • token: required(string)

    HTTP status code 200

    Email notification recipient successfully verified.

    HTTP status code 400

    Invalid request.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.

    HTTP status code 404

    Resource not found or querying user is not authorized for it.

    Body

    Media type: application/json

    Type: object

    Properties

    • message: required(string)

      Detailed error description.