v51
latestOpenAPI 3.0.3Mozilla Public License Version 2.0raw.githubusercontent.com2026-08-0165205256.0 KBAPIs
Get API definition with it's ID.
Get API definition from Tyk Gateway.
get/tyk/apis/{apiID}
Path parameters
apiIDstring required
The API ID.
Response
API definition.
Example response
{
"CORS": {
"allowed_headers": [
"Origin",
"Accept",
"Content-Type",
"Authorization"
],
"allowed_methods": [
"GET",
"HEAD",
"POST"
],
"allowed_origins": [
"https://*.foo.com"
],
"debug": true,
"exposed_headers": [
"Accept",
"Content-Type"
],
"max_age": 24
},
"auth": {
"auth_header_name": "Authorization"
},
"cache_options": {
"cache_timeout": 60,
"enable_cache": true
},
"custom_middleware": {
"auth_check": {
"name": "PreMiddlewareFunction"
},
"post": [
{
"name": "PreMiddlewareFunction"
}
],
"post_key_auth": [
{
"name": "PreMiddlewareFunction"
}
],
"pre": [
{
"name": "PreMiddlewareFunction"
}
],
"response": [
{
"name": "PreMiddlewareFunction"
}
]
},
"definition": {
"key": "x-api-version",
"location": "header"
},
"proxy": {
"listen_path": "/relative-path-examples/",
"strip_listen_path": true,
"target_url": "https://httpbin.org/"
},
"tags": [
"Default",
"v1"
]
}