The options can be combined. Pick a starting point from your main use case.
You have an overseas payment method and stable international network access
Official subscription
The model source is verifiable. Paid Claude plans include Claude Code, and ChatGPT Plus and higher plans include Codex.
You want to keep using Codex or Claude Code locally on a limited budget
API relay
You only change the endpoint and key. You have to verify the model source and data handling yourself.
You can accept a different model
Domestic models and coding tools
They are directly accessible and payable in China. Codex and Claude Code are tuned for their own vendors' models, so results may drop after switching.
You do research computing that needs GPUs, scientific software and a long-running environment
Scientify
It runs a Codex-based agent with high-quality models in the cloud, without third-party relays.
Account region
Mainland China is not a supported region for Anthropic or OpenAI. Sign-up and use require an account from a supported region.
Payment
Official subscriptions require an overseas bank card or another supported payment method. Domestic bank cards usually cannot pay directly.
Network access
Official services require stable international network access. Frequent changes in sign-in location or network exit can trigger account security checks.
Every option uses the same criteria. Costs follow official public prices; relay and domestic tool prices vary by provider.
Official subscription
- What you need
- An overseas payment method and stable international network access
- Cost
- Claude Pro $20/month, Max from $100/month; ChatGPT Plus and higher plans include Codex
- Model source
- Official models
- Requests pass through
- Official services
- Where it runs
- Your machine or the official cloud environment
- Main risks
- Account security checks and payment barriers
- Best for
- Mainly writing code, with overseas access
API relay
- What you need
- A relay account and key, plus a changed endpoint in the client
- Cost
- Pay-as-you-go or monthly, usually below official prices
- Model source
- Cannot be verified from the client
- Requests pass through
- The relay's servers, then the upstream provider
- Where it runs
- Your machine
- Main risks
- Model substitution, truncated context, service shutdown, data passing through a third party
- Best for
- Budget first, willing to verify
Domestic models and tools
- What you need
- An account and key from the vendor
- Cost
- Usually below official prices
- Model source
- Domestic models
- Requests pass through
- The vendor's services
- Where it runs
- Your machine
- Main risks
- Tool and model mismatch, lower quality
- Best for
- Accepting a different model
Scientify
- What you need
- A Scientify account
- Cost
- Pay-as-you-go; the same model usage costs about 30% of standard API pricing; new users get $5 worth of free credits
- Model source
- High-quality models such as GPT-5.6-sol, without third-party relays
- Requests pass through
- A Scientify isolated cloud computer; research data is not stored on Scientify servers
- Where it runs
- An isolated cloud computer; tasks continue after you close your laptop
- Main risks
- Built for research tasks; no API key for local clients
- Best for
- Research computing and long-running projects
Official subscription
Use an official OpenAI or Anthropic account and plan. Codex and Claude Code both run locally and both offer an official cloud environment.
How to connect
- Register an account in a supported region and add a supported payment method.
- Claude Code is included in Claude Pro and Max. Codex is included in ChatGPT Plus and higher plans.
- Install the client in your terminal and sign in with the official account.
Watch out for
- The account region and payment method must stay consistent over time.
- Frequent changes in sign-in environment can trigger security checks.
API relay
A relay offers an endpoint and key that follow the official protocol. The client sends requests to the relay, which forwards them to an upstream model.
How to connect
- Codex: add a model_provider in config.toml, set the relay's base_url, and provide the key through an environment variable.
- Claude Code: set ANTHROPIC_BASE_URL and the matching authentication key.
- Complete the checklist on this page after connecting.
Watch out for
- The model name shown in the client does not prove which model is actually called.
- Code, prompts and file contents pass through the relay's servers.
- If the upstream channel is cut off, the service may stop and prepaid balances may not be refunded.
Domestic models and tools
Connect Claude Code or Codex to a model from a domestic vendor, or use a domestic vendor's own coding tool.
How to connect
- Register on the vendor's platform and get a key.
- Follow the vendor's documentation to change the client's endpoint and model name, or install the vendor's coding tool.
Watch out for
- Prompts and tool calls in Codex and Claude Code are tuned for their own vendors' models. Complex tasks may perform worse after switching.
- Vendors differ in their support for tool calls and long context.
Scientify
Scientify is a scientific agent that runs in an isolated cloud computer. It is built on Codex and provides high-quality models such as GPT-5.6-sol. Model calls do not pass through third-party relays.
How to connect
- Register a Scientify account and create a project workspace in the browser.
- The agent searches literature, writes code and runs experiments in the cloud. When a task needs a GPU, the agent rents one after you grant permission, billed per second.
- Models and compute share one balance.
Watch out for
- Scientify is built for research tasks and does not provide API keys for local Codex or Claude Code.
- To use Claude Code in repositories on your own computer, choose one of the first three options.
These checks catch common problems but cannot prove that a relay is reliable. Repeat them whenever you switch relays or notice a change in quality.
Check
Call /v1/models and check the returned model names.
What it tells you
Matching names only show that the configuration is correct. Stop using the relay if names differ or advertised models are missing.
Check
Send input close to the advertised context length and ask the model to repeat its beginning and end.
What it tells you
If it cannot repeat the beginning, the context is being truncated.
Check
Run a task that reads several files, calls tools and edits code.
What it tells you
If tool calls fail or responses are malformed, parts of Codex and Claude Code will stop working.
Check
Compare the relay's price with the official API price.
What it tells you
If the price is far below the official API price, find out where the difference comes from, for example shared accounts or substituted models.
Check
Look up the provider's company, privacy policy and log retention terms.
What it tells you
Without a public company or terms, you cannot confirm whether code and prompts are logged.
Check
Top up a small amount first and increase it after a trial period.
What it tells you
If the service stops, your loss is limited to a small balance.
- You mainly write code in your own repositories
- Use an official subscription. Without overseas access, use domestic models and tools.
- Budget comes first and you are willing to verify
- Use a relay and repeat the checklist regularly.
- Code or data must not pass through an unknown third party
- Use an official subscription or a domestic vendor's official service, not an unknown relay.
- You need GPUs, scientific software and a long-running project environment
- Use Scientify. Day-to-day work in local repositories can still use the first three options.
Do relays downgrade the model?
They can. A relay can forward requests to a cheaper model, and the model name shown in the client does not prove which model is called. The long-context and tool-call checks catch some cases but cannot rule it out.
Can a relay leak my code?
Code, prompts and file contents pass through the relay's servers. Whether they are logged, and for how long, depends on the provider. Without a public company and privacy policy, you cannot confirm where the data goes.
Can both Codex and Claude Code use a custom endpoint?
Yes. Codex uses a model_provider with a base_url in config.toml. Claude Code uses ANTHROPIC_BASE_URL.
Can Scientify replace Claude Code on my machine?
No. Scientify provides a Codex-based agent in the cloud for research tasks and does not provide API keys for local clients. To use Claude Code in repositories on your own computer, use an official subscription, a relay or a domestic model.
Why are Scientify's model prices lower?
The same model usage on Scientify costs about 30% of standard API pricing, and model calls do not pass through third-party relays. See the model pricing page for details.
Scope of this comparison
- This page is based on official public documentation. No specific relay was tested.
- This page does not recommend or rate any specific relay or domestic vendor.
- Official prices and supported regions change. The official pages are authoritative.