Set up Pi
The example uses GPT-6.1 Sol (gpt-6.1-sol). Get an I Code Easy API key from API keys. Choose the Standard endpoint for GPT in Endpoint selection.
Installation
Use Node.js 22.19 or later.
npm install -g --ignore-scripts @earendil-works/pi-coding-agent
Pi
This configuration sends requests to /v1/responses over HTTP.
Merge the icodeeasy entry below into providers in ~/.pi/agent/models.json. Keep the $ in apiKey so Pi reads the environment variable.
{
"$schema": "https://pi.dev/schemas/models.schema.json",
"providers": {
"icodeeasy": {
"baseUrl": "https://api.icodeeasy.cc/v1",
"api": "openai-responses",
"apiKey": "$ICODEEASY_API_KEY",
"models": [
{
"id": "gpt-6.1-sol",
"name": "GPT-6.1 Sol"
}
]
}
}
}
Set the key in the terminal that launches the client. Replace YOUR_API_KEY with your key.
export ICODEEASY_API_KEY='YOUR_API_KEY'
$env:ICODEEASY_API_KEY = 'YOUR_API_KEY'
Start a session
Run pi, open /model, and select icodeeasy/gpt-6.1-sol.
Oh My Pi has its own configuration file. See Set up Oh My Pi.
Verify your first request
Send a short text prompt and check the model and request status in Usage logs. For a 401 error, check the key. For a model or permission error, check the model ID and selected endpoint. If the connection is unstable, try https://jp.icodeeasy.cc or https://sg.icodeeasy.cc and keep the /v1 path.
Official client documentation
Related guides
Set up Oh My Pi
In Oh My Pi, configure models.yml and launch omp with I Code Easy, then verify the first request.
OpenAI Responses
Send input using the OpenAI Responses format. This page shows HTTP streaming. See the related guide for Codex client setup.
How do I troubleshoot slow connections or failed requests?
Match 401, 403, 429, timeouts, and Gemini path errors before changing hosts. Switch to the jp or sg backup domain only after the network is the problem.