Create Address Object

Creates a new address object for a specified address group.

HTTP Request

POST /api/sonar/address-groups/:guid/addresses
Request using cURL
curl -H "Authorization: Bearer <API_KEY>" \
     -d address=1.1.1.1 \
     -d description="Public DNS" \
     -X POST \
     https://HOSTNAME/api/sonar/address-groups/4dc14f3d-ebf8-4032-8a7a-ef9ec6cd3dd2/addresses
Request Parameters
KeyRequiredTypeDescriptionNote
guidOStringAddress group GUID36 characters
addressOStringIP address
descriptionXStringDescriptionMaximimum 255 characters
periodX32-bit integerRetention period in daysMinimum 1 to maximum 52,560,000

Success Response

{}

Error Responses

Required argument is missing

HTTP status code 400

{
  "error_code": "null-argument",
  "error_msg": "address should be not null"
}
Invalid argument length

HTTP status code 400

{
  "error_code": "invalid-argument",
  "error_msg": "'description' must be shorter than or equal to 255 characters."
}
Identifier is not in valid GUID format

HTTP status code 400

{
  "error_code": "invalid-param-type",
  "error_msg": "guid should be guid type."
}
Invalid IP address

HTTP status code 400

{
  "error_code": "invalid-argument",
  "error_msg": "address should be valid IPv4 address: 256.255.255.255"
}
Retention period value is less than 1

HTTP status code 400

{
  "error_code": "invalid-argument",
  "error_msg": "'period' must be greater than or equal to 1."
}
Retention period value is greater than 52,560,000

HTTP status code 400

{
  "error_code": "invalid-argument",
  "error_msg": "'period' must be less than or equal to 52560000."
}
Address group is not found

HTTP status code 500

{
  "error_code": "illegal-state",
  "error_msg": "address group not found: ede06992-dd57-4b79-8c54-a295f33d8613"
}
No privilege to create an address group

HTTP status code 500

{
  "error_code": "illegal-state",
  "error_msg": "no-permission"
}