@fanfare-io/fanfare-sdk-core 0.3.0 → 0.4.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/dist/storefront.d.ts +0 -36
- package/dist/storefront.js +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
package/dist/storefront.d.ts
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
import { JourneySnapshot } from './experiences/journey.types';
|
|
2
|
-
import { AdmissionProofHeaders } from './security/admission-proof';
|
|
3
|
-
export type { AdmissionProofHeaders } from './security/admission-proof';
|
|
4
2
|
/** Static key map backing AccessStatus. Order is stable; drives exhaustiveness tests. */
|
|
5
3
|
export declare const ACCESS_STATUSES: readonly ["unconfigured", "loading", "blocked", "available", "granted", "ended"];
|
|
6
4
|
/**
|
|
@@ -35,26 +33,6 @@ export interface ExperienceResolver {
|
|
|
35
33
|
handle: string;
|
|
36
34
|
}): string | null | Promise<string | null>;
|
|
37
35
|
}
|
|
38
|
-
export interface CheckoutProofParams {
|
|
39
|
-
/** The PUBLIC checkout URL the storefront is about to POST to — the proof binds to exactly this URL. */
|
|
40
|
-
checkoutUrl: string;
|
|
41
|
-
/** Defaults to "POST". */
|
|
42
|
-
method?: string;
|
|
43
|
-
}
|
|
44
|
-
/**
|
|
45
|
-
* Mints the binding-proof headers for one checkout request: a DPoP JWS signed
|
|
46
|
-
* by this browser's persistent admission key over the GATE's public checkout
|
|
47
|
-
* URL, plus the key-thumbprint header. FRESH per call (new jti + iat) — call it
|
|
48
|
-
* again for every request, including retries the storefront issues itself; never
|
|
49
|
-
* reuse a previous result.
|
|
50
|
-
*
|
|
51
|
-
* Spread the returned headers into the `POST <checkoutUrl>` request alongside
|
|
52
|
-
* the claimed grant's token. Resolves `null` where persistent browser crypto is
|
|
53
|
-
* unavailable (SSR, no IndexedDB): post without proof headers — an unbound
|
|
54
|
-
* credential needs none, and a key-bound credential will be refused by the
|
|
55
|
-
* authority rather than the storefront guessing.
|
|
56
|
-
*/
|
|
57
|
-
export declare function buildCheckoutProofHeaders(params: CheckoutProofParams): Promise<AdmissionProofHeaders | null>;
|
|
58
36
|
export interface GrantRecord {
|
|
59
37
|
/**
|
|
60
38
|
* The client-visible grant value the adapter records when the shopper clears
|
|
@@ -71,20 +49,6 @@ export interface GrantRecord {
|
|
|
71
49
|
experienceId: string;
|
|
72
50
|
/** ms timestamp; absent = no client-side expiry known. */
|
|
73
51
|
expiresAt?: number;
|
|
74
|
-
/**
|
|
75
|
-
* @deprecated Reserved. Handoff tokens bridge active sessions (mint from the
|
|
76
|
-
* sequence capability grant, redeem single-use) and are not part of the
|
|
77
|
-
* admission/checkout verification contract, which is driven by the admission
|
|
78
|
-
* credential. Kept because the field is pinned by the published surface; do
|
|
79
|
-
* not wire new behavior to it.
|
|
80
|
-
*/
|
|
81
|
-
capabilityGrant?: string;
|
|
82
|
-
/**
|
|
83
|
-
* @deprecated Reserved. See `capabilityGrant` — checkout admission is enforced
|
|
84
|
-
* through the platform verifier/proxy using the admission credential, not via
|
|
85
|
-
* a handoff token. Do not wire new behavior to it.
|
|
86
|
-
*/
|
|
87
|
-
handoffToken?: boolean;
|
|
88
52
|
}
|
|
89
53
|
export interface VerificationResult {
|
|
90
54
|
ok: boolean;
|
package/dist/storefront.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const e=["unconfigured","loading","blocked","available","granted","ended"];function a(e){if(null===e)return"loading";switch(e.journeyStage){case"ready":case"routing":return"loading";case"gated":return"blocked";case"routed":switch(e.sequence.phase){case"enterable":return"available";case"scheduled":default:return"blocked";case"granted":return"granted";case"ended":case"unavailable":return"ended"}}}export{e as ACCESS_STATUSES,a as snapshotToAccessStatus};
|
package/dist/version.d.ts
CHANGED
package/dist/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const o="0.
|
|
1
|
+
const o="0.4.0";export{o as version};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fanfare-io/fanfare-sdk-core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "Official Fanfare Browser SDK for queue, draw, auction, and appointment experiences",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org",
|
|
@@ -122,7 +122,7 @@
|
|
|
122
122
|
"uuid": "^14.0.0",
|
|
123
123
|
"wretch": "^2.11.0",
|
|
124
124
|
"zustand": "^5.0.6",
|
|
125
|
-
"@fanfare-io/fanfare-sdk-contracts": "0.
|
|
125
|
+
"@fanfare-io/fanfare-sdk-contracts": "0.4.0"
|
|
126
126
|
},
|
|
127
127
|
"peerDependencies": {
|
|
128
128
|
"valibot": "^1.1.0",
|
|
@@ -165,7 +165,7 @@
|
|
|
165
165
|
"vite-plugin-dts": "^4.5.4",
|
|
166
166
|
"vite-tsconfig-paths": "^5.1.4",
|
|
167
167
|
"vitest": "^3.2.4",
|
|
168
|
-
"@fanfare-io/shared-models": "0.
|
|
168
|
+
"@fanfare-io/shared-models": "0.4.0"
|
|
169
169
|
},
|
|
170
170
|
"sideEffects": false,
|
|
171
171
|
"keywords": [
|