Logo
30 days of Postman - for developers API Documentation

API-API Version

Number of APIs: 5


1. Get All API Versions

GET https://api.getpostman.com/apis/{{apiId}}/versions

This call fetches details about the all the API Versions in the specified API.

The response will contain an array versions object which would be a list of all the API Version along with their details.

Requires API Key as X-Api-Key request header or apikey URL query parameter.



2. Create API Version

POST https://api.getpostman.com/apis/{{apiId}}/versions

This call creates a new API version in the specified API.

Request body should contain a version object which should have fields:

name Required. Name of the API Version
source If specified, it will copy the contents of the specified api version to create a new api verison.
id Required. Id of the apiversion from where the details are to be copied
schema Boolean. If true then copies the schema from the specified api version
relations Object. {"<relationType>": true/false}. Allowed relation types are `mock`, `monitor`, `documentation`, `contracttest`, `integrationtest`, `testsuite`, `environment` Relation types which should be copied over to the new api verison

Response contains a version object with all the details related to the created API Version, namely, id, name, api.

Requires API Key as X-Api-Key request header or apikey URL query parameter.



3. Update an API Version

PUT https://api.getpostman.com/apis/{{apiId}}/versions/{{apiVersionId}}

This call updates an existing API Version.

Request body should contain a version object with the fields which need to be updated. Only field which can be updated is name.

Response contains a version object with all the details related to the created API Version, namely, id, name, api etc.

Requires API Key as X-Api-Key request header or apikey URL query parameter.



4. Delete an API Version

DELETE https://api.getpostman.com/apis/{{apiId}}/versions/{{apiVersionId}}

This call deletes an existing API Version having the specified id.

Response contains an version object with id of the API Version which was deleted.

Requires API Key as X-Api-Key request header or apikey URL query parameter.



5. Get an API Version

GET https://api.getpostman.com/apis/{{apiId}}/versions/{{apiVersionId}}

This call fetches details about the specified API Version.

The response will contain a version object which would contain all the details of the API Version.

Requires API Key as X-Api-Key request header or apikey URL query parameter.



ENDPOINTS