Install
Install with PiG
pig install npm:pi-maritacaInstall with Pi
pi install npm:pi-maritacaPackages 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
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:
- It registers
maritacaas a model provider in pi - Fetches a fresh list of available models from Maritaca AI when you open pi
- Refresh the list of models when you
/modelor/reload - API fetch: The callback fetches models from the Maritaca AI
/api/modelsendpoint
Configuration
The extension uses the Responses API by default (Maritaca's recommended interface). Everything can be overridden:
| Env var | Default | Description |
|---|---|---|
MARITACA_API_BASE_URL | https://chat.maritaca.ai/api | API base URL |
MARITACA_API_FORMAT | openai-responses | openai-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_KEYTest 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