Skip to main content
Versionv1

Thresholds API (v1)

Download OpenAPI specification:Download

Sip Account Thresholds

Create Cost Threshold

Create a new cost threshold for the SIP account.

Authorizations:
X-CM-PRODUCTTOKEN
path Parameters
accountGuid
required
string <uuid>
Example: 00000000-0000-0000-0000-000000000000

Unique identifier of the Logical Account or Voice Account.

Request Body schema:

Model of the threshold rule

emailAddresses
Array of strings or null <email> [ items <email > ]

List of email addresses that will be notified when cost threshold is surpassed

phoneNumbers
Array of strings or null

List of phone numbers that will be notified when cost threshold is surpassed

guid
string or null <uuid>

Unique identifier for a given threshold rule

voiceAccountGuid
string <uuid>

The unique identifier of the Voice Account which this SIP Account is part of.

sipAccountGuid
string <uuid>

The unique identifier of the SIP Account which the rule applies to

threshold
required
number <double> >= 25

Decimal value representing the cost threshold in the currency of the sip account

blockAccountOnThreshold
boolean

Boolean value whether or not to block the SIP account when the threshold is surpassed

notificationSentOn
string or null <date-time>

Last time when a notification has been sent due to the threshold being passed. Null if threshold has never been passed

Responses

Request samples

Content type
{
  • "emailAddresses": [],
  • "phoneNumbers": [
    ],
  • "guid": "00000000-0000-0000-0000-000000000000",
  • "voiceAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "sipAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "threshold": 200.123,
  • "blockAccountOnThreshold": true,
  • "notificationSentOn": "2019-08-24T14:15:22Z"
}

Response samples

Content type
application/json
{
  • "emailAddresses": [],
  • "phoneNumbers": [
    ],
  • "guid": "00000000-0000-0000-0000-000000000000",
  • "voiceAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "sipAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "threshold": 200.123,
  • "blockAccountOnThreshold": true,
  • "notificationSentOn": "2019-08-24T14:15:22Z"
}

Get Cost Thresholds

Get all cost thresholds for the given SIP account.

Authorizations:
X-CM-PRODUCTTOKEN
path Parameters
accountGuid
required
string <uuid>
Example: 00000000-0000-0000-0000-000000000000

Unique identifier of the Logical Account or Voice Account.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Update Cost Threshold

Update a given cost threshold.

Authorizations:
X-CM-PRODUCTTOKEN
path Parameters
accountGuid
required
string <uuid>
Example: 00000000-0000-0000-0000-000000000000

Unique identifier of the Logical Account or Voice Account.

sipAccountThresholdGuid
required
string <uuid>
Example: 00000000-0000-0000-0000-000000000000

Unique identifier of the cost threshold rule.

Request Body schema:

Model of the threshold rule

emailAddresses
Array of strings or null <email> [ items <email > ]

List of email addresses that will be notified when cost threshold is surpassed

phoneNumbers
Array of strings or null

List of phone numbers that will be notified when cost threshold is surpassed

guid
string or null <uuid>

Unique identifier for a given threshold rule

voiceAccountGuid
string <uuid>

The unique identifier of the Voice Account which this SIP Account is part of.

sipAccountGuid
string <uuid>

The unique identifier of the SIP Account which the rule applies to

threshold
required
number <double> >= 25

Decimal value representing the cost threshold in the currency of the sip account

blockAccountOnThreshold
boolean

Boolean value whether or not to block the SIP account when the threshold is surpassed

notificationSentOn
string or null <date-time>

Last time when a notification has been sent due to the threshold being passed. Null if threshold has never been passed

Responses

Request samples

Content type
{
  • "emailAddresses": [],
  • "phoneNumbers": [
    ],
  • "guid": "00000000-0000-0000-0000-000000000000",
  • "voiceAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "sipAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "threshold": 200.123,
  • "blockAccountOnThreshold": true,
  • "notificationSentOn": "2019-08-24T14:15:22Z"
}

Response samples

Content type
application/json
{
  • "emailAddresses": [],
  • "phoneNumbers": [
    ],
  • "guid": "00000000-0000-0000-0000-000000000000",
  • "voiceAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "sipAccountGuid": "00000000-0000-0000-0000-000000000000",
  • "threshold": 200.123,
  • "blockAccountOnThreshold": true,
  • "notificationSentOn": "2019-08-24T14:15:22Z"
}

Delete Cost Threshold

Remove a given cost threshold.

Authorizations:
X-CM-PRODUCTTOKEN
path Parameters
accountGuid
required
string <uuid>
Example: 00000000-0000-0000-0000-000000000000

Unique identifier of the Logical Account or Voice Account.

sipAccountThresholdGuid
required
string <uuid>

Unique identifier of the cost threshold rule.

Responses

Response samples

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