قاعدة معرفة GetMyBot

API Quickstart

Your first GetMyBot API request in five minutes: create a personal token and call REST.

في هذه الصفحة

Create a personal token, find the base URL, and call your first REST endpoint.

Step 1. Create a personal token

Open the account dashboard, go to the personal tokens section, and create a new token (PAT). Copy its value immediately: it is shown only once and starts with the mbp_ prefix. When creating, choose scopes sufficient for your use case; see the authorization guide for details.

Step 2. Base URL and format

All REST endpoints live under the /api prefix. There is no version segment in the path. Request and response bodies are JSON; include the Content-Type: application/json header for requests with a body. The token is passed via the Authorization: Bearer mbp_… header.

Step 3. First request: list bots

Verify the token by requesting your list of bots. This requires the bots:read scope (or *):

curl -H "Authorization: Bearer mbp_YOUR_TOKEN" https://your-domain/api/bots

The response is a JSON array of bots. If the token is invalid or expired, a 401 is returned with the body {"error":"..."} (see errors).

Step 4. First mutation: create a reaction

Creating a reaction requires the reactions:write scope. Substitute the bot ID from step 3:

curl -X POST -H "Authorization: Bearer mbp_YOUR_TOKEN" -H "Content-Type: application/json" -d '{"name":"Hello","trigger":{"type":"command","value":"/start"}}' https://your-domain/api/bots/BOT_ID/reactions

A successful response returns the created reaction with its id. For exact request body fields, see the interactive reference: it generates ready-to-use examples in curl, JavaScript, and Python for every endpoint.

Step 5. Continue with the reference

Once the token is working, the rest is easier to explore in the interactive reference: it shows the full endpoint list, required scopes, body schemas, and a "Try it" button.

Managed AI quick request

Create a token with managed_ai:invoke, then send a provider-neutral request. Reuse the same key only when retrying the same operation:

curl -X POST https://your-domain/api/v1/ai/responses \
  -H "Authorization: Bearer mbp_YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: ai-demo-0001" \
  -d '{"profile":"balanced","provider":"auto","input":[{"role":"user","content":[{"type":"input_text","text":"Summarize this conversation"}]}],"max_output_tokens":300}'

Use /api/public/capabilities before rendering Managed AI or Meta UI. A false/unavailable value is a product state, not a transport failure.

What's next