Postman collection of API requests created by Testinvite.
Share
Created by Yusuf Turhallı / October, 2022
We have created a Postman collection for API requests. You can download the file at the end of the article. You can use the collection according to your needs by replacing global variables such as "organizationId", "privateKey", and "taskId" with yours.
There are 4 folders in the collection:
Creating Tickets: Requests for creating tickets
Fetching Test Results: Requests for fetching test result data of assessments
Fetching Monitoring Assets: Requests for fetching monitoring data of test instances
Fetch Tasks: Requests for fetching task data
For trying API requests immediately you can check the Postman collection. Please click here to download the collection.
Creating Tickets
We have included different types of requests for creating tickets. You can make requests for either single or multiple ticket creation with/out optional properties.
Creating Simple Ticket: Only required properties are included for creating one ticket. You can create a single ticket for one candidate via this request. In the user object, there will only be "fullname" property.
Creating Simple Ticket with Callback: In addition to required properties of the request body, "callback" property is included. Test result data can be sent to the "url" you define, as soon as the candidate finishes the assessment. You can create a ticket for single candidate via this request.
Creating Ticket with Additional Information: In the user object, addition to "fullname" property, optional ones are included. You can create single ticket for single candidate via this request.
Creating Multiple Tickets with Same or Different Information: You can create multiple tickets via this request. In the example, there will be 3 user objects in the users array. You can customize them according to your needs.
Fetching Test Results
There are two different requests for fetching test results of single or multiple tickets. You can fetch results of tickets by replacing "ticketId" properties of each object in the "tickets" array with your organization's candidates ticket ids. You can find ticket id of the candidate in the response of the ticket creation request.
Result for One Ticket with Ticket Id: You can fetch results of any ticket via this request. You should include "ticketId" of the candidate, that you got from the ticket creation request's response, in the "tickets" array.
Result for Multiple Tickets with Ticket Id: Only difference between this request and the previous one is that in this one you should include multiple objects with "ticketId" property in the "tickets" array.
Fetching Monitoring Assets
To fetch monitoring assets of a test instance you should replace "testinstanceId" property with the "testInstanceId" that you get from the request for fetching test results. You can check "Fetch by TestInstance Id" request that is included in this folder.
Fetch Tasks
There is one request in this folder by which you can fetch your task data through Testinvite's API. You can check "Fetch Tasks" request in it.