RemoteControl_2_API#PHP_Example

More
2 months 3 weeks ago #219772 by darshanrdesai
Hello LimeSurvey Team,
I am trying to use the below API
manual.limesurvey.org/RemoteControl_2_API#PHP_Example
But I get the below error:
Fatal error: Uncaught Exception: Incorrect response id: (request id: 1) in C:\PATH\jsonrpcphp\JsonRPCClient.php:196 Stack trace: #0 C:\PATH\Test.php(43): org\jsonrpcphp\JsonRPCClient->__call('get_session_key', Array) #1 {main} thrown in C:\PATH\jsonrpcphp\JsonRPCClient.php on line 196

Warning
: Trying to access array offset on value of type null in C:\PATH\jsonrpcphp\JsonRPCClient.php on line 195

Please Log in to join the conversation.

More
2 months 2 weeks ago #219780 by DenisChenu
Bad url maybe

> $myJSONRPCClient = new \org\jsonrpcphp\JsonRPCClient( LS_BASEURL.'/admin/remotecontrol' );

This is false : copy/paste from LimeSurvey interface.

Else : broke with Incorrect response id means there are no JSONRPC answer at end. Can be a 200, a 404 a 500 etc …

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.

More
2 months 2 weeks ago #219783 by darshanrdesai
Hello DenisChenu,

Thank you. URL used is below :
http://<DOMAIN>.limesurvey.org/limesurvey/index.php?r=admin/remotecontrol

If this is wrong kindly could you mention the right one please.

Yes, This is the below error message:
404 Not Found
nginx

Please Log in to join the conversation.

More
2 months 2 weeks ago #219784 by DenisChenu
In the administration page : where you activate RPC : manual.limesurvey.org/Global_settings#Interfaces

You see the url to use.

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: darshanrdesai

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now