Device42 DOQL API
The DOQL API from Device42 — 3 operation(s) for doql.
The DOQL API from Device42 — 3 operation(s) for doql.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/device42:device42-doql-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Device42 DOQL API
version: '2.0'
description: 'API Overview
RESTful APIs are supported in Device42 as one of the primary methods of entering, editing and retrieving data.'
contact:
name: Device42
email: support@device42.com
servers:
- url: https://<host>
security:
- basicAuth: []
- bearerAuth: []
tags:
- name: DOQL
paths:
/services/data/v1.0/query/:
get:
operationId: getDOQLData
description: Get DOQL data
summary: Get DOQL and Saved DOQL data
tags:
- DOQL
parameters:
- name: query
in: query
description: The DOQL query you want to run, a SELECT command whose results are to be returned.
required: true
schema:
type: string
- name: delimiter
in: query
description: Specifies the character that separates columns within each row (line) of the file. The default a comma. This must be a single one-byte character.
schema:
type: string
- name: header
in: query
description: If ‘yes’ specifies that the file contains a header line with the names of each column in the file. On output, the first line contains the column names from the table
schema:
type: string
- name: quote
in: query
description: Specifies the quoting character to be used when a data value is quoted. The default is double-quote. This must be a single one-byte character.
schema:
type: string
- name: null_string
in: query
description: Specifies the string that represents a null value. The default is an unquoted empty string.
schema:
type: string
- name: quote_escape
in: query
description: Specifies the character that should appear before a data character that matches the QUOTE value. The default is the same as the QUOTE value
schema:
type: string
- name: output_type
in: query
description: Specify output format for DOQL results. 'csv' is the default output format if parameter is not specified
schema:
type: string
enum:
- csv
- json
responses:
'200':
description: 'The above command returns results like this:'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
post:
operationId: postDOQLData
description: Use this API to query DOQL database
summary: Query DOQL Database
tags:
- DOQL
requestBody:
content:
application/x-www-form-urlencoded:
schema:
type: object
properties:
query:
description: The DOQL query you want to run, a SELECT command whose results are to be returned.
type: string
delimiter:
description: Specifies the character that separates columns within each row (line) of the file. The default a comma. This must be a single one-byte character.
type: string
header:
description: If ‘yes’ specifies that the file contains a header line with the names of each column in the file. On output, the first line contains the column names from the table
type: string
quote:
description: Specifies the quoting character to be used when a data value is quoted. The default is double-quote. This must be a single one-byte character.
type: string
null_string:
description: Specifies the string that represents a null value. The default is an unquoted empty string.
type: string
quote_escape:
description: Specifies the character that should appear before a data character that matches the QUOTE value. The default is the same as the QUOTE value
type: string
output_type:
description: Specify output format for DOQL results. 'csv' is the default output format if parameter is not specified.
type: string
enum:
- csv
- json
required:
- query
required: true
responses:
'200':
description: 'The above command returns results like this:'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
/api/2.0/dbb/:
get:
operationId: getDBBInformation
description: Get information for DBBs in Device42. You must be a superuser to access the API.
summary: Get DBB Information
tags:
- DOQL
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
view_dbb_compute_v2:
type: object
properties:
last_refresh_date:
example: '2023-07-10T19:01:06.655567+00:00'
refresh_queued:
example: false
row_count:
example: 4200
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
/api/2.0/dbb/refresh/:
get:
operationId: getDBBRefresh
description: Get list of DBBs that are queued for refresh. You must be a superuser to access the API.
summary: Get Queued DBB Refresh
tags:
- DOQL
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
dbbs:
example:
- view_dbb_compute_v2
- view_dbb_security_v2
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
post:
operationId: postDBBRefresh
description: Use this API to queue one or all DBBs for a refresh. You must be a superuser to access the API.
summary: Queue DBB Refresh
tags:
- DOQL
requestBody:
content:
application/x-www-form-urlencoded:
schema:
type: object
properties:
dbb_name:
description: Name of the DBB you want to refresh. If this parameter is not passed, all DBBs will be refreshed.
type: string
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
msg:
example:
- A refresh has already been queued.
code:
example: 1
'202':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
msg:
example:
- DBB has been queued for refresh.
code:
example: 0
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
components:
responses:
Forbidden:
description: Forbidden (The resource requested is hidden)
content:
application/json:
example:
errors:
- code: 403
reason: Forbidden
title: Forbidden
detail: The resource requested is hidden
BadRequest:
description: Bad Request (A validation exception has occurred.)
content:
application/json:
example:
errors:
- code: 400
reason: BAD_REQUEST
title: The error response code title.
detail: Details of the error response.
Unauthorized:
description: Unauthorized (Invalid credentials.)
content:
application/json:
example:
errors:
- code: 401
reason: Unauthorized
title: Unauthorized
detail: Invalid credentials.
InternalServerError:
description: Internal Server Error (A required parameter is missing or there is an issue with the server. Check the returned 'msg' field from the call.)
content:
application/json:
example:
errors:
- code: 500
reason: Internal Server Error
title: Internal Server Error
detail: A required parameter is missing or there is an issue with the server. Check the returned 'msg' field from the call.
NotFound:
description: Not Found (The specified resource could not be found)
content:
application/json:
example:
errors:
- code: 404
reason: Not Found
title: Not Found
detail: The specified resource could not be found.
ServiceUnavailable:
description: Service Unavailable (Please check if your Device42 instance is working normally.)
content:
application/json:
example:
errors:
- code: 503
reason: Service Unavailable
title: Service Unavailable
detail: Please check if your Device42 instance is working normally.
securitySchemes:
basicAuth:
type: http
scheme: basic
description: Basic authentication using a Device42 user's username and password.
bearerAuth:
type: http
scheme: bearer
description: Bearer token obtained from POST /tauth/1.0/token/ using an API Client's key/secret as Basic auth credentials.