data-connections

data-connections is the resource representing a connection

Endpoints

Skip to section
GET/data-connections
POST/data-connections
GET/data-connections/{qID}
PUT/data-connections/{qID}
PATCH/data-connections/{qID}
DELETE/data-connections/{qID}

Gets a list of connections

Query Parameters GET /data-connections

dataName
optional

Provides an alternate name to be used for data[] element in GET response.

extended
optional

Returns extended list of properties when set to true.

spaceId
optional

Filtering on connections by space ID

personal
optional

Filtering on connections, connections in personal space will be returned if set to true

owner
optional

Filtering on datafile connections, datafiles connections used in the app will be returned. The value set in this query is appId.

ownedByMe
optional

Filtering on conneections, return connections owned by the caller if set to true (doesn't apply to datafiles connectionos)

limit
optional, default=All resources will be returned if limit is not defined, minimum=1, maximum=100

Number of resources to be returned

sort
optional

Name of field sort on for pagination, with prefix with + or - indicating ascending or descending order. When used for data-connections, sort field only applies to non-datafiles connections. Whatever sorting order is, datafiles connections will be returned after all regular connections being returned.

page
optional

Pagination sursor string, which is generated auotmatically in previous pagination query.

noDatafiles
optional

Datafiles connections will not be returned if set to true

Responses GET /data-connections

200
application/json

List connections with optional filter queries. Connections will be filtered internally based on the space access rules applicable to the caller. When some of connections are not returned due to errors, errors array in the response will be set.

400
application/json

Bad request, typically when dataName is empty

500
application/json

Internal error, this happens when the service fails to make requests to dependency services

502
application/json

Bad gateway, this happens when the requests to dependency services are timedout

GET/data-connections

curl "https://your-tenant.us.qlikcloud.com/api/v1/data-connections" \
 -H "Authorization: Bearer <API-key>"

Response GET /data-connections

{
  "data": [
    {
      "qID": "string",
      "qName": "string",
      "qConnectStatement": "string",
      "qType": "string",
      "qLogOn": 0,
      "qArchitecture": 0,
      "qEngineObjectID": "string",
      "qCredentialsID": "string",
      "qCredentialsName": "string",
      "qSeparateCredentials": true,
      "qReferenceKey": "string",
      "qConnectionSecret": "string",
      "privileges": [],
      "space": "string",
      "user": "string",
      "tenant": "string",
      "created": "string",
      "updated": "string",
      "links": {
        "self": {
          "href": "string"
        }
      }
    }
  ],
  "links": {
    "self": {
      "href": "string"
    },
    "prev": {
      "href": "string"
    },
    "next": {
      "href": "string"
    }
  },
  "meta": {
    "count": 0
  },
  "errors": [
    {
      "code": "string",
      "title": "string",
      "detail": "string"
    }
  ]
}

Creates a connection. Depends on the fields defined in the request body, credentials embedded (or associated) in the connection can be updated or created.

Request Body POST /data-connections

application/json

No description

Responses POST /data-connections

201
application/json

Data connection created

400
application/json

Invalid data connection specified

403
application/json

User has no access to the connection or space

404
application/json

Credentials pointed by qCredentialsID in the request body doesn't exist

409
application/json

Data connection already exists

POST/data-connections

curl "https://your-tenant.us.qlikcloud.com/api/v1/data-connections" \
 -X POST \
 -H "Authorization: Bearer <API-key>" \
 -H "Content-type: application/json" \
 -d '{"owner":"string","qID":"string","qName":"string","qConnectStatement":"string","qType":"string","qLogOn":0,"qEngineObjectID":"string","qArchitecture":0,"qCredentialsID":"string","qCredentialsName":"string","qUsername":"string","qPassword":"string","qSeparateCredentials":true,"space":"string","datasourceID":"string","qConnectionSecret":"Any string"}'

Request POST /data-connections

{
  "owner": "string",
  "qID": "string",
  "qName": "string",
  "qConnectStatement": "string",
  "qType": "string",
  "qLogOn": 0,
  "qEngineObjectID": "string",
  "qArchitecture": 0,
  "qCredentialsID": "string",
  "qCredentialsName": "string",
  "qUsername": "string",
  "qPassword": "string",
  "qSeparateCredentials": true,
  "space": "string",
  "datasourceID": "string",
  "qConnectionSecret": "Any string"
}

Response POST /data-connections

{
  "qID": "string",
  "qName": "string",
  "qConnectStatement": "string",
  "qType": "string",
  "qLogOn": 0,
  "qArchitecture": 0,
  "qEngineObjectID": "string",
  "qCredentialsID": "string",
  "qCredentialsName": "string",
  "qSeparateCredentials": true,
  "qReferenceKey": "string",
  "privileges": [],
  "space": "string",
  "user": "string",
  "created": "string",
  "updated": "string",
  "links": {
    "self": {
      "href": "string"
    }
  }
}

Gets a connection by connection ID (or by name when type=connectionname is set in query)

Path Parameters GET /data-connections/{qID}

qID

Connection ID

Query Parameters GET /data-connections/{qID}

extended
optional

Returns extended list of properties when set to true.

type
optional

Connection / credential ID defined in path become connection / credential name when this query parameter is set

credentialId
optional

Credential ID

byCredentialName

If set to true, credentialId in the query will be intepreted as credential's name

spaceId
optional

Filtering on connections by space ID

noCache
optional

datafiles connections will be returned from cache by default (if data-connections is configured to use cache), this query parameter is used disable this default behavior, e.g. return an update-to-date datafiles connection if the query is set to true

Responses GET /data-connections/{qID}

200
application/json

Data connection fetched

400
application/json

qID is an invalid UUID

403
application/json

User has no access to the connection or space

404
application/json

Data connection not found

500
application/json

Credential decryption failed, which is most likely caused by invalid credentials

GET/data-connections/{qID}

curl "https://your-tenant.us.qlikcloud.com/api/v1/data-connections/{qID}" \
 -H "Authorization: Bearer <API-key>"

Response GET /data-connections/{qID}

{
  "qID": "string",
  "qName": "string",
  "qConnectStatement": "string",
  "qType": "string",
  "qLogOn": 0,
  "qArchitecture": 0,
  "qEngineObjectID": "string",
  "qCredentialsID": "string",
  "qCredentialsName": "string",
  "qSeparateCredentials": true,
  "qReferenceKey": "string",
  "qConnectionSecret": "string",
  "privileges": [],
  "space": "string",
  "user": "string",
  "tenant": "string",
  "created": "string",
  "updated": "string",
  "links": {
    "self": {
      "href": "string"
    }
  }
}

Updates a connection specified by connection ID (or by name when type=connectionname is set in query). Depends on the fields defined in the request body, credentials embedded (or associated) in the connection can be updated or created.

Path Parameters PUT /data-connections/{qID}

qID

Connection ID

Query Parameters PUT /data-connections/{qID}

type
optional

Connection / credential ID defined in path become connection / credential name when this query parameter is set

spaceId
optional

Filtering on connections by space ID

Request Body PUT /data-connections/{qID}

application/json

No description

Responses PUT /data-connections/{qID}

204
object

Data connection updated successfully

400
application/json

Bad request due to invalid data in body

403
application/json

User has no access to the connection or space

404
application/json

Data connection not found

409
application/json

Data connection already exists (when updated name conflicts with existing record)

PUT/data-connections/{qID}

curl "https://your-tenant.us.qlikcloud.com/api/v1/data-connections/{qID}" \
 -X PUT \
 -H "Authorization: Bearer <API-key>" \
 -H "Content-type: application/json" \
 -d '{"qID":"string","qName":"string","qConnectStatement":"string","qType":"string","qLogOn":0,"qEngineObjectID":"string","qArchitecture":0,"qCredentialsID":"string","qCredentialsName":"string","qUsername":"string","qPassword":"string","qSeparateCredentials":true,"space":"string","datasourceID":"string","qConnectionSecret":"string"}'

Request PUT /data-connections/{qID}

{
  "qID": "string",
  "qName": "string",
  "qConnectStatement": "string",
  "qType": "string",
  "qLogOn": 0,
  "qEngineObjectID": "string",
  "qArchitecture": 0,
  "qCredentialsID": "string",
  "qCredentialsName": "string",
  "qUsername": "string",
  "qPassword": "string",
  "qSeparateCredentials": true,
  "space": "string",
  "datasourceID": "string",
  "qConnectionSecret": "string"
}

Patches a connection specified by connection ID (or by name when type=connectionname is set in query).

Path Parameters PATCH /data-connections/{qID}

qID

Connection ID

Query Parameters PATCH /data-connections/{qID}

type
optional

Connection / credential ID defined in path become connection / credential name when this query parameter is set

Request Body PATCH /data-connections/{qID}

application/json

No description

Responses PATCH /data-connections/{qID}

204
object

Data connection updated successfully

400
application/json

Bad request due to invalid data in body

403
application/json

User has no access to the connection or space

404
application/json

Data connection not found

409
application/json

Data connection already exists (when updated name conflicts with existing record)

PATCH/data-connections/{qID}

curl "https://your-tenant.us.qlikcloud.com/api/v1/data-connections/{qID}" \
 -X PATCH \
 -H "Authorization: Bearer <API-key>" \
 -H "Content-type: application/json" \
 -d '{"op":"add","path":"Use '/qName' to pacth the field 'qName' on toplevel","value":"string"}'

Request PATCH /data-connections/{qID}

{
  "op": "add",
  "path": "Use '/qName' to pacth the field 'qName' on toplevel",
  "value": "string"
}

Deletes the specified data connection by ID (or by name when type=connectionname is set in query)

Path Parameters DELETE /data-connections/{qID}

qID

Connection ID

Query Parameters DELETE /data-connections/{qID}

type
optional

Connection / credential ID defined in path become connection / credential name when this query parameter is set

spaceId
optional

Filtering on connections by space ID

Responses DELETE /data-connections/{qID}

204
object

Data connection deleted successfully

403
application/json

User has no access to the connection or space

404
application/json

Data connection not found

DELETE/data-connections/{qID}

curl "https://your-tenant.us.qlikcloud.com/api/v1/data-connections/{qID}" \
 -X DELETE \
 -H "Authorization: Bearer <API-key>"

Connections

object

Properties

data

No description

links

No description

meta

No description

errors

No description

Credentials

object

Properties

data

No description

links

No description

meta

No description

errors

No description

CredentialCreate

Credential

Properties

qID
optional
string

UUID of the credential

qName
string

UName of the credential

qType
string

Type of credential

qUsername
string

User name

qPassword
string

Password

datasourceID
optional
string

ID datasource that the credential is created for

connectionId
optional
string

ID of connection that will be associated with the credential

Credential

object

Properties

qID
string

UUID of the credential

qName
string

Name of the credential

qType
string

Type of credential

qReferenceKey
optional
string

Reference key of credential in redis

qConnCount
integer

Number of linked connections

links

No description

Connection

object

Essential fields of a connection

Properties

qID
string

Unique identifier (UUID) for the data connection, must be same as qEngineObjectID

qName
string

Descriptive name of the data connection

qConnectStatement
string

Connection string for the data connection

qType
string

Type of connection - indicates connection provider type

qLogOn

Indicates the type of user associated with the data connection. Service user is indicated by 0, current application user is indicated by 1.

Enum:

0

1

0

1

LOG_ON_SERVICE_USER

LOG_ON_CURRENT_USER

qArchitecture
integer

0 or 1 value indicating whether the data connector is 64-bit (0) or 32-bit (1). Defaults to 0 if not specified.

Enum:

0

1

qEngineObjectID
string

Unique identifier (UUID) for the data connection, must be same as qID

qCredentialsID
optional
string

ID of the credential associated with the connection

qCredentialsName
optional
string

Name of the credential associated with the connection

qSeparateCredentials
boolean

Indicates whether or not this is a credential-less connection

qReferenceKey
optional
string

Reference key of credential in redis

qConnectionSecret
optional
string

String that contains connection specific secret (or password). This field will not be included in response of GET /data-connections, will only be included in the response of GET /data0connections/{qID}

privileges
Array<Privilege>

Array of string (i.e. update, delete, read) indicating the user's privileges on the associated connection

space
optional
string

ID of the space to which the connection belongs

user
string

User ID of the connection's creator

tenant
optional
string

Tenant ID of the connection's creator (Only when extended=true in query)

created
string

Datetime when the connection was created

updated
string

Datetime when the connection was last updated

links

No description

ConnectionCreateResponse

object

Essential fields of a connection

Properties

qID
string

Unique identifier (UUID) for the data connection, must be same as qEngineObjectID

qName
string

Descriptive name of the data connection

qConnectStatement
string

Connection string for the data connection

qType
string

Type of connection - indicates connection provider type

qLogOn

Indicates the type of user associated with the data connection. Service user is indicated by 0, current application user is indicated by 1.

Enum:

0

1

0

1

LOG_ON_SERVICE_USER

LOG_ON_CURRENT_USER

qArchitecture
integer

0 or 1 value indicating whether the data connector is 64-bit (0) or 32-bit (1). Defaults to 0 if not specified.

Enum:

0

1

qEngineObjectID
string

Unique identifier (UUID) for the data connection, must be same as qID

qCredentialsID
optional
string

ID of the credential associated with the connection

qCredentialsName
optional
string

Name of the credential associated with the connection

qSeparateCredentials
boolean

Indicates whether or not this is a credential-less connection

qReferenceKey
optional
string

Reference key of credential in redis

privileges
Array<Privilege>

No description

space
optional
string

ID of the space to which the connection belongs

user
optional
string

User ID of the connection's creator

created
optional
string

Datetime when the connection was created

updated
optional
string

Datetime when the connection was last updated

links

No description

ConnectionCreate

object

Properties

owner
optional
string

ID of the cloud app that owns this connection

qID
optional
string

Unique identifier (UUID) for the data connection. A UUID will be generated automatically if qID is not specified or empty

qName
string

Descriptive name of the data connection

qConnectStatement
string

Connection string for the data connection

qType
string

Type of connection - indicates connection provider type

qLogOn
optional

Indicates the type of user associated with the data connection. Service user is indicated by 0, current application user is indicated by 1. Value will be set to 1 if qLogOn is not defined in the request

Enum:

0

1

0

1

LOG_ON_SERVICE_USER

LOG_ON_CURRENT_USER

qEngineObjectID
optional
string

Unique identifier (UUID) for the data connection as specified by the Sense engine. A UUID will be generated automatically if this field is not specified or empty

qArchitecture
optional
integer

0 or 1 value indicating whether the data connector is 64-bit (0) or 32-bit (1). Defaults to 0 if not specified.

Enum:

0

1

qCredentialsID
optional
string

ID of the credential associated with the connection

qCredentialsName
optional
string

Name of the credential associated with the connection

qUsername
optional
string

Any logon username associated with the data connection

qPassword
optional
string

Any logon password associated with the data connection

qSeparateCredentials
optional, default=false
boolean

Indicates whether or not to create a credential-less connection

space
optional
string

ID of the space to which the connection belongs

datasourceID
string

ID of the datasource associated with this connection

qConnectionSecret
optional
string

String that contains connection specific secret (or password) that requires encryption before persist to database. This field is connection level secret

ConnectionUpdate

object

Properties

qID
string

Unique identifier for the data connection

qName
string

Descriptive name of the data connection

qConnectStatement
string

Connection string for the data connection

qType
string

Type of connection - indicates connection provider type

qLogOn
optional

Indicates the type of user associated with the data connection. Service user is indicated by 0, current application user is indicated by 1.

Enum:

0

1

0

1

LOG_ON_SERVICE_USER

LOG_ON_CURRENT_USER

qEngineObjectID
string

Unique identifier for the data connection as specified by the Sense engine

qArchitecture
optional
integer

0 or 1 value indicating whether the data connector is 64-bit (0) or 32-bit (1). Defaults to 0 if not specified.

Enum:

0

1

qCredentialsID
optional
string

ID of the credential associated with the connection

qCredentialsName
optional
string

Name of the credential associated with the connection

qUsername
optional
string

Any logon username associated with the data connection

qPassword
optional
string

Any logon password associated with the data connection

qSeparateCredentials
optional
boolean

Indicates whether or not this is a credential-less connection

space
optional
string

ID of the space to which the connection belongs

datasourceID
optional
string

ID of the datasource associated with this connection

qConnectionSecret
optional
string

String that contains connection level secret (or password). If this field presents in request, then existing connection secret will be updated to its value. If is an empty string, then eixsting connection secret will be cleared. If this field is missing, existing secret will not be updated.

PatchRequest

Array<object>

Properties

op
string

Operation type

Enum:

add

replace

remove

path
string

Path to the target field to be patched

value
string

The value used for the patch, only needed for 'add' or 'replace'. Value type coul dbe either string or integer, should match with the type of the target field

Privilege

string

Access type allowed on associated data connection

Meta

object

Properties

count
integer

Total count of resources being requested.

ResponseErrors

object

Properties

errors

No description

Errors

Array<object>

Properties

code
string

Unique error code

title
string

A summary in english explaining what went wrong

detail
string

More concrete details

qConnID

string

Connection ID

qCredID

string

Credential ID

dataName

string

Provides an alternate name to be used for data[] element in GET response.

extended

boolean

Returns extended list of properties when set to true.

spaceID

string

Filtering on connections by space ID

type

string

Connection / credential ID defined in path become connection / credential name when this query parameter is set

credentialID

string

Credential ID

personal

boolean

Filtering on connections, connections in personal space will be returned if set to true

bycredentialname

boolean

If set to true, credentialId in the query will be intepreted as credential's name

owner

boolean

Filtering on datafile connections, datafiles connections used in the app will be returned. The value set in this query is appId.

limit

integer

Number of resources to be returned

sort

string

Name of field sort on for pagination, with prefix with + or - indicating ascending or descending order. When used for data-connections, sort field only applies to non-datafiles connections. Whatever sorting order is, datafiles connections will be returned after all regular connections being returned.

page

string

Pagination sursor string, which is generated auotmatically in previous pagination query.

credentialType

string

Filtering on credential type

datasourceID

string

Filtering on datasource ID

embedded

boolean

Filtering on credential status (i.e. embedded vs separated)

ownedbyme

boolean

Filtering on conneections, return connections owned by the caller if set to true (doesn't apply to datafiles connectionos)

nocache

boolean

datafiles connections will be returned from cache by default (if data-connections is configured to use cache), this query parameter is used disable this default behavior, e.g. return an update-to-date datafiles connection if the query is set to true

nodatafiles

boolean

Datafiles connections will not be returned if set to true

v1.0.0
Was this page helpful?