29trust / 100

Calculators Tip Calculator

by AgentTools in Company & people data

x402 APIFailing, checked 3 h ago

Calculate the tip for any bill, the grand total, and how much each person pays when splitting. Defaults to a 15% tip. Use this when an agent needs to tip amount, total and per-person split.

GET https://agenttools-hub.vercel.app/api/v1/calculators/tip-calculator

Last 30 days

All checks passedSome failedAll failedNot checked
Uptime
13.3%
Response time
142 ms typical, 142 ms slowest 5%
Last check
3 h ago: Expected HTTP 402, got 308
Next check
any minute now

How to call it

# See the payment challenge (nothing is charged)
curl -i -X GET "https://agenttools-hub.vercel.app/api/v1/calculators/tip-calculator?bill=64.5&people=1&tipPercent=15"
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";

const client = new x402Client().register(
  "eip155:8453",
  new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_KEY)),
);
const pay = wrapFetchWithPayment(fetch, client);

// Not sure it's safe to pay? Preflight it first for $0.005:
// GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fagenttools-hub.vercel.app%2Fapi%2Fv1%2Fcalculators%2Ftip-calculator
const res = await pay("https://agenttools-hub.vercel.app/api/v1/calculators/tip-calculator?bill=64.5&people=1&tipPercent=15");
console.log(await res.json());

Example input

{
  "bill": 64.5,
  "people": 1,
  "tipPercent": 15
}

Example output

{
  "result": {
    "answer": "74.18",
    "answerLabel": "Total with 15% tip",
    "details": [
      {
        "label": "Tip amount",
        "value": "9.68"
      },
      {
        "label": "Bill",
        "value": "64.5"
      }
    ],
    "steps": [
      "Tip = 64.5 × 15 ÷ 100 = 9.68",
      "Total = 64.5 + 9.68 = 74.18"
    ],
    "value": 74.175
  },
  "tool": "tip-calculator"
}

Security scan

  • No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.

Recent checks

WhenResultHTTPTimePrice
3 h agoExpected HTTP 402, got 30830877 ms-
8 h agoExpected HTTP 402, got 30830878 ms-
12 h agoExpected HTTP 402, got 30830875 ms-
16 h agoExpected HTTP 402, got 30830871 ms-
20 h agoExpected HTTP 402, got 308308138 ms-
24 h agoExpected HTTP 402, got 308308367 ms-
28 h agoExpected HTTP 402, got 308308143 ms-
32 h agoExpected HTTP 402, got 30830853 ms-
36 h agoExpected HTTP 402, got 30830822 ms-
41 h agoExpected HTTP 402, got 308308117 ms-
45 h agoExpected HTTP 402, got 30830848 ms-
2 days agoExpected HTTP 402, got 30830870 ms-
2 days agoExpected HTTP 402, got 30830849 ms-
2 days agoPassed402232 ms$0.002
3 days agoPassed402142 ms$0.002