Vonage Traffic Control API

Version 1

API for activating or deactivating the Vonage Traffic Control (VTC) service for supported products and for checking the current VTC status. For more infomation, see our developer documentation

Télécharger la spécification OpenAPI

Traffic Control

Get VTC activation status for the product

Returns the current activation status of the Vonage Traffic Control (VTC) service for the specified product.

gethttps://api.nexmo.com/vtc/v1/configuration/product/:product_name

Authentification

CléDescriptionExemple
Authorization

Clé et secret de l'API encodés en Base64 et reliés par deux points.
En savoir plus

Headers

Basic <base64>

Trajectoire Paramètres

product_name
string
Exigée

The product name for which the VTC service is being managed. Only supported products are allowed.

Il doit s'agir de l'un d'entre eux :sms

Réponses
Type de contenu
application/json

The current VTC activation status for the specified product.

En-tête Paramètres
X-Request-Id
string(uuid)
exemplef94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Exigée
data
object

Object representing the activated/deactivated status of the Vonage Traffic Control (VTC) service.

status
string
Exigée
exempleACTIVATED

Indicates whether the VTC service is activated (ACTIVATED) or deactivated (DEACTIVATED) for the product.

Il doit s'agir de l'un d'entre eux :ACTIVATEDDEACTIVATED
_links
object
Exigée

HAL Links object

self
object
Exigée

A single HAL link object

href
string
Exigée
exemplehttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exempleapplication/json

Media type hint for the target resource

name
string
exempleresource-name

Secondary key for selecting link objects

title
string
exempleResource Title

Human-readable title for the link

Exemple Réponse

{
   "_embedded": {
      "data": {
         "status": "ACTIVATED"
      }
   },
   "_links": {
      "self": {
         "href": "https://api.vonage.com/v1/resources/abc123",
         "templated": false,
         "type": "application/json",
         "name": "resource-name",
         "title": "Resource Title"
      }
   }
}

Activate VTC for the product

Activates the Vonage Traffic Control (VTC) service for the specified product.

posthttps://api.nexmo.com/vtc/v1/configuration/product/:product_name/activate

Authentification

CléDescriptionExemple
Authorization

Clé et secret de l'API encodés en Base64 et reliés par deux points.
En savoir plus

Headers

Basic <base64>

Trajectoire Paramètres

product_name
string
Exigée

The product name for which the VTC service is being managed. Only supported products are allowed.

Il doit s'agir de l'un d'entre eux :sms

Réponses
Type de contenu
application/json

A HAL response with a relative link to check the resource status.

En-tête Paramètres
X-Request-Id
string(uuid)
exemplef94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Exigée
data
object

Object representing the activated/deactivated status of the Vonage Traffic Control (VTC) service.

status
string
Exigée
exempleACTIVATED

Indicates whether the VTC service is activated (ACTIVATED) or deactivated (DEACTIVATED) for the product.

Il doit s'agir de l'un d'entre eux :ACTIVATEDDEACTIVATED
_links
object
Exigée

HAL Links object

self
object
Exigée

A single HAL link object

href
string
Exigée
exemplehttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exempleapplication/json

Media type hint for the target resource

name
string
exempleresource-name

Secondary key for selecting link objects

title
string
exempleResource Title

Human-readable title for the link

Exemple Réponse

{
   "_embedded": {
      "data": {
         "status": "ACTIVATED"
      }
   },
   "_links": {
      "self": {
         "href": "https://api.vonage.com/v1/resources/abc123",
         "templated": false,
         "type": "application/json",
         "name": "resource-name",
         "title": "Resource Title"
      }
   }
}

Deactivate VTC for the product

Deactivates the Vonage Traffic Control (VTC) service for the specified product.

posthttps://api.nexmo.com/vtc/v1/configuration/product/:product_name/deactivate

Authentification

CléDescriptionExemple
Authorization

Clé et secret de l'API encodés en Base64 et reliés par deux points.
En savoir plus

Headers

Basic <base64>

Trajectoire Paramètres

product_name
string
Exigée

The product name for which the VTC service is being managed. Only supported products are allowed.

Il doit s'agir de l'un d'entre eux :sms

Réponses
Type de contenu
application/json

A HAL response with a relative link to check the resource status.

En-tête Paramètres
X-Request-Id
string(uuid)
exemplef94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Exigée
data
object

Object representing the activated/deactivated status of the Vonage Traffic Control (VTC) service.

status
string
Exigée
exempleACTIVATED

Indicates whether the VTC service is activated (ACTIVATED) or deactivated (DEACTIVATED) for the product.

Il doit s'agir de l'un d'entre eux :ACTIVATEDDEACTIVATED
_links
object
Exigée

HAL Links object

self
object
Exigée

A single HAL link object

href
string
Exigée
exemplehttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exempleapplication/json

Media type hint for the target resource

name
string
exempleresource-name

Secondary key for selecting link objects

title
string
exempleResource Title

Human-readable title for the link

Exemple Réponse

{
   "_embedded": {
      "data": {
         "status": "ACTIVATED"
      }
   },
   "_links": {
      "self": {
         "href": "https://api.vonage.com/v1/resources/abc123",
         "templated": false,
         "type": "application/json",
         "name": "resource-name",
         "title": "Resource Title"
      }
   }
}

Retrieve the current queue size

Retrieves the current queue size for the Vonage Traffic Control (VTC) service for the specified product.

gethttps://api.nexmo.com/vtc/v1/queues/product/:product_name/current

Authentification

CléDescriptionExemple
Authorization

Clé et secret de l'API encodés en Base64 et reliés par deux points.
En savoir plus

Headers

Basic <base64>

Trajectoire Paramètres

product_name
string
Exigée

The product name for which the VTC service is being managed. Only supported products are allowed.

Il doit s'agir de l'un d'entre eux :sms

Réponses
Type de contenu
application/json

The current queue size for the specified product.

En-tête Paramètres
X-Request-Id
string(uuid)
exemplef94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Exigée
data
object

Object representing the current queue size for the VTC service.

queue_size
integer
Exigée
exemple100

The current number of messages in the queue.

_links
object
Exigée

HAL Links object

self
object
Exigée

A single HAL link object

href
string
Exigée
exemplehttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exempleapplication/json

Media type hint for the target resource

name
string
exempleresource-name

Secondary key for selecting link objects

title
string
exempleResource Title

Human-readable title for the link

Exemple Réponse

{
   "_embedded": {
      "data": {
         "queue_size": 100
      }
   },
   "_links": {
      "self": {
         "href": "https://api.vonage.com/v1/resources/abc123",
         "templated": false,
         "type": "application/json",
         "name": "resource-name",
         "title": "Resource Title"
      }
   }
}

Retrieve historical queue size data

Retrieves historical queue size data for the Vonage Traffic Control (VTC) service for the specified product over a specified date range.

gethttps://api.nexmo.com/vtc/v1/queues/product/:product_name/historical

Authentification

CléDescriptionExemple
Authorization

Clé et secret de l'API encodés en Base64 et reliés par deux points.
En savoir plus

Headers

Basic <base64>

Trajectoire Paramètres

product_name
string
Exigée

The product name for which the VTC service is being managed. Only supported products are allowed.

Il doit s'agir de l'un d'entre eux :sms

Demande de renseignements Paramètres

start_date
string(date-time)
exemple2024-06-12T15:59:22.870Z

The date at which the returned dataset should start in ISO8601 format.

end_date
string(date-time)
exemple2024-06-12T15:59:42.870Z

The date at which the returned dataset should end in ISO8601 format.

Réponses
Type de contenu
application/json

Historical queue size data for the specified product over a specified date range.

En-tête Paramètres
X-Request-Id
string(uuid)
exemplef94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Exigée
historical_data
array

Array of historical queue size data points.

queue_size
integer
Exigée
exemple30

The queue size at a specific point in time.

timestamp
string(date-time)
Exigée
exemple2024-06-12T15:59:22.870Z

The timestamp of when the queue size was recorded.

_links
object
Exigée

HAL Links object

self
object
Exigée

A single HAL link object

href
string
Exigée
exemplehttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exempleapplication/json

Media type hint for the target resource

name
string
exempleresource-name

Secondary key for selecting link objects

title
string
exempleResource Title

Human-readable title for the link

Exemple Réponse

{
   "_embedded": {
      "historical_data": [
         {
            "queue_size": 30,
            "timestamp": "2024-06-12T15:59:22.870Z"
         }
      ]
   },
   "_links": {
      "self": {
         "href": "https://api.vonage.com/v1/resources/abc123",
         "templated": false,
         "type": "application/json",
         "name": "resource-name",
         "title": "Resource Title"
      }
   }
}