Vonage Traffic Control API

Versão 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

Baixar a especificação 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

Autenticação

ChaveDescriçãoOndeExemplo
Authorization

Chave e segredo da API codificados em Base64, separados por dois pontos.
Leia mais

Headers

Basic <base64>

Caminho Parâmetros

product_name
string
Obrigatório

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

Deve ser uma das seguintes opções:sms

Respostas
Tipo de conteúdo
application/json

The current VTC activation status for the specified product.

Cabeçalho Parâmetros
X-Request-Id
string(uuid)
exemplof94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Obrigatório
data
object

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

status
string
Obrigatório
exemploACTIVATED

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

Deve ser uma das seguintes opções:ACTIVATEDDEACTIVATED
_links
object
Obrigatório

HAL Links object

self
object
Obrigatório

A single HAL link object

href
string
Obrigatório
exemplohttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exemploapplication/json

Media type hint for the target resource

name
string
exemploresource-name

Secondary key for selecting link objects

title
string
exemploResource Title

Human-readable title for the link

Exemplo Resposta

{
   "_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

Autenticação

ChaveDescriçãoOndeExemplo
Authorization

Chave e segredo da API codificados em Base64, separados por dois pontos.
Leia mais

Headers

Basic <base64>

Caminho Parâmetros

product_name
string
Obrigatório

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

Deve ser uma das seguintes opções:sms

Respostas
Tipo de conteúdo
application/json

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

Cabeçalho Parâmetros
X-Request-Id
string(uuid)
exemplof94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Obrigatório
data
object

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

status
string
Obrigatório
exemploACTIVATED

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

Deve ser uma das seguintes opções:ACTIVATEDDEACTIVATED
_links
object
Obrigatório

HAL Links object

self
object
Obrigatório

A single HAL link object

href
string
Obrigatório
exemplohttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exemploapplication/json

Media type hint for the target resource

name
string
exemploresource-name

Secondary key for selecting link objects

title
string
exemploResource Title

Human-readable title for the link

Exemplo Resposta

{
   "_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

Autenticação

ChaveDescriçãoOndeExemplo
Authorization

Chave e segredo da API codificados em Base64, separados por dois pontos.
Leia mais

Headers

Basic <base64>

Caminho Parâmetros

product_name
string
Obrigatório

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

Deve ser uma das seguintes opções:sms

Respostas
Tipo de conteúdo
application/json

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

Cabeçalho Parâmetros
X-Request-Id
string(uuid)
exemplof94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Obrigatório
data
object

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

status
string
Obrigatório
exemploACTIVATED

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

Deve ser uma das seguintes opções:ACTIVATEDDEACTIVATED
_links
object
Obrigatório

HAL Links object

self
object
Obrigatório

A single HAL link object

href
string
Obrigatório
exemplohttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exemploapplication/json

Media type hint for the target resource

name
string
exemploresource-name

Secondary key for selecting link objects

title
string
exemploResource Title

Human-readable title for the link

Exemplo Resposta

{
   "_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

Autenticação

ChaveDescriçãoOndeExemplo
Authorization

Chave e segredo da API codificados em Base64, separados por dois pontos.
Leia mais

Headers

Basic <base64>

Caminho Parâmetros

product_name
string
Obrigatório

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

Deve ser uma das seguintes opções:sms

Respostas
Tipo de conteúdo
application/json

The current queue size for the specified product.

Cabeçalho Parâmetros
X-Request-Id
string(uuid)
exemplof94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Obrigatório
data
object

Object representing the current queue size for the VTC service.

queue_size
integer
Obrigatório
exemplo100

The current number of messages in the queue.

_links
object
Obrigatório

HAL Links object

self
object
Obrigatório

A single HAL link object

href
string
Obrigatório
exemplohttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exemploapplication/json

Media type hint for the target resource

name
string
exemploresource-name

Secondary key for selecting link objects

title
string
exemploResource Title

Human-readable title for the link

Exemplo Resposta

{
   "_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

Autenticação

ChaveDescriçãoOndeExemplo
Authorization

Chave e segredo da API codificados em Base64, separados por dois pontos.
Leia mais

Headers

Basic <base64>

Caminho Parâmetros

product_name
string
Obrigatório

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

Deve ser uma das seguintes opções:sms

Consulta Parâmetros

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

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

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

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

Respostas
Tipo de conteúdo
application/json

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

Cabeçalho Parâmetros
X-Request-Id
string(uuid)
exemplof94b4e56-604e-07e5-e5ad-5a7228618f81
A unique identifier for the request, used for tracking and debugging
_embedded
object
Obrigatório
historical_data
array

Array of historical queue size data points.

queue_size
integer
Obrigatório
exemplo30

The queue size at a specific point in time.

timestamp
string(date-time)
Obrigatório
exemplo2024-06-12T15:59:22.870Z

The timestamp of when the queue size was recorded.

_links
object
Obrigatório

HAL Links object

self
object
Obrigatório

A single HAL link object

href
string
Obrigatório
exemplohttps://api.vonage.com/v1/resources/abc123

The URL for the resource

templated
boolean

Indicates if the href is a URI template

type
string
exemploapplication/json

Media type hint for the target resource

name
string
exemploresource-name

Secondary key for selecting link objects

title
string
exemploResource Title

Human-readable title for the link

Exemplo Resposta

{
   "_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"
      }
   }
}