Harness Meta's Segment Anything 3 (SAM) framework for zero-shot, pixel-perfect object segmentation. Isolate items, generate masks, or track elements across frames using natural language or coordinate prompts.
One POST request. Get the result back directly — as an image, video, or JSON depending on the tool.
curl -X POST https://apiai.me/api/workflow/sam3-image \
-H "X-API-Key: YOUR_API_KEY" \
-F "image=@input.jpg" \
-F "mask_color=green" \
-F "mask_only=true" \
-F "mask_opacity=0.5" \
-F "prompt=person" \
-F "return_zip=false" \
-F "save_overlay=false" \
-F "threshold=0.5"
--output result.mp4
Test this tool visually before writing any code. Upload an image, set parameters, and see the result live. When it looks right, copy the auto-generated curl command and paste it into your app.
Process hundreds of images at once without writing a loop. Upload a CSV with one row per item, set your parameters, and download the results as a ZIP when they're done.
| Name | Required | Description | Default / Options |
|---|---|---|---|
mask_color |
optional | Color of the mask overlay. Options: 'green', 'red', 'blue', 'yellow', 'cyan', 'magenta' | green
|
mask_only |
optional | If True, returns a black-and-white mask image instead of an overlay on the original image | true
|
mask_opacity |
optional | Opacity of the mask overlay (0.0 to 1.0) | 0.5
|
prompt |
optional | Text prompt for segmentation | person
|
return_zip |
optional | If True, returns a ZIP file containing individual masks as PNGs | false
|
save_overlay |
optional | If True, includes the overlay image in the ZIP file | false
|
threshold |
optional | Confidence threshold for object detection | 0.5
|
Get an API key, test Sam3 Image in the dashboard, and copy the curl command.