From 07c1e4e1bafeff64d0b96bd8154a0d015d00cce3 Mon Sep 17 00:00:00 2001 From: Gregory Oschwald Date: Wed, 22 Apr 2026 21:24:49 +0000 Subject: [PATCH] Add `CLEAR` to the `Tag` enum Part of STF-190. The `clear` tag retracts a previously reported fraud report tag on a transaction, restoring its label to "unknown" (distinct from the positive `not_fraud` signal). Backend support shipped in STF-15; this adds SDK support. Co-Authored-By: Claude Opus 4.7 (1M context) --- CHANGELOG.md | 1 + src/constants.ts | 1 + src/request/transaction-report.spec.ts | 9 +++++++++ 3 files changed, 11 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d3c4c31b..e3ea4690 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ CHANGELOG for explicit device linking. You may provide this by providing `trackingToken` to `Device`. * Added `FatZebra` to the `Processor` enum. +* Added `CLEAR` to the `Tag` enum for use with the Report Transaction API. 8.3.0 (2026-01-20) ------------------ diff --git a/src/constants.ts b/src/constants.ts index 9f41765b..80f351a6 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -207,6 +207,7 @@ export enum Processor { export enum Tag { CHARGEBACK = 'chargeback', + CLEAR = 'clear', NOT_FRAUD = 'not_fraud', SPAM_OR_ABUSE = 'spam_or_abuse', SUSPECTED_FRAUD = 'suspected_fraud', diff --git a/src/request/transaction-report.spec.ts b/src/request/transaction-report.spec.ts index f9201c21..7454fdcc 100644 --- a/src/request/transaction-report.spec.ts +++ b/src/request/transaction-report.spec.ts @@ -60,4 +60,13 @@ describe('Device()', () => { }); }).not.toThrow(); }); + + it('accepts the clear tag', () => { + expect(() => { + new TransactionReport({ + ipAddress: '1.1.1.1', + tag: Tag.CLEAR, + }); + }).not.toThrow(); + }); });