Docs Guides
Guide

API Quick Start Guide

1. Sign in to the console

Account signup

Signup benefits

  • New users get $0.2 trial credit
  • Minimum top-up: $1
  • Register: Sign up

Setup

1. Get a token

  1. Sign in to the console
  2. Open the Tokens page
  3. Click Add token to get an API Key
Tip: When creating a token you can also set smart routing so the platform picks the best channel automatically. See Smart routing below.

2. API configuration

Optional BASE_URL values

https://api.digislash.com https://api.digislash.com/v1 https://api.digislash.com/v1/chat/completions
json
Note: Different clients may need different BASE_URL values; try the list above in order.

3. Pick a model

  • Model names are in the first column of Supported models on the home page

Example config

{ "base_url": "https://api.digislash.com", "api_key": "your_token_here", "model": "selected_model_name" }
json

Smart routing

Smart routing lets you control channel selection without changing code, optimizing for lowest price, fastest speed, highest success rate, or global best.

Modes

ModeDescription
System defaultUnset; follow the platform global policy
Smart auto (auto)Across all accessible channels, pick the best by speed / success / price
Price first (price)Lowest unit price among available channels
Speed first (speed)Fastest response among available channels
Success-rate first (success_rate)Highest recent success rate

Three ways to set it

Priority from high to low:

model suffix > request body provider.sort > token routing mode
json

Option 1: Model name suffix (simplest, per request)

Append a colon suffix to the model name. No other config changes required.

{ "model": "gpt-4o:price", "messages": [...] }
json

Supported suffixes:

SuffixEffectOpenRouter-style alias
:priceLowest price:floor
:speedFastest:nitro
:success_rateHighest success rate:stable
Suffixes only affect routing and are not sent upstream. Unknown suffixes (e.g. :beta, :v2) stay in the model name.

Option 2: Request body provider.sort (per request)

Add a provider field. Applies to that request only; does not change the token defaults.

{ "model": "gpt-4o", "messages": [{"role": "user", "content": "Hello"}], "provider": { "sort": "speed" } }
json

provider.sort values: price / speed / success_rate / floor / nitro / stable

Note: provider.sort does not support "auto". "auto" or unknown values are ignored and fall back to the token routing mode.

When creating or editing a token, choose a routing mode. It applies to all requests with that token.

Path: Token management → New/Edit token → Routing priority mode

OptionWhen to use
System default (unset)No special need; follow platform policy
Smart auto (auto)Let the platform find the global best channel
Price first (price)Cost-sensitive jobs
Speed first (speed)Realtime / low latency
Success-rate first (success_rate)Critical jobs
About smart auto (auto): - Expands candidates to all groups your account can access, not only the token's original group - Scores speed, success rate, and price in realtime - Billing multiplier follows the group of the channel actually routed to

Routing preview (simulate before switching)

Before changing modes, preview which channel and rate a mode would pick:

GET https://api.digislash.com/api/user/routing-preview?model=gpt-4o&priority=price&prompt_tokens=500
json
ParamDescription
modelRequired model name
priorityOptional: auto / price / speed / success_rate
prompt_tokensOptional input tokens for cost estimate

Example response:

{ "priority_applied": "price", "estimated_group": "standard", "estimated_price_per_1k": 0.002, "price_multiplier": 0.4, "warning": false, "channel_available": true, "prompt_tokens": 500, "estimated_cost": 1.0 }
json
FieldDescription
estimated_groupPredicted channel group
estimated_price_per_1kEstimated USD per 1K tokens
price_multiplierPrice ratio vs system default auto (< 1 means cheaper)
warningtrue if this mode is >1.5× auto; review carefully
estimated_costEstimated cost for the given prompt tokens

FAQ

Q: If both model suffix and provider.sort are set, which wins?

The model suffix wins. With :price, provider.sort is ignored.

Q: Can I override a token's routing mode per call?

Yes. Use provider.sort or a model suffix. Overrides apply only to that request.

Q: How does auto differ from leaving routing unset?

Both use a scored algorithm, but auto expands candidates to all accessible groups; unset stays within the token's configured groups.

Q: If auto routes to another group, does billing change?

Yes. Billing follows the routed channel's group. Use routing preview to confirm group and rate first.


Verify

  1. Test in the chat page
  2. Call the API with Postman, curl, etc.
  3. Use routing preview to confirm smart routing
Tip: Validate in chat first, then integrate in code