API v1 · Updated Oct 2, 2026

Developer Documentation

Everything you need to build with Arshan: authentication, models, agents, webhooks and SDKs for Python and Node.js.

Introduction

The Arshan API gives you programmatic access to everything in the platform: deploy and call models, run agents, manage datasets and receive events in real time. It is organised around REST, uses predictable resource URLs and returns JSON.

Base URL https://api.arshan.ai/v1

Quickstart

Install an official SDK, set your API key as an environment variable and make your first request.

Terminal
# Python
pip install arshan

# Node.js
npm install @arshan/sdk
Python
from arshan import Arshan

client = Arshan()  # reads ARSHAN_API_KEY from the environment

result = client.predictions.create(
    model="sentiment-v3",
    input="The new dashboard saves our team hours every week.",
)

print(result.label, result.confidence)  # positive 0.97
TipUse a workspace in test mode while you build. Test requests are free and never count towards your limits.

Authentication

Authenticate every request with a secret API key in the Authorization header. Create and rotate keys in Settings → API Keys. Keys are scoped to a single workspace and can be limited to read-only access.

cURL
curl https://api.arshan.ai/v1/models \
  -H "Authorization: Bearer $ARSHAN_API_KEY"
Keep keys secretNever expose secret keys in browser code or public repositories. Use short-lived tokens for client-side apps.

Models

List the models available to your workspace, including your fine-tuned versions.

GET/v1/models
ParameterTypeDescription
typestringFilter by language, vision or forecast.
limitintegerNumber of results, 1 to 100. Defaults to 20.

Predictions

Send input to a deployed model and receive a prediction. Requests are synchronous for most models; long-running jobs return a job_id you can poll or receive by webhook.

POST/v1/predictions

Agents

Agents combine a model, tools and policies to complete multi-step tasks. Start a run, then stream steps or wait for the result.

Node.js
const run = await arshan.agents.run({
  agent: "support-triage",
  input: { ticketId: "TCK-48213" },
  maxSteps: 8,
});

console.log(run.status, run.output.summary);

Webhooks

Subscribe to events such as agent.run.completed or model.deployed. Each payload is signed with your endpoint secret in the Arshan-Signature header.

JSON
{
  "id": "evt_9f2c1a",
  "type": "agent.run.completed",
  "created": 1767225600,
  "data": { "run_id": "run_51b0", "status": "succeeded" }
}

SDKs

  • Python: pip install arshan (3.9+)
  • Node.js: npm install @arshan/sdk (18+)
  • Go: go get github.com/arshan-ai/arshan-go

Examples

Browse complete sample apps: an inbox triage agent, a RAG assistant over Google Drive, a demand forecasting notebook and a Slack bot. Each example includes a one-click deploy button.

Rate Limits

Limits depend on your plan. Responses include X-RateLimit-Remaining headers, and requests over the limit return 429. See pricing for plan limits or the changelog for recent API changes.

PlanRequests / minuteConcurrent agent runs
Starter602
Professional1,20050
EnterpriseCustomCustom