format_number

Pack: currencyformat · Endpoint: https://gateway.pipeworx.io/currencyformat/mcp

Format a number with grouping, fixed decimals, as a percentage, or in compact notation (keyless, offline). style = “decimal” (default), “percent”, or “compact”.

Parameters

NameTypeRequiredDescription
numbernumberyesThe number to format.
localestringnoBCP-47 locale (default “en-US”).
stylestringnodecimal (default) | percent | compact.
decimalsnumbernoFixed number of fraction digits.

Example call

Arguments

{
  "number": 1234.567,
  "locale": "en-US",
  "style": "decimal",
  "decimals": 2
}

curl

curl -X POST https://gateway.pipeworx.io/currencyformat/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"format_number","arguments":{"number":1234.567,"locale":"en-US","style":"decimal","decimals":2}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('format_number', {
  "number": 1234.567,
  "locale": "en-US",
  "style": "decimal",
  "decimals": 2
});

More examples

{
  "number": 0.456,
  "style": "percent"
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "currencyformat": {
      "url": "https://gateway.pipeworx.io/currencyformat/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build August 15, 2026