dbt Labs IP Restriction Endpoints API
The IP Restriction Endpoints API from dbt Labs, for ip restriction endpoints.
The IP Restriction Endpoints API from dbt Labs, for ip restriction endpoints.
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/dbtlabs:dbtlabs-ip-restriction-endpoints-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: dbt Cloud API v3 IP Restriction Endpoints API
version: 3.0.0
description: '# How to use this API
The dbt Cloud API v3 contains endpoints for programmatic administration of your dbt Cloud account.
With it, you can replicate resources across projects, accounts, and environments, or standardize project
creation for business teams. For endpoints related to jobs and runs, refer to the
Discovery API or dbt Cloud API v2.
The API docs are generated from an openapi spec defined in the
dbt-cloud-openapi-spec
repository. If you find issues in these docs or have questions about using the dbt Cloud
API, please open an issue in the dbt-cloud-openapi-spec repo or contact support@getdbt.com.
## Authentication
To authenticate an application with the dbt Cloud API, navigate to the
Account Settings page and go to Personal Tokens from the left sidebar. Create one if you don''t have one already.
If you cannot access this page, confirm that your dbt Cloud account has access to the API,
and that you are using the hosted version of dbt Cloud. If dbt Cloud is running inside of a VPC
in an Enterprise account, contact your account manager for help finding your account-scoped Personal Access Token.
Once you''ve found your Personal Access Token (PAT) for your account, use it in the Authorization header of requests to the dbt Cloud API.
Be sure to include the `Token` prefix in the Authorization header, or the request will fail with a
"401 Unauthorized" error.
*Note: `Bearer` can be used in place of `Token` in the Authorization header. Both syntaxes are equivalent.*
**Headers**
```
Accept: application/json
Authorization: Token
```
## Pagination
All top-level API resources support bulk fetches using the "list" or `GET` API methods. These API methods accept `limit` and `offset` query parameters that you can use together to paginate results and return a subset of those results.
* Offset: Specifies how many records to skip. Can be an integer 0 and higher.
* Limit: Specifies the maximum records you want to retrieve in a single request. Can be an integer up to 100. This limit makes responses easier to handle for servers and people.
Endpoints that support pagination include some useful extra information about the pagination state. For example:
```json
{
data: [...],
extra: {
// How the results were filtered
filters: {...},
// The order of the results
order_by: "id",
// The pagination state
pagination: {
// The number of records returned in this response
count: 5,
// The total number of available records
total_count: 10,
}
}
}
````
## Example request
The following example uses the list projects endpoint to list the projects that your token is authorized to access.
This request skips the first 10 projects and lists the next 10 projects.
Be sure to replace `` in the Authorization header with your actual API token and `` with your actual account ID.
```bash
curl --request GET \
--url ''https://cloud.getdbt.com/api/v3/accounts//projects/?limit=10&offset=5'' \
--header ''Content-Type: application/json'' \
--header ''Authorization: Token ''
```'
termsOfService: https://www.getdbt.com/terms-of-service
contact:
email: support@getdbt.com
servers:
- url: https://cloud.getdbt.com/
description: Production (US)
- url: https://{account_prefix}.us1.dbt.com/
description: Production (US)
variables:
account_prefix:
default: ab123
description: Your unique account prefix. Can be found on your account settings page.
- url: https://emea.dbt.com/
description: Production (Europe)
- url: https://au.dbt.com/
description: Production (AU)
tags:
- name: IP Restriction Endpoints
paths:
/api/v3/accounts/{account_id}/ip-restrictions/:
get:
operationId: ListIPRestrictions
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
- in: query
name: include_related
schema:
type: string
description: Comma-separated list of related objects to include in the response.
tags:
- IP Restriction Endpoints
security:
- BearerAuthentication: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/IPRestrictionRuleListEnveloped'
description: ''
summary: List IP restrictions
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: List IP Restrictions
post:
operationId: SaveIPRestriction
description: 'Save net-new ip restriction rule
Note: As long as at least one cidr was successfully saved a 2XX will be returned.
Check the `extra` key within the response for a list of cidrs that failed to save.'
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
tags:
- IP Restriction Endpoints
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateIPRestrictionBodyRequest'
application/x-www-form-urlencoded:
schema:
$ref: '#/components/schemas/CreateIPRestrictionBodyRequest'
multipart/form-data:
schema:
$ref: '#/components/schemas/CreateIPRestrictionBodyRequest'
required: true
security:
- BearerAuthentication: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/IPRestrictionRuleEnveloped'
description: ''
summary: Save IP restriction
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: Save IP Restriction
/api/v3/accounts/{account_id}/ip-restrictions-set/:
post:
operationId: EnableIPRestrictions
description: Toggle the enablement of the IP restriction feature.
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
tags:
- IP Restriction Endpoints
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/EnableIPRestrictionsBodyRequest'
application/x-www-form-urlencoded:
schema:
$ref: '#/components/schemas/EnableIPRestrictionsBodyRequest'
multipart/form-data:
schema:
$ref: '#/components/schemas/EnableIPRestrictionsBodyRequest'
required: true
security:
- BearerAuthentication: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/IPRestrictionRuleSetEnveloped'
description: ''
summary: Enable IP restrictions
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: Enable IP Restrictions
/api/v3/accounts/{account_id}/ip-restrictions-set/{id}/validate/:
get:
operationId: ValidateClientIPAgainstIPRestrictions
description: 'This endpoint returns whether the client ip is acceptable based on the
configured ip restriction rules associated to the rule set.'
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
- in: path
name: id
schema:
type: integer
format: int64
required: true
- in: query
name: include_related
schema:
type: string
description: Comma-separated list of related objects to include in the response.
tags:
- IP Restriction Endpoints
security:
- BearerAuthentication: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/IPRestrictionSetValidate'
description: ''
summary: Validate client IP against IP restrictions
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: Validate Client IP Against IP Restrictions
/api/v3/accounts/{account_id}/ip-restrictions-set/{id}/validate/{rule_id}:
get:
operationId: ValidateClientIPAgainstIPRestrictionsExcludingSpecifiedIPRule
description: 'This endpoint returns whether the client ip is acceptable based on the
configured ip restriction rules associated to the rule set - excluding the ip rule id
passed into the url'
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
- in: path
name: id
schema:
type: integer
format: int64
required: true
- in: query
name: include_related
schema:
type: string
description: Comma-separated list of related objects to include in the response.
- in: path
name: rule_id
schema:
type: integer
format: int64
required: true
tags:
- IP Restriction Endpoints
security:
- BearerAuthentication: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/IPRestrictionSetValidate'
description: ''
summary: Validate client IP against IP restrictions excluding specified IP rule
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: Validate Client IP Against IP Restrictions Excluding Specified IP Rule
/api/v3/accounts/{account_id}/ip-restrictions/{id}:
get:
operationId: RetrieveIPRestriction
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
- in: path
name: id
schema:
type: integer
format: int64
required: true
- in: query
name: include_related
schema:
type: string
description: Comma-separated list of related objects to include in the response.
tags:
- IP Restriction Endpoints
security:
- BearerAuthentication: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/IPRestrictionRuleEnveloped'
description: ''
summary: Retrieve IP restriction
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: Retrieve IP Restriction
put:
operationId: UpdateIPRestriction
description: 'Update an existing ip restriction rule
Note: As long as at least one cidr was successfully saved a 2XX will be returned.
Check the `extra` key within the response for a list of cidrs that failed to save.'
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
- in: path
name: id
schema:
type: integer
format: int64
required: true
tags:
- IP Restriction Endpoints
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateIPRestrictionBodyRequest'
application/x-www-form-urlencoded:
schema:
$ref: '#/components/schemas/UpdateIPRestrictionBodyRequest'
multipart/form-data:
schema:
$ref: '#/components/schemas/UpdateIPRestrictionBodyRequest'
required: true
security:
- BearerAuthentication: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/IPRestrictionRule'
description: ''
summary: Update IP restriction
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: Update IP Restriction
delete:
operationId: DeleteIPRestriction
parameters:
- in: path
name: account_id
schema:
type: integer
format: int64
required: true
- in: path
name: id
schema:
type: integer
format: int64
required: true
tags:
- IP Restriction Endpoints
security:
- BearerAuthentication: []
responses:
'204':
description: No response body
summary: Delete IP restriction
x-summary-source: derived
x-operation-id-source: normalized
x-operation-id-original: Delete IP Restriction
components:
schemas:
IPRestrictionRuleListEnveloped:
type: object
properties:
data:
type: array
items:
$ref: '#/components/schemas/IPRestrictionRuleResponse'
extra:
$ref: '#/components/schemas/Extra'
status:
$ref: '#/components/schemas/ResponseStatus'
required:
- data
- extra
- status
IPRestrictionCidrBody:
title: IPRestrictionCidrBody
description: A CIDR range in an IP restriction rule. Include `id` to update an existing range.
type: object
properties:
id:
title: Id
format: int64
type: integer
cidr:
title: Cidr
type: string
enabled:
title: Enabled
default: true
type: boolean
state:
title: State
description: 1 keeps the range, 2 deletes it.
type: integer
ip_restriction_rule_id:
title: Ip Restriction Rule Id
description: Read-only, ignored.
format: int64
type: integer
cidr_ipv6:
title: Cidr Ipv6
description: Read-only, ignored.
type: string
created_at:
title: Created At
description: Read-only, ignored.
type: string
format: date-time
updated_at:
title: Updated At
description: Read-only, ignored.
type: string
format: date-time
required:
- cidr
additionalProperties: false
ResponseStatus:
type: object
properties:
code:
type: integer
default: 200
description: HTTP status code
is_success:
type: boolean
description: Whether the request was successful or not
user_message:
type: string
description: End-user friendly success or error message
developer_message:
type: string
description: Developer friendly success or error message
required:
- developer_message
- is_success
- user_message
EnableIPRestrictionsBodyRequest:
title: EnableIPRestrictionsBody
description: Turns IP restrictions on or off for the account.
type: object
properties:
enabled:
title: Enabled
type: boolean
account_id:
title: Account Id
description: Read-only, ignored.
format: int64
type: integer
state:
title: State
description: Read-only, ignored.
type: integer
required:
- enabled
additionalProperties: false
IPRestrictionRule:
type: object
properties:
name:
type: string
type:
type: integer
state:
example: 1
type: integer
description: A value of 1 means this entity is active and a value of 2 means this entity is deleted
ip_restriction_rule_set_id:
type: integer
format: int64
rule_set_enabled:
type: boolean
account_id:
type: integer
format: int64
cidrs:
type: array
items:
$ref: '#/components/schemas/IPRestrictionCidr'
created_by_id:
type: integer
format: int64
created_by_service_token_id:
type: integer
format: int64
description:
type: string
required:
- account_id
- ip_restriction_rule_set_id
- name
- rule_set_enabled
- state
- type
IPRestrictionSetValidate:
type: object
properties:
is_valid_for_admin:
type: boolean
required:
- is_valid_for_admin
IPRestrictionRuleSetEnveloped:
type: object
properties:
data:
$ref: '#/components/schemas/IPRestrictionRuleSetResponse'
status:
$ref: '#/components/schemas/ResponseStatus'
required:
- data
- status
UpdateIPRestrictionBodyRequest:
title: UpdateIPRestrictionBody
description: New values for an IP restriction rule and its CIDR ranges.
type: object
properties:
name:
title: Name
minLength: 1
type: string
type:
description: 1 allows the ranges, 2 denies them.
allOf:
- $ref: '#/components/schemas/IPRestrictionType'
description:
title: Description
type: string
rule_set_enabled:
title: Rule Set Enabled
type: boolean
cidrs:
title: Cidrs
default: []
type: array
items:
$ref: '#/components/schemas/IPRestrictionCidrBody'
account_id:
title: Account Id
description: Read-only, ignored.
format: int64
type: integer
ip_restriction_rule_set_id:
title: Ip Restriction Rule Set Id
description: Read-only, ignored.
format: int64
type: integer
state:
title: State
description: Read-only, ignored.
type: integer
created_by_id:
title: Created By Id
description: Read-only, ignored.
format: int64
type: integer
enabled_for_service_tokens:
title: Enabled For Service Tokens
description: Read-only, ignored.
type: boolean
id:
title: Id
description: Read-only, ignored.
format: int64
type: integer
required:
- name
- type
additionalProperties: false
IPRestrictionType:
title: IPRestrictionType
description: An enumeration.
enum:
- 1
- 2
type: integer
CreateIPRestrictionBodyRequest:
title: CreateIPRestrictionBody
description: An IP restriction rule and its CIDR ranges.
type: object
properties:
name:
title: Name
minLength: 1
type: string
type:
description: 1 allows the ranges, 2 denies them.
allOf:
- $ref: '#/components/schemas/IPRestrictionType'
description:
title: Description
type: string
rule_set_enabled:
title: Rule Set Enabled
type: boolean
cidrs:
title: Cidrs
default: []
type: array
items:
$ref: '#/components/schemas/IPRestrictionCidrBody'
account_id:
title: Account Id
description: Read-only, ignored.
format: int64
type: integer
ip_restriction_rule_set_id:
title: Ip Restriction Rule Set Id
description: Read-only, ignored.
format: int64
type: integer
state:
title: State
description: Read-only, ignored.
type: integer
created_by_id:
title: Created By Id
description: Read-only, ignored.
format: int64
type: integer
enabled_for_service_tokens:
title: Enabled For Service Tokens
description: Read-only, ignored.
type: boolean
required:
- name
- type
additionalProperties: false
IPRestrictionRuleResponse:
type: object
properties:
id:
type: integer
format: int64
readOnly: true
name:
type: string
type:
type: integer
state:
example: 1
type: integer
default: 1
description: A value of 1 means this entity is active and a value of 2 means this entity is deleted
ip_restriction_rule_set_id:
type: integer
format: int64
rule_set_enabled:
type: boolean
account_id:
type: integer
format: int64
cidrs:
type: array
items:
$ref: '#/components/schemas/IPRestrictionCidr'
created_by_id:
type: integer
format: int64
created_by_service_token_id:
type: integer
format: int64
enabled_for_service_tokens:
type: boolean
readOnly: true
description:
type: string
created_at:
type: string
format: date-time
readOnly: true
updated_at:
type: string
format: date-time
readOnly: true
required:
- created_at
- enabled_for_service_tokens
- id
- updated_at
CustomPagination:
type: object
properties:
count:
type: integer
description: Number of items in the current page
total_count:
type: integer
description: Total number of items
required:
- count
- total_count
IPRestrictionCidr:
type: object
properties:
state:
example: 1
type: integer
description: A value of 1 means this entity is active and a value of 2 means this entity is deleted
ip_restriction_rule_id:
type: integer
format: int64
enabled:
type: boolean
cidr:
type: string
cidr_ipv6:
type: string
required:
- cidr
- enabled
- ip_restriction_rule_id
- state
IPRestrictionRuleSetResponse:
type: object
properties:
id:
type: integer
format: int64
readOnly: true
account_id:
type: integer
format: int64
enabled:
type: boolean
state:
example: 1
type: integer
default: 1
description: A value of 1 means this entity is active and a value of 2 means this entity is deleted
enabled_for_service_tokens:
type: boolean
readOnly: true
created_at:
type: string
format: date-time
readOnly: true
updated_at:
type: string
format: date-time
readOnly: true
required:
- created_at
- enabled_for_service_tokens
- id
- updated_at
IPRestrictionRuleEnveloped:
type: object
properties:
data:
$ref: '#/components/schemas/IPRestrictionRuleResponse'
status:
$ref: '#/components/schemas/ResponseStatus'
required:
- data
- status
Extra:
type: object
properties:
filters:
type: object
additionalProperties: {}
description: Filters applied to the request
order_by:
type: string
description: Ordering applied to the request
pagination:
$ref: '#/components/schemas/CustomPagination'
required:
- filters
- order_by
- pagination
securitySchemes:
BearerAuthentication:
type: http
scheme: bearer
bearerFormat: Bearer