Configuration
Read and patch the merged nikcli config, reload it from disk, resolve the provider table, and manage MCP server entries and config profiles.
Send these requests to your own running server. Values stay in this browser.
How this works
Start a server with nikcli serve --hostname 127.0.0.1 --port 4096. Requests go
straight from this page to that address — the browser allows it because loopback counts as a
secure origin, and the server allows it because nikcli-ai.dev is in its CORS
allowlist.
To try things without touching your real sessions or config, start the server with
NIKCLI_TEST_HOME pointed at a throwaway directory — see
the guided tour.
Operations
10 endpoints, generated from the
server's own OpenAPI document. Every path also accepts the
directory and workspace query parameters that select which instance
handles the request.
| get | /config | config.get |
| patch | /config | config.update |
| get | /config/providers | config.providers |
| post | /config/reload | config.reload |
| post | /config/mcp | postConfigMcp |
| patch | /config/mcp/{name} | patchConfigMcp:name |
| delete | /config/mcp/{name} | deleteConfigMcp:name |
| get | /config/profiles | getConfigProfiles |
| post | /config/profiles | postConfigProfiles |
| post | /config/profiles/activate/{name} | postConfigProfilesActivate:name |
config.get | Name | In | Type | Required |
|---|---|---|---|
| directory | query | string | optional |
| workspace | query | string | optional |
{ [key: string]: unknown }
Example response from schema
{} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.config.get({
...
}) Try it
config.update | Name | In | Type | Required |
|---|---|---|---|
| directory | query | string | optional |
| workspace | query | string | optional |
{ [key: string]: unknown }
{ [key: string]: unknown }
{ name: string data: { [key: string]: unknown } }
Example response from schema
{} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.config.update({
...
}) Try it
config.providers | Name | In | Type | Required |
|---|---|---|---|
| directory | query | string | optional |
| workspace | query | string | optional |
{ providers: Provider[] default: { [key: string]: string } }
Example response from schema
{
"providers": [
{
"id": "",
"name": "",
"source": "env",
"env": [],
"key": "",
"options": {},
"models": {}
}
],
"default": {}
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.config.providers({
...
}) Try it
config.reload | Name | In | Type | Required |
|---|---|---|---|
| directory | query | string | optional |
| workspace | query | string | optional |
{ reloaded: boolean directory: string }
Example response from schema
{
"reloaded": false,
"directory": ""
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.config.reload({
...
}) Try it
postConfigMcp | Name | In | Type | Required |
|---|---|---|---|
| directory | query | string | optional |
| workspace | query | string | optional |
{ name: string config: unknown }
{ success: boolean }
Example response from schema
{
"success": false
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.postConfigMcp({
...
}) Try it
patchConfigMcp:name | Name | In | Type | Required |
|---|---|---|---|
| name | path | string | required |
| directory | query | string | optional |
| workspace | query | string | optional |
{ [key: string]: unknown }
{ success: boolean }
Example response from schema
{
"success": false
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.patchConfigMcp:name({
...
}) Try it
deleteConfigMcp:name | Name | In | Type | Required |
|---|---|---|---|
| name | path | string | required |
| directory | query | string | optional |
| workspace | query | string | optional |
{ success: boolean }
Example response from schema
{
"success": false
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.deleteConfigMcp:name({
...
}) Try it
This changes or removes server state, against whatever base URL is set above.
getConfigProfiles | Name | In | Type | Required |
|---|---|---|---|
| directory | query | string | optional |
| workspace | query | string | optional |
{ profiles: { [key: string]: ConfigProfileInfo } activeProfile: string }
Example response from schema
{
"profiles": {},
"activeProfile": ""
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.getConfigProfiles({
...
}) Try it
postConfigProfiles | Name | In | Type | Required |
|---|---|---|---|
| directory | query | string | optional |
| workspace | query | string | optional |
{ name: string }
{ success: boolean }
Example response from schema
{
"success": false
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.postConfigProfiles({
...
}) Try it
postConfigProfilesActivate:name | Name | In | Type | Required |
|---|---|---|---|
| name | path | string | required |
| directory | query | string | optional |
| workspace | query | string | optional |
{ success: boolean }
Example response from schema
{
"success": false
} Generated from the response schema — field values are placeholders, the shape is real.
SDK example
import { createNikcliClient } from "@nikcli-ai/sdk/httpapi"
const client = createNikcliClient()
await client.postConfigProfilesActivate:name({
...
}) Try it
Schemas
The 44 schemas reachable from these endpoints. Each is shown one level
deep; nested types link to their own entry below.
Names ending in _2, _3 and so on are the OpenAPI emitter
disambiguating same-named schemas declared by different HttpApi groups — they are distinct
shapes, not duplicates.
{ enabled?: boolean | null ratio?: | | number | "Infinity" | "-Infinity" | "NaN" | null items?: AdsItemConfig[] | null }
{ id: string text: string url?: string | null enabled?: boolean | null }
{ [key: string]: unknown | null }
{ image?: | { auto_resize?: boolean | null max_width?: | | number | "Infinity" | "-Infinity" | "NaN" | null max_height?: | | number | "Infinity" | "-Infinity" | "NaN" | null max_base64_bytes?: | | number | "Infinity" | "-Infinity" | "NaN" | null } | null }
{ environment?: string[] | null allow?: string[] | null soft_deny?: string[] | null hard_deny?: string[] | null classify_all_shell?: boolean | null model?: string | null disable?: boolean | null }
{ mode?: "sandbox" | "host" | null width?: | | number | "Infinity" | "-Infinity" | "NaN" | null height?: | | number | "Infinity" | "-Infinity" | "NaN" | null }
{ [key: string]: unknown }
{ name: string config: unknown }
{ mcpCount: | number | "Infinity" | "-Infinity" | "NaN" plugins: string[] providerCount: | number | "Infinity" | "-Infinity" | "NaN" }
{ profiles: { [key: string]: ConfigProfileInfo } activeProfile: string }
{ providers: Provider[] default: { [key: string]: string } }
{ reloaded: boolean directory: string }
{ name: string data: { [key: string]: unknown } }
{ type: "discord" botToken?: string | null enabled?: boolean | null }
{ type: "figma" token?: string | null enabled?: boolean | null }
{ type: "gchat" botToken?: string | null enabled?: boolean | null }
{ type: "github" token?: string | null oauthClientId?: string | null clientId?: string | null enabled?: boolean | null }
{ type: "linear" botToken?: string | null enabled?: boolean | null }
{ type: "lovable" token?: string | null apiKey?: string | null enabled?: boolean | null }
{ type: "slack" botToken?: string | null teamId?: string | null enabled?: boolean | null }
{ type: "teams" botToken?: string | null enabled?: boolean | null }
{ model?: string | null provider?: string | null }
{ leader?: string | null app_exit?: string | null editor_open?: string | null theme_list?: string | null sidebar_toggle?: string | null scrollbar_toggle?: string | null username_toggle?: string | null status_view?: string | null sync_view?: string | null session_export?: string | null session_new?: string | null session_list?: string | null session_timeline?: string | null session_fork?: string | null session_rename?: string | null session_delete?: string | null session_pin_toggle?: string | null session_scope_toggle?: string | null session_tab_back?: string | null session_tab_forward?: string | null session_quick_switch_1?: string | null session_quick_switch_2?: string | null session_quick_switch_3?: string | null session_quick_switch_4?: string | null session_quick_switch_5?: string | null session_quick_switch_6?: string | null session_quick_switch_7?: string | null session_quick_switch_8?: string | null session_quick_switch_9?: string | null stash_delete?: string | null model_provider_list?: string | null model_favorite_toggle?: string | null session_share?: string | null session_unshare?: string | null session_interrupt?: string | null session_codebro_open?: string | null subtask_background?: string | null subtask_picker?: string | null session_compact?: string | null messages_page_up?: string | null messages_page_down?: string | null messages_line_up?: string | null messages_line_down?: string | null messages_half_page_up?: string | null messages_half_page_down?: string | null messages_first?: string | null messages_last?: string | null messages_next?: string | null messages_previous?: string | null messages_last_user?: string | null messages_copy?: string | null messages_undo?: string | null messages_redo?: string | null messages_toggle_conceal?: string | null tool_details?: string | null model_list?: string | null model_cycle_recent?: string | null model_cycle_recent_reverse?: string | null model_cycle_favorite?: string | null model_cycle_favorite_reverse?: string | null command_list?: string | null agent_list?: string | null agent_cycle?: string | null agent_cycle_reverse?: string | null permission_mode?: string | null variant_cycle?: string | null input_clear?: string | null input_paste?: string | null input_submit?: string | null input_newline?: string | null input_move_left?: string | null input_move_right?: string | null input_move_up?: string | null input_move_down?: string | null input_select_left?: string | null input_select_right?: string | null input_select_up?: string | null input_select_down?: string | null input_line_home?: string | null input_line_end?: string | null input_select_line_home?: string | null input_select_line_end?: string | null input_visual_line_home?: string | null input_visual_line_end?: string | null input_select_visual_line_home?: string | null input_select_visual_line_end?: string | null input_buffer_home?: string | null input_buffer_end?: string | null input_select_buffer_home?: string | null input_select_buffer_end?: string | null input_delete_line?: string | null input_delete_to_line_end?: string | null input_delete_to_line_start?: string | null input_backspace?: string | null input_delete?: string | null input_undo?: string | null input_redo?: string | null input_word_forward?: string | null input_word_backward?: string | null input_select_word_forward?: string | null input_select_word_backward?: string | null input_delete_word_forward?: string | null input_delete_word_backward?: string | null history_previous?: string | null history_next?: string | null session_child_cycle?: string | null session_child_cycle_reverse?: string | null session_parent?: string | null session_child_close?: string | null terminal_suspend?: string | null terminal_title_toggle?: string | null tips_toggle?: string | null voice_record?: string | null app_support?: string | null }
"auto" | "stretch"
| "DEBUG" | "INFO" | "WARN" | "ERROR"
{ type: "local" command: string[] environment?: | { [key: string]: string } | null enabled?: boolean | null timeout?: | | number | "Infinity" | "-Infinity" | "NaN" | null }
{ clientId?: string | null clientSecret?: string | null scope?: string | null }
{ type: "remote" url: string enabled?: boolean | null headers?: | { [key: string]: string } | null oauth?: McpOAuthConfig | false | null timeout?: | | number | "Infinity" | "-Infinity" | "NaN" | null }
{ id: string providerID: string api: { id: string url?: string npm: string } name: string family?: string capabilities: { temperature: boolean reasoning: boolean attachment: boolean toolcall: boolean input: { text: boolean audio: boolean image: boolean video: boolean pdf: boolean } output: { text: boolean audio: boolean image: boolean video: boolean pdf: boolean } interleaved: | boolean | { field: "reasoning_content" | "reasoning_details" } } cost: { input: | number | "Infinity" | "-Infinity" | "NaN" output: | number | "Infinity" | "-Infinity" | "NaN" cache: { read: | number | "Infinity" | "-Infinity" | "NaN" write: | number | "Infinity" | "-Infinity" | "NaN" } experimentalOver200K?: { input: | number | "Infinity" | "-Infinity" | "NaN" output: | number | "Infinity" | "-Infinity" | "NaN" cache: { read: | number | "Infinity" | "-Infinity" | "NaN" write: | number | "Infinity" | "-Infinity" | "NaN" } } } limit: { context: | number | "Infinity" | "-Infinity" | "NaN" input?: | number | "Infinity" | "-Infinity" | "NaN" output: | number | "Infinity" | "-Infinity" | "NaN" } status: | "alpha" | "beta" | "deprecated" | "active" options: { [key: string]: unknown } headers: { [key: string]: string } release_date: string variants?: { [key: string]: { [key: string]: unknown } } }
"ask" | "allow" | "deny"
{ [key: string]: PermissionRuleConfig | null }
"default" | "auto"
{ [key: string]: PermissionActionConfig }
PermissionActionConfig | PermissionObjectConfig
{ effect: "allow" | "deny" action: string resource: string }
{ id: string name: string source: | "env" | "config" | "custom" | "api" env: string[] key?: string | null options: { [key: string]: unknown } models: { [key: string]: Model } }
{ api?: string | null name?: string | null env?: string[] | null id?: string | null npm?: string | null models?: | { [key: string]: { id?: string | null name?: string | null family?: string | null release_date?: string | null attachment?: boolean | null reasoning?: boolean | null temperature?: boolean | null tool_call?: boolean | null interleaved?: | | true | { field: "reasoning_content" | "reasoning_details" } | null cost?: | { input: | number | "Infinity" | "-Infinity" | "NaN" output: | number | "Infinity" | "-Infinity" | "NaN" cache_read?: | | number | "Infinity" | "-Infinity" | "NaN" | null cache_write?: | | number | "Infinity" | "-Infinity" | "NaN" | null context_over_200k?: | { input: | number | "Infinity" | "-Infinity" | "NaN" output: | number | "Infinity" | "-Infinity" | "NaN" cache_read?: | | number | "Infinity" | "-Infinity" | "NaN" | null cache_write?: | | number | "Infinity" | "-Infinity" | "NaN" | null } | null } | null limit?: | { context: | number | "Infinity" | "-Infinity" | "NaN" input?: | | number | "Infinity" | "-Infinity" | "NaN" | null output: | number | "Infinity" | "-Infinity" | "NaN" } | null modalities?: | { input: ( | "text" | "audio" | "image" | "video" | "pdf")[] output: ( | "text" | "audio" | "image" | "video" | "pdf")[] } | null experimental?: boolean | null status?: "alpha" | "beta" | "deprecated" | null options?: { [key: string]: unknown } | null headers?: | { [key: string]: string } | null provider?: | { npm: string api: string } | null reasoning_options?: | ( | { type: "effort" values: (string | null)[] } | { type: "toggle" } | { type: "budget_tokens" min?: | | number | "Infinity" | "-Infinity" | "NaN" | null max?: | | number | "Infinity" | "-Infinity" | "NaN" | null })[] | null variants?: | { [key: string]: { [key: string]: unknown | null } } | null disabled?: boolean | null } } | null auth_provider?: string | null whitelist?: string[] | null blacklist?: string[] | null options?: | { [key: string]: unknown | null } | null }
{ model?: string | null provider?: string | null }
| { type: "git" repository: string branch?: string | null description?: string | null } | { type: "local" path: string description?: string | null }
{ enabled?: boolean | null enableTunnel?: boolean | null provider?: | | "localtunnel" | "cloudflared" | "ngrok" | "remotosh" | "none" | null askOnExistingSession?: boolean | null }
{ port?: | | number | "Infinity" | "-Infinity" | "NaN" | null hostname?: string | null mdns?: boolean | null cors?: string[] | null }
{ provider?: string | null model?: string | null modelId?: string | null outputFormat?: string | null }
{ success: boolean }
{ url?: string | null token?: string | null }