Docs
API referenceSign in

OpenAI Codex CLI setup

Connect OpenAI Codex CLI to UncensoredLabs abliterated models through our stateless `/v1/responses` endpoint.

Configure Codex CLI

Add UncensoredLabs as a custom model provider in ~/.codex/config.toml using wire_api = "responses" and export UNCENSOREDLABS_API_KEY in your shell environment.

~/.codex/config.toml
model_provider = "uncensoredlabs"
model = "deepseek-v4.1-flash-1017-abliterated"

[model_providers.uncensoredlabs]
name = "UncensoredLabs"
base_url = "https://uncensoredlabs.dev/v1"
env_key = "UNCENSOREDLABS_API_KEY"
wire_api = "responses"
Launch Codex CLI
export UNCENSOREDLABS_API_KEY="ul_your_application_api_key"
codex
UncensoredLabs runs /v1/responses in stateless zero-retention mode (store: false). Pass conversation history in input; stateful previous_response_id chaining is disabled so prompts and outputs are never stored server-side.

Verify the connection

Use an application API key from the dashboard, not your account sign-in key. Keep credentials outside committed configuration.

Start a new session and request a short response. Then ask the client to list files without changing them, and review its tool permissions before a longer task.

Configuration examples were checked against the linked official documentation on November 1, 2026. Client versions and features vary; these guides do not certify every client release.

Troubleshooting

OpenAI Chat Completions (/v1/chat/completions), Anthropic Messages (/v1/messages), and stateless OpenAI Responses (/v1/responses) are supported. Image input and reasoning effort depend on the selected model. Client web-search features may require a separate service.
StatusWhat to check
400 / 404Check the base URL, exact model ID and protocol path. Do not append the completions path twice to a base-URL field.
401 / 403Check the application API key, its model permissions and whether it has been revoked.
402Check available credit and existing reservations. A reservation can exceed the final charge; use a smaller output limit before retrying.
429Respect Retry-After and reduce concurrent tasks. Do not immediately retry the same request in a loop.