REST API: Difference between revisions
From LimeSurvey Manual
No edit summary |
|||
Line 11: | Line 11: | ||
=Introduction= | =Introduction= | ||
LimeSurvey REST API v1 is available in | LimeSurvey REST API v1 is available in LS 5.5.0 or more recent which offers '''various [https://api.limesurvey.org/swagger API endpoints]'''. | ||
=Setup= | =Setup= | ||
== | ==Configure== | ||
In order to use REST API you must first enable the service, and then adjust the settings to suit your needs. To enable login to the LimeSurvey administration, go to [[Global settings]], choose the tab 'Interfaces' and select 'Publish API on /rest'. | In order to use REST API you must first enable the service, and then adjust the settings to suit your needs. To enable login to the LimeSurvey administration, go to [[Global settings]], choose the tab 'Interfaces' and select 'Publish API on /rest'. | ||
Line 23: | Line 23: | ||
The REST API uses the same security measures as the normal administration login. That means that the permission set of the used username and password is the same as if you would login in the administration with that user/password. Also the REST API is protected against brute-force password cracking - like the normal administration login. | The REST API uses the same security measures as the normal administration login. That means that the permission set of the used username and password is the same as if you would login in the administration with that user/password. Also the REST API is protected against brute-force password cracking - like the normal administration login. | ||
= | =Usage= | ||
==API Location== | |||
The REST API URL is [http://www.yourdomain.com/rest/v1 http://www.yourdomain.com/rest/v1] . | The REST API URL is [http://www.yourdomain.com/rest/v1 http://www.yourdomain.com/rest/v1] . | ||
The available API endpoints are documented using swagger [https://api.limesurvey.org/swagger https://api.limesurvey.org/swagger]. | The available API endpoints are documented using swagger [https://api.limesurvey.org/swagger https://api.limesurvey.org/swagger]. | ||
==Sessions== | |||
==Endpoints== | |||
==Examples== | |||
===PHP Example=== |
Revision as of 13:09, 18 October 2022
TODO
Under development
Available from version x (LS 5.5.0?)
Available API endpoints
Technical specification. UML.
Introduction
LimeSurvey REST API v1 is available in LS 5.5.0 or more recent which offers various API endpoints.
Setup
Configure
In order to use REST API you must first enable the service, and then adjust the settings to suit your needs. To enable login to the LimeSurvey administration, go to Global settings, choose the tab 'Interfaces' and select 'Publish API on /rest'.
Security
The REST API uses the same security measures as the normal administration login. That means that the permission set of the used username and password is the same as if you would login in the administration with that user/password. Also the REST API is protected against brute-force password cracking - like the normal administration login.
Usage
API Location
The REST API URL is http://www.yourdomain.com/rest/v1 .
The available API endpoints are documented using swagger https://api.limesurvey.org/swagger.