Logo
30-day challenge API Documentation

Create a collection from a schema

POST https://api.getpostman.com/apis/{{apiId}}/versions/{{apiVersionId}}/schemas/{{schemaId}}/collections

This endpoint is deprecated in Qodex v10 and higher.

Creates a collection and links it to an API as one or multiple relations.

Include the following properties in the request body:

  • name — A string that contains the name of the collection.

You can also include the following additional properties in the request body:

  • relations — An array that contains a list of relations to create:
    • contracttestDeprecated.
    • integrationtestDeprecated.
    • testsuiteDeprecated.
    • documentation
  • options — An object that contains advanced creation options and their values. You can find a complete list of properties and their values in Qodex's OpenAPI 3.0 to Qodex Collection v2.1.0 Converter OPTIONS documentation. These properties are case-sensitive.

 

Body PARAM

Key Datatype Required Description 
workspace
string Optional. The workspace ID in which to created the collection. If you do not include this query parameter, the system defaults to the "My Workspace" workspace.



HEADERS

Key Datatype Required Description 
Content-Type
string




RESPONSES

status OK

{ "collection": { "id": "12ece9e1-2abf-4edc-8e34-de66e74114d2", "uid": "12345678-12ece9e1-2abf-4edc-8e34-de66e74114d2" }, "relations": [ { "type": "documentation", "id": "d86b6c97-fdf9-4c37-825a-49b0223913c7" } ] }



Curl
curl -X POST 'https://api.getpostman.com/apis/undefined/versions/undefined/schemas/undefined/collections?workspace=undefined' -H 'Content-Type: application/json' -d '{"name":"undefined","relations":[{"type":"undefined"}],"options":{"undefined":"undefined"}}'

ENDPOINTS