← Catalog

pi-maritaca

pi extension for Maritaca AI

Extension

Install

Install with PiG

pig install npm:pi-maritaca

Install with Pi

pi install npm:pi-maritaca
Review before installing

Packages run code with your permissions and influence agent behavior. Catalog inclusion is not a security audit. Review the source before installing a third-party package.

Pi manifest JSON

The pi field of package.json.

{
  "extensions": [
    "./src/index.ts"
  ]
}

README

Written by the package's publisher, shown as published in version 0.1.0 (README.md). PiG does not review it.

pi-maritaca

npm version License GitHub Codeberg Author

pi extension for Maritaca AI.

Set up

With pi installed and ready to use, run:

pi install npm:pi-maritaca

Get an API key at plataforma.maritaca.ai, set the environment variable MARITACA_API_KEY with your key, and you should be ready to go.

export MARITACA_API_KEY='<Your API key here>'

You're ready. Run pi normally; the extension loads automatically:

pi

Use

Usage is mostly automatic. The extension will make your pi integrate seamlessly with Maritaca AI, so you should be able to see their models when you /model, the list will be reloaded when you /reload, etc.

Here's what the extension will do:

  1. It registers maritaca as a model provider in pi
  2. Fetches a fresh list of available models from Maritaca AI when you open pi
  3. Refresh the list of models when you /model or /reload
  4. API fetch: The callback fetches models from the Maritaca AI /api/models endpoint

Configuration

The extension uses the Responses API by default (Maritaca's recommended interface). Everything can be overridden:

Env varDefaultDescription
MARITACA_API_BASE_URLhttps://chat.maritaca.ai/apiAPI base URL
MARITACA_API_FORMATopenai-responsesopenai-responses or openai-completions
MARITACA_API_KEY—Your API key from plataforma.maritaca.ai

Or set them from your extension module:

import { createMaritacaExtension } from "pi-maritaca";

// Use the Chat Completions API instead
export default createMaritacaExtension({ apiFormat: "openai-completions" });

Precedence: config param > environment variable > default.

💡 Troubleshoot

If something is not working properly, you're not seeing Maritaca AI' models when you /model, etc., the first place to check is your API key:

echo $MARITACA_API_KEY

Test it against the API:

curl https://chat.maritaca.ai/api/models -H "Authorization: Bearer $MARITACA_API_KEY"

Reload pi (while in pi, run /reload). Check pi's console output for error messages, you'll most certainly find insights on what's wrong.

If nothing works and you believe it's a bug in the extension itself, open an issue at https://github.com/joeljuca/pi-maritaca/issues.

Contribute

See: CONTRIBUTING.md

License

Apache-2.0 © Joel Jucá