1. API Key & Authentication
Get started with Durrun API access, create your API key, authenticate requests, and connect to Durrun endpoints.
Request Account
Send a request to get API access.
Create API Key
Create and manage your API keys.
Start Integrating
Use your API key with our endpoints.
Create an API Key
After your account is approved, create an API key from your API Portal.
API Endpoints
Use the following endpoints to access different data from Durrun.
| Feature | Endpoint URL | Method | Description | Action |
|---|---|---|---|---|
| Query | https://api.durrun.com/api/query.php | GET | Search models and integrations | |
| Templates | https://api.durrun.com/api/templates.php | GET | Get all templates | |
| Providers | https://api.durrun.com/api/providers.php | GET | Get all providers | |
| Models | https://api.durrun.com/api/models.php | GET | Get all models, filter by provider or template | |
| Model by ID & Language | https://api.durrun.com/api/model-code.php | GET | Get integration code by model ID and language |
Query
GETSearch models and integrations with a free-text query. Add a language to the query (for example "java" or "python") to get code samples in the results.
Base URL
Query parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
query | string | Required | — | Search text. Examples: Recraft vector PHP, SharpAPI summarize python. |
limit | integer | Optional | 20 | Results per page. Maximum 50. |
cursor | string | Optional | — | Page token. Use next_cursor from the previous response. |
Request headers
| Header | Value |
|---|---|
X-API-KEY | YOUR_API_KEY |
Accept | application/json |
Example request
# 1. Request with base URL, parameters and headers
curl -G "https://api.durrun.com/api/query.php" \
-H "X-API-KEY: YOUR_API_KEY" \
-H "Accept: application/json" \
--max-time 30 \
--data-urlencode "query=SharpAPI java" \
--data-urlencode "limit=20"
# 2. Next page: copy next_cursor from the response and add
# --data-urlencode "cursor=NEXT_CURSOR" Paginated: when has_more is true, send next_cursor as cursor to get the next page.
Response fields
| Field | Description |
|---|---|
query / language / match_type | How the query was read. language appears only when the query names one; match_type is all_words or partial. |
limit / total_count | Results per page and total number of matching models. |
has_more / next_cursor | Paging. When has_more is true, send next_cursor as cursor. |
response[] | List of models: model_id, model_name, version, provider, type, description, documentation_url. When a language is given: language, code, get_code. |
status / message | Only on errors, e.g. {"status":"error","message":"Invalid or missing API key."} |
Templates
GETList all templates (image, video, voiceai, web, database, and more).
Base URL
Query parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
limit | integer | Optional | 20 | Results per page. Maximum 50. |
cursor | string | Optional | — | Page token. Use next_cursor from the previous response. |
Request headers
| Header | Value |
|---|---|
X-API-KEY | YOUR_API_KEY |
Accept | application/json |
Example request
# 1. Request with base URL, parameters and headers
curl -G "https://api.durrun.com/api/templates.php" \
-H "X-API-KEY: YOUR_API_KEY" \
-H "Accept: application/json" \
--max-time 30 \
--data-urlencode "limit=20"
# 2. Next page: copy next_cursor from the response and add
# --data-urlencode "cursor=NEXT_CURSOR" Paginated: when has_more is true, send next_cursor as cursor to get the next page.
Providers
GETList all providers (openai, sharpapi, recraft, grokai, and more).
Base URL
Query parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
limit | integer | Optional | 20 | Results per page. Maximum 50. |
cursor | string | Optional | — | Page token. Use next_cursor from the previous response. |
Request headers
| Header | Value |
|---|---|
X-API-KEY | YOUR_API_KEY |
Accept | application/json |
Example request
# 1. Request with base URL, parameters and headers
curl -G "https://api.durrun.com/api/providers.php" \
-H "X-API-KEY: YOUR_API_KEY" \
-H "Accept: application/json" \
--max-time 30 \
--data-urlencode "limit=20"
# 2. Next page: copy next_cursor from the response and add
# --data-urlencode "cursor=NEXT_CURSOR" Paginated: when has_more is true, send next_cursor as cursor to get the next page.
Models
GETList models, optionally filtered by provider and template.
Base URL
Query parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
provider | string | Optional | — | Provider slug: openai, sharpapi, recraft, grokai… |
template | string | Optional | — | Template slug: image, video, voiceai, web, database… |
limit | integer | Optional | 20 | Results per page. Maximum 50. |
cursor | string | Optional | — | Page token. Use next_cursor from the previous response. |
Request headers
| Header | Value |
|---|---|
X-API-KEY | YOUR_API_KEY |
Accept | application/json |
Example request
# 1. Request with base URL, parameters and headers
curl -G "https://api.durrun.com/api/models.php" \
-H "X-API-KEY: YOUR_API_KEY" \
-H "Accept: application/json" \
--max-time 30 \
--data-urlencode "provider=recraft" \
--data-urlencode "template=image" \
--data-urlencode "limit=20"
# 2. Next page: copy next_cursor from the response and add
# --data-urlencode "cursor=NEXT_CURSOR" Paginated: when has_more is true, send next_cursor as cursor to get the next page.
Model by ID & Language
GETGet the integration code for one model in a specific programming language.
Base URL
Query parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
model_id | integer | Required | — | Model ID, as returned by Models or Query. |
language | string | Required | — | php, node, python, go, java, csharp, curl… |
page | integer | Optional | 1 | Page number when the code spans several pages. |
Request headers
| Header | Value |
|---|---|
X-API-KEY | YOUR_API_KEY |
Accept | application/json |
Example request
# 1. Request with base URL, parameters and headers
curl -G "https://api.durrun.com/api/model-code.php" \
-H "X-API-KEY: YOUR_API_KEY" \
-H "Accept: application/json" \
--max-time 30 \
--data-urlencode "model_id=95" \
--data-urlencode "language=php" \
--data-urlencode "page=1"