1 USD ≈ 27,000 credits · display only
Reference rate may change over time.
1 USD ≈ 27,000 credits · display only
Reference rate may change over time.
Gommo Developer client
Official Gommo Developer TypeScript client — npm alias @ai-gateway/client. Calls Gommo public API (api.gommo.net, v2.api.gommo.net).
npm install @ai-gateway/clientPackage: @ai-gateway/client on npm (current v1.0.0).
Pin a version in production:
npm install @ai-gateway/[email protected]Verify registry:
npm view @ai-gateway/client versionWhen developing the gateway repo itself:
npm run client:build
npm install ./packages/gateway-clientimport { GommoClient } from '@ai-gateway/client';
const client = new GommoClient({
accessToken: process.env.GOMMO_ACCESS_TOKEN,
domain: process.env.GOMMO_DOMAIN ?? 'YOUR_REGISTRATION_DOMAIN',
// optional overrides:
// v2BaseUrl: process.env.GOMMO_V2_BASE_URL ?? 'https://v2.api.gommo.net',
// authBaseUrl: process.env.GOMMO_AUTH_BASE_URL ?? 'https://api.gommo.net',
});| Option | Default | Description |
|---|---|---|
v2BaseUrl | https://v2.api.gommo.net | Models, jobs, upload |
authBaseUrl | https://api.gommo.net | Login, me, chat, audio |
domain | <registration-domain> | Gommo registration domain |
projectId | default | Gommo project id |
accessToken | — | Bearer token |
fetch | globalThis.fetch | Custom fetch (Node/Bun/Deno) |
Only when deploying this repo — see Deploy → Self-host (advanced). SDK transport: 'gateway' is for dev/portal, not the Gommo public contract.
// Recommended — proves token + registration domain:
const me = await client.auth.me();
console.log(me.balancesInfo?.credits_ai);
// Gommo mode only: synthetic ok (does not validate the token):
const health = await client.health();
console.log(health.data?.ok);