Create a schema
POST https://api.getpostman.com/apis/{{apiId}}/versions/{{apiVersionId}}/schemas
Creates a schema. The request body must contain a Requires an API Key as the schema
object with the following properties:
type
— A string value that contains the schema's type. One of:
openapi3_1
openapi3
openapi2
openapi1
raml
raml1
wsdl1
wsdl2
graphql
proto2
graphql
proto3
language
— A string value that contains the schema's language. One of:
json
or yaml
graphql
xml
proto
schema
— Optional. A string value that contains the schema's contents.
X-Api-Key
request header or an apikey
URL query parameter.
Body
PARAM
Key | Datatype | Required | Description |
HEADERS
Key | Datatype | Required | Description |
Content-Type
|
string |
RESPONSES
status OK
{
"schema": {
"id": "e3b3a0b7-34d5-4fc5-83e0-118bd9e8c822",
"language": "yaml",
"apiVersion": "ad810c39-df60-434e-a76f-a2192cd8d81f",
"type": "openapi3",
"createdBy": "1234567890",
"updatedBy": "1234567890",
"createdAt": "2021-05-22T13:17:07.000Z",
"updatedAt": "2021-05-22T13:17:07.000Z"
}
} |
ENDPOINTS