Add a Cloudflare Device
Payload
| Name | Description |
|---|---|
| name
|
(Mandatory) Name of the device. Constraints:
|
| accessUrl | (Mandatory) Access URL of the Cloudflare. |
| accountNumber | (Mandatory) Account number. |
| vendor
|
(Mandatory) Vendor of the device - Cloudflare. |
| credentialType
|
(Mandatory) Type of credential to be associated for the
device. The possible value is:
|
| module
|
(Mandatory) Modules with which the device is to be
added. The possible value is:
|
| dataCenter
|
(Optional) Data center with which the device is to be added. |
Response Structure
- Status Code: 202 OK
- Message: Successful
- Headers:
- Content-Type: application/json
| Name | Description |
|---|---|
| response
|
Success message or failure description in case of error. |
| message
|
Success message or failure description in case of error. |
| appStatusCode
|
Application specific status code for the response. Will be non-null for failure response. |
| tags
|
More info in case of failure response. |
Status Codes
| HTTP Status Code | appStatusCode | Message | Possible remediation |
|---|---|---|---|
| 202 Accepted | - | Device has been successfully added and configuration parse is triggered | - |
| 400 Bad Request | ADC_INV_0004 | Validation error | One or more fields are invalid. Reason for validation failure and possible remediation will be available in ‘tags’ field of response. |
| 409 Conflict | ADC_INV_0001 | Device(s) Already Exists | Device already exists in AppViewX. Change the name of the device and IP/FQDN. |
| 409 Conflict | ADC_INV_0006 | Device Name Already Exists. | Change the name of the device and retry adding. |
| 409 Conflict | ADC_INV_0007 | IP Already Exists | Change the IP of the device and retry adding. |
| 409 Conflict | ADC_INV_0027 | FQDN already exists | Change the FQDN field of the device and retry adding. |
| 404 Not Found | ADC_INV_1076 | Device not available for the given details. | Check if the requested device is added in the inventory. |
Sample Request/Response
Use Case
Add a Cloudflare device of name cloudflare4,with access URL https://api.cloudflare.com/client/v4/ with account number b15f0ecdf78c8b0d27923d2db551844f.
https://<IP/HostName/TenantName>:<GWPORT>/avxapi/adc-device-add
Sample Request
{
"payload": {
"name": "cloudflare4",
"accessUrl": "https://api.cloudflare.com/client/v4/",
"accountNumber": "b15f0ecdf78c8b0d27923d2db551844f",
"vendor": "Cloudflare",
"module": [
"GSLB"
],
"credentialType": "Manual Entry",
"password": "U0xJR1hPajFpcHlYNWFPeEdHX1ZnNGhfeGVZenlvRjhIbVlMdUw3Mg=="
}
}Sample Response
{
"response": "Device is added to the inventory.",
"message": "Device has been successfully added and configuration parse is triggered.",
"appStatusCode": null,
"tags": null,
"headers": null
}