Skip to content

Ximdex CMS API: Login

Javi Carretero edited this page Sep 5, 2013 · 3 revisions

This action allows to log an user into Ximdex, obtaining a token (called ximtoken) which must be used in any secured action of the Ximdex API. An action is secured whether it needs a token to be executed.

This token contains information about the user who is performing the login and this information can be used by the other actions, for example to check the user permissions in a specific document.

Description Log in into Ximdex CMS
URL /api/login
Parameters user (required): Ximdex CMS's username. It must exists previously.
pass (required): Password for this user.
Response ximtoken: token now associated to the user while the time defined on the TokenTTL lasts. It would be needed to perform all the secured actions provided by the Ximdex API.
Example
POST Request #1 curl -X POST --data "user=johndoe&pass=my_pass" http://example.org/ximdex/api/login
GET Request #1 curl -X GET "http://example.org/ximdex/api/login? user=johndoe&pass=my_pass"
Response #1 {"error":0,"data":{"ximtoken":"ajVhcGx0aFBHZnlERVNiZ0huUkZjRldDSmpIZ3QwRzlNRjlHaitGZ3NLci9HNldIejlpazNlSjA0Q2gzUXJwVjlvcEhXUlkwaU5GZHVybkZ0endGR2c9PQ=="}}

Topics

  • Home
  • How do I start?
  • Easy Recipes

Clone this wiki locally