Using limesurvey RPC with chrome postman

Mehr
6 Monate 3 Wochen her #182198 von someuser99
I am trying to test lime survey Remote control 2 API using post man. I have enabled RPC for JSON on my live survey instance.

i make a get request on postman(As shown in the image attached) for get_session and export_responses method.

In both the cases, i get status 200 OK along with the following text in the body

Loading...
RemoteControl is available using json for transport and exposes the following functionality:
activate_survey
/**
* Activate an existing survey
*
* Return the result of the activation
* Failure status : Invalid Survey ID, Constistency check error, Activation Error, Invalid session key, No permission
*
* @access public
* @param string $sSessionKey Auth credentials
* @param int $iSurveyID ID of the Survey to be activated
* @return array in case of success result of the activation
*/
activate_tokens
/**
* Initialise the token system of a survey where new participant tokens may be later added.
*
* @access public
* @param string $sSessionKey Auth credentials
* @param integer $iSurveyID ID of the Survey where a survey participants table will be created for
* @param array $aAttributeFields An array of integer describing any additional attribute fields
* @return array Status=>OK when successful, otherwise the error description
*/
add_group
/**
* Add an empty group with minimum details to a chosen survey.
* Used as a placeholder for importing questions.
* Returns the groupid of the created group.
*
* @access public
* @param string $sSessionKey Auth credentials
* @param int $iSurveyID ID of the Survey to add the group
and so on...

why don't i get a string as i should in both the cases?
Anhänge:

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

LimeSurvey Partners
Mehr
6 Monate 3 Wochen her #182202 von 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 .
An error happen ? Before make a new topic : remind the Debug mode .

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Mehr
6 Monate 3 Wochen her - 6 Monate 3 Wochen her #182210 von tpartner
This works for me after getting a session key:

{
	"method": "get_survey_properties",
	"params": [
		"cJxNVsllmB4ttejg3VT3FxqeuqrCVqc5",
		"885886"
	],
	"id": 1
}


Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Official LimeSurvey Partner - partnersurveys.com
Anhänge:
Letzte Änderung: 6 Monate 3 Wochen her von tpartner.
Folgende Benutzer bedankten sich: DenisChenu

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Mehr
6 Monate 3 Wochen her #182221 von DenisChenu
Yep, because you d a josn-rpc call. Not someuser99 who need hekp not totaly related to LS ;)

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 .
An error happen ? Before make a new topic : remind the Debug mode .

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Mehr
6 Monate 3 Wochen her #182289 von someuser99
Thank you. works for me now as well.

1) May i ask why you used 'POST' here? Since we are receiving the data, i thought it should be get.

2) Also, what is the 'id' field in your post? what does it describe.

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Mehr
6 Monate 3 Wochen her #182290 von tpartner
1) LSjsonRPCServer.php seems to require it - github.com/LimeSurvey/LimeSurvey/blob/ma...sonRPCServer.php#L14

2) Again, LSjsonRPCServer.php requires it - github.com/LimeSurvey/LimeSurvey/blob/ma...sonRPCServer.php#L39

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Official LimeSurvey Partner - partnersurveys.com
Folgende Benutzer bedankten sich: DenisChenu

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Mehr
6 Monate 3 Wochen her #182353 von 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 .
An error happen ? Before make a new topic : remind the Debug mode .
Folgende Benutzer bedankten sich: tpartner

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Jetzt loslegen!

Melden Sie sich jetzt an, und erstellen Sie in wenigen Minuten Ihre erste Umfrage.

Account einrichten

Abonnieren Sie unseren Newsletter

Abonnieren Sie unseren Newsletter für alle Neuigkeiten rund um LimeSurvey
captcha