You've configured your environment file and set up a connected app. The next task is to set up Postman and use it to get the session token from the org.
-
Go to www.postman.com/downloads.
-
Click Try the Web Version.
-
Enter an Email, Username, and Password, then click Create free account.
-
Type your name, then click Continue twice.
-
From the Home page, click Create New, then click HTTP Request.
-
Click Import, drag your collection file into the Import window, and click Import in the window.
-
Click Import, drag your environment file into the Import window, and click Import in the window.
-
Click Collections, expand Vlocity Digital Commerce APIs Collection, and click SFDC OAuth Username Password.
-
Change No Environment to the name of the environment you uploaded.
-
Click Send. The response looks something like this:
{ "access_token": "xxxxxxxxxxxxxxxxxxxxxxxxxx", "instance_url": "https://demo.my.salesforce.com", "id": "https://login.salesforce.com/id/.../...", "token_type": "Bearer", "issued_at": "1632504402777", "signature": "wNsUOlj65HMf8vqbDwm8bRnsK" }
note: Note: If you create your org in Summer ’23 or later, the OAuth 2.0 username-password flow is blocked by default. To enable the username-password flow, from Setup, select OAuth and OpenID Connect Settings, and select Allow OAuth Username-Password Flows.
- Save the
access_tokenvalue for use in a subsequent task. Use the access_token for the session locally.