List IP restrictions

GET https://www.digicert.com/services/v2/container/{{container_id}}/ip/rules

Use this endpoint to get a list of existing IP rules in your CertCentral account.

Example requests and responses

cURL

curl --request GET 'https://www.digicert.com/services/v2/container/{{container_id}}/ip/rules' \
--header 'X-DC-DEVKEY: {{api_key}}' \
--header 'Content-Type: application/json'

200 OK

{
  "ip_rules": [
    {
      "id": 1233,
      "date_created": "2023-08-17T18:13:44+00:00",
      "account_id": "1234",
      "container_id": 1234,
      "user_id": 0,
      "ip_address": "192.0.2.0",
      "ip_address_end": "192.0.2.5"
    },
    {
      "id": 1234,
      "date_created": "2023-08-17T18:14:44+00:00",
      "account_id": "1234",
      "container_id": 1234,
      "user_id": 0,
      "api_key_id": 1234,
      "ip_address": "192.0.2.29",
      "ip_address_end": "192.0.2.29"
    }
  ]
}

Path parameters

NameTypeDescription
container_idintegerID of the top-level account container (division).
To get the ID of the top-level container in your account, use the List containers API endpoint. The top-level container is the container with a parent_id value of 0.

Response parameters

NameTypeDescription
ip_rulesarray of objectsList of IP rule objects.
.. idintegerIP rule ID. Use this ID to delete an IP rule.
.. date_createdstringDate and time the rule was created. UTC timezone, ISO-8601 format.
.. account_idstringID of account the rule belongs to.
.. container_idintegerID of container the rule belongs to.
.. user_idintegerID of user the rule is for. Returns 0 if the rule does not apply to a specific user (for example, if it applies account wide or to an API key).
.. api_key_idintegerID of API key the rule is for. Not present if the rule does not apply to an API key.
.. ip_addressstringStarting IP address in allowed address range.
.. ip_address_endstringEnding IP address in allowed address range. Alternately, if the rule restricts access to a single address, both ip_address and ip_address_end contain the same value (the allowed address).
.. descriptionstringCustom rule description.