Cloud Jasmin DevelopmentGuides
DevelopmentGuides
Guides
Back | List of Articles

Response state codes

Last changed in 29/08/2022

Responses to Web API requests produce different HTTP status codes depending on the result of the operation.

If the operation is successfully executed, an expected status code for the operation type is returned.

If an error occurs, for example, in the validation of the request parameters, or if another unexpected exception occurs, an error status code is returned.

Status codes

The following is the list of status codes that can be returned for each endpoint.

Creating a record (POST)

Expected status codes:

  • 201 (Created) – the record has been created successfully.

Error status codes:

  • 400 (BadRequest) – request parameters are invalid.
  • 401 (Unauthorized) – authentication headers are not valid.
  • 403 (Forbidden) – the app is not authorized to access the subscription.
  • 500 (InternalServerError) – an internal error occurred while processing the request.

Updating a record attribute (PUT)

Expected status codes:

  • 200 (OK) – the record has been updated successfully.

Error status codes:

  • 401 (Unauthorized) – the authentication headers are not valid.
  • 404 (NotFound) – the record does not exist.
  • 403 (Forbidden) – the app is not authorized to access the subscription.
  • 500 (InternalServerError) – an internal error occurred while processing the request.

Canceling a record (DELETE)

Expected status codes:

  • 204 (NoContent) – the record has been deleted successfully.

Error status codes:

  • 401 (Unauthorized) – the authentication headers are not valid.
  • 403 (Forbidden) – the app is not authorized to access the subscription.
  • 500 (InternalServerError) – an internal error occurred while processing the request.

Viewing a record (GET)

Expected status codes:

  • 200 (OK) – the message body contains the record.

Error status codes:

  • 401 (Unauthorized) – the authentication headers are not valid.
  • 403 (Forbidden) – the app is not authorized to access the subscription.
  • 404 (NotFound) – the record does not exist.
  • 500 (InternalServerError) – an internal error occurred while processing the request.

List of all records (GET)

Expected status codes:

  • 200 (OK) – the message body contains the list of records.

Error status codes:

  • 401 (Unauthorized) – the authentication headers are not valid.
  • 403 (Forbidden) – the app is not authorized to access the subscription.
  • 500 (InternalServerError) – an internal error occurred while processing the request.

List of record page (GET)

Expected status codes:

  • 200 (OK) – the message body contains the record list.

Error status codes:

  • 401 (Unauthorized) – the authentication headers are not valid.
  • 403 (Forbidden) – the app is not authorized to access the subscription.
  • 500 (InternalServerError) – an internal error occurred while processing the request.

Error messages

If an error occurs in the request, the body of the response message includes additional data about the error.

Further information: Error messages

Bookmark or share this article
Esta página foi útil?
Obrigado pelo seu voto.

login para deixar a sua opinião.

Obrigado pelo seu feedback. Iremos analisá-lo para continuarmos a melhorar!
Artigos Relacionados
Boas práticas de integração Como utilizar OData para obter uma lista de encomendas? Como executar queries OData sobre os dados? Actualización de los endpoints de las integraciones [ES] Códigos de estado das respostas