OK, so I have managed to add participants using the API.
Format is
{
"method": "add_participants",
"params": {
"sSessionKey":"##############################",
"iSurveyID": 123,
"aParticipantData":
[
{
"firstname": "Stephen",
"lastname": "Jones",
"email": "stephenj@hotmail.com",
"emailstatus": "OK",
"language": "en",
"token":"MG0007",
"attribute_1": "XYZ"
}
]
},
"bCreateToken": "false",
"id": 1
}
But how do I do this and SET the token for the user. I want specific tokens that relate to other information.
When I use the following in aParticipantData nothing happens and a Token is set for the user irrespective of the bCreateToken setting:
"token":"MG0007"
If I can't set as part of add_participant, can I change using set_participant_properties ?
I get a "No valid Data" status if I use this JSON:
{
"method": "set_participant_properties",
"params": {
"sSessionKey":"##########################",
"iSurveyID": 123,
"iTokenId" : 8,
"aTokenData":
[
{
"token":"MG0007"
}
]
},
"id": 1
}
The topic has been locked.