75trust / 100
Social Thread
by api.x-402.online in News & content
x402 APIPassing, checked 3 h ago
Get one Hacker News or Lemmy thread: the post with its text and the comments flattened with depth and score. One community thread by id from /v1/social/search (hn:<id> or lemmy:<id>): the post with its text and the comments flattened with depth, score and author. Query: ?id=hn:49806046&limit=50
GET https://api.x-402.online/v1/social/thread
Last 30 days
All checks passedSome failedAll failedNot checked
- Uptime
- 100%
- Response time
- 394 ms typical, 430 ms slowest 5%
- Last check
- 3 h ago
- Next check
- any minute now
How to call it
# See the payment challenge (nothing is charged)
curl -i -X GET "https://api.x-402.online/v1/social/thread?id=hn%3A1&limit=20"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%2Fapi.x-402.online%2Fv1%2Fsocial%2Fthread
const res = await pay("https://api.x-402.online/v1/social/thread?id=hn%3A1&limit=20");
console.log(await res.json());Example input
{
"id": "hn:1",
"limit": 20
}Example output
{
"comment_count": 12,
"comments": [
{
"author": "…",
"body": "…",
"depth": 0,
"score": 3
}
],
"post": {
"score": 57,
"source": "hackernews",
"title": "…"
}
}Security scan
- No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 3 h ago | Passed | 402 | 380 ms | $0.02 |
| 6 h ago | Passed | 402 | 395 ms | $0.02 |
| 10 h ago | Passed | 402 | 430 ms | $0.02 |
| 13 h ago | Passed | 402 | 361 ms | $0.02 |
| 17 h ago | Passed | 402 | 568 ms | $0.02 |
| 21 h ago | Passed | 402 | 419 ms | $0.02 |
| 24 h ago | Passed | 402 | 368 ms | $0.02 |
| 28 h ago | Passed | 402 | 361 ms | $0.02 |
| 32 h ago | Passed | 402 | 394 ms | $0.02 |
| 35 h ago | Passed | 402 | 402 ms | $0.02 |
| 40 h ago | Passed | 402 | 328 ms | $0.02 |