Use index.php to get Pinterest API token the easy way (it took me quite some time before I could find the way to start the Oauth Flow)
Place the index.php anywhere in htdocs and launch it from a browser
The image bellow is a screenshot of what you will get, just follow the instructions
- Start the OAuth flow
- Receive the access code
- Get an access token
As described in the docs : https://developers.pinterest.com/docs/api/v5/#section/Refreshing-an-access-token