Quick Start Guide
From Zero to Segmentation in 3 Minutes
Three steps. Copy-paste code. No ML setup, no model hosting.
Get Free API Key5 free credits on signup1 credit per callNo credit card required
01
Get your API key
Create a free account. Your API key is generated instantly — no waitlist, no credit card.
Create Free Account →Your key will look like:
// Your key will look like:
const API_KEY = "sk-sam3-xxxxxxxxxxxxxxxxxxxxxxxx";// Your key will look like:
const API_KEY = "sk-sam3-xxxxxxxxxxxxxxxxxxxxxxxx";02
Send your first request
POST an image (Base64) and a text prompt to our endpoint. Works with any HTTP client.
curl -X POST https://api.sam3.ai/v1/segment \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"image": "data:image/jpeg;base64,/9j/4AAQ...",
"prompts": ["cat"]
}'curl -X POST https://api.sam3.ai/v1/segment \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"image": "data:image/jpeg;base64,/9j/4AAQ...",
"prompts": ["cat"]
}'03
Parse the response
You get back polygon masks with labels and confidence scores — ready to render in your app.
JSON Response
{
"masks": [
{
"label": "cat",
"confidence": 0.96,
"polygon": [
[120, 45], [185, 32], [260, 40],
[318, 78], [325, 160], [290, 240],
[200, 268], [118, 250], [80, 175],
["..."]
]
}
]
}{
"masks": [
{
"label": "cat",
"confidence": 0.96,
"polygon": [
[120, 45], [185, 32], [260, 40],
[318, 78], [325, 160], [290, 240],
[200, 268], [118, 250], [80, 175],
["..."]
]
}
]
}Each mask contains the object label, confidence score, and polygon coordinates.
1 credit per API call · 5 free credits on signupBuy more from $0.07 / callView pricing →
Ready to start building?
5 free credits on signup. No credit card required.