Personal Access Tokens¶
A user that has any access level to a facility can obtain a Personal Access Token (PAT) from the Golf Portal web site. This token can then be used by a client application to act on behalf of that user and communicate with the TrackMan Cloud API.
The steps to acquire a Personal Access Token are as follows:
-
Navigate to the golf portal web site
https://portal.trackmangolf.com
. -
From the Facility main menu, select API -> Personal Access Token
- On the landing page, click on the
Create Token
button. A popup dialog will appear to fill in information on the new token. Fill in theToken name
field and optionally theDescription
field and click on theCreate token
button.
- Copy the
Client ID
andClient Secret
in the dialog that appears. TheClient Secret
is never saved, so this is the only chance to copy it and keep it safe somewhere else. If you lose it, you'll have to create a new Personal Access Token.
- You can now use the
Client Id
andClient Secret
to obtain a bearer token using the following request:
curl --request POST \
--url https://login.trackmangolf.com/connect/token \
--header 'content-type: application/x-www-form-urlencoded' \
--data grant_type=client_credentials \
--data client_id=xxx.xxx... \
--data client_secret=xxx.xxx... \
--data 'scope=https://auth.trackman.com/dr/facility'