- Two-step auth.
POST /thirdparty/v1/user/apiloginexchanges{ userId, apiKey }for atoken, and every other call sendsAuthorization: bearer <token>— the wordbearerlowercased, as Wachete’s own docs write it. The plugin accepts a packed<userId>\n<apiKey>key and does the login itself, caching the token until it expires, or a bare token if you already have one. - Creating and updating are one call, but the two use different methods.
tasks.upsertis aPUTon the collection andfolders.upsertis aPOSTon the same collection; in both, the body’siddecides between creating and updating, not the route. - The enums are ambiguous, and the plugin accepts both forms. Wachete’s OpenAPI document declares alert, job and messaging types as integers, but that same document’s own example payload sends names (
"Error","NotEq","Webhook","SinglePage") and the prose docs do too. The plugin accepts a name or the number and sends what you give it, so either contract works. - Alert names.
Error,Changed,NotEq,Eq,Contains,NotContains,StartsWith,EndsWith,Regex,Lower,Greater,Exists,NotExists. Messaging names:Email,Webhook,Sms,Slack,Teams,Telegram,Pushover,Discord. - A
SinglePagemonitor takes no crawling settings.crawlingDepth,urlFilter,crawlBinaryContentandcrawlPagesFromAllDomainsonly apply to aPortalmonitor, so sending them on aSinglePageone is rejected before the request rather than silently ignored. tasks.searchsits after/task/{id}in the API’s path table. A router that matched{id}first would treat “search” as a monitor id; Wachete’s own routing resolves it, and the plugin calls/task/searchexplicitly.- Deleting a folder deletes its contents.
folders.deleteremoves every subfolder and monitor inside it, which makes it the most destructive call here — far more thantasks.delete, which removes one monitor. - The last value lives in
data. A monitor’sdata.rawis what the last check read,data.valueChangedTimestampis when it last differed, anddata.erroris set when the check failed — so a monitor can befailedCountwithout any notification arriving. - History and notifications page by continuation token. Both answer
continuationToken, which is null on the last page.data.listcan return a Google-style diff per entry withreturnDiff, which is much larger than the raw values. notifications.getcarries the sent HTML. It answers JSON with the monitor’sname,url,timestampUtcand the alert as thehtmlthat was sent. The plugin’s event log records the HTML’s length, never its content, which is the watched page’s text.
- 12 typed API operations
Setup
1
Install
2
Add the plugin
corsair.ts
multiTenancy: true, scope calls with corsair.withTenant(id). See Quick start for KEK + Hub keys, and Multi-tenancy for account isolation.3
Choose authentication
- API Key (Recommended)
No setup required yet. When you make your first request as a tenant, Corsair prompts for the API key.More: API Key
4
Connect a tenant
Mint a connect link and send the tenant to it. Hub hosts the page and delivers the result to your app — see Connect / OAuth.
Example API calls
Read a monitorWhat’s next
API reference
Every
wachete.api.* operation with input and output types.Connect / OAuth
createLink, Hub delivery, and tenant connect flows.
Use with agents
Expose this plugin’s operations as MCP tools.