以编程方式访问 alltools.one 功能。通过 REST API 管理代码片段、共享数据并跟踪历史记录。
https://api.alltools.onePull your team's saved JSON / YAML / CSV formatter configs in GitHub Actions or GitLab CI to keep builds consistent.
# .github/workflows/validate.yml
- name: Fetch saved formatter config
run: |
curl -sf "https://api.alltools.one/api/snippets?tool=json-formatter&limit=1" \
-H "X-API-Key: ${{ secrets.ALLTOOLS_API_KEY }}" | jq '.snippets[0].data'When your automation workflow produces a formatted CSV or JSON, POST it directly as a named snippet for later retrieval.
curl -X POST https://api.alltools.one/api/snippets \
-H "X-API-Key: ato_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"tool": "csv-formatter",
"title": "Daily Report 2025-01-15",
"data": { "csv": "name,value\nAlice,42\nBob,99" },
"tags": ["automated", "daily"]
}'Create a shareable link for any formatted output — useful for embedding live data previews in Notion, Slack, or documentation.
curl -X POST https://api.alltools.one/api/shares \
-H "X-API-Key: ato_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"tool": "json-formatter",
"title": "API Response Sample",
"data": { "input": "{\"status\":\"ok\",\"result\":42}" }
}'
# Returns: { "share_url": "https://alltools.one/share/abc123def4", "id": "abc123def4" }大多数端点需要通过 Firebase JWT 令牌或 API 密钥进行身份验证。
通过 Firebase Auth 获取令牌,然后将其包含在 Authorization 标头中:
curl https://api.alltools.one/api/auth/profile \
-H "Authorization: Bearer <firebase_id_token>"Pro 用户可以从控制台创建 API 密钥。在 X-API-Key 标头中包含密钥:
curl https://api.alltools.one/api/snippets \
-H "X-API-Key: ato_your_key_here"保存和管理工具输出。免费用户最多可存储 5 个代码片段;Pro 用户可获得无限存储空间。
为工具数据创建可共享链接。免费共享在 30 天后过期(最大 5 MB)。Pro 共享永不过期(最大 50 MB)。
跟踪工具使用情况。免费用户:最近 20 条记录。Pro 用户:无限历史记录。
管理编程 API 密钥。需要 Pro 计划。每用户最多 5 个密钥。
通过 Razorpay 集成管理 Pro 订阅。
| 代码 | 含义 | 常见原因 |
|---|---|---|
200 | OK | Request succeeded |
201 | Created | Resource created |
400 | Bad Request | Validation error or malformed input |
401 | Unauthorized | Missing or invalid auth token |
403 | Forbidden | Pro plan required or not the resource owner |
404 | Not Found | Resource does not exist |
409 | Conflict | Duplicate resource (e.g. email already subscribed) |
410 | Gone | Share link has expired |
413 | Payload Too Large | Data exceeds size limit (5MB free / 50MB pro) |
429 | Too Many Requests | Rate limit exceeded |
Pro 计划专属。请求按 API 密钥分别跟踪。
每 IP 地址每 60 秒 5 次请求。
| 功能 | 免费 | Pro |
|---|---|---|
| 已保存代码片段 | 15 | 无限 |
| 历史记录条目 | 20 | 无限 |
| 最大共享大小 | 5 MB | 50 MB |
| 共享过期时间 | Never | 永不 |
| API 请求 | — | Unlimited (fair use) |
| API 密钥 | 0 | 5 |