Schnellstart-Anleitung

Von Null zur Segmentierung in 3 Minuten

Drei Schritte. Copy-Paste-Code. Kein ML-Setup, kein Modell-Hosting.

Kostenlosen API-Schlüssel erhalten
5 kostenlose Credits bei Registrierung1 Credit pro AufrufKeine Kreditkarte erforderlich
01

API-Schlüssel erhalten

Erstellen Sie ein kostenloses Konto. Ihr API-Schlüssel wird sofort generiert – keine Warteliste, keine Kreditkarte.

Kostenloses Konto erstellen →

Ihr Schlüssel sieht so aus:

// Your key will look like:
const API_KEY = "sk-sam3-xxxxxxxxxxxxxxxxxxxxxxxx";
02

Erste Anfrage senden

POST ein Bild (Base64) und einen Text-Prompt an unseren Endpunkt. Funktioniert mit jedem 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"]
  }'
NewClick-to-segment endpoint — /v1/pvs
Read docs →

Use point prompts (positive/negative) to segment a specific area — no text prompt required. Same auth, same pricing as /v1/segment.

# Click-to-segment (PVS) — when you already know the area you want
curl -X POST https://api.sam3.ai/v1/pvs \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "image": "data:image/jpeg;base64,/9j/4AAQ...",
    "points": [
      { "x": 412, "y": 318, "positive": true },
      { "x": 540, "y": 290, "positive": false }
    ]
  }'
03

Antwort parsen

Sie erhalten Polygon-Masken mit Labels und Konfidenzwerten zurück – bereit zum Rendern in Ihrer App.

JSON-Antwort

{
  "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],
        ["..."]
      ]
    }
  ]
}

Jede Maske enthält das Objektlabel, den Konfidenzwert und die Polygon-Koordinaten.

1 Credit pro API-Aufruf · 5 kostenlose Credits bei RegistrierungMehr kaufen ab $0,07 / AufrufPreise ansehen →

Bereit zum Loslegen?

5 kostenlose Credits bei Registrierung. Keine Kreditkarte erforderlich.