AI setup · Local bridge

Connect Mangos to a local AI bridge.

OpenCodex is independent third-party software that can make configured AI models available through a local endpoint on your computer.

You can connect that endpoint to Mangos AI without entering an API key in Mangos. This is a third-party compatibility workflow, not an official Mangos integration.

Local onlyThe bridge stays on loopback and is not exposed to your network.
No key in MangosThe local bridge handles the compatible endpoint and its upstream authentication.
Your model IDsUse the endpoint and exact model IDs returned by your own setup.
Before you start

What you need

  • Mangos AI installed
  • Node.js 18 or newer
  • A coding agent or terminal
  • Permission to use your chosen account or model through third-party software
Keep the bridge running

OpenCodex must remain running whenever a Mangos agent uses the connected model.

Step 1

Paste this prompt into your coding agent

Copy the complete prompt below and paste it into your preferred coding agent.

Prompt for your coding agent
Help me set up the independent OpenCodex local bridge for use with Mangos AI.

Use the current official instructions at https://opencodex.me and proceed carefully:

1. Check that Node.js 18 or newer and npm are installed.
2. Install @bitkyc08/opencodex globally if it is not already installed.
3. Start OpenCodex on loopback only. Do not expose it to my network or change firewall settings.
4. Do not use sudo, display credentials, or configure account access without asking me.
5. If provider or account setup requires interaction, give me the local dashboard URL and pause while I complete it.
6. After I confirm setup, verify OpenCodex is ready and retrieve the available model IDs from its local models endpoint.
7. Ask before installing a persistent background service.
8. Finish with exactly:
   MANGOS ENDPOINT: <local base URL ending in /v1>
   MODEL IDS: <up to five available model IDs>
   STATUS: <ready or the remaining problem>

Do not modify Mangos AI or any unrelated project files.

Your coding agent may ask you to open a local dashboard such as:

Local dashboard
http://localhost:10100

Complete any account, provider, or model setup directly inside that local dashboard. Do not paste private credentials into the coding-agent conversation.

After completing the setup, return to your coding agent and tell it to continue.

Step 2

Copy the returned endpoint and model

When setup is complete, your coding agent should return something similar to:

Example result
MANGOS ENDPOINT: http://127.0.0.1:10100/v1
MODEL IDS: ollama/llama3, provider/model-name
STATUS: ready

The port may be different if 10100 is unavailable. Always use the endpoint your coding agent returns.

Step 3

Connect the endpoint in Mangos

  1. Open AI Settings

    Open Mangos AI and click AI Settings in the sidebar.

  2. Select OpenAI

    Select the card labeled OpenAI and leave the API key field blank.

  3. Enter the endpoint

    Click the pencil beside Endpoint and paste the returned MANGOS ENDPOINT.

  4. Choose the model

    Click Fetch models, then select one of the returned models.

  5. Test and save

    Click Test connection, then Save as Default.

Why the card says “OpenAI”

The label identifies the compatible request format exposed by the local bridge. It does not indicate an official Mangos integration, partnership, or endorsement.

Model selection

If your model does not appear

Type the exact model ID into the model search field. For example:

Model ID
ollama/llama3

Mangos should offer an option like:

Manual selection
Use "ollama/llama3"

Select that option and test the connection. Model IDs vary between installations. Use an ID returned by your own OpenCodex setup rather than guessing one.

Apply your settings

Existing agents

Saving this configuration in AI Settings makes it the default for new agents and outreach campaigns.

Existing social agents retain their individual AI settings. To update one:

  1. Open the agent’s menu.
  2. Select Edit.
  3. Continue to its AI settings.
  4. Enter the same endpoint and model.
  5. Test the connection.
  6. Save the agent.
Day-to-day use

Keep OpenCodex running

The local bridge must be running whenever Mangos needs the connected model.

Start manually
ocx start
Check status
ocx status
Wait until ready
ocx ready --wait

If you want OpenCodex to run automatically in the background, ask your coding agent:

Background-service prompt
OpenCodex is working. Please explain the background-service option for my operating system, then ask for confirmation before enabling it.
When something goes wrong

Troubleshooting

Mangos cannot connect

  • Confirm OpenCodex is running.
  • Run ocx status.
  • Run ocx ready --wait.
  • Confirm the endpoint uses the current OpenCodex port.
  • Confirm the endpoint ends in /v1.
  • Use 127.0.0.1 or localhost.
  • Do not use an externally exposed address.

No models appear

  • Finish the provider and model setup in the OpenCodex dashboard.
  • Ask your coding agent to retrieve the model IDs again.
  • Enter the exact model ID manually in Mangos.
  • Do not substitute a guessed model name.

Authentication failed

  • Complete account or key setup inside the local OpenCodex dashboard.
  • Do not place upstream credentials in Mangos when the local bridge handles authentication.
  • Review the connected provider’s current terms and account rules.

It stopped working after a restart

OpenCodex may no longer be running. Start it again with ocx start. You can also review the optional background-service setup.

Important

Third-party notice

OpenCodex is independent, community-maintained third-party software. Mangos AI does not provide, operate, endorse, or guarantee OpenCodex or any account or model provider used through it.

This compatibility workflow works today but may change as third-party software, APIs, and provider rules evolve. Review all applicable terms before connecting an account, subscription, API key, or model.

For current installation and configuration information, visit the OpenCodex documentation or OpenCodex repository.

Connect your local model to Mangos.

Start with the guarded setup prompt, then use the endpoint your coding agent returns.