create Api OAS

POST {{baseUrl}}/api/apis/oas?base_api_id=<string>&base_api_version_name=<string>&new_version_name=<string>&set_default=<boolean>

Create an API Definition in OAS format. The id and api_id fields in the definition are auto-generated by Tyk and cannot be set by the user.

Request Params

KeyDatatypeRequiredDescription
base_api_idstringThe base API which the new version will be linked to.
base_api_version_namestringThe version name of the base API while creating the first version. This doesn't have to be sent for the next versions but if it is set, it will override base API version name.
new_version_namestringThe version name of the created version.
set_defaultstringIf true, the new version is set as default version.

Request Body

{"value"=>"reference https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/schemas/v3.0/schema.json not found in the OpenAPI spec"}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring
Acceptstring

RESPONSES

status: OK

{&quot;action&quot;:&quot;\u003cstring\u003e&quot;,&quot;key&quot;:&quot;\u003cstring\u003e&quot;,&quot;key_hash&quot;:&quot;\u003cstring\u003e&quot;,&quot;status&quot;:&quot;\u003cstring\u003e&quot;}