Logo
15_Days_of_Postman_-_for_testers_IvanKo API Documentation

Collections-Forks

Number of APIs: 6


1. Get a collection's forks

GET {{baseUrl}}/collections/{{collectionId}}/forks

Gets a collection's forked collections. The response returns data for each fork, such as the fork's ID, the user who forked it, and the fork's creation date.



2. Get source collection's status

GET {{baseUrl}}/collections/{{collectionId}}/source-status

Checks whether there is a change between the forked collection and its parent (source) collection.

If the value of the isSourceAhead property is true in the response, then there is a difference between the forked collection and its source collection.

Note:

This endpoint may take a few minutes to return an updated isSourceAhead status.



3. Get all forked collections

GET {{baseUrl}}/collections/collection-forks

Gets a list of all the authenticated user's forked collections.



4. Pull source changes

PUT {{baseUrl}}/collections/{{collectionId}}/pulls

Pulls the changes from a parent (source) collection into the forked collection. In the endpoint's response:

  • The destinationId is the ID of the forked collection.
  • The sourceId is the ID of the source collection.



5. Create a fork

POST {{baseUrl}}/collections/fork/{{collectionId}}?workspace=<string>

Creates a [fork] from an existing collection into a workspace. Include the following required request body properties:

  • label — A string value that contains the fork's label.



6. Merge a fork

POST {{baseUrl}}/collections/merge

Merges a forked collection back into its parent collection. Include the following required properties in the request body:

  • source — A string value that contains the source collection's ID.

  • destination — A string value that contains the destination (parent) collection's ID.

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

  • strategy — A string value that contains the fork's merge strategy. One of:

    • deleteSource — Merge the changes into the parent collection. After the merge process is complete, Qodex deletes the fork. You must have Editor access to both the parent and forked collections.
    • updateSourceWithDestination — (Default) Merge the changes into the parent collection. Any differences in the parent collection are also made to the fork.



ENDPOINTS