Usage of Access Token

Release Time
03/02/2018
Views
6102 times
Category
Comodo ONE portal
Tags

Introduction

3rd Party Authentication and Authorization API provides a security mechanism similar to OAuth2 standard. With this mechanism client APIs can access C1 Platform Resources in a secure way. 

There are some prerequisites before usage of this API. 

  • Client API credentials. Credentials will be provided by the C1 team. The credentials shall be used for HTTP Basic Authentication of endpoints.
  • Resource owner credentials. Credentials shall be used for login endpoint. Username/password and TLS Client Certificate Verification.

First clients need to obtain access and refresh tokens via login endpoint. With access token clients can access protected resources. Please see section "Usage Of Access Token" to use access tokens. 

For testing purposed on Preview Environment following credentials is created.

For User Client (name):

    username: user

    password: *******************************


Access tokens are short lived tokens. Therefore they expire quickly. New access tokens can be obtained without resource owner credentials via renew endpoint. Refresh tokens are used to create new access tokens. Refresh tokens are long lived tokens and can be persisted for longer use. They are critical for the security of protected resources. Because of that please store them in a secure way and do not share them with any other 3rd parties. 

On order to access Authentication API TLS Client Certificate Verification is also performed. Therefore the test certificate must be shared with Comodo to grad access. 

For details of the transactions for authentication API please look at 3rd Party API 

  

Usage of Access Token:

Access Tokens are sent within the header of the request in order to access resources.

Execution

Sample execution can be handled via Postman Application. 

Header part can be handled via Postman Application

Success Output

Error Output