ShipBob’s API supports two authentication methods: Personal Access Token (PAT) for single-user integrations and OAuth 2.0 for multi-user applications.
Prerequisites
Before you begin, you’ll need a ShipBob account. Choose your environment:Our sandbox accounts are separate environments and data cannot be transferred over to production.
Choose Your Authentication Method
Personal Access Token
- Best for single-user custom integrations
- Quick setup, no expiration, and full account access
OAuth 2.0
- Best if you want to create a multi-user app
- Required for apps listed on the ShipBob App Store
Personal Access Token (PAT) Flow
This is best for single-user custom integrations and quick setup, no expiration and full account access.1
Generate Your Token
Navigate to the ShipBob dashboard and create your PAT:
- Production
- Sandbox
Go to Integrations > API Tokens > Generate New Token
When you request your first PAT, ShipBob automatically creates a Single-Merchant Application (SMA) and channel to manage your tokens. You can generate multiple tokens and revoke them anytime.
2
Add Token to API Requests
Include your PAT in the
Authorization header of all API requests:3
Retrieve Your Channel ID
OAuth Flow
OAuth is required for multi-user integrations and applications listed on the ShipBob App Store. It provides secure, granular access control with token expiration.
Step 1: Create App
Generate credentials from the ShipBob dashboard by going to Integrations > OAuth Apps > Create App. See more here.If you want to test on a sandbox account here is the link to create one.
Step 2: Request Permission to Access User Data
Once you have your client ID and secret, you can use them to get a user’s permission to access their account data. You start by making a request to the following endpoint:Use
https://authstage.shipbob.com/connect/authorize if on sandbox.| Parameter | Values | Required? |
|---|---|---|
client_id | Client id provided by step 1. | required |
scope | One or more scopes granted by step 1, space-separated. NOTE: if you want to take advantage of refresh tokens (aka offline access mode) you must additionally request the offline_access scope. | required |
redirect_uri | The callback URI ShipBob will call after the user responds to the request for consent. Must match one of the provided values from step 1. | required |
response_mode | If you include this query parameter with value form_post then we will make a POST request to your callback URL, instead of including the data as a fragment. | optional |
integration_name | Name of the integration for this particular user. We recommend that you know the user’s store name on your platform. If not provided, the user will be prompted to provide their name or choose one from a drop-down of options. | recommended |
state | Application-provided string to help prevent replay attacks. Echoed back to the application in the callback for validation. | recommended |
nonce | A random string you can send and we will send it back within the token, to prevent replay attacks, code substitutions, etc. | recommended |
Step 3: Implement Your Callback URI
When the user grants access, ShipBob redirects to your callback URI with the following parameters:Step 4: Obtain an Access Token
Exchange the authorizationcode for an access token by making a POST request:
Use
https://authstage.shipbob.com/connect/token if using sandbox.Step 5: Refresh Token
If usingoffline_access, a refresh_token will also be provided.
Use it to obtain new tokens without requiring user login:
refresh_token will be generated every time you create a new access_token.
Step 6: Retrieve Your Channel ID
Most of the POST requests on the ShipBob API require you to include ashipbob_channel_id in the header. Retrieve it via:
https://sandbox-api.shipbob.com/2025-07/channel.
You’re now ready to make authenticated API requests using ShipBob!
Step 7: Test Your App (Optional)
- Verify the OAuth flow works end-to-end.
- Ensure scopes and permissions are correctly applied.
- Test with sandbox data before going live.
Step 8: Publish in ShipBob App Store (Optional)
Want to make your app available to all ShipBob merchants? Publishing to the App Store allows any ShipBob user to discover and install your integration.
1
Submit App for Review
In the ShipBob dashboard, navigate to Integrations > OAuth Apps, find your app, and click Publish in the Action column.Required Information:
-
App Icon (500x500px, .png or .jpeg)
This image represents your app in the ShipBob App Store. Choose a clear, recognizable logo. -
Integration Description (max 500 characters)
Highlight key features, benefits, and use cases. Focus on what problems your app solves for merchants. -
Support Documentation Link
Provide a URL to help articles or guides that explain how to use your integration. -
Support Email
Enter a support email address where users can reach your team for questions or issues. -
Install URL
This is where users will be redirected when they click Get App in the ShipBob App Store. It should route to your OAuth authorization flow (Step 2).
2
Review Process
The ShipBob team will review your app within 1-3 business days.They may contact the user listed under the Created By column if additional details or changes are needed.
3
Approval & Listing
Once approved, your app will be listed in the ShipBob App Store.ShipBob merchants can now discover and install your app.
Monitor your support email for user questions and feedback after launch. A responsive support experience helps build trust with merchants.
App Store Listing Best Practices
App Store Listing Best Practices
- Clear Icon: Use a simple, recognizable logo that looks good at small sizes
- Compelling Description: Focus on merchant benefits, not just technical features
- Quality Documentation: Provide step-by-step setup guides and troubleshooting tips
- Responsive Support: Answer merchant questions promptly to build trust
- Test Thoroughly: Ensure your OAuth flow works flawlessly before submitting
Quick Reference
Environment URLs
Environment URLs
Common Headers
Common Headers
Token Lifetimes
Token Lifetimes
| Token Type | Lifetime | Notes |
|---|---|---|
| PAT | Never expires | Revoke manually from dashboard |
| OAuth Access Token | 1 hour | Refresh before expiration |
| OAuth Refresh Token | 30 days | New one issued with each refresh |
Security Best Practices
Security Best Practices
- ✅ Store tokens securely (e.g., encrypted database, secrets manager)
- ✅ Never commit tokens to version control
- ✅ Use HTTPS for all API requests
- ✅ Implement proper error handling for expired tokens
- ✅ Validate
stateparameter in OAuth callbacks - ✅ Use
offline_accessscope only when necessary - ✅ Regularly rotate PAT tokens
- ⛔ Don’t expose tokens in client-side code
- ⛔ Don’t share tokens between environments
