§ Getting Started

How to use MeshInfer.AI

From zero to your first AI inference call in under 5 minutes. Follow the steps below to set up routing, send requests, and monitor usage.

Quick-start checklist0/5 done
  1. Sign up & choose a plan
  2. Generate an API key
  3. Install the SDK
  4. Make your first inference call
  5. Review usage & costs
Step 1

Sign up & choose a plan

Visit the Pricing page to choose the plan that fits your usage. The Developer plan is the best starting point for individuals and small teams — it includes 100k requests/month at $499/mo.

Developer$499/mo · 100k requests · local + cloud routing
Startup$1,050/mo · 2M requests · mesh routing enabled
Growth$2,499/mo · 20M requests · priority routing + SLA
Enterprise$10,000+/mo · unlimited · dedicated cluster + HIPAA BAA

Click Get started on any plan to go through the checkout. After payment you'll be redirected to your dashboard.

Step 2

Generate an API key

Navigate to API Key Manager. Click Create new key, give it a descriptive name (e.g. prod-app-v1), and optionally set:

Rotation schedulee.g. every 90 days — recommended for production
IP restrictionLock the key to specific CIDR ranges
Rate limitOverride the plan default per-key
Expiry dateSet a hard expiry for short-lived keys
Save your key immediately
The full key is only shown once at creation. Store it in a secrets manager (e.g. AWS Secrets Manager, Doppler, Vault). The dashboard only shows the prefix after creation.
Step 3

Install the SDK

Choose your runtime:

bash — JavaScript / TypeScript
npm install @meshinfer/sdk
# or
yarn add @meshinfer/sdk
bash — Python
pip install meshinfer
bash — OpenAI drop-in (no SDK install needed)
# Just change the base URL in your existing OpenAI client:
client = OpenAI(
    base_url="https://api.meshinfer.ai/v1",
    api_key="msk_live_…"
)

For React apps, import the provider at your app root. Full examples are in the API & SDK reference →

Step 4

Make your first inference call

The SDK automatically discovers the best route (local → mesh → cloud) for every request. No routing logic needed on your side.

javascript
import { MeshInfer } from '@meshinfer/sdk';

const client = new MeshInfer({ apiKey: process.env.MESHINFER_API_KEY });

const response = await client.chat.completions.create({
  model: 'auto',           // let the router pick the best model/route
  messages: [
    { role: 'user', content: 'Explain quantum key distribution in one paragraph.' }
  ],
  stream: true,            // streaming is fully supported
});

for await (const chunk of response) {
  process.stdout.write(chunk.choices[0]?.delta?.content ?? '');
}
python
from meshinfer import MeshInfer

client = MeshInfer(api_key="msk_live_…")

response = client.chat.completions.create(
    model="auto",
    messages=[{"role": "user", "content": "Hello from MeshInfer!"}]
)
print(response.choices[0].message.content)
Try it live
Use the Route Playground → to simulate routing decisions in your browser — no API key required.
Step 5

Configure routing preferences

By default, the router uses a balanced mode — optimising for cost and latency. You can override per-request or globally via a Routing Policy.

javascript
// Per-request override
await client.chat.completions.create({
  model: 'auto',
  messages: […],
  // MeshInfer extensions
  meshinfer: {
    privacy_policy: 'local_only',   // never leave the device
    cost_preference: 'cheap',       // aggressively favour local/mesh
    latency_budget_ms: 2000,        // cloud fallback if local > 2s
  }
});

For persistent rules, create a Routing Policy in the dashboard — pin regions, enable weighted A/B traffic splits, or set hard no-cloud rules.

Step 6

Review usage & monitor costs

Optional

Earn by contributing your device to the mesh

If your device has WebGPU or native ML runtime support, you can run the Hardware Capability Benchmark to see your eligible tier and estimated monthly earnings. Devices that qualify can opt in to serve inference tasks for other platform users during idle time.

Observer$2–5/mo · any modern browser with WebGPU
Seedling$5–15/mo · mid-range GPU, 8GB VRAM
Reliable$15–40/mo · RTX 3080+ or M2 Pro
Trusted$40–80/mo · RTX 4090 or M3 Max
Elite$80–150+/mo · multi-GPU or dedicated server

Explore further

Need help?
Email support@meshinfer.ai — we respond within one business day. For urgent production issues, Enterprise customers have a dedicated Slack channel.