Skip to main content

Healthchecks

GET HealthChecks#

Gets all healthchecks associated with the current distribution

GET ALL
MethodGET ALL
URL or EndPoint/api/v{version}/projects/{projectId}/distributions/{distributionId}/healthchecks
HeadersAuthorization
ParametersdistributionId, projectId, version
BodyNot Applicable

The description of the URL parameters is as follows:

URL Parameter NameMandatoryTypeExampleDescription
v{version}Yesstringv1Shows the version of API
{projectId}Yesstring($uuid)3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
{distributionId}Yesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned

The description of the parameters is as follows:

Parameter NameMandatoryTypeExampleDescription
projectIdYesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty project configuration is returned
distributionIdYesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
VersionYesstring($uuid)v1Shows the version of API

Request Body#

The request does not have a request body.

Responses#

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in json format by the service.

{  "success": true,  "errors": [    "string"  ],  "messages": [    "string"  ],  "result": [    {      "id": 0,      "distributionId": "string",      "name": "string",      "requestMethod": "string",      "requestPath": "string",      "host": "string",      "expectedResponse": 0,      "interval": 0    }  ],  "resultInfo": {    "totalCount": 0,    "pageIndex": 0,    "pageSize": 0,    "totalPages": 0,    "hasNextPage": true,    "hasPreviousPage": true  }}
Field NameTypeExampleDescription
successbooltrueIf response is success will return true otherwise will return false
errorsarray []"string"Indicate if there was an error
messagesarray []"string"Returns the response message from back-end
resultarray [object]Returns a behavior object
idinteger($int32)0The identifier for the healthe check
distributionId"string"stringReturns the distribution id
namestring"string"Returns name of the healthcheck
requestMethodstring"string"Returns the request method
requestPathstring"string"Returns the request path
hoststring"string"Returns the host for the healthcheck
expectedResponseinteger($int32)0Returns the expected response for the healthcheck
intervalinteger($int32)0Returns the interval for the healthcheck
resultInfoarray [object]Returns an object of behavior
totalCountinteger($int32)0How many records of behavior entity are in database
pageIndexinteger($int32)0Returns how many pages of paganed data are
pageSizeinteger($int32)0Returns paganed data
totalPagesinteger($int32)0How many pages
hasNextPagebooltrueReturns the next page of paganed data
hasPreviousPagebooltrueReturns the previous page of paganed data

Errors

For information about the errors that are common to all actions, see Common Errors:

  • HTTP Status Code: 401 Unauthorized
  • HTTP Status Code: 403 Forbidden
  • HTTP Status Code: 404 Not found

POST Healthcheck#

Creates a new healthcheck.

POST
MethodPOST
URL or EndPoint/api/v{version}/projects/{projectId}/distributions/{distributionId}/healthchecks
HeadersAuthorization
ParametersprojectId, distributionId, version
Body{ name, requestMethod, requestPath, host, expectedResponse. threshold, window, interval, timeout, initial }

The description of the URL parameters is as follows:

URL Parameter NameMandatoryTypeExampleDescription
v{version}Yesstringv1Shows the version of API
{projectId}Yesstring($uuid)3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
{distributionId}Yesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned

The description of the parameters is as follows:

Parameter NameMandatoryTypeExampleDescription
projectIdYesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty project configuration is returned
distributionIdYesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
VersionYesstring($uuid)v1Shows the version of API

Request body#

{  "name": "string",  "requestMethod": 0,  "requestPath": "string",  "host": "string",  "expectedResponse": 0,  "threshold": 0,  "window": 0,  "interval": 0,  "timeout": 0,  "initial": 0}

The description of the parameters is as follows:

Body Parameter NameMandatoryTypeExampleDescription
nameYesstring"string"Sends the name for healthcheck
requestMethodYesinteger($int32)0Sends the request method
requestPathYesstring"string"Sends the request path
hostNostring"string"Sends the host
expectedResponseYesinteger($int32)0Sends the expected response
thresholdYesinteger($int32)0Sends the threshold
windowYesinteger($int32)0Sends the window
intervalYesinteger($int32)0Sends the interval for the healthcheck
timeoutNointeger($int32)0Sends the timeout for healthcheck
initialYesinteger($int32)0Sends the initial for the healthcheck

Responses#

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in json format by the service.

{  "success": true,  "errors": [    "string"  ],  "messages": [    "string"  ],  "result": {    "id": 0,    "distributionId": "string",    "name": "string",    "requestMethod": 0,    "requestPath": "string",    "host": "string",    "expectedResponse": 0,    "threshold": 0,    "window": 0,    "interval": 0,    "timeout": 0,    "initial": 0,    "requestMethodOptions": [      {        "id": 0,        "value": "string"      }    ],    "expectedResponseOptions": [      {        "id": 0,        "value": "string"      }    ]  },  "resultInfo": {    "totalCount": 0,    "pageIndex": 0,    "pageSize": 0,    "totalPages": 0,    "hasNextPage": true,    "hasPreviousPage": true  }}
Field NameTypeExampleDescription
successbooltrueIf response is success will return true otherwise will return false
errorsstring"string"Indicate if there was an error
messagesstring"string"Returns the response message from back-end
resultarray [object]Returns a behavior object
idinteger($int32)0The identifier for the behavior
distributionIdstring"string"Returns the identifier of distribution in behaviors
namestring"string"Returns the name for healthcheck
requestMethodinteger($int32)0Returns the request method
requestPathstring"string"Returns the request path
hoststring"string"Returns the host
expectedResponseinteger($int32)0Returns the expected response
thresholdinteger($int32)0Returns the threshold
windowinteger($int32)0Returns the window
intervalinteger($int32)0Returns the interval for the healthcheck
timeoutinteger($int32)0Returns the timeout for healthcheck
initialinteger($int32)0Returns the initial for the healthcheck
requestMethodOptionsarray[object]Returns the request method options
idstring"string"Returns the id of request method option
valuestring"string"Returns the value of the request method option
expectedResponseOptionsarray[object]Returns the expected response options
idinteger($int32)0Returns the id of expected response options
valueinteger($int32)0Returns the value of expected response options
resultInfoarray [object]Returns an object of behavior
totalCountinteger($int32)0How many records of behavior entity are in database
pageIndexinteger($int32)0Returns how many pages of paganed data are
pageSizeinteger($int32)0Returns paganed data
totalPagesinteger($int32)0How many pages
hasNextPagebooltrueReturns the next page of paganed data
hasPreviousPagebooltrueReturns the previous page of paganed data

Errors

For information about the errors that are common to all actions, see Common Errors:

  • HTTP Status Code: 401 Unauthorized
  • HTTP Status Code: 403 Forbidden
  • HTTP Status Code: 404 Not found

GET HealthCheck#

Gets the healthcheck by id

GET
MethodGET By Id
URL or EndPoint/api/v{version}/projects/{projectId}/distributions/{distributionId}/healthchecks/{id}
HeadersAuthorization
ParametersdistributionId, id, version, projectId
BodyNot Applicable

The description of the URL parameters is as follows:

URL Parameter NameMandatoryTypeExampleDescription
v{version}Yesstringv1Shows the version of API
{projectId}Yesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
{distributionId}Yesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
{id}Yesinteger($int32)0Shows the version of API

The description of the parameters is as follows:

Parameter NameMandatoryTypeExampleDescription
projectIdYesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
versionYesstringv1Shows the version of API
distributionIdYesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
idYesinteger($int32)0The behavior's ID.

Request Body#

The request does not have a request body.

Responses#

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in json format by the service.

{  "success": true,  "errors": [    "string"  ],  "messages": [    "string"  ],  "result": {    "id": 0,    "distributionId": "string",    "name": "string",    "requestMethod": 0,    "requestPath": "string",    "host": "string",    "expectedResponse": 0,    "threshold": 0,    "window": 0,    "interval": 0,    "timeout": 0,    "initial": 0,    "requestMethodOptions": [      {        "id": 0,        "value": "string"      }    ],    "expectedResponseOptions": [      {        "id": 0,        "value": "string"      }    ]  },  "resultInfo": {    "totalCount": 0,    "pageIndex": 0,    "pageSize": 0,    "totalPages": 0,    "hasNextPage": true,    "hasPreviousPage": true  }}
Field NameTypeExampleDescription
successbooltrueIf response is success will return true otherwise will return false
errorsstring"string"Indicate if there was an error
messagesstring"string"Returns the response message from back-end
resultarray [object]Returns a behavior object
idinteger($int32)0The identifier for the behavior
distributionIdstring"string"Returns the identifier of distribution in behaviors
namestring"string"Returns the name for healthcheck
requestMethodinteger($int32)0Returns the request method
requestPathstring"string"Returns the request path
hoststring"string"Returns the host
expectedResponseinteger($int32)0Returns the expected response
thresholdinteger($int32)0Returns the threshold
windowinteger($int32)0Returns the window
intervalinteger($int32)0Returns the interval for the healthcheck
timeoutinteger($int32)0Returns the timeout for healthcheck
initialinteger($int32)0Returns the initial for the healthcheck
requestMethodOptionsarray[object]Returns the request method options
idstring"string"Returns the id of request method option
valuestring"string"Returns the value of the request method option
expectedResponseOptionsarray[object]Returns the expected response options
idinteger($int32)0Returns the id of expected response options
valueinteger($int32)0Returns the value of expected response options
resultInfoarray [object]Returns an object of behavior
totalCountinteger($int32)0How many records of behavior entity are in database
pageIndexinteger($int32)0Returns how many pages of paganed data are
pageSizeinteger($int32)0Returns paganed data
totalPagesinteger($int32)0How many pages
hasNextPagebooltrueReturns the next page of paganed data
hasPreviousPagebooltrueReturns the previous page of paganed data

Errors

For information about the errors that are common to all actions, see Common Errors:

  • HTTP Status Code: 401 Unauthorized
  • HTTP Status Code: 403 Forbidden
  • HTTP Status Code: 404 Not found

PUT HealthCheck#

Updates an existing healthcheck.

PUT
MethodPUT
URL or EndPoint/api/v{version}/projects/{projectId}/distributions/{distributionId}/healthchecks/{id}
HeadersAuthorization
ParametersdistributionId, id, version, projectId
Body{ name, requestMethod, requestPath, host, expectedResponse. threshold, window, interval, timeout, initial

The description of the URL parameters is as follows:

URL Parameter NameMandatoryTypeExampleDescription
v{version}Yesstringv1Shows the version of API
{projectId}Yesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
{distributionId}Yesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
{id}Yesinteger($int32)0Shows the version of API

The description of the parameters is as follows:

Parameter NameMandatoryTypeExampleDescription
projectIdYesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
versionYesstringv1Shows the version of API
distributionIdYesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
idYesinteger($int32)0The behavior's ID.

Request body#

{  "name": "string",  "requestMethod": 0,  "requestPath": "string",  "host": "string",  "expectedResponse": 0,  "threshold": 0,  "window": 0,  "interval": 0,  "timeout": 0,  "initial": 0}

The description of the parameters is as follows:

Body Parameter NameMandatoryTypeExampleDescription
nameYesstring"string"Sends the name for healthcheck
requestMethodYesinteger($int32)0Sends the request method
requestPathYesstring"string"Sends the request path
hostNostring"string"Sends the host
expectedResponseYesinteger($int32)0Sends the expected response
thresholdYesinteger($int32)0Sends the threshold
windowYesinteger($int32)0Sends the window
intervalYesinteger($int32)0Sends the interval for the healthcheck
timeoutNointeger($int32)0Sends the timeout for healthcheck
initialYesinteger($int32)0Sends the initial for the healthcheck

Responses#

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in json format by the service.

{  "success": true,  "errors": [    "string"  ],  "messages": [    "string"  ],  "result": {    "id": 0,    "distributionId": "string",    "name": "string",    "requestMethod": 0,    "requestPath": "string",    "host": "string",    "expectedResponse": 0,    "threshold": 0,    "window": 0,    "interval": 0,    "timeout": 0,    "initial": 0,    "requestMethodOptions": [      {        "id": 0,        "value": "string"      }    ],    "expectedResponseOptions": [      {        "id": 0,        "value": "string"      }    ]  },  "resultInfo": {    "totalCount": 0,    "pageIndex": 0,    "pageSize": 0,    "totalPages": 0,    "hasNextPage": true,    "hasPreviousPage": true  }}
Field NameTypeExampleDescription
successbooltrueIf response is success will return true otherwise will return false
errorsstring"string"Indicate if there was an error
messagesstring"string"Returns the response message from back-end
resultarray [object]Returns a behavior object
idinteger($int32)0The identifier for the behavior
distributionIdstring"string"Returns the identifier of distribution in behaviors
namestring"string"Returns the name for healthcheck
requestMethodinteger($int32)0Returns the request method
requestPathstring"string"Returns the request path
hoststring"string"Returns the host
expectedResponseinteger($int32)0Returns the expected response
thresholdinteger($int32)0Returns the threshold
windowinteger($int32)0Returns the window
intervalinteger($int32)0Returns the interval for the healthcheck
timeoutinteger($int32)0Returns the timeout for healthcheck
initialinteger($int32)0Returns the initial for the healthcheck
requestMethodOptionsarray[object]Returns the request method options
idstring"string"Returns the id of request method option
valuestring"string"Returns the value of the request method option
expectedResponseOptionsarray[object]Returns the expected response options
idinteger($int32)0Returns the id of expected response options
valueinteger($int32)0Returns the value of expected response options
resultInfoarray [object]Returns an object of behavior
totalCountinteger($int32)0How many records of behavior entity are in database
pageIndexinteger($int32)0Returns how many pages of paganed data are
pageSizeinteger($int32)0Returns paganed data
totalPagesinteger($int32)0How many pages
hasNextPagebooltrueReturns the next page of paganed data
hasPreviousPagebooltrueReturns the previous page of paganed data

Errors

For information about the errors that are common to all actions, see Common Errors:

  • HTTP Status Code: 401 Unauthorized
  • HTTP Status Code: 403 Forbidden
  • HTTP Status Code: 404 Not found

DELETE HealthCheck#

Deletes healthcheck by id.

DELETE
MethodDELETE
URL or EndPoint/api/v{version}/projects/{projectId}/distributions/{distributionId}/behaviors/{id}
HeadersAuthorization
ParametersdistributionId, id, version, projectId
BodyNot Applicable

The description of the URL parameters is as follows:

URL Parameter NameMandatoryTypeExampleDescription
v{version}Yesstringv1Shows the version of API
{projectId}Yesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
{distributionId}Yesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
{id}Yesinteger($int32)0Shows the version of API

The description of the parameters is as follows:

Parameter NameMandatoryTypeExampleDescription
projectIdYesstring3fa85f64-5717-4562-b3fc-2c963f66afa6The project's ID. If the ID is empty, an empty distribution configuration is returned
versionYesstringv1Shows the version of API
distributionIdYesstring"string"The distribution's ID. If the ID is empty, an empty distribution configuration is returned
idYesinteger($int32)0The behavior's ID.

Responses#

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in json format by the service.

{  "success": true,  "errors": [    "string"  ],  "messages": [    "string"  ],  "result": {    "id": 0,    "distributionId": "string",    "name": "string",    "requestMethod": 0,    "requestPath": "string",    "host": "string",    "expectedResponse": 0,    "threshold": 0,    "window": 0,    "interval": 0,    "timeout": 0,    "initial": 0,    "requestMethodOptions": [      {        "id": 0,        "value": "string"      }    ],    "expectedResponseOptions": [      {        "id": 0,        "value": "string"      }    ]  },  "resultInfo": {    "totalCount": 0,    "pageIndex": 0,    "pageSize": 0,    "totalPages": 0,    "hasNextPage": true,    "hasPreviousPage": true  }}
Field NameTypeExampleDescription
successbooltrueIf response is success will return true otherwise will return false
errorsstring"string"Indicate if there was an error
messagesstring"string"Returns the response message from back-end
resultarray [object]Returns a behavior object
idinteger($int32)0The identifier for the behavior
distributionIdstring"string"Returns the identifier of distribution in behaviors
namestring"string"Returns the name for healthcheck
requestMethodinteger($int32)0Returns the request method
requestPathstring"string"Returns the request path
hoststring"string"Returns the host
expectedResponseinteger($int32)0Returns the expected response
thresholdinteger($int32)0Returns the threshold
windowinteger($int32)0Returns the window
intervalinteger($int32)0Returns the interval for the healthcheck
timeoutinteger($int32)0Returns the timeout for healthcheck
initialinteger($int32)0Returns the initial for the healthcheck
requestMethodOptionsarray[object]Returns the request method options
idstring"string"Returns the id of request method option
valuestring"string"Returns the value of the request method option
expectedResponseOptionsarray[object]Returns the expected response options
idinteger($int32)0Returns the id of expected response options
valueinteger($int32)0Returns the value of expected response options
resultInfoarray [object]Returns an object of behavior
totalCountinteger($int32)0How many records of behavior entity are in database
pageIndexinteger($int32)0Returns how many pages of paganed data are
pageSizeinteger($int32)0Returns paganed data
totalPagesinteger($int32)0How many pages
hasNextPagebooltrueReturns the next page of paganed data
hasPreviousPagebooltrueReturns the previous page of paganed data

Errors

For information about the errors that are common to all actions, see Common Errors:

  • HTTP Status Code: 401 Unauthorized
  • HTTP Status Code: 403 Forbidden
  • HTTP Status Code: 404 Not found