1jehuang / 1jehuang/jcode

How to modify endpoint and API key for an existing OpenAI-compatible provider profile?Can't find endpoint URL and API key in config.toml for it

Open
#927 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

documentation question
Dominant language
Rust
Stars
19.9k
Forks
2.3k
Avg merge
2d 7h
Merged PRs (30d)
30

Description

Description

I added an OpenAI-compatible provider using jcode provider add command. Now I need to change the endpoint URL and API key, but I can't find these settings anywhere in ~/.jcode/config.toml.

What I've checked
  1. I opened ~/.jcode/config.toml and looked for the provider configuration:

    cat ~/.jcode/config.toml
    
  2. The file only contains basic settings like:

    [provider]
    default_provider = "my-api"
    
    [display]
    centered = true
    

    But there's no [providers.my-api] section showing the base_url or api_key.

  3. I also checked:

    • ~/.config/jcode/*.env - no relevant files found
    • ~/.jcode/ directory - only config.toml and sessions
    • The docs at https://jcode.sh/docs#providers - they mention config.toml but don't explain where the actual endpoint/key are stored
Questions
  1. Where does jcode actually store the endpoint URL and API key for providers added via jcode provider add? They don't appear to be in config.toml.

  2. How can I update the endpoint URL and API key for an existing provider profile if I can't find where they're stored?

  3. Is there a command like jcode provider list to show current configuration, or jcode provider edit to modify it?

  4. If the credentials are stored elsewhere (like in a keychain, encrypted file, or separate auth file), how do I update them?

Steps to reproduce
# Add a provider
printf '%s' "$MY_API_KEY" | jcode provider add test-api \
  --base-url https://test.example.com/v1 \
  --model gpt-4

# Check config - endpoint and key are missing
cat ~/.jcode/config.toml
Expected behavior

I expected to find the endpoint URL and API key in ~/.jcode/config.toml under [providers.test-api], or have a clear way to update them through the CLI.

Environment
  • OS: win11
  • jcode version: 0.75.5

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the jcode provider add command and the provider documentation at https://jcode.sh/docs#providers. Trace how the command handles --base-url, --model, and the piped API key, then compare that behavior with ~/.jcode/config.toml and ~/.config/jcode/*.env. Done means documenting where these values are stored and the supported way to view or update an existing provider.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli, documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.