Messaging API specification (9e074e34355a5facbece3910d74e59e0e26c61fd)

Download OpenAPI specification:Download

The messaging service implements all functions for message-management in GroupAlarm

Authentication

API_Token

To use this API, you need an API-Token from the RBAC settings of your GroupAlarm organization. Place the token inside the HTTP-Header API-Token for every request, otherwise the API will return an "401 Unauthorized" error for your request.

Security Scheme Type API Key
Header parameter name: API-TOKEN

Personal-Access-Token

To use this API, you need a Personal Access Token from your profile settings. Place the token inside the HTTP-Header Personal-Access-Token for every request, otherwise the API will return an "401 Unauthorized" error for your request.

Security Scheme Type API Key
Header parameter name: Personal-Access-Token

user

SetUserEscalation

Creates or updates an existing escalation configuration for the passed user

Request Body schema: application/json

new escalation configuration

required
Array of objects (Escalation) [ items ]

configured escalations

organizationID
integer <int64>

organization id for editing escalation as an organization administrator

userID
integer <int64>

assigned user for this escalation configuration for organization administrator editing

Responses

Request samples

Content type
application/json
{
  • "escalations": [
    ],
  • "organizationID": 0,
  • "userID": 0
}

Response samples

Content type
application/json
{
  • "message": "escalation saved"
}

GetUserEscalation

Returns the escalation configuration for the passed user

path Parameters
userID
required
integer

user id for the requested escalation

query Parameters
organization_id
integer

has to be set if you want to edit a user as admin of an organization

Responses

Response samples

Content type
application/json
{
  • "escalations": [
    ],
  • "organizationID": 0,
  • "userID": 0
}

escalation

SetOrganizationEscalation

Sets the escalation configuration for the given organization

Request Body schema: application/json

new escalation configuration

required
Array of objects (Escalation) [ items ]

configured escalations

organizationID
integer <int64>

organization id for editing escalation as an organization administrator

userID
integer <int64>

assigned user for this escalation configuration for organization administrator editing

Responses

Request samples

Content type
application/json
{
  • "escalations": [
    ],
  • "organizationID": 0,
  • "userID": 0
}

GetOrganizationEscalation

Returns the escalation configuration for the given organization

path Parameters
organizationID
required
integer

organizationID for the requested escalation

Responses

Response samples

Content type
application/json
{
  • "escalations": [
    ],
  • "organizationID": 0,
  • "userID": 0
}

RemoveOrganizationEscalation

Removes the escalation configuration for the given organization

path Parameters
organizationID
required
integer

organizationID for the requested escalation

Responses

Response samples

Content type
application/json
{
  • "escalations": [
    ],
  • "organizationID": 0,
  • "userID": 0
}

alarm

GetAlarmMessageStatus

Returns the current alarm message status for the user in the given alarm

path Parameters
alarm_id
required
integer

alarmID this request is about

query Parameters
organization_id
required
integer

associated organization requesting the information (used for rbac-check)

user_id
required
integer

requested user status

Responses

Response samples

Content type
application/json
{
  • "devices": [
    ],
  • "messageId": "string"
}

feedback

Sets the user feedback for a specific alarm or organization using the api.

You can use a JWT Token or Personal Access Token to update a specific user's feedback in an alarm or organization. You can also use an organization api token to update any user's feedback in an alarm or your organization.

Request Body schema: application/json

the users feedback

alarmID
integer <int64>

AlarmID associated to the feedback

organizationID
integer <int64>

OrganizationID associated to the feedback

response
required
boolean

Response should be true if the user gave positive feedback and false if not

userID
required
integer <int64>

UserID of the user that is sending this feedback

Responses

Request samples

Content type
application/json
{
  • "alarmID": 0,
  • "organizationID": 0,
  • "response": true,
  • "userID": 0
}

Response samples

Content type
application/json
{
  • "success": true
}

organization

GetTimeout

Returns the timeout of an message in the organization

path Parameters
organizationID
required
integer

organization id for the requested timeout

Responses

Response samples

Content type
application/json
{
  • "timeout": 0
}

SetTimeout

Sets the timeout of an message in the organization

path Parameters
organizationID
required
integer

organization id for the requested timeout

Request Body schema: application/json

organization timeout configuration

timeout
required
integer <int64>

Timeout of any message for the given organization

Responses

Request samples

Content type
application/json
{
  • "timeout": 0
}

Response samples

Content type
application/json
{
  • "timeout": 0
}