Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 0 additions & 16 deletions .changeset/event-discriminated-union.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/event-simulator-browser.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/webhook-type.md

This file was deleted.

20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
# Fingerprint Server API Node.js SDK

## 7.11.0

### Minor Changes

- **types**: ⚠️ Type-breaking change in generated TypeScript types for OpenAPI v3.11.0. No runtime change.

- `Event` is now a union of `EventDevice` and `EventEdge`, discriminated by `source`. Both are exported. Edge events ([Automation Intelligence API](https://docs.fingerprint.com/reference/automation-intelligence-api)) have no Identification, no `rule_action`, and none of the Smart Signals that need device data. They still have IP, proxy, VPN and bot detection.
- Code that reads device-only fields such as `event.identification` or `event.rule_action` no longer compiles. Check `source` first:

```ts
if (event.source === 'device') {
console.log(event.rule_action?.type)
}
```

- `source` is now required on `Event`. Objects typed as `Event` without `source` (for example, test fixtures) no longer compile. For webhook bodies, use the new `Webhook` type. ([4b1c846](https://github.com/fingerprintjs/node-sdk/commit/4b1c846a8e8f41f13e2a6a10baec950bbc58993b))

- **events**: `simulator` also flags Safari running inside the iOS Simulator, not only the native iOS SDK ([4b1c846](https://github.com/fingerprintjs/node-sdk/commit/4b1c846a8e8f41f13e2a6a10baec950bbc58993b))
- **webhooks**: Add `Webhook` type for webhook bodies. Same as `Event`, but `source` is optional on device events, because webhooks stored before `source` existed don't have it. ([4b1c846](https://github.com/fingerprintjs/node-sdk/commit/4b1c846a8e8f41f13e2a6a10baec950bbc58993b))

## 7.10.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@fingerprint/node-sdk",
"version": "7.10.0",
"version": "7.11.0",
"description": "Node.js wrapper for Fingerprint Server API",
"main": "dist/index.cjs",
"module": "dist/index.mjs",
Expand Down
Loading