/api/v1/accounting/hike/start
auth: jwt (administrator) + connector licence gateBegin a Hike OAuth2 authorisation flow. Returns the Hike authorisation URL. Rate-limited (10/min `open` bucket).
handlers: HikeAuthController.start
No parameters.
APIResponseDataObject<HikeStartResponse>APIErrorAPIError/api/v1/accounting/hike/callback
auth: none (Hike-initiated browser redirect)Hike redirects the operator's browser here after consent. Validates `state`, exchanges `code`, upserts the store connection, then redirects to the app deep link (302 on desktop browsers; on mobile an HTML bridge page that navigates to the deep link). On failure the redirect carries a sanitised error code, never the message. Mounted without the JWT guard because no app session exists on this request.
handlers: HikeAuthController.callback
| name | required | default | description |
|---|---|---|---|
code querystring | no | — | Authorisation code from Hike. |
state querystring | no | — | OAuth state issued by `/start`. |
error querystring | no | — | Hike error code when consent failed. |
emptytext/html/api/v1/accounting/hike/status
auth: jwt (any authenticated member of the business)Connection summary: every Hike store connection (no tokens), outlet filter list, `autoFiscaliseInvoices`, `autoFiscaliseConnector`, `syncFromDate`.
handlers: HikeAuthController.status
No parameters.
APIResponseDataObject<HikeStatusResponse>APIError/api/v1/accounting/hike/connections/:connectionId
auth: jwt (administrator)Disconnect ONE Hike store. Per connection, never business-wide: a business may hold several Hike stores.
handlers: HikeAuthController.disconnect
| name | required | default | description |
|---|---|---|---|
connectionId pathstring (uuid) | yes | — | Hike connection id (one per Hike store). |
APIResponseDataObject<{ deactivatedCount: number }>APIError/api/v1/accounting/hike/connections/:connectionId/outlets/sync
auth: jwt (administrator); 10/min rate limit (`open` bucket)Refresh the outlet catalogue from Hike for one connection. An outlet with no mapped Location BLOCKS its sales rather than inheriting a default.
handlers: HikeAuthController.syncOutlets
| name | required | default | description |
|---|---|---|---|
connectionId pathstring (uuid) | yes | — | Hike connection id (one per Hike store). |
APIResponseDataObject<HikeOutletSyncResult>APIErrorAPIErrorAPIError/api/v1/accounting/hike/connections/:connectionId/outlets
auth: jwt (administrator)List the connection's Hike outlets with their mapped VSMS Location (if any).
handlers: HikeAuthController.listOutlets
| name | required | default | description |
|---|---|---|---|
connectionId pathstring (uuid) | yes | — | Hike connection id (one per Hike store). |
APIResponseDataList<object>APIErrorAPIError/api/v1/accounting/hike/connections/:connectionId/outlets/:outletId/location
auth: jwt (administrator)Assign (or clear) the VSMS Location for one Hike outlet. `locationId: null` clears the mapping, which BLOCKS that outlet's sales.
handlers: HikeAuthController.setOutletLocation
| name | required | default | description |
|---|---|---|---|
connectionId pathstring (uuid) | yes | — | Hike connection id (one per Hike store). |
outletId pathstring | yes | — | Hike's own outlet id (not validated as a UUID). |
locationId bodystring (uuid) | null | yes | — | Location to map; `null` clears. Required — omission is rejected. |
APIResponseDataObject<object>APIErrorAPIError/api/v1/accounting/hike/outlets/resync-blocked
auth: jwt (administrator)Re-sync Hike invoices blocked by outlet routing (LOCATION_NOT_MAPPED / LOCATION_CERTIFICATE_MISSING) and dispatch the ones that can now be signed. BUSINESS-WIDE (no `:connectionId`): the same pass the dashboard action runs. Clears only the two location reasons. Runs in the background: replies `202 { runId }` at once and stores the outcome on the run. The finished run's `result` is an `APIResponseDataObject` of the re-sync counts (`reprocessed`, `nowEligible`, `nowEligibleInvoices`, `nowEligibleQuotes`, `stillBlocked`, `autoFiscalisationJobIds`).
handlers: HikeAuthController.resyncOutletBlocked
No parameters.
APIResponseDataObject<BackgroundRunAcceptedDTO>APIErrorAPIErrorAPIError/api/v1/accounting/hike/registers/sync
auth: jwt (administrator); 10/min rate limit (`open` bucket)Sync Hike registers as print tills. BUSINESS-WIDE (no `:connectionId`): the Receipt Printers tab is scoped per connector, so one call refreshes every Hike store's tills.
handlers: HikeAuthController.syncRegisters
No parameters.
APIResponseDataObject<HikeRegisterSyncResult>APIErrorAPIErrorAPIError/api/v1/accounting/hike/register-tills
auth: jwt (administrator)List Hike register tills grouped by outlet, business-wide.
handlers: HikeAuthController.listRegisterTills
No parameters.
APIResponseDataList<object>APIErrorAPIError/api/v1/accounting/hike/connections/:connectionId/sync
auth: jwt (administrator | view_invoices | submit_invoices)Manual Sync Now for ONE Hike store (per connection, not per business). Pulls sales, normalises and persists to `Invoices` (`Source='hike'`); with auto-fiscalise on, newly-inserted eligible invoices are dispatched as fiscalisation jobs. Both query params omitted = resume from the connection's own watermark. `modifiedSince` is a one-off lower bound that wins over the watermark and is not persisted; `dateTo` bounds the run and stops the watermark advancing. The response message is `fetched=X inserted=Y duplicates=Z laybyPayments=N refundsLinked=M[ jobIds=...]`. Runs in the background: replies `202 { runId }` at once and stores the outcome on the run. The finished run's `result` is the old synchronous body: `APIResponseDataObject<SyncHikeInvoicesResult>` with the counters `message`.
handlers: HikeAuthController.syncInvoices
| name | required | default | description |
|---|---|---|---|
connectionId pathstring (uuid) | yes | — | Hike connection id (one per Hike store). |
modifiedSince queryYYYY-MM-DD | ISO-8601 datetime | no | — | Lower bound; a bare date is a wall-clock date in the store's timezone. |
dateTo queryYYYY-MM-DD | ISO-8601 datetime | no | — | Upper bound of the run; same format as `modifiedSince`. |
APIResponseDataObject<BackgroundRunAcceptedDTO>APIErrorAPIErrorAPIError/api/v1/accounting/hike/sync-all
auth: jwt (administrator | view_invoices | submit_invoices)Sync All for Hike: syncs the listed connections one after another in ONE background run, never two at once, so a multi-store backlog does not load the provider or the database in parallel. Each connection takes its own sync lock as it is reached; one already syncing is reported `skipped`, and one failing does not stop the rest. Replies `202 { runId }`; the finished run's `result` is an `APIResponseDataObject<SyncAllResultDTO>` whose `connections[]` hold each connection's status and the body its single Sync Now would have returned.
handlers: HikeAuthController.syncAllInvoices
| name | required | default | description |
|---|---|---|---|
connectionIds bodyuuid[] (1-50) | yes | — | The connections to sync, in order. |
modifiedSince bodystring | no | — | Optional lower bound, same format as the single-connection sync. |
dateTo bodystring | no | — | Optional upper bound, same format as the single-connection sync. |
APIResponseDataObject<BackgroundRunAcceptedDTO>APIErrorAPIError/api/v1/accounting/hike/tax-mappings
auth: jwt (administrator)List all per-business Hike tax-id → V-SDC label mappings (`Provider='hike'`), active and deactivated.
handlers: HikeTaxMappingsController.list
No parameters.
APIResponseDataList<TaxRateMappingDTO>APIError/api/v1/accounting/hike/tax-mappings/seed
auth: jwt (administrator)Pull the Hike tax catalogue for one connection and seed unmapped rows. Rate-limited (10/min `open` bucket).
handlers: HikeTaxMappingsController.seed
| name | required | default | description |
|---|---|---|---|
connectionId bodystring (uuid) | yes | — | Connection whose taxes to pull. |
APIResponseDataObject<HikeTaxSeedResult>APIErrorAPIError/api/v1/accounting/hike/tax-mappings
auth: jwt (administrator)Create or update one Hike tax mapping. `vsdcTaxLabel` is validated against the business's LIVE V-SDC label set.
handlers: HikeTaxMappingsController.upsert
| name | required | default | description |
|---|---|---|---|
providerTaxType bodystring | yes | — | Hike tax id as a string. |
providerTaxName bodystring | null | no | — | Human-readable Hike tax name. |
providerRate bodynumber | null | no | — | Hike tax rate. |
vsdcTaxLabel bodystring | yes | — | V-SDC label. |
vsdcRate bodynumber | null | no | — | V-SDC rate percent. |
APIResponseDataObject<TaxRateMappingDTO>APIErrorAPIError/api/v1/accounting/hike/tax-mappings/:providerTaxType
auth: jwt (administrator)Soft-delete (`IsActive = 0`, row retained).
handlers: HikeTaxMappingsController.remove
| name | required | default | description |
|---|---|---|---|
providerTaxType pathstring | yes | — | Hike's own tax id as a string (immutable key; never the editable tax name). |
emptyAPIError/api/v1/accounting/hike/tax-mappings/:providerTaxType/restore
auth: jwt (administrator)Re-activate a deactivated mapping (`IsActive = 1`).
handlers: HikeTaxMappingsController.restore
| name | required | default | description |
|---|---|---|---|
providerTaxType pathstring | yes | — | Hike's own tax id as a string (immutable key; never the editable tax name). |
emptyAPIError/webhooks/hike/:connectionId/:hash
auth: none — the URL HMAC (`:hash`) is the credentialHike-initiated webhook delivery. Hike sends no signature, so `:hash` is verified (constant-time) against the connection id; a mismatch answers a bare 403 and writes a `HIKE_WEBHOOK_AUTH_FAILED` audit. A valid delivery is acked 200 BEFORE any work, then the sale id is enqueued on the Hike webhook Redis Stream for `HikeWebhookWorker`. Hike wraps the payload in a single top-level key named after the event (e.g. `Invoice_Created`); an unreadable body is acked and dropped.
handlers: HikeWebhookController.handle
| name | required | default | description |
|---|---|---|---|
connectionId pathstring | yes | — | Hike connection id. |
hash pathstring | yes | — | HMAC of the connection id; the only credential. |
emptyempty/api/v1/accounting/hike/connections/:connectionId/outlets/:outletId/reject
auth: jwt (administrator)Decline a discovered Hike outlet; its sales are held exactly like an unmapped outlet's. Refused while the outlet is mapped — clear the mapping first. Idempotent when already rejected.
handlers: HikeAuthController.rejectOutlet
| name | required | default | description |
|---|---|---|---|
connectionId pathstring (uuid) | yes | — | Hike connection id (one per Hike store). |
outletId pathstring | yes | — | Hike's own outlet id (1-100 chars, not validated as a UUID). |
APIResponseDataObject<object>APIErrorAPIErrorAPIError/api/v1/accounting/hike/connections/:connectionId/outlets/:outletId/accept
auth: jwt (administrator)Accept a previously rejected Hike outlet back: it returns to the ordinary unmapped state for the admin to map. Nothing is released by accepting; held sales are freed by the re-sync once a Location is assigned. No-op for an outlet that is not rejected.
handlers: HikeAuthController.acceptOutlet
| name | required | default | description |
|---|---|---|---|
connectionId pathstring (uuid) | yes | — | Hike connection id (one per Hike store). |
outletId pathstring | yes | — | Hike's own outlet id (1-100 chars, not validated as a UUID). |
APIResponseDataObject<object>APIErrorAPIErrorAPIError