SandBase X Gateway
https://api.sandbase.ai/v1/api/sandbase/twitterProxy requests to X API v2 endpoints via OAuth. Specify the target path using the endpoint parameter alongside optional query parameters, headers, and request bodies.
- Price
- Free
- Method
- POST
- Response
- JSON
- Parameters
- 1 required · 5 optional
Try the model
Playground
Your output will appear here
Complete the inputs, then click Run.
Model card
Specifications
Pricing
- Base price
- Free
Request & response
- Method
- POST
- Request body
- application/json
- Response
- application/json
- Execution
- sync
Parameters
- endpoint
- string · required
- method
- string (GET, POST, PUT, PATCH, DELETE) · optional
- params
- object · optional
- headers
- object · optional
- body
- object · optional
- retries
- integer · optional
Access
- Provider
- SandBase
- API
- Platform API
- Base URL
- https://api.sandbase.ai
- Endpoint
- /v1/api/sandbase/twitter
- Authentication
- Bearer API key
API README
SandBase X Gateway API
Access the X API v2 through a managed gateway by specifying the target path in endpoint. Pass additional query criteria in params or payloads in body depending on the HTTP method.
Use cases
- Query user profiles and account metadata from X.
- Retrieve tweet timelines and engagement metrics.
- Forward authorized requests to X API v2 endpoints.
Request
curl -X POST "https://api.sandbase.ai/v1/api/sandbase/twitter" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"endpoint": "<endpoint>"}'
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
endpoint | string | Yes | X API v2 path, e.g. /2/users/me |
body | object | No | Request body (POST/PUT/PATCH). |
method | string | No | — |
params | object | No | URL query parameters as key-value pairs. |
headers | object | No | Additional request headers. |
retries | integer | No | Retry count on 5xx/timeout. |
Notes
- Supply the relative X API v2 path in
endpoint, such as/2/users/me. - Set the HTTP verb in
methodto match the target endpoint requirement. - Use
retriesto set automatic retry attempts for 5xx errors or timeouts.
Start building
Send your first request
Platform API endpoint with unified authentication and usage tracking.
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1/api/sandbase/twitter" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{}
SANDBASE_JSON
)
printf '%s\n' "$result"Explore more
Related APIs
| API | Price | Response | Released |
|---|---|---|---|
SandBase X GatewayThis API SandBase | Free | JSON | Jun 21, 2026 |
SandBase | Free | JSON | Jun 20, 2026 |
SandBase | Free | JSON | Jun 21, 2026 |
SandBase | Free | JSON | Jun 21, 2026 |
SandBase | Free | JSON | Jun 20, 2026 |
SandBase | Free | JSON | Jun 21, 2026 |
Questions
FAQ
How do I use the SandBase X Gateway API?
Send a POST request to https://api.sandbase.ai/v1/api/sandbase/twitter with your SandBase API key in the Authorization header (Bearer) and the parameters as a JSON body. You can also try it in the Playground on this page without writing code.
How much does the SandBase X Gateway API cost?
SandBase X Gateway is free to call on SandBase. You only need a SandBase account and API key.
What parameters does the SandBase X Gateway API accept?
Required: endpoint (string). Optional: method (one of GET, POST, PUT, PATCH, DELETE), params (object), headers (object), body (object) and retries (integer). The Parameters table and the Playground on this page list every field.
What does the SandBase X Gateway API return?
A JSON response returned in the same HTTP request (synchronous).
Do I need a SandBase developer account or API key?
No. SandBase X Gateway runs through SandBase, so one SandBase API key covers this endpoint and every other API and model in the catalog. You do not need to apply for SandBase API access separately.
