@cookiemunch/sdk 0.24.0 → 0.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +11 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/types.d.ts +11 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -20,7 +20,7 @@ import type { ConformanceReport } from './executor-conformance.js';
|
|
|
20
20
|
* This package's version, sent in the default User-Agent. Cloudflare answers a request with
|
|
21
21
|
* no recognisable User-Agent with `403 error code: 1010`; a test pins this to package.json.
|
|
22
22
|
*/
|
|
23
|
-
export declare const SDK_VERSION = "0.
|
|
23
|
+
export declare const SDK_VERSION = "0.25.0";
|
|
24
24
|
export interface CookieMunchOptions {
|
|
25
25
|
apiKey: string;
|
|
26
26
|
/** "https://api.cookiemunch.net" — the /v1 prefix is appended automatically. */
|
|
@@ -733,6 +733,11 @@ export interface ScanStatus {
|
|
|
733
733
|
lastScannedAt: number | null;
|
|
734
734
|
/** What the last scan saw of the live banner's Accept all / Reject all. Absent until measured. */
|
|
735
735
|
buttonParity?: ButtonParityScan;
|
|
736
|
+
/** Visitors' measurements per viewport class, when any reported. */
|
|
737
|
+
buttonParityByViewport?: {
|
|
738
|
+
desktop?: ButtonParityScan;
|
|
739
|
+
mobile?: ButtonParityScan;
|
|
740
|
+
};
|
|
736
741
|
/** Where the last scan is: `idle` when the site was never scanned (older servers left it out). */
|
|
737
742
|
state?: 'idle' | 'queued' | 'scanning' | 'done' | 'failed';
|
|
738
743
|
scanId?: string;
|
|
@@ -777,6 +782,11 @@ export interface ButtonParityScan {
|
|
|
777
782
|
/** 0–100; null when no banner was found. */
|
|
778
783
|
score: number | null;
|
|
779
784
|
checkedAt?: number;
|
|
785
|
+
/** Present when real visitors' browsers measured it (most distinct networks agree on each finding). */
|
|
786
|
+
source?: 'visitors';
|
|
787
|
+
viewport?: 'mobile' | 'desktop';
|
|
788
|
+
/** Distinct networks the findings were agreed over. */
|
|
789
|
+
reports?: number;
|
|
780
790
|
}
|
|
781
791
|
/** @deprecated The server returns {@link ScanStatus}; kept only for back-compat. */
|
|
782
792
|
export interface ScanResult {
|
package/dist/index.js
CHANGED