# Settings

# Show

Get the detail of Cloudflare integration.

# HTTP Request:

GET https://api.serveravatar.com/organizations/{organization}/servers/{server}/applications/{application}/dns-manager

# Curl request Example:

curl --request GET \
  --url "https://api.serveravatar.com/organizations/{organization}/servers/{server}/applications/{application}/dns-manager" \
  --header 'Content-Type: application/json' \
  --header 'Authorization: <YOUR API TOKEN>'

# Response:

# Cloudflare detail.

  • 200 (Ok)
{
  "dnsManager": {
    "id": 7,
    "token": "xS--5TvONWoAFCLZLfvBF0cwfiw-ncesHEpI9",
    "domain_id": "a67cfe94229536aba57da2e7b4611c"
  }
}

# Organization Not Found

  • 404 (Not Found)
{
    "message": "Organization not found!"
}

# Application Not found

  • 404 (Not Found)
{
    "message": "Application not found!"
}

# Server Not Found

  • 404 (Not Found)
{
    "message": "Server not found!"
}

# Update

Update Cloudflare details.

# HTTP Request:

PATCH https://api.serveravatar.com/organizations/{organization}/servers/{server}/applications/{application}/dns-manager

# Parameter:

Parameters Required Type Description
bearerToken Yes String Your cloudflare bearer token.
domainId Yes String Your cloudflare zone id.

# Curl Request Example:

curl --request PATCH \
  --url "https://api.serveravatar.com/organizations/{organization}/servers/{server}/applications/{application}/dns-manager" \
  --header 'Content-Type: application/json' \
  --header 'Authorization: <YOUR API TOKEN>' \
  --data '{
    "bearerToken": "xS--5TvONWoAFCLZLfvBF0cwfiw-ncesHEpI9",
    "domainId": "a67cfe94229536aba57da2e7b4611c"
  }'

# Response:

# Update cloudflare detail.

  • 200 (Ok)
{
  "message": "DNS Manager credentials updated successfully."
}

# Organization Not Found

  • 404 (Not Found)
{
    "message": "Organization not found!"
}

# Application Not found

  • 404 (Not Found)
{
    "message": "Application not found!"
}

# Server Not Found

  • 404 (Not Found)
{
    "message": "Server not found!"
}

# Server Error

  • 500 (Internal Server Error)
{
    "message": "Something went really wrong!"
}

# Delete

Delete cloudflare detail.

# HTTP Request:

DELETE https://api.serveravatar.com/organizations/{organization}/servers/{server}/applications/{application}/dns-manager
curl --request DELETE \
  --url "https://api.serveravatar.com/organizations/{organization}/servers/{server}/applications/{application}/dns-manager" \
  --header 'Content-Type: application/json' \
  --header 'Authorization: <YOUR API TOKEN>' 

# Response:

# Delete cloudflare detail.

  • 200 (Ok)
{
	"message":"DNS Manager credentials remove successfully."
}

# Record Not found

  • 404 (Not Found)
{
    "message": "Cloudflare record not found!"
}

# Organization Not Found

  • 404 (Not Found)
{
    "message": "Organization not found!"
}

# Application Not found

  • 404 (Not Found)
{
    "message": "Application not found!"
}

# Server Not Found

  • 404 (Not Found)
{
    "message": "Server not found!"
}

# Server Error

  • 500 (Internal Server Error)
{
    "message": "Something went really wrong!"
}
Last Updated: 5/2/2023, 12:48:26 PM