Skip to main content
Use NetHunt CRM through Corsair: one client, typed API calls. NetHunt’s API needs two credentials. The email is the account address and the API key is the legacy key from NetHunt’s Settings, Apps and other integrations, API key (LEGACY), Generate. The newer nh_live_ tokens under Settings, API & MCP answer 401 on these routes (checked live 2026-11-17). Both are stored on the account: the plugin sends them as HTTP Basic auth, where the email is the username and the key is the password. Set both before the first call, for example pnpm corsair setup --plugin=nethunt --tenant=acme api_key=<key> email=<you@example.com>, or pass key and email in the plugin options. account.verify confirms the pair works and returns the user behind it. What to know before you write:
  • Folders hold user-defined fields. folders.list gives the ids, and folders.fields gives the names a create or update may set. There are no fixed columns, so call both before building a field map.
  • A create and an update take different shapes. records.create takes a flat fields map plus a required timeZone, which NetHunt needs to interpret date values. records.update takes fieldActions, one entry per field, each able to overwrite, remove or add. Combining overwrite with remove is rejected here because NetHunt forbids it.
  • A delete goes over POST and answers {}. So does linking a Gmail thread. Both return a small result the plugin derives from the call that succeeded, rather than from a body that carries nothing.
  • records.changes is the only route that reports a delete. Each change lists, per field, the values removed (remove) and added (add), and the user who made it as { personalName, emailAddress }. It is a change log, not a snapshot history: it has no full before and after values.
  • Reads page by time, not by offset. records.recent and records.updated default their window to 24 hours and take a since instant. NetHunt takes fieldName repeatedly for one call, which the plugin sends as separate parameters.
Worth knowing:
  • NetHunt sends no error codes. A bad email or key is a 401 with a plain-text body, not JSON. A missing folder or record is a 404 with an empty body. The plugin reads both.
  • A 5xx on a write is never retried. NetHunt takes no idempotency key, so a retried create or update can double up. A 5xx on a read is retried twice.
What you get:
  • 16 typed API operations

Setup

1

Install

2

Add the plugin

corsair.ts
With multiTenancy: true, scope calls with corsair.withTenant(id). See Quick start for KEK + Hub keys, and Multi-tenancy for account isolation.
3

Choose authentication

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

List the folders this account can read
Create a record in a folder
See the full list on the API page.

What’s next

API reference

Every nethunt.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.