Docs / Refresh News Bot
Refresh News Bot
Refresh News Bot
POST/v1/account/news-bot/refresh
- Auth
- cookie session + X-Requested-With: cabinhub-console
- Cache-Control
no-store- Source of truth
clients/openapi.jsonanddocs/API.md§12
Rank the corpus against the stored brief, under both refresh limits.
Reads the current feed, selected desks, and matching indexed archive stories. Fresh coverage, when enabled and requested, is considered by the scheduler.
Description: clients/openapi.json
Parameters
| Name | In | Required | Type | Example | Notes |
|---|---|---|---|---|---|
X-Requested-With | header | no | string |
Example request
curl -sS -X POST \
'https://vg.tempproject.online/v1/account/news-bot/refresh' \
-H "Cookie: cbn_session=$NEWS_SESSION" \
-H "X-Requested-With: cabinhub-console"import json
import os
import urllib.request
URL = "https://vg.tempproject.online/v1/account/news-bot/refresh"
def call() -> dict:
req = urllib.request.Request(URL, method="POST", headers={
"Cookie": f"cbn_session={os.environ['NEWS_SESSION']}",
"X-Requested-With": "cabinhub-console",
})
with urllib.request.urlopen(req, timeout=15) as res:
print(res.status, res.headers.get("Location"))
text = res.read().decode("utf-8")
return json.loads(text) if text else {}
if __name__ == "__main__":
print(call())const res = await fetch(
"https://vg.tempproject.online/v1/account/news-bot/refresh",
{
method: "POST",
headers: {
cookie: `cbn_session=${process.env.NEWS_SESSION}`,
"x-requested-with": "cabinhub-console",
},
},
);
if (!res.ok) throw new Error(`${res.status} ${await res.text()}`);
console.log(res.headers.get("etag"), await res.json());The requests are generated from the path template and the parameters in clients/openapi.json, so a new parameter appears here without an edit to this site.
Example response
cache-control: no-store
content-type: application/octet-streamNo JSON body on this route; the headers are the ones docs/API.md §2 documents for it
Failures
This operation can answer 200, 400, 401, 422. The full envelope for each status, with its body, is on Errors.