#Adding more models from oauth

1 messages · Page 1 of 1 (latest)

elfin solarBOT
#

Yep — you can do this pretty easily.

Quick path:

  1. Check your version first:
pnpm openclaw --version
  1. See what your current auth can use:
pnpm openclaw models status
pnpm openclaw models list --provider openai-codex
  1. In this Discord thread, test models live with:
#
/model

(or /model list, then pick one)

  1. Set a new default / fallback when you like one:
pnpm openclaw models set <provider/model>
pnpm openclaw models fallbacks add <provider/model>

If you want models from other providers too, you’ll need auth for each provider (OAuth or API key), not just OpenAI Codex OAuth.

If you paste your pnpm openclaw models status output, I can tell you exactly what to tweak next.

Docs:

past shard
# elfin solar ```text /model ``` (or `/model list`, then pick one) 4. Set a new default / fal...

1 - OpenClaw 2026.3.13 (61d171a)
2-

  • openai effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=0, token=1, api_key=0) | openai:manual=token:sk-proj-...2Dh0cp8A | env=sk-proj-...2Dh0cp8A | source=env: OPENAI_API_KEY
  • openai-codex effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=1, token=0, api_key=0) | openai-codex:default=OAuth

OAuth/token status

  • openai
    • openai:manual static
  • openai-codex usage: 5h 100% left ⏱4h 59m · Week 0% left ⏱2h 5m
    • openai-codex:default ok expires in 3d

Model Input Ctx Local Auth Tags
openai-codex/gpt-5.3-codex text+image 266k no yes default,configured,alias:gpt53
openai-codex/gpt-5.4 text+image 266k no yes configured,alias:gpt54
openai-codex/gpt-5.2 text+image 266k no yes configured,alias:gpt52

3 - discord only shows 5.3 codex, gpt 5.2 and gpt 5.4

4- my fallbacks are currently kimi k2.5 and Deepseek-reasoner. I'd like to have my fallback be gpt 5.2 first and second kimi k2.5

i need to configure the other open ai models that are available so they show up when i do "/models" under open ai. Im really just looking to add models from open ai that i have available but just arent configured.

these are the ones im most interested in trying out:
openai/gpt-4.1-mini s
openai/gpt-5-mini
openai/gpt-4.1-nano
openai/o3-mini

#

@elfin solar

elfin solarBOT
#

Got you 👍 — key detail:

With OpenAI Codex OAuth, you can test models under the openai-codex/* provider that your account exposes.
It does not automatically unlock every provider/model family.

If you want to test beyond that, do:

pnpm openclaw models status
pnpm openclaw models list --all

Then in chat:

/ model

(picker in Discord is easiest for quick switching)

#

If you see Model "... is not allowed", your allowlist is blocking it (agents.defaults.models).

If you paste pnpm openclaw models status, I’ll point out exactly what’s available right now and what auth you’d need next.

past shard
elfin solarBOT
#

You’re right — thanks for the direct callout.

What you’re seeing is expected: Codex OAuth only exposes the Codex provider catalog, which is why you only see those 3.

If you want “the other OpenAI models”, you need to add OpenAI API-key auth (provider openai), not just openai-codex OAuth.

Do this:

pnpm openclaw onboard --auth-choice openai-api-key
# (or: pnpm openclaw configure --section model)

Then verify:

pnpm openclaw models list --provider openai
pnpm openclaw models status
past shard
elfin solarBOT
#

100% fair — and you’re correct.

You’re using ChatGPT Premium OAuth.
In OpenClaw, that OAuth path is currently represented as provider openai-codex (naming is confusing, but it’s the same OAuth flow you mean).

So the practical rule is:

  • Your OAuth account can only use the models that provider exposes for your entitlement.
  • If only 3 show up, there isn’t an extra config flag to unlock more from that same OAuth token.

To use additional OpenAI families, you need a second auth source (OpenAI API key provider openai) alongside OAuth.

If you want, run and paste this and I’ll give you an exact next config:

pnpm openclaw models status
pnpm openclaw models list --provider openai-codex
past shard
# elfin solar 100% fair — and you’re correct. You’re using **ChatGPT Premium OAuth**. In Open...

I had to cut out a few secitons to make this fit:
Default : openai-codex/gpt-5.3-codex
Fallbacks (2) : moonshot/kimi-k2.5, minimax/MiniMax-M2.5
Image model : -
Image fallbacks (0): -
Aliases (8) : kimi -> moonshot/kimi-k2.5, Deepseek -> deepseek/deepseek-reasoner, Minimax -> minimax/MiniMax-M2.5, ds-chat -> deepseek/deepseek-chat, gpt54 -> openai-codex/gpt-5.4, gpt53 -> openai-codex/gpt-5.3-codex, gpt52 -> openai-codex/gpt-5.2, lite -> google/gemini-flash-lite-latest
Configured models (8): moonshot/kimi-k2.5, deepseek/deepseek-reasoner, minimax/MiniMax-M2.5, deepseek/deepseek-chat, openai-codex/gpt-5.4, openai-codex/gpt-5.3-codex, openai-codex/gpt-5.2, google/gemini-flash-lite-latest

  • openai effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=0, token=1, api_key=0) | openai:manual=token:sk-proj-...2Dh0cp8A | env=sk-proj-...2Dh0cp8A | source=env: OPENAI_API_KEY
  • openai-codex effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=1, token=0, api_key=0) | openai-codex:default=OAuthOAuth/token status
  • openai
    • openai:manual static
  • openai-codex usage: 5h 100% left ⏱4h 59m · Week 0% left ⏱10m
    • openai-codex:default ok expires in 3d
      Model Input Ctx Local Auth Tags
      openai-codex/gpt-5.3-codex text+image 266k no yes default,configured,alias:gpt53
      openai-codex/gpt-5.4 text+image 266k no yes configured,alias:gpt54
      openai-codex/gpt-5.2 text+image 266k no yes configured,alias:gpt52
elfin solarBOT
#

Perfect — this output is exactly what we needed.

You already have both auth paths working:

  • openai-codex OAuth âś…
  • openai via OPENAI_API_KEY âś…

So the blocker is your model allowlist (Configured models (8)), which currently excludes other openai/* entries.

Fastest way to test everything

Temporarily remove the allowlist:

pnpm openclaw config unset agents.defaults.models

Then:

#
/model

and you should see the broader catalog from authenticated providers.

If it doesn’t refresh immediately:

pnpm openclaw gateway restart

If you want to keep a strict allowlist

Keep agents.defaults.models, but add the extra openai/<model> entries you want to test.


So yeah: auth is fine; this is just allowlist scope.
Docs: https://docs.openclaw.ai/concepts/models#model-is-not-allowed-and-why-replies-stop

past shard
elfin solarBOT
#

Nice — that’s the right approach.

Yep, keep your allowlist and just append those entries under agents.defaults.models in ~/.openclaw/openclaw.json.

Use this pattern (only showing the new ones to add):

{
agents: {
defaults: {
models: {
"openai/gpt-4.1-mini": {},
"openai/gpt-5-mini": {},
"openai/gpt-4.1-nano": {},
"openai/o3-mini": {}, // letter "o", not zero
},
#
},
},
}

Then verify:

pnpm openclaw models list --provider openai
pnpm openclaw models status

And test in chat with /model.

Small correction: openai/03-mini should be openai/o3-mini (letter o).

past shard
elfin solarBOT
#

Yes — you can add them via terminal without replacing your existing list.

This appends keys one-by-one under agents.defaults.models:

for m in "openai/gpt-4.1-mini" "openai/gpt-5-mini" "openai/gpt-4.1-nano" "openai/o3-mini"; do
pnpm openclaw config set "agents.defaults.models[\"$m\"]" "{}" --strict-json
done

✅ This is additive (it won’t wipe your current models).
Only those exact keys are created/updated.

Then verify + refresh:

#
pnpm openclaw config get agents.defaults.models
pnpm openclaw models list --provider openai
pnpm openclaw gateway restart

And test in chat with /model.

(Also: o3-mini uses letter o, not zero.)

past shard
past shard
#

@elfin solar are you down?

elfin solarBOT
#

I’m here 👋
Not down — want me to sanity-check your current model list/output now?

past shard
#

youre terminal code didnt work. there was a " in the wrong spot and it messed it all up.

elfin solarBOT
#

Ugh, yep — that one is on me. Sorry.
Here’s the correct copy/paste (no escaping gymnastics):

openclaw config set 'agents.defaults.models["openai/gpt-4.1-mini"]' '{}' --strict-json
openclaw config set 'agents.defaults.models["openai/gpt-5-mini"]' '{}' --strict-json
openclaw config set 'agents.defaults.models["openai/gpt-4.1-nano"]' '{}' --strict-json
openclaw config set 'agents.defaults.models["openai/o3-mini"]' '{}' --strict-json

This is additive (not a replacement of your existing list).

Then check:

openclaw config get agents.defaults.models
#
openclaw models list --provider openai
openclaw gateway restart

If you want, paste the output of openclaw config get agents.defaults.models and I’ll verify it looks clean.

past shard
# elfin solar ```bash openclaw models list --provider openai openclaw gateway restart ``` If ...

etracichbot@Petracichs-Mac-mini ~ % openclaw config get agents.defaults.models

🦞 OpenClaw 2026.3.13 (61d171a)
I read logs so you can keep pretending you don't have to.

{
"moonshot/kimi-k2.5": {
"alias": "kimi"
},
"deepseek/deepseek-reasoner": {
"alias": "Deepseek"
},
"minimax/MiniMax-M2.5": {
"alias": "Minimax"
},
"deepseek/deepseek-chat": {
"alias": "ds-chat"
},
"openai-codex/gpt-5.4": {
"alias": "gpt54"
},
"openai-codex/gpt-5.3-codex": {
"alias": "gpt53"
},
"openai-codex/gpt-5.2": {
"alias": "gpt52"
},
"google/gemini-flash-lite-latest": {
"alias": "lite"
},
""openai/gpt-4.1-mini"": {},
""openai/gpt-5-mini"": {},
""openai/gpt-4.1-nano"": {},
""openai/o3-mini"": {}
}
petracichbot@Petracichs-Mac-mini ~ % openclaw models list --provider openai
openclaw gateway restart

🦞 OpenClaw 2026.3.13 (61d171a)
Claws out, commit in—let's ship something mildly responsible.

No models found.

elfin solarBOT
#

Perfect debug output — found it.

Those keys were created with literal quote characters in the key name:

  • "\"openai/gpt-4.1-mini\"" (wrong)
    instead of
  • "openai/gpt-4.1-mini" (right)

Let’s fix it cleanly in one shot (terminal-only, no manual editor):

cat > /tmp/openclaw-models.json <<'JSON'
{
"moonshot/kimi-k2.5": { "alias": "kimi" },
"deepseek/deepseek-reasoner": { "alias": "Deepseek" },
"minimax/MiniMax-M2.5": { "alias": "Minimax" },
#
"deepseek/deepseek-chat": { "alias": "ds-chat" },
"openai-codex/gpt-5.4": { "alias": "gpt54" },
"openai-codex/gpt-5.3-codex": { "alias": "gpt53" },
"openai-codex/gpt-5.2": { "alias": "gpt52" },
"google/gemini-flash-lite-latest": { "alias": "lite" },
"openai/gpt-4.1-mini": {},
"openai/gpt-5-mini": {},
"openai/gpt-4.1-nano": {},
"openai/o3-mini": {}
}
JSON

openclaw config set agents.defaults.models "$(cat /tmp/openclaw-models.json)" --strict-json
openclaw config validate
openclaw models list --provider openai
#
openclaw gateway restart

This keeps your existing models and adds the four OpenAI ones.
If you paste the new openclaw config get agents.defaults.models, I’ll verify it’s clean.

past shard
past shard
#

@elfin solar

elfin solarBOT
#

I’m here 👋 still with you.

Use this exact fix (it avoids the quoted-key path issue entirely):

# optional backup
openclaw config get agents.defaults.models > /tmp/models.backup.json

cat > /tmp/models.fixed.json <<'JSON'
{
"moonshot/kimi-k2.5": { "alias": "kimi" },
"deepseek/deepseek-reasoner": { "alias": "Deepseek" },
"minimax/MiniMax-M2.5": { "alias": "Minimax" },
"deepseek/deepseek-chat": { "alias": "ds-chat" },
"openai-codex/gpt-5.4": { "alias": "gpt54" },
"openai-codex/gpt-5.3-codex": { "alias": "gpt53" },
#
"openai-codex/gpt-5.2": { "alias": "gpt52" },
"google/gemini-flash-lite-latest": { "alias": "lite" },
"openai/gpt-4.1-mini": {},
"openai/gpt-5-mini": {},
"openai/gpt-4.1-nano": {},
"openai/o3-mini": {}
}
JSON

openclaw config set agents.defaults.models "$(cat /tmp/models.fixed.json)" --strict-json
openclaw models list --provider openai
openclaw gateway restart

If you paste the new openclaw config get agents.defaults.models, I’ll confirm it’s clean.

past shard
#

@elfin solar

#

@elfin solar

past shard
#

@elfin solar