Original Invitation Status | Invite API Behavior |
---|---|
Invitation Pending (Test Attempt not taken) | API returns the pending invitation and replaces Access time and timezone ID with new details from the request. |
Invitation Cancelled | API returns the pending invitation, updates Access time and timezone ID, and changes status to Pending. |
Invitation Expired | API returns the pending invitation, updates Access time and timezone ID, and changes status to Pending. |
Test Status - Complete | API returns the same invitation. If the candidate attempts the test, they see: “You have already appeared for the test. Please contact test administrator for further assistance.” |
Test Status - In Progress | API returns the current invitation where the test is in progress. |
Test Status - Test Left | API returns the same invitation. If the candidate attempts the test, they see: “You have already appeared for the test. Please contact test administrator for further assistance.” |
curl --location -g --request POST 'https://apiv3.imocha.io/v3/tests/{testId}/testlinks/{testLinkId}/invite' \
--header 'x-api-key;' \
--header 'Content-Type: application/json' \
--data-raw '{
"email": "string",
"name": "string",
"callbackUrl": "string",
"redirectUrl": "string",
"disableMandatoryFields": 0,
"hideInstruction": 0,
"sendEmail": "string"
}'
{
"testInvitationId": 3178622,
"testUrl": "https://test.imocha.io/IMInstructions?eVdzZUlmaHBKK1crRU53dmdEWmM3UzFhQmhWTXFZSk5GZUdhc1RlSDdqQT0m",
"status": "Pending"
}