Web integrations

A web integration is a resource representing a list of whitelisted origins that can make requests to a specified tenant. It is the implementation of the CORS mechanism within Qlik Cloud.

List web integrations

Retrieves web integrations matching the query.

Facts

Rate limit Tier 1 (1000 requests per minute)

Query Parameters

  • endingBefore string

    The target web integration ID to start looking before for web integrations. Cannot be used in conjunction with startingAfter.

  • limit number

    The number of web integration entries to retrieve.

  • sort string

    The field to sort by. Prefix with +/- to indicate ascending/descending order.

    Can be one of: "name""+name""-name"

  • startingAfter string

    The target web integration ID to start looking after for web integrations. Cannot be used in conjunction with endingBefore.

  • tenantId string

    The tenant ID to filter by.

Responses

200

An array of web integration objects.

  • application/json object

    An array of web integration objects.

    Show application/json properties
    • data array of objects

      Properties of web integrations in a given tenant.

      Show data properties
      • id string

        The unique web integration identifier.

      • name string

        The name of the web integration.

      • created string

        The time the web integration was created.

      • tenantId string

        The tenant that the web integration belongs to.

      • createdBy string

        The user that created the web integration.

      • lastUpdated string

        The time the web integration was last updated.

      • validOrigins array of strings

        The origins that are allowed to make requests to the tenant.

    • links object

      Pagination links

      Show links properties
      • next object

        Link information for next page.

        Show next properties
        • href string
          Required

          URL to the next page of records.

      • prev object

        Link information for previous page.

        Show prev properties
        • href string
          Required

          URL to the previous page of records.

      • self object
        Required

        Link information for current page.

        Show self properties
        • href string
          Required

          URL to the current page of records.

default

Unexpected error.

  • application/json object

    The error response object describing the error from the handling of an HTTP request.

    Show application/json properties
    • errors array of objects

      An array of errors related to the operation.

      Show errors properties
      • code string
        Required

        The error code.

      • meta object

        Additional properties relating to the error.

      • title string
        Required

        Summary of the problem.

      • detail string

        A human-readable explanation specific to this occurrence of the error.

      • source object

        References to the source of the error.

        Show source properties
        • pointer string

          A JSON Pointer to the property that caused the error.

        • parameter string

          The URI query parameter that caused the error.

      • status string
        Required

        The HTTP status code.

    • traceId string

      A unique identifier for tracing the error.

GET /api/v1/web-integrations
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({
hostConfig: {
host: 'https://{tenant}.{region}.qlikcloud.com',
apiKey: '<access-token>',
},
})
await qlik.webIntegrations.getWebIntegrations({})
qlik web-integration ls
curl "https://{tenant}.{region}.qlikcloud.com/api/v1/web-integrations" \
-H "Authorization: Bearer <access_token>"

Example Response

{
"data": [
{
"id": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"name": "string",
"created": "2018-10-30T07:06:22Z",
"tenantId": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"createdBy": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"lastUpdated": "2018-10-30T07:06:22Z",
"validOrigins": [
"string"
]
}
],
"links": {
"next": {
"href": "string"
},
"prev": {
"href": "string"
},
"self": {
"href": "string"
}
}
}

Create web integration

Creates a web integration.

Facts

Rate limit Tier 2 (100 requests per minute)

Request Body

Required

Properties that the user wants to set for the web integration.

  • application/json object
    Show application/json properties
    • name string
      Required

      The name of the web integration to create.

    • validOrigins array of strings

      The origins that are allowed to make requests to the tenant.

Responses

201

Web integration created successfully.

  • application/json object

    The creation of a web integration response.

    Show application/json properties
    • id string

      The unique web integration identifier.

    • name string

      The name of the newly created web integration.

    • links object

      Pagination links

      Show links properties
      • self object
        Required

        Link information for current page.

        Show self properties
        • href string
          Required

          URL to the current page of records.

    • created string

      The time the web integration was created.

    • tenantId string

      The tenant that the web integration belongs to.

    • createdBy string

      The user that created the web integration.

    • lastUpdated string

      The time the web integration was last updated.

    • validOrigins array of strings

      The origins that are allowed to make requests to the tenant.

400

Invalid request was made.

  • application/json object

    The error response object describing the error from the handling of an HTTP request.

    Show application/json properties
    • errors array of objects

      An array of errors related to the operation.

      Show errors properties
      • code string
        Required

        The error code.

      • meta object

        Additional properties relating to the error.

      • title string
        Required

        Summary of the problem.

      • detail string

        A human-readable explanation specific to this occurrence of the error.

      • source object

        References to the source of the error.

        Show source properties
        • pointer string

          A JSON Pointer to the property that caused the error.

        • parameter string

          The URI query parameter that caused the error.

      • status string
        Required

        The HTTP status code.

    • traceId string

      A unique identifier for tracing the error.

403

Requestor not allowed to create a web integration.

  • application/json object

    The error response object describing the error from the handling of an HTTP request.

    Show application/json properties
    • errors array of objects

      An array of errors related to the operation.

      Show errors properties
      • code string
        Required

        The error code.

      • meta object

        Additional properties relating to the error.

      • title string
        Required

        Summary of the problem.

      • detail string

        A human-readable explanation specific to this occurrence of the error.

      • source object

        References to the source of the error.

        Show source properties
        • pointer string

          A JSON Pointer to the property that caused the error.

        • parameter string

          The URI query parameter that caused the error.

      • status string
        Required

        The HTTP status code.

    • traceId string

      A unique identifier for tracing the error.

POST /api/v1/web-integrations
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({
hostConfig: {
host: 'https://{tenant}.{region}.qlikcloud.com',
apiKey: '<access-token>',
},
})
await qlik.webIntegrations.createWebIntegration({
name: 'My Web Integration',
validOrigins: ['https://thirdPartyApp.com'],
})
qlik web-integration create \
--name 'My Web Integration'
curl "https://{tenant}.{region}.qlikcloud.com/api/v1/web-integrations" \
-X POST \
-H "Content-type: application/json" \
-H "Authorization: Bearer <access_token>" \
-d '{"name":"My Web Integration","validOrigins":["https://thirdPartyApp.com"]}'

Example Response

{
"id": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"name": "My Web Integration",
"links": {
"self": {
"href": "http://mytenant.region.domain/api/v1/web-integrations/id"
}
},
"created": "2018-10-30T07:06:22Z",
"tenantId": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"createdBy": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"lastUpdated": "2018-10-30T07:06:22Z",
"validOrigins": [
"https://thirdPartyApp.com"
]
}

Get web integration by ID

Retrieves a single web integration by ID.

Facts

Rate limit Tier 1 (1000 requests per minute)

Path Parameters

  • id string
    Required

    The ID of the web integration to retrieve.

Responses

200

Web integration found.

  • application/json object

    A web integration object.

    Show application/json properties
    • id string

      The unique web integration identifier.

    • name string

      The name of the web integration.

    • created string

      The time the web integration was created.

    • tenantId string

      The tenant that the web integration belongs to.

    • createdBy string

      The user that created the web integration.

    • lastUpdated string

      The time the web integration was last updated.

    • validOrigins array of strings

      The origins that are allowed to make requests to the tenant.

404

Web integration not found.

  • application/json object

    The error response object describing the error from the handling of an HTTP request.

    Show application/json properties
    • errors array of objects

      An array of errors related to the operation.

      Show errors properties
      • code string
        Required

        The error code.

      • meta object

        Additional properties relating to the error.

      • title string
        Required

        Summary of the problem.

      • detail string

        A human-readable explanation specific to this occurrence of the error.

      • source object

        References to the source of the error.

        Show source properties
        • pointer string

          A JSON Pointer to the property that caused the error.

        • parameter string

          The URI query parameter that caused the error.

      • status string
        Required

        The HTTP status code.

    • traceId string

      A unique identifier for tracing the error.

GET /api/v1/web-integrations/{id}
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({
hostConfig: {
host: 'https://{tenant}.{region}.qlikcloud.com',
apiKey: '<access-token>',
},
})
await qlik.webIntegrations.getWebIntegration(
'TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69',
)
qlik web-integration get 'TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69'
curl "https://{tenant}.{region}.qlikcloud.com/api/v1/web-integrations/{id}" \
-H "Authorization: Bearer <access_token>"

Example Response

{
"id": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"name": "string",
"created": "2018-10-30T07:06:22Z",
"tenantId": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"createdBy": "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69",
"lastUpdated": "2018-10-30T07:06:22Z",
"validOrigins": [
"string"
]
}

Update web integration by ID

Updates a single web integration by ID.

Facts

Rate limit Tier 2 (100 requests per minute)

Path Parameters

  • id string
    Required

    The ID of the web integration to update.

Request Body

Required

Properties that the user wants to update for the web integration.

  • application/json array of objects

    A JSON Patch document as defined in http://tools.ietf.org/html/rfc6902.

    Show application/json properties
    • op string
      Required

      The operation to be performed.

      Can be one of: "replace"

    • path string
      Required

      A JSON Pointer.

      Can be one of: "/name""/validOrigins"

    • value string
      Required

      New value to be used for this operation.

Responses

204

Web integration updated successfully.

400

Invalid request was made.

  • application/json object

    The error response object describing the error from the handling of an HTTP request.

    Show application/json properties
    • errors array of objects

      An array of errors related to the operation.

      Show errors properties
      • code string
        Required

        The error code.

      • meta object

        Additional properties relating to the error.

      • title string
        Required

        Summary of the problem.

      • detail string

        A human-readable explanation specific to this occurrence of the error.

      • source object

        References to the source of the error.

        Show source properties
        • pointer string

          A JSON Pointer to the property that caused the error.

        • parameter string

          The URI query parameter that caused the error.

      • status string
        Required

        The HTTP status code.

    • traceId string

      A unique identifier for tracing the error.

404

Web integration not found.

  • application/json object

    The error response object describing the error from the handling of an HTTP request.

    Show application/json properties
    • errors array of objects

      An array of errors related to the operation.

      Show errors properties
      • code string
        Required

        The error code.

      • meta object

        Additional properties relating to the error.

      • title string
        Required

        Summary of the problem.

      • detail string

        A human-readable explanation specific to this occurrence of the error.

      • source object

        References to the source of the error.

        Show source properties
        • pointer string

          A JSON Pointer to the property that caused the error.

        • parameter string

          The URI query parameter that caused the error.

      • status string
        Required

        The HTTP status code.

    • traceId string

      A unique identifier for tracing the error.

PATCH /api/v1/web-integrations/{id}
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({
hostConfig: {
host: 'https://{tenant}.{region}.qlikcloud.com',
apiKey: '<access-token>',
},
})
await qlik.webIntegrations.patchWebIntegration(
'TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69',
[
{
op: 'replace',
path: '/name',
value: 'New name',
},
],
)
qlik web-integration patch 'TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69' \
--op 'replace' \
--path '/name' \
--value 'New name'
curl "https://{tenant}.{region}.qlikcloud.com/api/v1/web-integrations/{id}" \
-X PATCH \
-H "Content-type: application/json" \
-H "Authorization: Bearer <access_token>" \
-d '[{"op":"replace","path":"/name","value":"New name"}]'

Delete web integration by ID

Deletes a single web integration by ID.

Facts

Rate limit Tier 2 (100 requests per minute)

Path Parameters

  • id string
    Required

    The ID of the web integration to delete.

Responses

204

Web integration deleted successfully.

404

Web integration not found.

  • application/json object

    The error response object describing the error from the handling of an HTTP request.

    Show application/json properties
    • errors array of objects

      An array of errors related to the operation.

      Show errors properties
      • code string
        Required

        The error code.

      • meta object

        Additional properties relating to the error.

      • title string
        Required

        Summary of the problem.

      • detail string

        A human-readable explanation specific to this occurrence of the error.

      • source object

        References to the source of the error.

        Show source properties
        • pointer string

          A JSON Pointer to the property that caused the error.

        • parameter string

          The URI query parameter that caused the error.

      • status string
        Required

        The HTTP status code.

    • traceId string

      A unique identifier for tracing the error.

DELETE /api/v1/web-integrations/{id}
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({
hostConfig: {
host: 'https://{tenant}.{region}.qlikcloud.com',
apiKey: '<access-token>',
},
})
await qlik.webIntegrations.deleteWebIntegration(
'TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69',
)
qlik web-integration rm 'TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69'
curl "https://{tenant}.{region}.qlikcloud.com/api/v1/web-integrations/{id}" \
-X DELETE \
-H "Authorization: Bearer <access_token>"