How to authenticate in Situm Rest API  


The authentication process is used to verify the user identity according to the allowed permissions. 

You can get more info about the authentication and authorization in Developers, in the following link:

More info: http://developers.situm.es/pages/rest/authentication 


In this FAQ, you will help you how to get the Authentication and Authorization through Swagger. You can find How to display the REST API in Swagger here. 


There are two kinds of authentication that you can use in Swagger in order to use Situm API:


  • Authorization Bearer
  • JWT from an user/password
  • JWT from an user/API Key



How to get the Authorization 


Authorization is the process by which it is allowed to access private resources. During this process, it must be defined which resources and operations can be carried out ("only read" or "read and write").



There are different kinds of authorization:

You can get all the API requests by the Authorization Bearer:


  • Authorization Bearer
    You can get the Authorization Bearer logged into your dashboard account. Once you are in the page, press F12. Inside Application > and then, Cookies, you will get the access_token
     

    Insert the access_token in their value field.




           



You can also get the authorization by the following ones:



1. JWT from an user/password In Base 64 encode you will encode your <user:password> of your dashboard account and insert it in the first field.

In the second field: For this authentication, you can use the following authorization: 
  • AuthorizationBasic

    You can get the Authorization Basic from the Swagger, where you will  insert the username and the password of your dashboard account. 

     

2.  JWT from an user/apikey authentication


In Base 64 encodeyou will encode your <user:password> of your dashboard account and insert it in the first field. 



For this authentication, you can use the following authorization: 

  • Authorization Basic With API Key

    Fill the blanks with the Basic user and API Key as password: