Need help with your APIs? I offer API discovery, governance & evangelism services. Explore services →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

APIs.io Engineering Platform D1 API

The D1 API from APIs.io Engineering Platform — 6 operation(s) for d1.

This API exposes 8 operations across 6 paths, and defines 18 schemas. It is described by OpenAPI 3.0.0, at version 2015-07-09.

Requests are made against 4 base URLs: http://apigateway.{region}.amazonaws.com, https://apigateway.{region}.amazonaws.com, http://apigateway.{region}.amazonaws.com.cn, https://apigateway.{region}.amazonaws.com.cn.

8 operations 6 paths 18 schemas 1 DELETE2 GET5 POST

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.0.0
API Version
2015-07-09
Base URL
https://{bucketname}.s3.amazonaws.com
Authentication
API Key
Terms of Service
Resource Areas
1

Authentication & Security 1

APIs.io Engineering Platform D1 API declares 1 security scheme for authenticating requests. An API key is passed in the header as Authorization (hmac). By default, every request must be authenticated.

  • hmac — Amazon Signature authorization v4

Paths & Operations 8

Across 6 paths, the API surfaces 8 operations — 1 DELETE, 2 GET, 5 POST. Each is listed below with its method, path, parameters, and response codes.

D1 8
GET
/accounts/{account_id}/d1/database
APIs.io Engineering Platform List D1 Databases
cloudflare-d1-list-databases 4 params → 4XX200
POST
/accounts/{account_id}/d1/database
APIs.io Engineering Platform Create D1 Database
cloudflare-d1-create-database 1 param body → 4XX200
DELETE
/accounts/{account_id}/d1/database/{database_id}
APIs.io Engineering Platform Delete D1 Database
cloudflare-d1-delete-database 2 params → 4XX200
GET
/accounts/{account_id}/d1/database/{database_id}
APIs.io Engineering Platform Get D1 Database
cloudflare-d1-get-database 2 params → 4XX200
POST
/accounts/{account_id}/d1/database/{database_id}/export
APIs.io Engineering Platform Export D1 Database as SQL
cloudflare-d1-export-database 2 params body → 4XX200202
POST
/accounts/{account_id}/d1/database/{database_id}/import
APIs.io Engineering Platform Import SQL into your D1 Database
cloudflare-d1-import-database 2 params body → 4XX200202
POST
/accounts/{account_id}/d1/database/{database_id}/query
APIs.io Engineering Platform Query D1 Database
cloudflare-d1-query-database 2 params body → 4XX200
POST
/accounts/{account_id}/d1/database/{database_id}/raw
APIs.io Engineering Platform Raw D1 Database query
cloudflare-d1-raw-database-query 2 params body → 4XX200

Schemas 18

The contract defines 18 schemas that model the data the API accepts and returns. The most detailed are d1_query-meta (7 properties), d1_database-details-response (6 properties), d1_api-response-common-failure (4 properties), d1_api-response-common (4 properties). Each schema is shown below with its type and property counts.

d1_database-name
string
d1_sql
string
Your SQL query. Supports multiple statements, joined by semicolons, which will be executed as a batch.
d1_api-response-common
object
4 properties 4 required
d1_primary-location-hint
string
Specify the region to create the D1 primary, if available. If this option is omitted, the D1 will be created as close as possible to the current user.
d1_database-version
string
d1_messages
array
d1_raw-result-response
object
3 properties
d1_database-identifier
string
d1_params
array
d1_database-details-response
object
6 properties
d1_query-meta
object
7 properties
d1_created-at
string
Specifies the timestamp the resource was created as an ISO8601 string.
d1_table-count
number
d1_account-identifier
string
Account identifier tag.
d1_file-size
number
The D1 database's size, in bytes.
d1_api-response-common-failure
object
4 properties 4 required
d1_query-result-response
object
3 properties
d1_database-response
object
4 properties

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

engineering-platform-d1-api-openapi.yml Raw ↑