Authentication

First, to obtain your client ID and generate a client secret, go to the Developers page on the Ledge web application.

To access the Ledge API, you must request an access token when authenticating a user. To request an access token, make a POST call to the token URL.

curl --request POST --url '<https://goledge.us.auth0.com/oauth/token>' 
	--header 'content-type: application/x-www-form-urlencoded' 
	--data grant_type=client_credentials 
	--data client_id=YOUR_CLIENT_ID 
	--data client_secret=YOUR_CLIENT_SECRET 
	--data audience=https://goledge.us.auth0.com/api/v2/

You receive an HTTP 200 response with a payload containing access_token, token_type, and expires_in values:

{
	"access_token":"eyJz93a...k4laUWw",
	"token_type":"Bearer",
	"expires_in":10800
}

Last updated