Skip to main content
Use HotspotSystem through Corsair: one client, typed API calls. HotspotSystem runs Wi-Fi hotspots and reports who connected, how, and what they paid. This plugin wraps the v2 REST API. Generate an API key in the Control Center under Tools & Settings > API Keys, then store it as the account’s api_key. It is sent in the sn-apikey header. The docs also describe HTTP Basic with the key as the username and an empty password, which the plugin does not use, so the key never travels in the URL. Things to know before you call:
  • Every operation is a read. The documented API has 18 GET operations and no write, so nothing here changes state on the provider’s side and every call is safe to retry.
  • The account-wide reads and the per-location reads are different operations, not a filter. customers.list covers every location the key can see; locations.customers covers one. Both exist for customers, subscribers, vouchers and each of the four transaction types.
  • Paging uses limit and offset, and the next offset is in a response header. Each list returns next_offset when the API’s Link header names a next page, and omits it on the last page. Pass it back as offset to continue. The API cannot return the header and the body together through the shared client, so the paged reads use their own request that returns both.
  • fields and sort name properties of the response object. fields narrows the response to a comma separated list, which the plugin takes as an array. sort takes one property name, with a leading - for descending. A name the resource does not have is refused by the API rather than ignored.
  • Dates are 2013-05-21 17:53:39 strings. The notes page documents that format, and the transaction records use an ISO timestamp instead. Neither is converted, so both are string in the output.
  • A location ID can be a string or a number. The Swagger types it as a string, while every transaction record returns location_id as a number, so the per-location operations accept either.
  • Some transaction fields are documented only as TODO. The Swagger leaves every MacTransaction, PaidTransaction, SocialTransaction and VoucherTransaction field undocumented, so nothing on them is required and the values are passed through exactly as sent, including smscountry.
  • No pagination on locations.options. It returns every location as { id, name } with no metadata and no paging.
  • No inbound webhooks yet. HotspotSystem can POST customer.create, subscriber.create and transaction.*.create events to a callback URL set up in the Control Center, signed with an HMAC-SHA256 header. This plugin does not register a webhook route for them, so new records are read with the list operations.
What you get:
  • 18 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 first ten locations with just their ID and name
Read the account customers
See the full list on the API page.

What’s next

API reference

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