Register candidate for test

  • Description

    Register candidate for a test.
    Post data on "Register candidate for test" API.
    Please note that, if any request posted more than once for the same candidate, it will update fullName, callbackUrl, redirectUrl parameters on existing record.
  • URL structure

    https://api.interviewmocha.com/v2/tests/{testId}/register

  • Request Method

    POST

  • Request Data

    Parameters
    Parameter Description Default Data Type Is Mandatory
    testId Test Id associated with particular test None Int64 Yes
    Request Body Data
    Parameter Description Default Data Type Is Mandatory
    emailId Email Id of Candidate None String Yes
    fullName Full name of Candidate None String Yes
    callbackURL After completion of test callback object will be send on this URL None String No
    redirectURL After completion of test candidate will redirect to this URL None String No
  • Response Data

    Parameters
    Argument Name Description Return Data Type
    statuscode Status code returned with every response String
    description Status code message String
    result Wrapper Object Object
    result.testInvitationId Unique Id of Candidate Test Int64
    result.takeTestURL URL for take test. By using this URL candidate can start the test String
  • Sample Code

    Example Curl request will look like this:

    curl -i -H "x-api-key:YOUR_API_KEY_HERE" -H "content-type:application/json;charset=utf-8" -X POST https://api.interviewmocha.com/v2/tests/840702/register -d '{"emailId":"testemail@interviewmocha.com","fullName":"Amit Mishra", "callbackURL":"http://yoursite.com/savecallbackpage", "redirectURL":"http://yoursite.com/thankyoupage"}'

    Response Body:
    {
      "statuscode": "200.1",
      "description": "The request has succeeded.",
      "result": {
        "testInvitationId": 2256212,
        "takeTestURL": "https://test.interviewmocha.com/IMInstructions?8MfJPEhDQOv%2fCCYR7U%2fTog%3d%3d"
      }
    }
    
    Callback object:
    The callback object will send to url mentioned in HTTP request.
     {
            "CandidateEmailId": "testemail@interviewmocha.com",
    	"AttemptedOn": "2015-06-26T21:31:03.19",
    	"TotalScore ": 50,
    	"CandidateScore ": 34,
    	"ReportPDFUrl ": "http: //app.interviewmocha.com/PDFReport?id="*************",
    	"TestInvitationId": 2256212
    }