To let your users connect a login via Salt Edge Connect, your application should request a token that will be used to identify your application, the customer and the action to be performed.

Before acquiring a token, you should be sure that a customer exists, or you should create one.

In order to request a token, your application should send a POST request to the Tokens resource, which will yield a new token. The headers used in the request should correspond to the authentication methods described in the Authentication page.

The token is only valid for a period of 60 seconds. If you redirect the user to the page after the token has expired, the user will see a “Token Expired” error on the Salt Edge Connect page.

Using a token

You can request a token for the following login actions: connect, reconnect and refresh.

Examples for requesting tokens can be found on the tokens page in API Reference.

After you have successfully requested a token, you can redirect your user to the Salt Edge Connect page. You can find the URL generated for your user in the connect_url field of the response.