Start from zero and get AI coding tools running in 5 minutes.
Table of Contents
- 1. Why You Need Nbility
- 2. What These Tools Are
- 3. What a Terminal Is
- 4. Where the Tools Run
- 5. What an API Is
- 6. Why Many People Struggle
- 7. What Nbility Is
- 8. What to Do When Errors Happen
- 9. Start with Registration and Balance
- 10. Install and Configure Tools
- 11. First Use
1. Why You Need Nbility
AI coding tools have improved quickly over the last two years.
Tools like Claude Code and Codex are no longer just chat assistants. They can understand project code, write files, diagnose errors, execute commands, and often feel like an engineer helping you inside the terminal.
For users in mainland China, the first setup often runs into practical issues:
- You may need proxy tools, which adds setup friction
- Official subscriptions can be expensive for long-term use
- Accounts may face risk controls or bans
- Direct API usage can become unexpectedly expensive without cost awareness
Nbility lowers these barriers so you can start using the tools first instead of getting blocked by environment setup.
2. What These Tools Are
2.1 OpenAI and Anthropic
Think of these companies as AI model providers.
OpenAI: provides GPT-series models and is related to the Codex ecosystemAnthropic: provides Claude-series models, the core capability behind Claude Code
They train models and provide APIs. Many AI tools you see are essentially calling these models.
2.2 ChatGPT and Claude
ChatGPT and Claude are AI chat products on the web or in apps. They are good
for conversation, writing, summarization, Q&A, and thinking assistance.
If you have used ChatGPT or Claude before, think of them as:
- Entry points for general users
- Web pages you can open and chat with directly
- More chat-oriented interactions
2.3 Codex and Claude Code
Codex and Claude Code are more like AI assistants inside the terminal.
Their biggest differences from ordinary chat products are:
- They can run in a terminal
- They can read and edit local project files
- They can help execute development tasks, locate errors, and understand code structure
If ChatGPT and Claude are "chat advisors", Codex and Claude Code are closer to assistants that can enter your workspace and help do the work.
3. What a Terminal Is
For many beginners, the biggest psychological barrier to Claude Code or Codex is not AI. It is the terminal.
A terminal is a window where you type commands. Many development tools are started through it.
Common ways to open it:
Windows: pressWin + R, entercmd; or open the Start menu and search forTerminalMac: pressCommand + Space, typeTerminal, and press Enter
It is normal if the command-line window looks unfamiliar at first. Most common operations are simply copying one command and pressing Enter.
4. Where the Tools Run
Many people think Claude Code or Codex is a complete AI installed on their own computer.
More accurately, they:
- Start on your local computer
- Connect to cloud AI models through the network
This is a "local operation + cloud inference" setup.
So you need:
- Your own computer
- A working network connection
- A usable API Key
5. What an API Is
An API is a channel that lets software call AI.
When you chat with ChatGPT in a browser, you are using AI directly as a person. Tools like Claude Code and Codex call AI through an API as software.
So when you use Claude Code or Codex, they are not thinking by themselves. They send requests through the interface you configured, the cloud model processes them, and the result comes back.
This is why you often hear these terms:
API KeyBase URLmodel name
They are the basic information tools need to connect to AI services.
6. Why Many People Struggle
The tools are powerful, but many people get stuck on access cost and environment issues rather than capability.
6.1 Official Subscriptions Cost Money
Many official products charge monthly subscriptions, which can become expensive over time.
For users who only want to try things, code occasionally, or are still learning, a stable monthly fee in USD can be a high barrier.
6.2 Risk Controls in Mainland China
Some users run into:
- Unstable network environments
- Data-center IPs being recognized
- Risk controls during login or payment
- Later account restrictions or bans
These issues are unrelated to coding skill, but they directly affect whether you can use the tools smoothly.
6.3 API Cost Can Get Out of Control
API pricing is pay-as-you-go and looks flexible, but without a mental model it can exceed your budget quickly.
For example, if you repeatedly ask a tool to read a large project, modify code,
and answer complex follow-up questions for a long session, cost can grow faster
than expected. Some users may reach nearly ¥700 of usage the first time they
seriously try it, then notice afterward.
That is why cost control is an important part of beginner onboarding.
7. What Nbility Is
Nbility is a unified AI API gateway.
Its core role is not to train new models. It helps you access and use existing model services more smoothly.
For beginners, the most direct value is:
- One API Key can access
40+AI models - No need to manage separate accounts for every model family
- Groups make model and cost management easier to understand
- It is more suitable for practical setup for users in mainland China
If your goal is to get Claude Code, Codex, Cursor, and similar tools running quickly, Nbility is less about advanced concepts and more about reducing setup friction.
8. What to Do When Errors Happen
Errors are normal, especially the first time you install command-line tools.
Do not interpret an error as "I am not suited for this". A more practical approach is to understand the symptom and troubleshoot one thing at a time.
8.1 Use an AI Assistant to Troubleshoot
You can send a screenshot of the error to Doubao, ChatGPT, or another AI assistant and ask it to identify the likely cause.
If you are a complete beginner, clearly tell it:
- You are new to the command line
- Which step you reached
- You want it to guide you step by step
8.2 How to Take a Screenshot
Mac: pressCmd + Shift + 4Windows: pressWin + Shift + S
Try to include the full error, the command you entered, and the terminal window title. This makes diagnosis easier.
8.3 How to Ask for Help
This template is useful for beginners:
I am new to the command line. My goal is [your goal]. Please guide me step by step and give only one step at a time.
You can also include:
- Which step you are on
- What command you just ran
- What the error says
- Whether you use Mac or Windows
8.4 Common Symptom Checklist
| Symptom | Check first |
|---|---|
| timeout / ECONNREFUSED | Proxy environment |
| command not found | PATH environment variable |
| Permission denied | Permission issue |
| Version incompatible | Node.js version |
8.5 Proxy Environment Issues
This is one of the easiest categories to miss.
Many proxy tools affect not only the browser but also network requests from the terminal. Sometimes a web page opens normally, but command-line tools time out, refuse connections, or use the wrong proxy when calling APIs.
When this happens, the simplest flow is:
- Completely quit the proxy app
- Close the current terminal window
- Open a new terminal
- Run the installation or configuration command again
If the problem disappears, the proxy environment was probably interfering.
9. Start with Registration and Balance
Step 1: Register an Account
Open the registration page and create an account first.
Step 2: Add Balance
After signing in, open the console and use the top-up entry. Beginners should start with a small amount, verify that the tool works, and then add more if needed.
Pricing Explanation
A practical way to understand Nbility pricing is:
official USD price x group multiplier / 7 = CNY price
| Multiplier | Approx. official USD value per 1 CNY | Example group |
|---|---|---|
| 0.2x | $5.00 | codex (GPT series) |
| 0.8x | $1.25 | claude (Claude series) |
| 1.5x | $0.67 | gemini (Gemini series) |
Step 3: Create an API Key
Open the token page in the console and click create token.
Choose the group by tool:
Claude Code:claude/claude-mixCodex:codex
Copy your API Key after creation. You will need it when configuring tools.
10. Install and Configure Tools
Before Installation
If a proxy app is running on your computer, quit it completely and reopen the terminal. This reduces many confusing timeout issues during installation.
Step 4: Install Node.js
Node.js is a common prerequisite for Claude Code and Codex.
Mac:
- Download and install the
LTSversion from the Node.js website
Windows:
winget install OpenJS.NodeJS.LTS
Verify installation:
node -v
npm -v
Step 5: Install Codex CLI
Mac:
sudo npm install -g @openai/codex@latest
Windows:
npm install -g @openai/codex@latest
Verify installation:
codex --version
Step 6: Install Claude Code
Mac:
sudo npm install -g @anthropic-ai/claude-code@latest
Windows:
npm install -g @anthropic-ai/claude-code@latest
Verify installation:
claude --version
Step 7: Configure the API
You can configure it in two ways.
Method 1: click the CC-Switch button on the token page to import the
configuration with one click.
Method 2: manually configure environment variables.
Claude Code:
export ANTHROPIC_BASE_URL=https://api.nbility.dev
export ANTHROPIC_AUTH_TOKEN=sk-your-key
Codex:
export OPENAI_API_KEY=sk-your-key
export OPENAI_BASE_URL=https://api.nbility.dev/v1
For Windows users, the syntax for environment variables is different, but the core information is the same: one key plus the correct Base URL.
11. First Use
11.1 Before You Start
Before using the tools seriously, confirm:
- The token has balance
- Environment variables are configured
- The terminal is open
11.2 Which Tool to Try First
If you are not sure which tool to start with:
Claude Code: better for chatting, thinking, and discussing plansCodex: better for executing tasks, debugging, and directly editing projects
You do not need to learn everything at once. Get one tool running first, then expand gradually.
11.3 Start Claude Code
In the terminal, enter:
claude
11.4 Start Codex
In the terminal, enter:
codex
If the command starts normally, you have completed the most important first step.