- Posts: 9
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
export_responses_by_token: Unknown named parameter $sToken
- przemyslaw.uzdowski.itcard
- Topic Author
- Offline
- New Member
Less
More
3 months 2 weeks ago - 3 months 2 weeks ago #254404
by przemyslaw.uzdowski.itcard
export_responses_by_token: Unknown named parameter $sToken was created by przemyslaw.uzdowski.itcard
Please help us help you and fill where relevant:
Your LimeSurvey version: LimeSurvey Cloud Version 6.4.0
==================
Hello,
with POST method to remotecontrol URI I am trying to get reponses by token via Postman.
I receive error 500 with title "Unknown named parameter $sToken".
Documentation states that this parameter exists:
export_responses_by_token(string $sSessionKey,integer $iSurveyID,string $sDocumentType,string $sToken,string $sLanguageCode = null,string $sCompletionStatus = 'all',string $sHeadingType = 'code',string $sResponseType = 'short',array $aFields = null): array|string
What am I doing wrong?
Your LimeSurvey version: LimeSurvey Cloud Version 6.4.0
==================
Hello,
with POST method to remotecontrol URI I am trying to get reponses by token via Postman.
I receive error 500 with title "Unknown named parameter $sToken".
Documentation states that this parameter exists:
export_responses_by_token(string $sSessionKey,integer $iSurveyID,string $sDocumentType,string $sToken,string $sLanguageCode = null,string $sCompletionStatus = 'all',string $sHeadingType = 'code',string $sResponseType = 'short',array $aFields = null): array|string
Code:
{ "method": "export_responses_by_token", "params": { "sSessionKey": "{{session_key}}", "iSurveyID": 233154, "sDocumentType": "csv", "sToken": "{{participant_access_code}}" }, "id": 1 }
What am I doing wrong?
Last edit: 3 months 2 weeks ago by przemyslaw.uzdowski.itcard.
Please Log in to join the conversation.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10109
- Thank you received: 3595
3 months 2 weeks ago #254428
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic export_responses_by_token: Unknown named parameter $sToken
What does {{participant_access_code}} return?
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Please Log in to join the conversation.
- przemyslaw.uzdowski.itcard
- Topic Author
- Offline
- New Member
Less
More
- Posts: 9
- Thank you received: 0
3 months 1 week ago - 3 months 1 week ago #254472
by przemyslaw.uzdowski.itcard
Replied by przemyslaw.uzdowski.itcard on topic export_responses_by_token: Unknown named parameter $sToken
It is a variable that returns "token" that is created with "add_participants" method ("aParticipantData" parameter).
Access code/token can also be set by adding a new Survey Participant in GUI and filling "Access code".
$sToken stands for something else than Survey Participant Acces Code?
Access code/token can also be set by adding a new Survey Participant in GUI and filling "Access code".
$sToken stands for something else than Survey Participant Acces Code?
Last edit: 3 months 1 week ago by przemyslaw.uzdowski.itcard.
Please Log in to join the conversation.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10109
- Thank you received: 3595
3 months 1 week ago #254527
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic export_responses_by_token: Unknown named parameter $sToken
No, I was just asking whether it actually returns the token. Have you tested that?
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Please Log in to join the conversation.
- przemyslaw.uzdowski.itcard
- Topic Author
- Offline
- New Member
Less
More
- Posts: 9
- Thank you received: 0
3 months 1 week ago #254578
by przemyslaw.uzdowski.itcard
Replied by przemyslaw.uzdowski.itcard on topic export_responses_by_token: Unknown named parameter $sToken
I am not entirely sure what you mean by ‘it returning the token’.
As I understand it, in ‘params’ I should include the token (access code) of a participant who took part in the survey.
The only thing that the method returns is quite a long code that includes a message:
So I guess I have not tested it. What should I do?
As I understand it, in ‘params’ I should include the token (access code) of a participant who took part in the survey.
The only thing that the method returns is quite a long code that includes a message:
Code:
<div class="col"> <h2 class="error-title"> 500: Internal Server Error Unknown named parameter $sToken </h2> <div class="error-content">An internal error occurred while the Web server was processing your request. </div> Please contact Your Name to report this problem. </div>
So I guess I have not tested it. What should I do?
Please Log in to join the conversation.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10109
- Thank you received: 3595
3 months 1 week ago #254593
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic export_responses_by_token: Unknown named parameter $sToken
I have no clue how you derive {{participant_access_code}} . To test, try hard-coding a valid token value for the sToken parameter.
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Please Log in to join the conversation.
- przemyslaw.uzdowski.itcard
- Topic Author
- Offline
- New Member
Less
More
- Posts: 9
- Thank you received: 0
3 months 1 week ago #254594
by przemyslaw.uzdowski.itcard
Replied by przemyslaw.uzdowski.itcard on topic export_responses_by_token: Unknown named parameter $sToken
If sToken stands for an Access code of a Participant, I've already tried to hard-code it: same result. That is why I am seeking for help.
Please Log in to join the conversation.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13648
- Thank you received: 2491
3 months 1 week ago #254612
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic export_responses_by_token: Unknown named parameter $sToken
Can you try aTokens in place of sToken ?
github.com/LimeSurvey/LimeSurvey/blob/bb...hp#L3623C90-L3623C97
Or remove the keys maybe.
github.com/LimeSurvey/LimeSurvey/blob/bb...hp#L3623C90-L3623C97
Or remove the keys maybe.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The following user(s) said Thank You: przemyslaw.uzdowski.itcard
Please Log in to join the conversation.
- przemyslaw.uzdowski.itcard
- Topic Author
- Offline
- New Member
Less
More
- Posts: 9
- Thank you received: 0
3 months 1 week ago #254659
by przemyslaw.uzdowski.itcard
Now I need to find out what I can do with this result, but it's a different story.
Thank you!
Replied by przemyslaw.uzdowski.itcard on topic export_responses_by_token: Unknown named parameter $sToken
It worked! I've received a result.Can you try aTokens in place of sToken ?
Now I need to find out what I can do with this result, but it's a different story.
Thank you!
Please Log in to join the conversation.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13648
- Thank you received: 2491
3 months 1 week ago #254661
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic export_responses_by_token: Unknown named parameter $sToken
OK,
Update name of parameters in remote control broke API semantical version …
Strange since we use json_rpc 1.0 www.jsonrpc.org/specification_v1
Update name of parameters in remote control broke API semantical version …
Strange since we use json_rpc 1.0 www.jsonrpc.org/specification_v1
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Please Log in to join the conversation.