Set Up Your Org
Learning Objectives
In this project, you'll:
- Get your org ready to use Postman.
- Load the Salesforce Platform APIs for Postman collection.
- Connect Postman to your org.
- Verify the connection with Postman.
Why Use Postman to Access the Salesforce Platform APIs?
Salesforce exposes a rich set of application program interfaces (APIs) that integrate with third-party systems. All of these APIs are thoroughly documented, but how can you quickly try them on a given org, or better yet, on multiple orgs? Postman helps you discover, explore, and test integration options with the Salesforce Platform APIs.
About Salesforce Platform APIs
Salesforce provides programmatic access to your org's information through simple, powerful, and secure APIs. The APIs provided by Salesforce include REST, SOAP, Connect, User Interface, Analytics, Bulk, Metadata, and Streaming.
About Postman
Postman is an application that you can use to configure and call HTTP-based APIs, such as REST or SOAP. You configure this powerful tool in an easy-to-use graphical user interface. It supports environment variables, team workspaces, and JavaScript automation. If you are new to Postman then check out their Learning Center.
Web or Desktop?
Use Postman as a desktop app or in a web browser. In this project, you set up and use Postman in a web browser, because it doesn't require downloading and installing software.
About the Salesforce Platform APIs for Postman Collection
The Salesforce Platform APIs for Postman collection is a resource that wraps together 200+ request templates for many Salesforce Platform APIs. This open source collection uses the configurable Postman environment and variables so that you can easily authenticate and try the requests on multiple Salesforce orgs.
Create a New Trailhead Playground
For this project, you need to create a new Trailhead Playground. Scroll to the bottom of this page, click the playground name, then click Create Playground. It typically takes 3–4 minutes to create a new Trailhead Playground.
Get Your Trailhead Playground Username and Password
Let's get started by opening your Trailhead Playground. Scroll to the bottom of this page and click Launch. If you see a tab in your org labeled Get Your Login Credentials, great! Skip ahead to step 1. Otherwise, from the App Launcher (), find and open Playground Starter and follow the steps.
- Click the Get Your Login Credentials tab and take note of your username.
- Click Reset My Password.
This sends an email to the address associated with your username.
- Click the link in the email.
- Enter a new password, confirm it, and click Change Password.
Save your username and password for use later in this project.
Set Up Cross-Origin Resource Sharing in Salesforce
Cross-Origin Resource Sharing (CORS) allows code running in a web browser to communicate with Salesforce from a specific origin. Let's add the URL patterns for Postman.
- In your Trailhead Playground, from Setup, enter
cors
in the Quick Find box and select CORS.
- In the Allowed Origins List, click New.
- Enter
https://*.postman.com
as the Origin URL Pattern.
- Click Save.
- Select CORS again.
- Click New and enter
https://*.postman.co
(note the .co domain extension) as the Origin URL Pattern.
- Click Save.
Your playground is ready for you to connect Postman to it. You do that in the next step.