Overview
The Handshake endpoint is called every time a user opens the supplies module in your platform. It authenticates the user and returns a secure, time-limited session token that you use to embed the Sticker iframe.When to Call This Endpoint
1
User Clicks Supplies
User navigates to the supplies/procurement section in your platform
2
Get Current User
Identify the authenticated user from your session
3
Call Handshake API
Send user identifier to receive a session token
4
Embed iframe
Display the iframe using the returned URL
API Endpoint
https://api.usesticker.com
Authentication
Use theX-API-Key header (not Authorization: Bearer):
Request Format
Send eitherinternal_user_id OR profile_id:
Recommended: Use
internal_user_id (your internal identifier from organization setup). This way you don’t need to store Sticker profile IDs in your database.Response Format
Response Fields
Session Token Properties
Session tokens have important security properties:Complete Flow Example
Here’s what a typical integration looks like:Code Examples
Your Backend Endpoint
Your Frontend Component
Error Handling
400 Invalid Request
400 Invalid Request
internal_user_id or profile_id in the request body.404 Profile Not Found
404 Profile Not Found
- Ensure organization setup was called first
- Verify the
internal_user_idmatches what was used in setup - Check you’re using the correct partner API key
400 Profile Not Set Up
400 Profile Not Set Up
Best Practices
Generate On-Demand Only
Generate On-Demand Only
Create tokens only when the user clicks to open supplies. Don’t pre-generate or cache tokens.
Server-Side Only
Server-Side Only
Always call the handshake from your backend. Never expose your API key in frontend code.
Handle Expiration
Handle Expiration
If a user takes too long to load the page (>5 min), generate a fresh token:
Error Recovery
Error Recovery
If the iframe fails to load, show a retry button that generates a new token:

The embedded Sticker experience after successful authentication
Testing
Test the handshake flow:- Setup a test user via organization setup endpoint
- Call handshake with the test user’s
internal_user_id - Verify response contains valid
iframe_embed_url - Open the URL in a browser to confirm authentication works
Next Steps
iframe Embedding
Learn how to embed and style the iframe
API Reference
Complete API specification

