免费、开放 CORS 的 JSON —— 把计算器当作工具或代理来用
披萨面团计算器提供一个免费、只读、开放 CORS 的 JSON 接口,方便脚本、应用和 AI 代理以编程方式计算面团配方。
GET https://pizza-calculator.the-bread-code.io/dough.json
只读 GET;返回 Access-Control-Allow-Origin: *,因此可从浏览器或任意来源调用。无需密钥,无需注册。
| 参数 | 取值 | 说明 |
|---|---|---|
| pizzas | 1–10000 | 披萨数量。 |
| style | neapolitan · ny · roman · custom | 披萨风格(设定默认值)。 |
| weight_per_pizza | 克 | 每个披萨的面团球重量。 |
| hydration | 百分比或小数 | 以烘焙百分比表示的水量(例如 60 或 0.6)。 |
| dough_type | yeast · sourdough | 发酵方式。 |
| starter_percent | 1–50 | 仅酸面团:酵种占面粉的百分比。 |
| starter_hydration | 百分比 | 仅酸面团:酵种含水量(默认 100)。 |
GET https://pizza-calculator.the-bread-code.io/dough.json?pizzas=4&style=neapolitan&weight_per_pizza=270&hydration=60&dough_type=yeast
返回输入参数(回显)、面团总重量、配料明细(克数 + 烘焙百分比)、发酵预设;酸面团还会返回酵种明细,那不勒斯还会返回玛格丽特配料用量。
用 iframe 把计算器嵌入你自己的页面:
<iframe src="https://pizza-calculator.the-bread-code.io/embed" width="100%" height="640" style="border:0" title="Pizza Dough Calculator" loading="lazy"></iframe>
欢迎注明出处链接到本站,但并非必需。