IP Policies
IP policies let you control which IP addresses can access your Qlik Cloud tenant. Use this API to manage allowlisting rules by creating, listing, updating, and deleting IP policies. When allowlisting is enabled, only users connecting from allowed IPv4 addresses or ranges can access the tenant.
Endpoints
Returns a list of IP policies present in the tenant. The user must be assigned the TenantAdmin role.
Facts
| Rate limit | Tier 1 (1000 requests per minute) |
Query Parameters
- fields string
A comma-separated list of fields to limit in the response.
- filter string
The advanced filtering to use for the query. Refer to RFC 7644 for the syntax. All conditional statements within this query parameter are case insensitive.
field "enabled" supports following operators: eq
field "id" supports following operators: eq, ne
field "name" supports following operators: eq, co
field "tenantId" supports following operators: eq
- limit number
The number of IP policies to retrieve.
- page string
The page cursor. Takes precedence over other parameters.
- sort string
Optional resource field name to sort on, eg. name. Can be prefixed with +/- to determine order, defaults to (+) ascending.
Can be one of: "enabled""+enabled""-enabled""createdAt""+createdAt""-createdAt""updatedAt""+updatedAt""-updatedAt""name""+name""-name"
- totalResults boolean
Determines whether to return a count of the total records matched in the query. Defaults to false.
Responses
200
IP policies retrieved successfully. The response includes an array of IP policies and pagination links.
- application/json object
application/json properties
- data array of objectsRequired
An array of IP policies.
data properties
- id stringRequired Filterable
The unique identifier for the IP policy.
- name string
The descriptive name for the IP policy.
- enabled boolean
Indicates whether the IP policy is enabled.
- editable boolean
Indicates whether the IP policy can be updated.
- tenantId string
The tenant unique identifier associated with the given IP policy.
- createdAt string
The timestamp for when the resource was created.
- createdBy string
The user ID of the user who created the IP policy.
- deletable boolean
Indicates whether the IP policy can be deleted.
- updatedAt string
The timestamp for when the resource was last updated.
- updatedBy string
The user ID of the user who last updated the IP policy.
- allowedIps array of strings
An array of allowed IP addresses.
- toggleable boolean
Indicates whether the IP policy can be enabled/disabled.
-
- links objectRequired
Contains pagination links. self is a link to the current results page, next is a link to the next results page and prev is a link to the previous results page
links properties
- next object
A link
next properties
- href stringRequired
-
- prev object
A link
prev properties
- href stringRequired
-
- self objectRequired
A link
self properties
- href stringRequired
-
-
- totalResults integer
Indicates the total number of matching documents. Will only be returned if the query parameter "totalResults" is true.
-
400
Invalid request parameters for querying IP policies.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
401
Unauthorized, JWT is invalid or not provided.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
429
Request has been rate limited.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
500
Internal server error.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({ hostConfig: { host: 'https://{tenant}.{region}.qlikcloud.com', apiKey: '<access-token>', },})
await qlik.core.ipPolicies.getIpPolicies({})qlik core ip-policy lscurl "https://{tenant}.{region}.qlikcloud.com/api/core/ip-policies" \-H "Authorization: Bearer <access_token>"Example Response
{ "data": [ { "id": "507f191e810c19729de860ea", "name": "Allow access from office IP addresses.", "enabled": true, "editable": true, "tenantId": "644fd58b846d649c82eba436", "createdAt": "2021-03-21T17:32:28Z", "createdBy": "507f191e810c19729de860ea", "deletable": true, "updatedAt": "2021-03-22T10:01:02Z", "updatedBy": "507f191e810c19729de860ea", "allowedIps": [ "61.254.213.0/24", "22.46.216.142" ], "toggleable": true } ], "links": { "next": { "href": "http://mytenant.us.qlikcloud.com/api/core/ip-policies?page=QaFdFYW6pImZvRgFaDyB1UffNgfs4mRd" }, "prev": { "href": "http://mytenant.us.qlikcloud.com/api/core/ip-policies?page=QaFdFYW6pImZvRgFaDyB1UffNgfs4mRd" }, "self": { "href": "http://mytenant.us.qlikcloud.com/api/core/ip-policies?page=QaFdFYW6pImZvRgFaDyB1UffNgfs4mRd" } }, "totalResults": 42}Creates a new IPv4 IP policy in the tenant. If this is the first enabled policy, IP allowlisting will be enabled and access via other IP addresses will be blocked. The user's IP address must be present in at least one policy if allowlisting is enabled. The user must be assigned the TenantAdmin role. IPv6 IP addresses are not currently supported.
Facts
| Rate limit | Tier 2 (100 requests per minute) |
Request Body
Required- application/json object
application/json properties
- name string
The descriptive name for the IP policy.
- enabled boolean
Indicates whether the IP policy is enabled.
- allowedIps array of stringsRequired
An array of allowed IP IPv4 addresses, either as plain IP addresses, or as CIDR ranges.
-
Responses
201
Request successfully completed.
- application/json object
application/json properties
- id stringRequired Filterable
The unique identifier for the IP policy.
- name stringRequired Filterable
The descriptive name for the IP policy.
- enabled booleanRequired
Indicates whether the IP policy is enabled.
- editable booleanRequired
Indicates whether the IP policy can be updated.
- tenantId stringRequired Filterable
The tenant unique identifier associated with the given IP policy.
- createdAt stringRequired Filterable
The timestamp for when the IP policy was created.
- createdBy stringRequired
The user ID of the user who created the IP policy.
- deletable booleanRequired
Indicates whether the IP policy can be deleted.
- updatedAt stringRequired Filterable
The timestamp for when the IP policy was last updated.
- updatedBy stringRequired
The user ID of the user who last updated the IP policy.
- allowedIps array of stringsRequired
An array of allowed public IPv4 addresses.
- toggleable booleanRequired
Indicates whether the IP policy can be enabled/disabled..
-
400
Invalid request body.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
404
IP Policy ID not found or Invalid format.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
429
Request has been rate limited.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
500
Internal Server Error.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({ hostConfig: { host: 'https://{tenant}.{region}.qlikcloud.com', apiKey: '<access-token>', },})
await qlik.core.ipPolicies.createIpPolicy({ allowedIps: [ '61.254.213.0/24',
'22.46.216.142', ], name: 'Allow access from office IP addresses.',})qlik core ip-policy create \ --allowedIps '61.254.213.0/24,22.46.216.142'curl "https://{tenant}.{region}.qlikcloud.com/api/core/ip-policies" \-X POST \-H "Content-type: application/json" \-H "Authorization: Bearer <access_token>" \-d '{"name":"Allow access from office IP addresses.","enabled":false,"allowedIps":["61.254.213.0/24","22.46.216.142"]}'Example Response
{ "id": "507f191e810c19729de860ea", "name": "Allow access from office IP addresses.", "enabled": true, "editable": true, "tenantId": "644fd58b846d649c82eba436", "createdAt": "2021-03-21T17:32:28Z", "createdBy": "507f191e810c19729de860ea", "deletable": true, "updatedAt": "2021-03-22T10:01:02Z", "updatedBy": "507f191e810c19729de860ea", "allowedIps": [ "61.254.213.0/24", "22.46.216.142" ], "toggleable": true}Retrieves details for a specific IP policy by policy ID.
Facts
| Rate limit | Tier 1 (1000 requests per minute) |
Path Parameters
- id stringRequired
The IP policy unique identifier
Responses
200
Request successfully completed.
- application/json object
application/json properties
- id stringRequired Filterable
The unique identifier for the IP policy.
- name stringRequired Filterable
The descriptive name for the IP policy.
- enabled booleanRequired
Indicates whether the IP policy is enabled.
- editable booleanRequired
Indicates whether the IP policy can be updated.
- tenantId stringRequired Filterable
The tenant unique identifier associated with the given IP policy.
- createdAt stringRequired Filterable
The timestamp for when the IP policy was created.
- createdBy stringRequired
The user ID of the user who created the IP policy.
- deletable booleanRequired
Indicates whether the IP policy can be deleted.
- updatedAt stringRequired Filterable
The timestamp for when the IP policy was last updated.
- updatedBy stringRequired
The user ID of the user who last updated the IP policy.
- allowedIps array of stringsRequired
An array of allowed public IPv4 addresses.
- toggleable booleanRequired
Indicates whether the IP policy can be enabled/disabled..
-
401
Unauthorized, JWT is invalid or not provided.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
404
IP Policy ID not found or Invalid format.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
429
Request has been rate limited.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
500
Internal Server Error.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({ hostConfig: { host: 'https://{tenant}.{region}.qlikcloud.com', apiKey: '<access-token>', },})
await qlik.core.ipPolicies.getIpPolicy('string')qlik core ip-policy get 'string'curl "https://{tenant}.{region}.qlikcloud.com/api/core/ip-policies/{id}" \-H "Authorization: Bearer <access_token>"Example Response
{ "id": "507f191e810c19729de860ea", "name": "Allow access from office IP addresses.", "enabled": true, "editable": true, "tenantId": "644fd58b846d649c82eba436", "createdAt": "2021-03-21T17:32:28Z", "createdBy": "507f191e810c19729de860ea", "deletable": true, "updatedAt": "2021-03-22T10:01:02Z", "updatedBy": "507f191e810c19729de860ea", "allowedIps": [ "61.254.213.0/24", "22.46.216.142" ], "toggleable": true}Updates the IP policy. If this is the first enabled policy in the tenant, IP allowlisting will be enabled and access via other IP addresses will be blocked. The user's IP address must be present in at least one policy if allowlisting is enabled. The user must be assigned the TenantAdmin role.
Facts
| Rate limit | Tier 2 (100 requests per minute) |
Path Parameters
- id stringRequired
The unique identifier for the IP policy.
Request Body
Required- application/json array of objects
An array of JSON Patch documents
application/json properties
- op stringRequired
The operation to be performed.
Can be one of: "replace"
- path stringRequired
A JSON Pointer.
Can be one of: "/enabled""/name""/allowedIps"
- value string|boolean|arrayRequired
The value to be used for this operation.
One of:- string
- boolean
- array of strings
-
-
Responses
204
IP policy updated successfully.
400
Invalid request body.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
401
Unauthorized, JWT is invalid or not provided.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
403
Access Denied.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
404
IP policy ID not found or Invalid format.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
429
Request has been rate limited.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
500
Internal server error.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({ hostConfig: { host: 'https://{tenant}.{region}.qlikcloud.com', apiKey: '<access-token>', },})
await qlik.core.ipPolicies.patchIpPolicy( 'string', [ { op: 'replace', path: '/name', value: 'New name', },
{ op: 'replace', path: '/allowedIps', value: ['61.254.213.0/24', '22.46.216.142'], },
{ op: 'replace', path: '/enabled', value: true, }, ],)qlik core ip-policy patch 'string' \ --op 'replace' \ --path '/name' \ --value New namecurl "https://{tenant}.{region}.qlikcloud.com/api/core/ip-policies/{id}" \-X PATCH \-H "Content-type: application/json" \-H "Authorization: Bearer <access_token>" \-d '[{"op":"replace","path":"/name","value":"New name"},{"op":"replace","path":"/allowedIps","value":["61.254.213.0/24","22.46.216.142"]},{"op":"replace","path":"/enabled","value":true}]'Deletes an IP policy by ID. If this is the last enabled policy in the tenant, IP allowlisting will be disabled and access will be permitted via all IP addresses. The user's IP address must be present in at least one other policy if allowlisting is enabled. The user must be assigned the TenantAdmin role.
Facts
| Rate limit | Tier 2 (100 requests per minute) |
Path Parameters
- id stringRequired
The unique identifier for the IP policy.
Responses
204
IP policy deleted successfully.
401
Unauthorized, JWT is invalid or not provided.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
403
Access Denied.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
404
IP policy ID not found or Invalid format.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
429
Request has been rate limited.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
500
Internal server error.
- application/json object
The error response object describing the error from the handling of an HTTP request.
application/json properties
- errors array of objects
An array of errors related to the operation.
errors properties
- code stringRequired
The error code.
- meta object
Additional properties relating to the error.
- title stringRequired
Summary of the problem.
- detail string
A human-readable explanation specific to this occurrence of the problem.
- source object
References to the source of the error.
source properties
- pointer string
A JSON Pointer to the property that caused the error.
- parameter string
The URI query parameter that caused the error.
-
-
- traceId string
A unique identifier for tracing the error.
-
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({ hostConfig: { host: 'https://{tenant}.{region}.qlikcloud.com', apiKey: '<access-token>', },})
await qlik.core.ipPolicies.deleteIpPolicy( 'string',)qlik core ip-policy rm 'string'curl "https://{tenant}.{region}.qlikcloud.com/api/core/ip-policies/{id}" \-X DELETE \-H "Authorization: Bearer <access_token>"