By default the router tries our listings in routing order and fails over before the first byte — never mid-answer. The price is the provider's own list price; you pay $0.80 in / $1.20 out per 1M. Uptime is our own 24h measurement; a dash means too few requests to measure yet. Open the row for the provider's specs and policies.
curl https://api.routerplus.com/v1/chat/completions \
-H "Authorization: Bearer $TM_API_KEY" -H "content-type: application/json" \
-d '{"model":"morph/morph-v3-fast",
"messages":[{"role":"user","content":"<instruction>Add an optional third number</instruction>\n<code>def total(a, b):\n return a + b</code>\n<update>def total(a, b, c=0):\n # ... existing code ...\n return a + b + c</update>"}]}'
# choices[0].message.content is the whole merged file# OpenAI SDK — only the base URL changes. Fast Apply: instruction, original code, edit. import os from openai import OpenAI client = OpenAI(base_url="https://api.routerplus.com/v1", api_key=os.environ["TM_API_KEY"]) r = client.chat.completions.create(model="morph/morph-v3-fast", messages=[{"role": "user", "content": "<instruction>Add an optional third number</instruction>\n<code>def total(a, b):\n return a + b</code>\n<update>def total(a, b, c=0):\n # ... existing code ...\n return a + b + c</update>"}]) merged = r.choices[0].message.content # the whole merged file
import OpenAI from "openai"; const client = new OpenAI({ baseURL: "https://api.routerplus.com/v1", apiKey: process.env.TM_API_KEY }); const r = await client.chat.completions.create({ model: "morph/morph-v3-fast", messages: [{ role: "user", content: "<instruction>Add an optional third number</instruction>\n<code>def total(a, b):\n return a + b</code>\n<update>def total(a, b, c=0):\n # ... existing code ...\n return a + b + c</update>" }] }); const merged = r.choices[0].message.content; // the whole merged file
| prompt | $0.8 |
| completion | $1.2 |
Every billed response carries usage.cost — recompute your bill from the wire.