Overview
Connect a Google account once from the dashboard, then send and read its mail over plain REST. Base URL: https://api.reinterface.com/api/v1. All responses are JSON. Last updated: 2026-08-08.
Authentication
Requests carry a short-lived access token, not your API key. POST your personal key to /api/v1/token once, then send the token it returns in the Authorization header for the next hour. Find your key under Dashboard → Settings → API keys. The token identifies you, so it only ever reaches accounts you connected yourself.
curl -X POST https://api.reinterface.com/api/v1/token \
-H "x-api-key: <YOUR_API_KEY>"
# {"access_token":"eyJ...","token_type":"Bearer","expires_in":3600}-H "Authorization: Bearer <ACCESS_TOKEN>"Picking an account: if you have exactly one connected Google account you never need to pass anything, every endpoint defaults to it. With several accounts, pass connection_id (from GET /google/accounts) to choose one.
Connected accounts
Lists your connected Google accounts. Use the returned id as connection_id when you have more than one account.
/api/v1/google/accountsList your connected Google accounts
curl https://api.reinterface.com/api/v1/google/accounts \
-H "Authorization: Bearer <ACCESS_TOKEN>"{
"accounts": [
{
"id": "<CONNECTION_ID>",
"email": "user@gmail.com",
"name": "User Name",
"status": "connected",
"scopes": ["...gmail.send", "...gmail.readonly"],
"last_connected_at": "2026-07-16T09:00:00Z"
}
]
}Send email
/api/v1/gmail/sendSend email as the connected account
Provide to, subject, and text and/or html. connection_id is optional.
curl -X POST https://api.reinterface.com/api/v1/gmail/send \
-H "Authorization: Bearer <ACCESS_TOKEN>" \
-H "content-type: application/json" \
-d '{
"to": "recipient@example.com",
"subject": "Hello",
"html": "<p>Body</p>"
}'{
"id": "18c1a2b3d4e5f6a7",
"threadId": "18c1a2b3d4e5f6a7",
"status": "sent"
}List messages
/api/v1/gmail/messagesList recent messages (metadata + snippet)
Query params: max_results (default 10, max 50) and optional connection_id.
curl "https://api.reinterface.com/api/v1/gmail/messages?max_results=10" \
-H "Authorization: Bearer <ACCESS_TOKEN>"{
"messages": [
{
"id": "18c1a2b3d4e5f6a7",
"threadId": "18c1a2b3d4e5f6a7",
"snippet": "First lines of the email…",
"subject": "Hello",
"from": "Sender <sender@example.com>",
"to": "user@gmail.com",
"date": "Thu, 17 Jul 2026 09:00:00 +0000"
}
]
}Get one message
/api/v1/gmail/messages/{id}Get one message with the full body
curl "https://api.reinterface.com/api/v1/gmail/messages/18c1a2b3d4e5f6a7" \
-H "Authorization: Bearer <ACCESS_TOKEN>"{
"id": "18c1a2b3d4e5f6a7",
"threadId": "18c1a2b3d4e5f6a7",
"snippet": "First lines of the email…",
"subject": "Hello",
"from": "Sender <sender@example.com>",
"to": "user@gmail.com",
"date": "Thu, 17 Jul 2026 09:00:00 +0000",
"text": "Plain-text body",
"html": "<p>HTML body</p>"
}Errors
Errors return { "success": false, "error": { "code", "message" } }.
| Status | Code | Meaning |
|---|---|---|
| 401 | unauthorized | Missing, invalid or expired access token |
| 400 | invalid_request | Missing required fields |
| 403 | missing_scope | Account lacks a Gmail permission, reconnect it |
| 404 | not_found | connection_id does not exist or is not yours |
| 404 | google_account_not_connected | No connected Google account |
| 502 | gmail_send_failed | Gmail rejected the send |
Endpoint summary
| Method | Path | Purpose |
|---|---|---|
| GET | /api/v1/google/accounts | List your connected Google accounts |
| POST | /api/v1/gmail/send | Send email via Gmail |
| GET | /api/v1/gmail/messages | List recent messages |
| GET | /api/v1/gmail/messages/{id} | Get one message (full body) |