Erros de API

Quando uma API da Vonage retorna um erro — por exemplo, se sua conta não tiver crédito —, a API retornará um erro no formato RFC 7807.

Isso fornece uma explicação básica sobre qual é o problema, por que ele ocorreu e quais são as etapas para resolvê-lo. Confira o exemplo para ver como um relatório de resolução de problema ( out-of-credit ) é formatado.

Provavelmente, você vai querer avaliar desde o início quais erros seu aplicativo precisará tratar; esta página fornece uma lista de todos os erros possíveis que podem ocorrer, com uma explicação mais detalhada de como lidar com eles.

HTTP/1.1 403 Forbidden
Content-Type: application/problem+json
Content-Language: en
{
  "type": "https://example.com/Error#out-of-credit",
  "title": "You do not have enough credit",
  "detail": "Your current balance is 30, but that costs 50.",
  "instance": "<trace_id>"
}

10 API do DLC

CódigoInformações
brand-conflict

Descrição

A conflict when a brand is being created or edited and there is an issue with a 3rd party vendor.

Resolução

Ensure all required fields have values and there are no errors in those values. If the error persists, contact support.

brand-parameters

Descrição

There are errors in the brand data submitted.

Resolução

Ensure all required fields have values included and correct any errors to values in the specified fields.

invalid-usecase-data

Descrição

There are errors in the data submitted for use case qualification.

Resolução

Ensure all required fields have values included and correct any errors to values in the specified fields.

use-case-denied

Descrição

The use case requested has been denied for this brand.

Resolução

Ensure your use case does not require additional brand vetting or pre/post Mobile Network Operator approval.

vetting-conflict

Descrição

A conflict during the brand vetting request has occurred.

Resolução

If the error persists, contact support.

invalid-vetting-data

Descrição

There are errors in the vetting request data submitted.

Resolução

Ensure all required fields have values and correct any errors to values in the specified fields.

invalid-json

Descrição

Your request cannot be parsed.

Resolução

Ensure there are no invalid characters or values in your request.

brand-not-qualified

Descrição

A conflict when a campaign is being created under a brand that hasn't qualified for the specified use case.

Resolução

Verify the brand use case qualifies before submitting the campaign.

invalid-campaign-data

Descrição

There are errors in the campaign data submitted.

Resolução

Ensure all required fields have values and correct any errors to values in the specified fields.

numbers-already-linked

Descrição

The number you are attempting to link is already linked to another campaign.

Resolução

You must link a unique number to a campaign. Link a different number to this campaign.

invalid-number-data

Descrição

There are errors in the number data submitted.

Resolução

Ensure all required fields have values and correct any errors to values in the specified fields.