Token

In this post we will see how to use the authorization token to make any Ventiapp public API call.

HTTP Header

In the previous post, a Bearer Token is obtained after authenticating against the Login endpoint. To make any call, the Authorization value must be added to the Headers of the REST call. It is done as follows

Key header: Authorization Value header: Bearer + token (sin comillas)

Example:

Authorization: Bearer V9e78myG5kPq_Kp8TAUhnJOnVvZEQ6rWS7IFbCD9dkxReYUSe_m1Sn5xjq2KF-XJhTIlQWvF9GIndhtDjx7WQr4CzYye1KLTNkJevRPNk2HR9cEULifFArxez8kA4evkRDke-4a3Gekdb_sDcQZXr6X1D4C7MeqyNAT0LjvqgLR-dFXdbNQrBkvIX_I6hsPzEAR0mjcxWRawVMfcq97vpPUAW42cZJD-AJbZdE9KVwUYgIhgO2M2IBZLrctLvl2xjx3OrQy9-Y_d---wUUDoWw

All the API's request must need this header

Example cURL:

curl --header "Authorization: Bearer  V9e78myG5kPq_Kp8TAUhnJOnVvZEQ6rWS7IFbCD9dkxReYUSe_m4Sn5xjq2KF-XJhTIlQWvF9GIndhtDjx7WQr4CzYye1KLTNkJevRPNk2HR9cEULifFArxez8kA4evkRDke-4a3Gekdb_sDcQZXr6X1D4C7MeqyNAT0LjvqgLR-dFXdbNQrBkvIX_I6hsPzEAR0mjcxWRawVMfcq97vpPUAW42cZJD-AJbZdE9KVwUYgIhgO2M2IBZLrctLvl2xjx3OrQy9-Y_d---wUUDoWw"  https://ventiapi.azurewebsites.net/api/account/userdata

Última actualización