SwiftRelay

← All sprint notes

Codex via SwiftRelay: A Relay Service Setup in Minutes

Cost per lapEN

Three lines replace a separate account setup

Getting Codex ready usually means managing another official account, its own access details, and a separate billing relationship before your first prompt. With SwiftRelay, that setup shrinks to three lines. Copy them into your terminal, run Codex, and you are on the track. SwiftRelay is a pay-per-token API relay, so there is no monthly fee and nothing to subscribe to. You top up a balance, and each call deducts only the amount it actually used.

Here is the complete Codex configuration:

01  export OPENAI_BASE_URL=https://api.fastapirelay.com/v1
02  export OPENAI_API_KEY=<your swft_ key>

codex

The base URL points Codex at the SwiftRelay API host, and the API key is the swft_ key connected to your SwiftRelay account. There is no account pool to sort through and no separate client-specific configuration to maintain. Once the lines are in place, you can start working with the models available through the OpenAI-compatible endpoint, including GPT-6 Astra, GPT-6.1 Sol, DeepSeek V4 Flash, and DeepSeek V4 Pro.

That is the first thing you stop managing: a second billing arrangement for the same kind of work. Instead of thinking about another account balance, you watch one SwiftRelay balance and the cost of each Codex call. The setup is deliberately direct, which makes SwiftRelay a practical relay service for people who would rather spend their attention on the task in front of them than on administration.

A worked day, priced line by line

The following is an example, not a quotation for a particular workload. Suppose you make 10 Codex calls in a day, and every call uses 10,000 input tokens, 2,000 output tokens, and 5,000 cache-read tokens. The sums below use the current prices per 1M tokens shown on the SwiftRelay pricing page.

For DeepSeek V4 Flash, the input cost for one call is $0.02639, calculated from 10,000 input tokens at the input price of $0.2639 per 1M tokens. The output cost is $0.0212, calculated from 2,000 output tokens at the output price of $1.06 per 1M tokens. The cache-read cost is $0.03472, calculated from 5,000 cache-read tokens at the cache-read price of $0.006944 per 1M tokens.

  • DeepSeek V4 Flash, one call: $0.02639 input + $0.0212 output + $0.03472 cache read = $0.08231
  • DeepSeek V4 Flash, 10 calls: $0.08231 × 10 = $0.8231

For DeepSeek V4 Pro, the input cost for one call is $0.117, from 10,000 input tokens at $1.17 per 1M tokens. The output cost is $0.0702, from 2,000 output tokens at $3.51 per 1M tokens. The cache-read cost is $0.1945, from 5,000 cache-read tokens at $0.0389 per 1M tokens.

  • DeepSeek V4 Pro, one call: $0.117 input + $0.0702 output + $0.1945 cache read = $0.3817
  • DeepSeek V4 Pro, 10 calls: $0.3817 × 10 = $3.817

For GPT-6 Astra, the input cost for one call is $0.06597, from 10,000 input tokens at $0.6597 per 1M tokens. The output cost is $0.0656, from 2,000 output tokens at $3.28 per 1M tokens. The cache-read cost is $0.3265, from 5,000 cache-read tokens at $0.0653 per 1M tokens.

  • GPT-6 Astra, one call: $0.06597 input + $0.0656 output + $0.3265 cache read = $0.45807
  • GPT-6 Astra, 10 calls: $0.45807 × 10 = $4.5807

For GPT-6.1 Sol, the input cost for one call is $0.01736, from 10,000 input tokens at $0.1736 per 1M tokens. The output cost is $0.017084, from 2,000 output tokens at $0.8542 per 1M tokens. The cache-read cost is $0.1735, from 5,000 cache-read tokens at $0.0347 per 1M tokens.

  • GPT-6.1 Sol, one call: $0.01736 input + $0.017084 output + $0.1735 cache read = $0.207944
  • GPT-6.1 Sol, 10 calls: $0.207944 × 10 = $2.07944

Now add the four 10-call totals for this example: $0.8231 + $3.817 + $4.5807 + $2.07944 = $11.30024. That is the exact combined amount used by those 40 calls under the stated token pattern.

Where the balance goes after every call

The second thing you stop managing is uncertainty about where the money went. SwiftRelay usage lists the tokens and the cost per call, so you can inspect the work instead of guessing. With the example total of $11.30024, a $13.89 top-up would leave $13.89 − $11.30024 = $2.58976 in the balance. Nothing is rounded away, and nothing is deducted for time you did not spend using the service.

That makes the economics easy to follow. You choose a top-up amount, you run your Codex sessions, and each call deducts only what it used. If a day is light, the balance stays available for the next day. If you want to change models, the same balance and the same three-line configuration stay in place. There is no need to reorganise your setup every time you move between GPT-6 Astra, GPT-6.1 Sol, DeepSeek V4 Flash, and DeepSeek V4 Pro.

You also stop managing a crowded list of credentials. SwiftRelay supports up to 20 live API keys per account, which gives you room to separate work without creating a separate billing relationship for every project. When you need help, support is available through Messages in the dashboard after you log in. The conversation stays beside the account where the balance and usage records are visible, rather than in another inbox.

Top-ups, refunds and rewards without a subscription

The third thing you stop managing is the pressure of a recurring commitment you did not choose. SwiftRelay has no monthly fee and nothing to subscribe to. You top up a balance, and the balance is spent call by call. The available top-up amounts are $1.39, $6.94, $13.89, $27.78, $69.44, and $138.89, so you can choose the size that suits the run you are planning.

New accounts also receive a sign-up gift credit of $0.22. That is a small starting cushion, but more importantly, it means your first configuration does not have to begin at zero.

There is a clear refund rule as well. Unused credit can be refunded within 11 days of a top-up, minus what was used and the payment fee. That removes the guesswork from the early part of a top-up: if the balance is still unused within the stated window, you know how the refund is calculated.

SwiftRelay also includes referral rewards. You receive 14% of each top-up made by someone you invited, and 3% from the people they invite. Rewards can be withdrawn once they reach the $4.86 minimum, or they can be moved into your balance for future calls. If you would rather keep spending in one place, moving the reward into the balance keeps the accounting simple.

From a clean first run to your next lap

Picture the finish of your setup like a clean first lap. The stopwatch starts when you copy the three lines, not when you finish reconciling another account. You paste the base URL, add your swft_ key, run codex, and make a call. The dashboard then shows the tokens used and the cost of that call, while the balance absorbs only that amount.

From there, the routine is refreshingly short. Check the balance, top up if needed, choose the model that fits the job, and keep working. The worked example above shows how the numbers arrive line by line, so a larger day can be estimated from the same visible inputs: input tokens, output tokens, and cache-read tokens. You are never asked to accept a fixed monthly charge in exchange for access you might not use.

SwiftRelay keeps the relay service focused on the part that matters for Codex: a quick setup, a single balance, transparent per-call costs, and access to GPT and DeepSeek models through the OpenAI-compatible endpoint. The account details, the balance, the usage list, and support through Messages all live in the dashboard you already log into.

Sign up for SwiftRelay, top up your balance, copy those three lines, and put your next Codex run on the track.

Keep reading

Back for another lap?Log in