@nokinc-flur/sdk 2.4.0 → 3.0.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/README.md +17 -17
- package/dist/index.cjs +3 -5216
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +369 -204
- package/dist/index.d.ts +369 -204
- package/dist/index.js +3 -4937
- package/dist/index.js.map +1 -1
- package/openapi/flur.openapi.json +167 -7
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -832,7 +832,8 @@ type OnboardingCompleteInput = {
|
|
|
832
832
|
fingerprintHash?: string;
|
|
833
833
|
};
|
|
834
834
|
type OnboardingCompleteResponse = {
|
|
835
|
-
|
|
835
|
+
accessToken: string;
|
|
836
|
+
refreshToken: string;
|
|
836
837
|
userId: string;
|
|
837
838
|
restricted: boolean;
|
|
838
839
|
risk_reasons: OnboardingRiskReason[];
|
|
@@ -845,7 +846,7 @@ type RegisterDeviceInput = {
|
|
|
845
846
|
platform: string;
|
|
846
847
|
model?: string;
|
|
847
848
|
networkSignals: {
|
|
848
|
-
ip
|
|
849
|
+
ip?: string;
|
|
849
850
|
asn?: number;
|
|
850
851
|
country?: string;
|
|
851
852
|
carrier?: string;
|
|
@@ -866,6 +867,7 @@ type AuthRefreshInput = {
|
|
|
866
867
|
fingerprintHash: string;
|
|
867
868
|
};
|
|
868
869
|
type AuthRefreshResponse = {
|
|
870
|
+
accessToken: string;
|
|
869
871
|
refreshToken: string;
|
|
870
872
|
stepUpRequired: boolean;
|
|
871
873
|
};
|
|
@@ -1000,7 +1002,12 @@ type SendMoneyInput = {
|
|
|
1000
1002
|
recipientIdentifier: string;
|
|
1001
1003
|
money: Money;
|
|
1002
1004
|
sendAuthToken: string;
|
|
1003
|
-
|
|
1005
|
+
/**
|
|
1006
|
+
* Stable, caller-owned idempotency key. REQUIRED: generate one per logical
|
|
1007
|
+
* transfer and reuse it across retries so a dropped response can never settle
|
|
1008
|
+
* the same transfer twice.
|
|
1009
|
+
*/
|
|
1010
|
+
idempotencyKey: string;
|
|
1004
1011
|
defaultCountry?: string;
|
|
1005
1012
|
};
|
|
1006
1013
|
type SendMoneyOptions = AuthorizedOptions & {
|
|
@@ -2207,18 +2214,6 @@ declare function verifyRequestHMAC(input: {
|
|
|
2207
2214
|
signature: string;
|
|
2208
2215
|
}): boolean;
|
|
2209
2216
|
|
|
2210
|
-
declare const REPLAY_WINDOW_MS: number;
|
|
2211
|
-
type HmacFetchOptions = {
|
|
2212
|
-
apiKey: string;
|
|
2213
|
-
apiSecret: string;
|
|
2214
|
-
fetchImpl?: typeof fetch;
|
|
2215
|
-
nowMs?: () => number;
|
|
2216
|
-
nonceFn?: () => string;
|
|
2217
|
-
/** Optional scope claim forwarded as `X-Flur-Scope` (comma-joined). Backend remains authoritative. */
|
|
2218
|
-
scope?: readonly string[];
|
|
2219
|
-
};
|
|
2220
|
-
declare function createHmacFetch(opts: HmacFetchOptions): typeof fetch;
|
|
2221
|
-
|
|
2222
2217
|
declare const PASS_KINDS: readonly ["ride-ticket", "transit-pass", "event-ticket", "voucher", "loyalty", "receipt-link"];
|
|
2223
2218
|
type PassKind = (typeof PASS_KINDS)[number];
|
|
2224
2219
|
declare const PASS_STATES: readonly ["issued", "active", "redeemed", "expired", "revoked"];
|
|
@@ -2653,7 +2648,10 @@ declare function verifyReceipt(r: Receipt, issuerPublicKeySpkiB64: string): bool
|
|
|
2653
2648
|
|
|
2654
2649
|
type PassesClientOptions = {
|
|
2655
2650
|
baseUrl: string;
|
|
2656
|
-
/**
|
|
2651
|
+
/**
|
|
2652
|
+
* Pre-configured fetch that signs partner requests. Use the fetch returned by
|
|
2653
|
+
* `createFlurPartnerClient(...)` (Flur-Hmac scheme). Falls back to global fetch.
|
|
2654
|
+
*/
|
|
2657
2655
|
fetchImpl?: typeof fetch;
|
|
2658
2656
|
};
|
|
2659
2657
|
type IssuePassInput = {
|
|
@@ -2878,6 +2876,331 @@ type AccountsClient = {
|
|
|
2878
2876
|
};
|
|
2879
2877
|
declare function createAccountsClient(opts: AccountsClientOptions): AccountsClient;
|
|
2880
2878
|
|
|
2879
|
+
/**
|
|
2880
|
+
* Offline verification of the unified Offline Authorization Certificate (OAC).
|
|
2881
|
+
*
|
|
2882
|
+
* The OAC is issuer-signed and folds identity (phoneE164, displayName, bound
|
|
2883
|
+
* device key) into the same credential that carries offline spend authority.
|
|
2884
|
+
* This lets two users who meet for the first time recognise and pay each
|
|
2885
|
+
* other WITHOUT a network round-trip: the verifier checks the issuer
|
|
2886
|
+
* signature against a *pinned* trusted issuer key (a Trust Bundle refreshed
|
|
2887
|
+
* whenever the device is online), never the key embedded in the credential.
|
|
2888
|
+
*
|
|
2889
|
+
* Trust model:
|
|
2890
|
+
* - Provisional offline authorization, authoritative online settlement.
|
|
2891
|
+
* A successful offline verify proves the credential was issued by Flur
|
|
2892
|
+
* and is within its validity window; the backend still re-checks
|
|
2893
|
+
* revocation, balance, and caps at settlement. Short OAC TTL is the
|
|
2894
|
+
* revocation-propagation mechanism — a revoked user cannot refresh and
|
|
2895
|
+
* their OAC expires within the issuance TTL.
|
|
2896
|
+
*
|
|
2897
|
+
* Wire format mirrors `flur-backend/src/offline-consumer/service.ts`
|
|
2898
|
+
* (`oacSigningPayload`): the issuer signs `canonicalJSONBytes({ domain, ...oac })`
|
|
2899
|
+
* with its P-256 key. Adding fields to `ConsumerOAC` automatically includes
|
|
2900
|
+
* them in the signed bytes, so identity is covered without a new domain.
|
|
2901
|
+
*/
|
|
2902
|
+
|
|
2903
|
+
/**
|
|
2904
|
+
* Domain tag bound into the OAC issuer signature. MUST match
|
|
2905
|
+
* `OAC_DOMAIN` in `flur-backend/src/offline-consumer/service.ts`.
|
|
2906
|
+
*/
|
|
2907
|
+
declare const CONSUMER_OAC_DOMAIN: "flur:consumer-offline:v1:oac";
|
|
2908
|
+
/**
|
|
2909
|
+
* A pinned issuer key the device trusts for offline OAC verification.
|
|
2910
|
+
* Sourced from the backend Trust Bundle (`GET /v1/issuer/keys`) and cached
|
|
2911
|
+
* on-device. `notBeforeMs` / `notAfterMs` bound the key's own validity so a
|
|
2912
|
+
* rotated-out key cannot be used to verify a freshly minted credential.
|
|
2913
|
+
*/
|
|
2914
|
+
interface TrustedIssuerKey {
|
|
2915
|
+
issuerId: string;
|
|
2916
|
+
/** Issuer P-256 public key as SubjectPublicKeyInfo DER, base64. */
|
|
2917
|
+
publicKeySpkiB64: string;
|
|
2918
|
+
notBeforeMs?: number;
|
|
2919
|
+
notAfterMs?: number;
|
|
2920
|
+
}
|
|
2921
|
+
/** Identity surfaced to the caller after a successful offline verify. */
|
|
2922
|
+
interface OacOfflineIdentity {
|
|
2923
|
+
oacId: string;
|
|
2924
|
+
issuerId: string;
|
|
2925
|
+
userId: string;
|
|
2926
|
+
phoneE164: string;
|
|
2927
|
+
displayName: string;
|
|
2928
|
+
/** Holder's bound device key; lets the caller verify receipts offline. */
|
|
2929
|
+
devicePubkeySpkiB64: string;
|
|
2930
|
+
}
|
|
2931
|
+
type VerifyOacOfflineResult = {
|
|
2932
|
+
ok: true;
|
|
2933
|
+
oac: ConsumerOAC;
|
|
2934
|
+
identity: OacOfflineIdentity;
|
|
2935
|
+
} | {
|
|
2936
|
+
ok: false;
|
|
2937
|
+
reason: 'malformed' | 'untrusted_issuer' | 'signature_invalid' | 'window_too_long' | 'not_yet_valid' | 'expired' | 'revoked';
|
|
2938
|
+
};
|
|
2939
|
+
interface VerifyOacOfflineOptions {
|
|
2940
|
+
/** Override the wall clock; defaults to `Date.now()`. */
|
|
2941
|
+
nowMs?: number;
|
|
2942
|
+
/**
|
|
2943
|
+
* Verified revoked-OAC id set from a pinned revocation status-list (see
|
|
2944
|
+
* `verifyRevocationList`). When supplied, an otherwise-valid OAC whose
|
|
2945
|
+
* `oacId` is present is rejected with reason `'revoked'`. Omitting this
|
|
2946
|
+
* preserves the TTL-only revocation baseline.
|
|
2947
|
+
*/
|
|
2948
|
+
revokedOacIds?: ReadonlySet<string>;
|
|
2949
|
+
}
|
|
2950
|
+
/** Canonical OAC payload (domain-bound) the backend issuer signs. */
|
|
2951
|
+
declare function consumerOacSigningPayload(oac: ConsumerOAC): {
|
|
2952
|
+
phoneE164: string;
|
|
2953
|
+
userId: string;
|
|
2954
|
+
deviceId: string;
|
|
2955
|
+
displayName: string;
|
|
2956
|
+
currency: string;
|
|
2957
|
+
perTxCapKobo: number;
|
|
2958
|
+
cumulativeCapKobo: number;
|
|
2959
|
+
validFromMs: number;
|
|
2960
|
+
validUntilMs: number;
|
|
2961
|
+
counterSeed: number;
|
|
2962
|
+
issuedAtMs: number;
|
|
2963
|
+
issuerId: string;
|
|
2964
|
+
oacId: string;
|
|
2965
|
+
alg: "p256";
|
|
2966
|
+
devicePubkeySpkiB64: string;
|
|
2967
|
+
domain: "flur:consumer-offline:v1:oac";
|
|
2968
|
+
};
|
|
2969
|
+
/**
|
|
2970
|
+
* Verify a signed OAC offline against a pinned set of trusted issuer keys.
|
|
2971
|
+
*
|
|
2972
|
+
* Security invariants:
|
|
2973
|
+
* - The signature is checked against the PINNED key for `oac.issuerId`,
|
|
2974
|
+
* never the credential-embedded `issuerPublicKeySpkiB64`. An attacker who
|
|
2975
|
+
* forges an OAC with their own key (and a matching embedded key) fails
|
|
2976
|
+
* because their key is not pinned.
|
|
2977
|
+
* - The pinned key's own validity window is enforced.
|
|
2978
|
+
* - The OAC validity window is enforced (`validFromMs <= now < validUntilMs`).
|
|
2979
|
+
*/
|
|
2980
|
+
declare function verifyOacOffline(signed: SignedConsumerOAC, trustedKeys: readonly TrustedIssuerKey[], options?: VerifyOacOfflineOptions): VerifyOacOfflineResult;
|
|
2981
|
+
/**
|
|
2982
|
+
* QR prefix for a presented unified OAC. A holder shows this QR to be paid
|
|
2983
|
+
* and/or identified offline; the scanner decodes it and calls
|
|
2984
|
+
* `verifyOacOffline` against its pinned trust bundle. Distinct from the
|
|
2985
|
+
* settlement-receipt (`FLURSR1.`) and pay-card prefixes so the scanner can
|
|
2986
|
+
* dispatch by prefix without ambiguity.
|
|
2987
|
+
*/
|
|
2988
|
+
declare const CONSUMER_OAC_QR_PREFIX: "FLUROAC1.";
|
|
2989
|
+
/** True iff `value` looks like a presented OAC QR payload. */
|
|
2990
|
+
declare function isConsumerOacQR(value: string): boolean;
|
|
2991
|
+
/**
|
|
2992
|
+
* Advisory "pay me" request a holder may attach to a presented OAC pay code:
|
|
2993
|
+
* an amount, a purpose/intent, and a free-text reference. This rides as an
|
|
2994
|
+
* UNSIGNED suffix on the QR (see {@link encodeConsumerOacQR}) — it is never
|
|
2995
|
+
* part of the issuer-signed credential and carries no authority. The payer's
|
|
2996
|
+
* app treats it purely as a prefill hint and always confirms the amount,
|
|
2997
|
+
* exactly as with a NIBSS dynamic QR.
|
|
2998
|
+
*/
|
|
2999
|
+
declare const OacPresentmentRequestSchema: z.ZodObject<{
|
|
3000
|
+
/** Requested amount in minor units (kobo). */
|
|
3001
|
+
amountMinor: z.ZodOptional<z.ZodNumber>;
|
|
3002
|
+
/** Purpose/intent code (mirrors the NIBSS intent vocabulary). */
|
|
3003
|
+
intent: z.ZodOptional<z.ZodString>;
|
|
3004
|
+
/** Free-text reference / note. */
|
|
3005
|
+
reference: z.ZodOptional<z.ZodString>;
|
|
3006
|
+
}, "strict", z.ZodTypeAny, {
|
|
3007
|
+
amountMinor?: number | undefined;
|
|
3008
|
+
reference?: string | undefined;
|
|
3009
|
+
intent?: string | undefined;
|
|
3010
|
+
}, {
|
|
3011
|
+
amountMinor?: number | undefined;
|
|
3012
|
+
reference?: string | undefined;
|
|
3013
|
+
intent?: string | undefined;
|
|
3014
|
+
}>;
|
|
3015
|
+
type OacPresentmentRequest = z.infer<typeof OacPresentmentRequestSchema>;
|
|
3016
|
+
/**
|
|
3017
|
+
* Encode a signed OAC as a scannable QR payload. The envelope is validated
|
|
3018
|
+
* before encoding so a malformed credential can never be presented.
|
|
3019
|
+
*
|
|
3020
|
+
* An optional advisory {@link OacPresentmentRequest} is appended as a
|
|
3021
|
+
* dot-separated, base64url-encoded suffix:
|
|
3022
|
+
* `FLUROAC1.<base64url(signed)>.<base64url(request)>`
|
|
3023
|
+
* The signed segment is byte-identical with or without the suffix, so the
|
|
3024
|
+
* credential's verifiability is unaffected. An empty request adds no suffix.
|
|
3025
|
+
*/
|
|
3026
|
+
declare function encodeConsumerOacQR(signed: SignedConsumerOAC, request?: OacPresentmentRequest): string;
|
|
3027
|
+
/**
|
|
3028
|
+
* Decode (WITHOUT verifying) a presented OAC QR back into a signed envelope.
|
|
3029
|
+
* Any advisory request suffix is ignored here — use
|
|
3030
|
+
* {@link decodeConsumerOacRequest} to read it. The caller MUST pass the result
|
|
3031
|
+
* to `verifyOacOffline` against pinned keys before trusting any field —
|
|
3032
|
+
* decoding proves nothing about authenticity.
|
|
3033
|
+
*/
|
|
3034
|
+
declare function decodeUnverifiedConsumerOacQR(value: string): SignedConsumerOAC;
|
|
3035
|
+
/**
|
|
3036
|
+
* Read the advisory {@link OacPresentmentRequest} from a presented OAC QR, or
|
|
3037
|
+
* `null` if absent/malformed. This is purely a prefill hint and is NEVER
|
|
3038
|
+
* authoritative — a malformed suffix is treated as "no request" and never
|
|
3039
|
+
* throws, so a bad suffix can never block a verifiable credential.
|
|
3040
|
+
*/
|
|
3041
|
+
declare function decodeConsumerOacRequest(value: string): OacPresentmentRequest | null;
|
|
3042
|
+
|
|
3043
|
+
/**
|
|
3044
|
+
* OAC revocation status-list — offline verification.
|
|
3045
|
+
*
|
|
3046
|
+
* Short OAC TTL (24h, rolling) is the BASELINE revocation-propagation
|
|
3047
|
+
* mechanism: a revoked user cannot refresh, so their credential lapses within
|
|
3048
|
+
* the issuance window. The revocation status-list shrinks that window from
|
|
3049
|
+
* "up to 24h" to "time since the device last pinned a fresh list": the issuer
|
|
3050
|
+
* publishes a signed list of OAC IDs that are revoked AND not yet expired, and
|
|
3051
|
+
* the offline verifier rejects any scanned OAC whose id appears in it.
|
|
3052
|
+
*
|
|
3053
|
+
* The list is naturally bounded: an OAC that lapses on its own TTL drops off
|
|
3054
|
+
* the list (expiry already covers it), so the published set only ever carries
|
|
3055
|
+
* revocations from roughly the last 24h.
|
|
3056
|
+
*
|
|
3057
|
+
* Trust model mirrors the OAC itself: the list is issuer-signed and verified
|
|
3058
|
+
* OFFLINE against the SAME pinned issuer trust bundle (`GET /v1/issuer/keys`),
|
|
3059
|
+
* never the key embedded in the payload. A `sequence` makes the list
|
|
3060
|
+
* monotonic so a device never accepts an older snapshot over a newer one.
|
|
3061
|
+
*/
|
|
3062
|
+
|
|
3063
|
+
/**
|
|
3064
|
+
* Domain tag bound into the revocation-list issuer signature. MUST match
|
|
3065
|
+
* `REVOCATION_DOMAIN` in `flur-backend/src/offline-consumer/service.ts`.
|
|
3066
|
+
*/
|
|
3067
|
+
declare const CONSUMER_REVOCATION_DOMAIN: "flur:consumer-offline:v1:revocation";
|
|
3068
|
+
/**
|
|
3069
|
+
* Hard cap on the number of revoked ids in a single list. Because the list
|
|
3070
|
+
* only carries unexpired revocations (~24h window), this bounds the payload
|
|
3071
|
+
* while comfortably exceeding any realistic revocation rate.
|
|
3072
|
+
*/
|
|
3073
|
+
declare const REVOCATION_LIST_MAX_ENTRIES = 100000;
|
|
3074
|
+
declare const RevocationListSchema: z.ZodObject<{
|
|
3075
|
+
issuerId: z.ZodString;
|
|
3076
|
+
/**
|
|
3077
|
+
* Monotonic snapshot counter. A device MUST NOT replace a pinned list with
|
|
3078
|
+
* one carrying a lower sequence — this defeats a downgrade/rollback attack
|
|
3079
|
+
* that replays an older list to resurrect a revoked credential.
|
|
3080
|
+
*/
|
|
3081
|
+
sequence: z.ZodNumber;
|
|
3082
|
+
issuedAtMs: z.ZodNumber;
|
|
3083
|
+
/**
|
|
3084
|
+
* Freshness bound. After this instant the list is considered stale and the
|
|
3085
|
+
* verifier treats it as untrustworthy (fail-closed), forcing a re-pin.
|
|
3086
|
+
* Optional so the issuer may publish a list without a hard expiry.
|
|
3087
|
+
*/
|
|
3088
|
+
notAfterMs: z.ZodOptional<z.ZodNumber>;
|
|
3089
|
+
/** OAC ids that are revoked AND not yet past their own validity window. */
|
|
3090
|
+
revokedOacIds: z.ZodArray<z.ZodString, "many">;
|
|
3091
|
+
}, "strip", z.ZodTypeAny, {
|
|
3092
|
+
issuedAtMs: number;
|
|
3093
|
+
issuerId: string;
|
|
3094
|
+
sequence: number;
|
|
3095
|
+
revokedOacIds: string[];
|
|
3096
|
+
notAfterMs?: number | undefined;
|
|
3097
|
+
}, {
|
|
3098
|
+
issuedAtMs: number;
|
|
3099
|
+
issuerId: string;
|
|
3100
|
+
sequence: number;
|
|
3101
|
+
revokedOacIds: string[];
|
|
3102
|
+
notAfterMs?: number | undefined;
|
|
3103
|
+
}>;
|
|
3104
|
+
type RevocationList = z.infer<typeof RevocationListSchema>;
|
|
3105
|
+
declare const SignedRevocationListSchema: z.ZodObject<{
|
|
3106
|
+
list: z.ZodObject<{
|
|
3107
|
+
issuerId: z.ZodString;
|
|
3108
|
+
/**
|
|
3109
|
+
* Monotonic snapshot counter. A device MUST NOT replace a pinned list with
|
|
3110
|
+
* one carrying a lower sequence — this defeats a downgrade/rollback attack
|
|
3111
|
+
* that replays an older list to resurrect a revoked credential.
|
|
3112
|
+
*/
|
|
3113
|
+
sequence: z.ZodNumber;
|
|
3114
|
+
issuedAtMs: z.ZodNumber;
|
|
3115
|
+
/**
|
|
3116
|
+
* Freshness bound. After this instant the list is considered stale and the
|
|
3117
|
+
* verifier treats it as untrustworthy (fail-closed), forcing a re-pin.
|
|
3118
|
+
* Optional so the issuer may publish a list without a hard expiry.
|
|
3119
|
+
*/
|
|
3120
|
+
notAfterMs: z.ZodOptional<z.ZodNumber>;
|
|
3121
|
+
/** OAC ids that are revoked AND not yet past their own validity window. */
|
|
3122
|
+
revokedOacIds: z.ZodArray<z.ZodString, "many">;
|
|
3123
|
+
}, "strip", z.ZodTypeAny, {
|
|
3124
|
+
issuedAtMs: number;
|
|
3125
|
+
issuerId: string;
|
|
3126
|
+
sequence: number;
|
|
3127
|
+
revokedOacIds: string[];
|
|
3128
|
+
notAfterMs?: number | undefined;
|
|
3129
|
+
}, {
|
|
3130
|
+
issuedAtMs: number;
|
|
3131
|
+
issuerId: string;
|
|
3132
|
+
sequence: number;
|
|
3133
|
+
revokedOacIds: string[];
|
|
3134
|
+
notAfterMs?: number | undefined;
|
|
3135
|
+
}>;
|
|
3136
|
+
/** ASN.1 DER ECDSA P-256 issuer signature over the signing payload, base64. */
|
|
3137
|
+
issuerSig: z.ZodString;
|
|
3138
|
+
/** Issuer's P-256 public key as SubjectPublicKeyInfo DER, base64. */
|
|
3139
|
+
issuerPublicKeySpkiB64: z.ZodString;
|
|
3140
|
+
}, "strip", z.ZodTypeAny, {
|
|
3141
|
+
issuerSig: string;
|
|
3142
|
+
issuerPublicKeySpkiB64: string;
|
|
3143
|
+
list: {
|
|
3144
|
+
issuedAtMs: number;
|
|
3145
|
+
issuerId: string;
|
|
3146
|
+
sequence: number;
|
|
3147
|
+
revokedOacIds: string[];
|
|
3148
|
+
notAfterMs?: number | undefined;
|
|
3149
|
+
};
|
|
3150
|
+
}, {
|
|
3151
|
+
issuerSig: string;
|
|
3152
|
+
issuerPublicKeySpkiB64: string;
|
|
3153
|
+
list: {
|
|
3154
|
+
issuedAtMs: number;
|
|
3155
|
+
issuerId: string;
|
|
3156
|
+
sequence: number;
|
|
3157
|
+
revokedOacIds: string[];
|
|
3158
|
+
notAfterMs?: number | undefined;
|
|
3159
|
+
};
|
|
3160
|
+
}>;
|
|
3161
|
+
type SignedRevocationList = z.infer<typeof SignedRevocationListSchema>;
|
|
3162
|
+
type VerifyRevocationListResult = {
|
|
3163
|
+
ok: true;
|
|
3164
|
+
list: RevocationList;
|
|
3165
|
+
revokedOacIds: ReadonlySet<string>;
|
|
3166
|
+
} | {
|
|
3167
|
+
ok: false;
|
|
3168
|
+
reason: 'malformed' | 'untrusted_issuer' | 'signature_invalid' | 'stale';
|
|
3169
|
+
};
|
|
3170
|
+
interface VerifyRevocationListOptions {
|
|
3171
|
+
/** Override the wall clock; defaults to `Date.now()`. */
|
|
3172
|
+
nowMs?: number;
|
|
3173
|
+
}
|
|
3174
|
+
/**
|
|
3175
|
+
* Canonical revocation-list payload (domain-bound) the issuer signs.
|
|
3176
|
+
*
|
|
3177
|
+
* Cross-implementation contract (MUST match the backend signer byte-for-byte):
|
|
3178
|
+
* optional fields with no value are OMITTED from the signed object, never
|
|
3179
|
+
* emitted as `null` or `undefined`. `canonicalJSONBytes` rejects `undefined`
|
|
3180
|
+
* object values outright, so building the payload explicitly (rather than
|
|
3181
|
+
* spreading a `list` that may carry an explicit `notAfterMs: undefined`) keeps
|
|
3182
|
+
* verification total — it can never throw on a well-typed list — and keeps the
|
|
3183
|
+
* signed bytes identical whether `notAfterMs` was absent or explicitly unset.
|
|
3184
|
+
*/
|
|
3185
|
+
declare function revocationListSigningPayload(list: RevocationList): Record<string, unknown>;
|
|
3186
|
+
/**
|
|
3187
|
+
* Verify a signed revocation list offline against pinned issuer keys.
|
|
3188
|
+
*
|
|
3189
|
+
* Security invariants (identical to `verifyOacOffline`):
|
|
3190
|
+
* - The signature is checked against the PINNED key for `list.issuerId`,
|
|
3191
|
+
* never the payload-embedded key.
|
|
3192
|
+
* - The pinned key's own validity window is enforced.
|
|
3193
|
+
* - A list past `notAfterMs` fails closed (`stale`) so a long-offline device
|
|
3194
|
+
* cannot keep trusting a frozen snapshot forever.
|
|
3195
|
+
*
|
|
3196
|
+
* Note: rollback protection via `sequence` is intentionally NOT enforced here
|
|
3197
|
+
* (verification is stateless). The caller persisting the pinned list MUST
|
|
3198
|
+
* reject any replacement whose `sequence` is lower than the pinned one.
|
|
3199
|
+
*/
|
|
3200
|
+
declare function verifyRevocationList(signed: SignedRevocationList, trustedKeys: readonly TrustedIssuerKey[], options?: VerifyRevocationListOptions): VerifyRevocationListResult;
|
|
3201
|
+
/** True iff `oacId` appears in a verified revocation set. */
|
|
3202
|
+
declare function isOacRevoked(oacId: string, revokedOacIds: ReadonlySet<string>): boolean;
|
|
3203
|
+
|
|
2881
3204
|
/**
|
|
2882
3205
|
* Consumer-side Offline Collect SDK client.
|
|
2883
3206
|
*
|
|
@@ -2915,14 +3238,14 @@ declare const IssuerTrustKeySchema: z.ZodObject<{
|
|
|
2915
3238
|
issuerId: string;
|
|
2916
3239
|
alg: "p256";
|
|
2917
3240
|
publicKeySpkiB64: string;
|
|
2918
|
-
notBeforeMs?: number | undefined;
|
|
2919
3241
|
notAfterMs?: number | undefined;
|
|
3242
|
+
notBeforeMs?: number | undefined;
|
|
2920
3243
|
}, {
|
|
2921
3244
|
issuerId: string;
|
|
2922
3245
|
alg: "p256";
|
|
2923
3246
|
publicKeySpkiB64: string;
|
|
2924
|
-
notBeforeMs?: number | undefined;
|
|
2925
3247
|
notAfterMs?: number | undefined;
|
|
3248
|
+
notBeforeMs?: number | undefined;
|
|
2926
3249
|
}>;
|
|
2927
3250
|
type IssuerTrustKey = z.infer<typeof IssuerTrustKeySchema>;
|
|
2928
3251
|
declare const IssuerTrustBundleSchema: z.ZodObject<{
|
|
@@ -2936,30 +3259,30 @@ declare const IssuerTrustBundleSchema: z.ZodObject<{
|
|
|
2936
3259
|
issuerId: string;
|
|
2937
3260
|
alg: "p256";
|
|
2938
3261
|
publicKeySpkiB64: string;
|
|
2939
|
-
notBeforeMs?: number | undefined;
|
|
2940
3262
|
notAfterMs?: number | undefined;
|
|
3263
|
+
notBeforeMs?: number | undefined;
|
|
2941
3264
|
}, {
|
|
2942
3265
|
issuerId: string;
|
|
2943
3266
|
alg: "p256";
|
|
2944
3267
|
publicKeySpkiB64: string;
|
|
2945
|
-
notBeforeMs?: number | undefined;
|
|
2946
3268
|
notAfterMs?: number | undefined;
|
|
3269
|
+
notBeforeMs?: number | undefined;
|
|
2947
3270
|
}>, "many">;
|
|
2948
3271
|
}, "strip", z.ZodTypeAny, {
|
|
2949
3272
|
keys: {
|
|
2950
3273
|
issuerId: string;
|
|
2951
3274
|
alg: "p256";
|
|
2952
3275
|
publicKeySpkiB64: string;
|
|
2953
|
-
notBeforeMs?: number | undefined;
|
|
2954
3276
|
notAfterMs?: number | undefined;
|
|
3277
|
+
notBeforeMs?: number | undefined;
|
|
2955
3278
|
}[];
|
|
2956
3279
|
}, {
|
|
2957
3280
|
keys: {
|
|
2958
3281
|
issuerId: string;
|
|
2959
3282
|
alg: "p256";
|
|
2960
3283
|
publicKeySpkiB64: string;
|
|
2961
|
-
notBeforeMs?: number | undefined;
|
|
2962
3284
|
notAfterMs?: number | undefined;
|
|
3285
|
+
notBeforeMs?: number | undefined;
|
|
2963
3286
|
}[];
|
|
2964
3287
|
}>;
|
|
2965
3288
|
type IssuerTrustBundle = z.infer<typeof IssuerTrustBundleSchema>;
|
|
@@ -3107,8 +3430,8 @@ declare const ConsumerOACSchema: z.ZodObject<{
|
|
|
3107
3430
|
counterSeed: number;
|
|
3108
3431
|
issuedAtMs: number;
|
|
3109
3432
|
issuerId: string;
|
|
3110
|
-
alg: "p256";
|
|
3111
3433
|
oacId: string;
|
|
3434
|
+
alg: "p256";
|
|
3112
3435
|
devicePubkeySpkiB64: string;
|
|
3113
3436
|
}, {
|
|
3114
3437
|
phoneE164: string;
|
|
@@ -3123,8 +3446,8 @@ declare const ConsumerOACSchema: z.ZodObject<{
|
|
|
3123
3446
|
counterSeed: number;
|
|
3124
3447
|
issuedAtMs: number;
|
|
3125
3448
|
issuerId: string;
|
|
3126
|
-
alg: "p256";
|
|
3127
3449
|
oacId: string;
|
|
3450
|
+
alg: "p256";
|
|
3128
3451
|
devicePubkeySpkiB64: string;
|
|
3129
3452
|
}>;
|
|
3130
3453
|
type ConsumerOAC = z.infer<typeof ConsumerOACSchema>;
|
|
@@ -3178,8 +3501,8 @@ declare const SignedConsumerOACSchema: z.ZodObject<{
|
|
|
3178
3501
|
counterSeed: number;
|
|
3179
3502
|
issuedAtMs: number;
|
|
3180
3503
|
issuerId: string;
|
|
3181
|
-
alg: "p256";
|
|
3182
3504
|
oacId: string;
|
|
3505
|
+
alg: "p256";
|
|
3183
3506
|
devicePubkeySpkiB64: string;
|
|
3184
3507
|
}, {
|
|
3185
3508
|
phoneE164: string;
|
|
@@ -3194,8 +3517,8 @@ declare const SignedConsumerOACSchema: z.ZodObject<{
|
|
|
3194
3517
|
counterSeed: number;
|
|
3195
3518
|
issuedAtMs: number;
|
|
3196
3519
|
issuerId: string;
|
|
3197
|
-
alg: "p256";
|
|
3198
3520
|
oacId: string;
|
|
3521
|
+
alg: "p256";
|
|
3199
3522
|
devicePubkeySpkiB64: string;
|
|
3200
3523
|
}>;
|
|
3201
3524
|
/** ASN.1 DER ECDSA P-256 issuer signature, base64. */
|
|
@@ -3217,8 +3540,8 @@ declare const SignedConsumerOACSchema: z.ZodObject<{
|
|
|
3217
3540
|
counterSeed: number;
|
|
3218
3541
|
issuedAtMs: number;
|
|
3219
3542
|
issuerId: string;
|
|
3220
|
-
alg: "p256";
|
|
3221
3543
|
oacId: string;
|
|
3544
|
+
alg: "p256";
|
|
3222
3545
|
devicePubkeySpkiB64: string;
|
|
3223
3546
|
};
|
|
3224
3547
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3237,8 +3560,8 @@ declare const SignedConsumerOACSchema: z.ZodObject<{
|
|
|
3237
3560
|
counterSeed: number;
|
|
3238
3561
|
issuedAtMs: number;
|
|
3239
3562
|
issuerId: string;
|
|
3240
|
-
alg: "p256";
|
|
3241
3563
|
oacId: string;
|
|
3564
|
+
alg: "p256";
|
|
3242
3565
|
devicePubkeySpkiB64: string;
|
|
3243
3566
|
};
|
|
3244
3567
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3294,8 +3617,8 @@ declare const OACRecordSchema: z.ZodObject<{
|
|
|
3294
3617
|
counterSeed: number;
|
|
3295
3618
|
issuedAtMs: number;
|
|
3296
3619
|
issuerId: string;
|
|
3297
|
-
alg: "p256";
|
|
3298
3620
|
oacId: string;
|
|
3621
|
+
alg: "p256";
|
|
3299
3622
|
devicePubkeySpkiB64: string;
|
|
3300
3623
|
}, {
|
|
3301
3624
|
phoneE164: string;
|
|
@@ -3310,8 +3633,8 @@ declare const OACRecordSchema: z.ZodObject<{
|
|
|
3310
3633
|
counterSeed: number;
|
|
3311
3634
|
issuedAtMs: number;
|
|
3312
3635
|
issuerId: string;
|
|
3313
|
-
alg: "p256";
|
|
3314
3636
|
oacId: string;
|
|
3637
|
+
alg: "p256";
|
|
3315
3638
|
devicePubkeySpkiB64: string;
|
|
3316
3639
|
}>;
|
|
3317
3640
|
/** ASN.1 DER ECDSA P-256 issuer signature, base64. */
|
|
@@ -3340,8 +3663,8 @@ declare const OACRecordSchema: z.ZodObject<{
|
|
|
3340
3663
|
counterSeed: number;
|
|
3341
3664
|
issuedAtMs: number;
|
|
3342
3665
|
issuerId: string;
|
|
3343
|
-
alg: "p256";
|
|
3344
3666
|
oacId: string;
|
|
3667
|
+
alg: "p256";
|
|
3345
3668
|
devicePubkeySpkiB64: string;
|
|
3346
3669
|
};
|
|
3347
3670
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3364,8 +3687,8 @@ declare const OACRecordSchema: z.ZodObject<{
|
|
|
3364
3687
|
counterSeed: number;
|
|
3365
3688
|
issuedAtMs: number;
|
|
3366
3689
|
issuerId: string;
|
|
3367
|
-
alg: "p256";
|
|
3368
3690
|
oacId: string;
|
|
3691
|
+
alg: "p256";
|
|
3369
3692
|
devicePubkeySpkiB64: string;
|
|
3370
3693
|
};
|
|
3371
3694
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3450,8 +3773,8 @@ declare const OfflineStatusResultSchema: z.ZodObject<{
|
|
|
3450
3773
|
counterSeed: number;
|
|
3451
3774
|
issuedAtMs: number;
|
|
3452
3775
|
issuerId: string;
|
|
3453
|
-
alg: "p256";
|
|
3454
3776
|
oacId: string;
|
|
3777
|
+
alg: "p256";
|
|
3455
3778
|
devicePubkeySpkiB64: string;
|
|
3456
3779
|
}, {
|
|
3457
3780
|
phoneE164: string;
|
|
@@ -3466,8 +3789,8 @@ declare const OfflineStatusResultSchema: z.ZodObject<{
|
|
|
3466
3789
|
counterSeed: number;
|
|
3467
3790
|
issuedAtMs: number;
|
|
3468
3791
|
issuerId: string;
|
|
3469
|
-
alg: "p256";
|
|
3470
3792
|
oacId: string;
|
|
3793
|
+
alg: "p256";
|
|
3471
3794
|
devicePubkeySpkiB64: string;
|
|
3472
3795
|
}>;
|
|
3473
3796
|
/** ASN.1 DER ECDSA P-256 issuer signature, base64. */
|
|
@@ -3496,8 +3819,8 @@ declare const OfflineStatusResultSchema: z.ZodObject<{
|
|
|
3496
3819
|
counterSeed: number;
|
|
3497
3820
|
issuedAtMs: number;
|
|
3498
3821
|
issuerId: string;
|
|
3499
|
-
alg: "p256";
|
|
3500
3822
|
oacId: string;
|
|
3823
|
+
alg: "p256";
|
|
3501
3824
|
devicePubkeySpkiB64: string;
|
|
3502
3825
|
};
|
|
3503
3826
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3520,8 +3843,8 @@ declare const OfflineStatusResultSchema: z.ZodObject<{
|
|
|
3520
3843
|
counterSeed: number;
|
|
3521
3844
|
issuedAtMs: number;
|
|
3522
3845
|
issuerId: string;
|
|
3523
|
-
alg: "p256";
|
|
3524
3846
|
oacId: string;
|
|
3847
|
+
alg: "p256";
|
|
3525
3848
|
devicePubkeySpkiB64: string;
|
|
3526
3849
|
};
|
|
3527
3850
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3546,8 +3869,8 @@ declare const OfflineStatusResultSchema: z.ZodObject<{
|
|
|
3546
3869
|
counterSeed: number;
|
|
3547
3870
|
issuedAtMs: number;
|
|
3548
3871
|
issuerId: string;
|
|
3549
|
-
alg: "p256";
|
|
3550
3872
|
oacId: string;
|
|
3873
|
+
alg: "p256";
|
|
3551
3874
|
devicePubkeySpkiB64: string;
|
|
3552
3875
|
};
|
|
3553
3876
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3572,8 +3895,8 @@ declare const OfflineStatusResultSchema: z.ZodObject<{
|
|
|
3572
3895
|
counterSeed: number;
|
|
3573
3896
|
issuedAtMs: number;
|
|
3574
3897
|
issuerId: string;
|
|
3575
|
-
alg: "p256";
|
|
3576
3898
|
oacId: string;
|
|
3899
|
+
alg: "p256";
|
|
3577
3900
|
devicePubkeySpkiB64: string;
|
|
3578
3901
|
};
|
|
3579
3902
|
issuerPublicKeySpkiB64: string;
|
|
@@ -3621,8 +3944,8 @@ declare const ConsumerPaymentClaimSchema: z.ZodObject<{
|
|
|
3621
3944
|
payerNonce: string;
|
|
3622
3945
|
payeeNonce: string;
|
|
3623
3946
|
occurredAtMs: number;
|
|
3624
|
-
alg: "p256";
|
|
3625
3947
|
oacId: string;
|
|
3948
|
+
alg: "p256";
|
|
3626
3949
|
payerDeviceId: string;
|
|
3627
3950
|
payerPubkeySpkiB64: string;
|
|
3628
3951
|
payerSignatureDerB64: string;
|
|
@@ -3848,6 +4171,12 @@ type MeOfflineClient = {
|
|
|
3848
4171
|
getSettlement: (idOrKey: string) => Promise<ConsumerSettlement>;
|
|
3849
4172
|
/** Fetch the public pinned issuer trust bundle (`GET /v1/issuer/keys`). */
|
|
3850
4173
|
getIssuerKeys: () => Promise<IssuerTrustBundle>;
|
|
4174
|
+
/**
|
|
4175
|
+
* Fetch the issuer-signed OAC revocation status-list
|
|
4176
|
+
* (`GET /v1/issuer/revocations`). Pinned and checked offline alongside the
|
|
4177
|
+
* issuer trust bundle to bound the revocation window below the OAC TTL.
|
|
4178
|
+
*/
|
|
4179
|
+
getRevocations: () => Promise<SignedRevocationList>;
|
|
3851
4180
|
};
|
|
3852
4181
|
declare function createMeOfflineClient(opts: MeOfflineClientOptions): MeOfflineClient;
|
|
3853
4182
|
|
|
@@ -4096,170 +4425,6 @@ declare function verifyConsumerSettlement(settlement: ConsumerSettlement, issuer
|
|
|
4096
4425
|
declare function encodeConsumerSettlementReceiptQR(settlement: ConsumerSettlement): string;
|
|
4097
4426
|
declare function decodeUnverifiedConsumerSettlementReceiptQR(value: string): ConsumerSettlement;
|
|
4098
4427
|
declare function verifyConsumerSettlementReceiptQR(value: string, issuerPublicKeySpkiB64: string): ConsumerSettlement;
|
|
4099
|
-
/**
|
|
4100
|
-
* @deprecated One-argument decode is unverified and exists only for 2.x
|
|
4101
|
-
* source compatibility. Prefer `verifyConsumerSettlementReceiptQR(value,
|
|
4102
|
-
* issuerPublicKeySpkiB64)` or pass the issuer key as the second argument.
|
|
4103
|
-
*/
|
|
4104
|
-
declare function decodeConsumerSettlementReceiptQR(value: string): ConsumerSettlement;
|
|
4105
|
-
declare function decodeConsumerSettlementReceiptQR(value: string, issuerPublicKeySpkiB64: string): ConsumerSettlement;
|
|
4106
|
-
|
|
4107
|
-
/**
|
|
4108
|
-
* Offline verification of the unified Offline Authorization Certificate (OAC).
|
|
4109
|
-
*
|
|
4110
|
-
* The OAC is issuer-signed and folds identity (phoneE164, displayName, bound
|
|
4111
|
-
* device key) into the same credential that carries offline spend authority.
|
|
4112
|
-
* This lets two users who meet for the first time recognise and pay each
|
|
4113
|
-
* other WITHOUT a network round-trip: the verifier checks the issuer
|
|
4114
|
-
* signature against a *pinned* trusted issuer key (a Trust Bundle refreshed
|
|
4115
|
-
* whenever the device is online), never the key embedded in the credential.
|
|
4116
|
-
*
|
|
4117
|
-
* Trust model:
|
|
4118
|
-
* - Provisional offline authorization, authoritative online settlement.
|
|
4119
|
-
* A successful offline verify proves the credential was issued by Flur
|
|
4120
|
-
* and is within its validity window; the backend still re-checks
|
|
4121
|
-
* revocation, balance, and caps at settlement. Short OAC TTL is the
|
|
4122
|
-
* revocation-propagation mechanism — a revoked user cannot refresh and
|
|
4123
|
-
* their OAC expires within the issuance TTL.
|
|
4124
|
-
*
|
|
4125
|
-
* Wire format mirrors `flur-backend/src/offline-consumer/service.ts`
|
|
4126
|
-
* (`oacSigningPayload`): the issuer signs `canonicalJSONBytes({ domain, ...oac })`
|
|
4127
|
-
* with its P-256 key. Adding fields to `ConsumerOAC` automatically includes
|
|
4128
|
-
* them in the signed bytes, so identity is covered without a new domain.
|
|
4129
|
-
*/
|
|
4130
|
-
|
|
4131
|
-
/**
|
|
4132
|
-
* Domain tag bound into the OAC issuer signature. MUST match
|
|
4133
|
-
* `OAC_DOMAIN` in `flur-backend/src/offline-consumer/service.ts`.
|
|
4134
|
-
*/
|
|
4135
|
-
declare const CONSUMER_OAC_DOMAIN: "flur:consumer-offline:v1:oac";
|
|
4136
|
-
/**
|
|
4137
|
-
* A pinned issuer key the device trusts for offline OAC verification.
|
|
4138
|
-
* Sourced from the backend Trust Bundle (`GET /v1/issuer/keys`) and cached
|
|
4139
|
-
* on-device. `notBeforeMs` / `notAfterMs` bound the key's own validity so a
|
|
4140
|
-
* rotated-out key cannot be used to verify a freshly minted credential.
|
|
4141
|
-
*/
|
|
4142
|
-
interface TrustedIssuerKey {
|
|
4143
|
-
issuerId: string;
|
|
4144
|
-
/** Issuer P-256 public key as SubjectPublicKeyInfo DER, base64. */
|
|
4145
|
-
publicKeySpkiB64: string;
|
|
4146
|
-
notBeforeMs?: number;
|
|
4147
|
-
notAfterMs?: number;
|
|
4148
|
-
}
|
|
4149
|
-
/** Identity surfaced to the caller after a successful offline verify. */
|
|
4150
|
-
interface OacOfflineIdentity {
|
|
4151
|
-
oacId: string;
|
|
4152
|
-
issuerId: string;
|
|
4153
|
-
userId: string;
|
|
4154
|
-
phoneE164: string;
|
|
4155
|
-
displayName: string;
|
|
4156
|
-
/** Holder's bound device key; lets the caller verify receipts offline. */
|
|
4157
|
-
devicePubkeySpkiB64: string;
|
|
4158
|
-
}
|
|
4159
|
-
type VerifyOacOfflineResult = {
|
|
4160
|
-
ok: true;
|
|
4161
|
-
oac: ConsumerOAC;
|
|
4162
|
-
identity: OacOfflineIdentity;
|
|
4163
|
-
} | {
|
|
4164
|
-
ok: false;
|
|
4165
|
-
reason: 'malformed' | 'untrusted_issuer' | 'signature_invalid' | 'window_too_long' | 'not_yet_valid' | 'expired';
|
|
4166
|
-
};
|
|
4167
|
-
interface VerifyOacOfflineOptions {
|
|
4168
|
-
/** Override the wall clock; defaults to `Date.now()`. */
|
|
4169
|
-
nowMs?: number;
|
|
4170
|
-
}
|
|
4171
|
-
/** Canonical OAC payload (domain-bound) the backend issuer signs. */
|
|
4172
|
-
declare function consumerOacSigningPayload(oac: ConsumerOAC): {
|
|
4173
|
-
phoneE164: string;
|
|
4174
|
-
userId: string;
|
|
4175
|
-
deviceId: string;
|
|
4176
|
-
displayName: string;
|
|
4177
|
-
currency: string;
|
|
4178
|
-
perTxCapKobo: number;
|
|
4179
|
-
cumulativeCapKobo: number;
|
|
4180
|
-
validFromMs: number;
|
|
4181
|
-
validUntilMs: number;
|
|
4182
|
-
counterSeed: number;
|
|
4183
|
-
issuedAtMs: number;
|
|
4184
|
-
issuerId: string;
|
|
4185
|
-
alg: "p256";
|
|
4186
|
-
oacId: string;
|
|
4187
|
-
devicePubkeySpkiB64: string;
|
|
4188
|
-
domain: "flur:consumer-offline:v1:oac";
|
|
4189
|
-
};
|
|
4190
|
-
/**
|
|
4191
|
-
* Verify a signed OAC offline against a pinned set of trusted issuer keys.
|
|
4192
|
-
*
|
|
4193
|
-
* Security invariants:
|
|
4194
|
-
* - The signature is checked against the PINNED key for `oac.issuerId`,
|
|
4195
|
-
* never the credential-embedded `issuerPublicKeySpkiB64`. An attacker who
|
|
4196
|
-
* forges an OAC with their own key (and a matching embedded key) fails
|
|
4197
|
-
* because their key is not pinned.
|
|
4198
|
-
* - The pinned key's own validity window is enforced.
|
|
4199
|
-
* - The OAC validity window is enforced (`validFromMs <= now < validUntilMs`).
|
|
4200
|
-
*/
|
|
4201
|
-
declare function verifyOacOffline(signed: SignedConsumerOAC, trustedKeys: readonly TrustedIssuerKey[], options?: VerifyOacOfflineOptions): VerifyOacOfflineResult;
|
|
4202
|
-
/**
|
|
4203
|
-
* QR prefix for a presented unified OAC. A holder shows this QR to be paid
|
|
4204
|
-
* and/or identified offline; the scanner decodes it and calls
|
|
4205
|
-
* `verifyOacOffline` against its pinned trust bundle. Distinct from the
|
|
4206
|
-
* settlement-receipt (`FLURSR1.`) and pay-card prefixes so the scanner can
|
|
4207
|
-
* dispatch by prefix without ambiguity.
|
|
4208
|
-
*/
|
|
4209
|
-
declare const CONSUMER_OAC_QR_PREFIX: "FLUROAC1.";
|
|
4210
|
-
/** True iff `value` looks like a presented OAC QR payload. */
|
|
4211
|
-
declare function isConsumerOacQR(value: string): boolean;
|
|
4212
|
-
/**
|
|
4213
|
-
* Advisory "pay me" request a holder may attach to a presented OAC pay code:
|
|
4214
|
-
* an amount, a purpose/intent, and a free-text reference. This rides as an
|
|
4215
|
-
* UNSIGNED suffix on the QR (see {@link encodeConsumerOacQR}) — it is never
|
|
4216
|
-
* part of the issuer-signed credential and carries no authority. The payer's
|
|
4217
|
-
* app treats it purely as a prefill hint and always confirms the amount,
|
|
4218
|
-
* exactly as with a NIBSS dynamic QR.
|
|
4219
|
-
*/
|
|
4220
|
-
declare const OacPresentmentRequestSchema: z.ZodObject<{
|
|
4221
|
-
/** Requested amount in minor units (kobo). */
|
|
4222
|
-
amountMinor: z.ZodOptional<z.ZodNumber>;
|
|
4223
|
-
/** Purpose/intent code (mirrors the NIBSS intent vocabulary). */
|
|
4224
|
-
intent: z.ZodOptional<z.ZodString>;
|
|
4225
|
-
/** Free-text reference / note. */
|
|
4226
|
-
reference: z.ZodOptional<z.ZodString>;
|
|
4227
|
-
}, "strict", z.ZodTypeAny, {
|
|
4228
|
-
amountMinor?: number | undefined;
|
|
4229
|
-
reference?: string | undefined;
|
|
4230
|
-
intent?: string | undefined;
|
|
4231
|
-
}, {
|
|
4232
|
-
amountMinor?: number | undefined;
|
|
4233
|
-
reference?: string | undefined;
|
|
4234
|
-
intent?: string | undefined;
|
|
4235
|
-
}>;
|
|
4236
|
-
type OacPresentmentRequest = z.infer<typeof OacPresentmentRequestSchema>;
|
|
4237
|
-
/**
|
|
4238
|
-
* Encode a signed OAC as a scannable QR payload. The envelope is validated
|
|
4239
|
-
* before encoding so a malformed credential can never be presented.
|
|
4240
|
-
*
|
|
4241
|
-
* An optional advisory {@link OacPresentmentRequest} is appended as a
|
|
4242
|
-
* dot-separated, base64url-encoded suffix:
|
|
4243
|
-
* `FLUROAC1.<base64url(signed)>.<base64url(request)>`
|
|
4244
|
-
* The signed segment is byte-identical with or without the suffix, so the
|
|
4245
|
-
* credential's verifiability is unaffected. An empty request adds no suffix.
|
|
4246
|
-
*/
|
|
4247
|
-
declare function encodeConsumerOacQR(signed: SignedConsumerOAC, request?: OacPresentmentRequest): string;
|
|
4248
|
-
/**
|
|
4249
|
-
* Decode (WITHOUT verifying) a presented OAC QR back into a signed envelope.
|
|
4250
|
-
* Any advisory request suffix is ignored here — use
|
|
4251
|
-
* {@link decodeConsumerOacRequest} to read it. The caller MUST pass the result
|
|
4252
|
-
* to `verifyOacOffline` against pinned keys before trusting any field —
|
|
4253
|
-
* decoding proves nothing about authenticity.
|
|
4254
|
-
*/
|
|
4255
|
-
declare function decodeUnverifiedConsumerOacQR(value: string): SignedConsumerOAC;
|
|
4256
|
-
/**
|
|
4257
|
-
* Read the advisory {@link OacPresentmentRequest} from a presented OAC QR, or
|
|
4258
|
-
* `null` if absent/malformed. This is purely a prefill hint and is NEVER
|
|
4259
|
-
* authoritative — a malformed suffix is treated as "no request" and never
|
|
4260
|
-
* throws, so a bad suffix can never block a verifiable credential.
|
|
4261
|
-
*/
|
|
4262
|
-
declare function decodeConsumerOacRequest(value: string): OacPresentmentRequest | null;
|
|
4263
4428
|
|
|
4264
4429
|
/**
|
|
4265
4430
|
* FLURA1 — single-SMS consumer-offline settle token.
|
|
@@ -6671,4 +6836,4 @@ declare function createOfflinePaymentAuthorizationArtifactUri(input: {
|
|
|
6671
6836
|
}>;
|
|
6672
6837
|
};
|
|
6673
6838
|
|
|
6674
|
-
export { ACCOUNT_FUNDED_OAC_MAX_TTL_MS, ACCOUNT_STATUSES, ACCOUNT_TYPES, ADDITIONAL_DATA_SUBFIELD, ARTIFACT_BODY_SCHEMAS, ARTIFACT_TYPES, type Account, type AccountActivityItem, type AccountMembership, AccountMembershipSchema, AccountSchema, type AccountStatus, type AccountSummaryResponse, type AccountType, type AccountsClient, type AccountsClientOptions, type AddMemberInput, type AdditionalData, type ApiCredentialPublic, ApiCredentialPublicSchema, type ApiCredentialsAdminClient, type ArtifactBody, type ArtifactHeader, ArtifactHeaderSchema, type ArtifactType, type AtomicRedeemReceiptInput, type AtomicRedeemResponse, type AttestationSecurityLevel, AttestationSecurityLevelSchema, type AuthLogoutInput, type AuthRefreshInput, type AuthRefreshResponse, type AuthorizeSendWithBiometricInput, type AuthorizedOptions, type BiometricSigner, type BuildPassInput, type BuildReceiptInput, type BuildRedemptionInput, CLAIM_DOMAIN_V2, COLLECTION_INTENT_STATUSES, COLLECTION_PAYMENT_STATUSES, CONSUMER_OAC_DOMAIN, CONSUMER_OAC_QR_PREFIX, CONSUMER_OFFLINE_CLAIM_SUBMIT_GRACE_MS, CONSUMER_PAYMENT_REQUEST_DOMAIN, CONSUMER_SETTLEMENT_DOMAIN, CONSUMER_SETTLEMENT_RECEIPT_QR_PREFIX, CUSTODIAL_MODES, type CanonicalClaimInput, type CashNamespace, type ClaimSignature, type CollectionIntent, CollectionIntentSchema, type CollectionPayment, type CollectionPaymentResult, CollectionPaymentResultSchema, CollectionPaymentSchema, type CollectionReportSummary, CollectionReportSummarySchema, type CollectionStatement, CollectionStatementSchema, type CollectionsClient, type CollectionsClientOptions, type ConsumerCollectionsClient, type ConsumerOAC, type OACRecord as ConsumerOACRecord, OACRecordSchema as ConsumerOACRecordSchema, ConsumerOACSchema, type ConsumerPaymentClaim, ConsumerPaymentClaimSchema, type ConsumerPaymentRequestEnvelope, ConsumerPaymentRequestEnvelopeSchema, type ConsumerSettleResult, ConsumerSettleResultSchema, type ConsumerSettlement, ConsumerSettlementSchema, type ConsumerWithdrawalsClient, type ConsumerWithdrawalsClientOptions, type CreateBusinessAccountInput, type CreateCollectionIntentInput, CreateCollectionIntentInputSchema, type CreatePayLinkResponse, type CreatePayoutDestinationInput, CreatePayoutDestinationInputSchema, type CreatePayoutInput, CreatePayoutInputSchema, type CreateTransferOptions, type CreateWithdrawalInput, CreateWithdrawalInputSchema, type CreateWithdrawalResult, CreateWithdrawalResultSchema, type CustodialMode, type DecodedArtifactUri, type DecodedOfflineSmsSettleToken, type DeviceKeyAlg, DeviceKeyAlgSchema, type DeviceKeyRecord, DeviceKeyRecordSchema, type DeviceTrustState, FIELD, FLUR_ARTIFACT_URI_PREFIX, FLUR_ARTIFACT_URI_SCHEME, FLUR_ARTIFACT_VERSION, FlurApiError, FlurArtifactError, FlurCapExceededError, FlurClient, type FlurClientOptions, FlurError, type FlurErrorCode, FlurExpiredError, type FlurHandle, type FlurInitOptions, type FlurOfflineSettlementsClient, type FlurPartnerClient, type FlurPaymentEvent, FlurReplayError, HARDENED_ARTIFACT_TYPES, type HmacFetchOptions, IdentityArtifactSchema, type IngestFundingResult, IngestFundingResultSchema, type IssueAccountOacInput, IssueAccountOacInputSchema, type IssueOfflineTokenInput, type IssuePassInput, type IssueReceiptInput, type IssuerTrustBundle, IssuerTrustBundleSchema, type IssuerTrustKey, IssuerTrustKeySchema, LedgerJournalEntryArtifactSchema, type ListPassesInput, type ListPassesResponse, type ListPayoutDestinationsResult, ListPayoutDestinationsResultSchema, type ListReceiptsInput, type ListReceiptsResponse, type ListTransactionsOptions, MEMBERSHIP_ROLES, MERCHANT_PAYOUT_STATUSES, MERCHANT_PROFILE_STATUSES, type MeOfflineClient, type MeOfflineClientOptions, type MembershipRole, type MerchantAccountInfo, type MerchantPayout, MerchantPayoutSchema, type MerchantProfile, MerchantProfileSchema, type MintedApiCredential, MintedApiCredentialSchema, type Money, NGN_CURRENCY_CODE, NG_COUNTRY_CODE, NQRParseError, type NQRPayloadInput, NqrPaymentRequestArtifactSchema, type OAC, OACSchema, OAC_DEFAULT_CUMULATIVE_KOBO, OAC_DEFAULT_PER_TX_KOBO, OAC_DEFAULT_VALIDITY_MS, OFFLINE_CLAIM_SMS_PREFIX, OFFLINE_SMS_SETTLE_DOMAIN, OFFLINE_SMS_SETTLE_HEADER_BYTES, OFFLINE_SMS_SETTLE_PREFIX, OFFLINE_SMS_SETTLE_SIGNATURE_BYTES, OFFLINE_SMS_SETTLE_TOKEN_BYTES, OFFLINE_SMS_SETTLE_VERSION, type OacOfflineIdentity, type OacPresentmentRequest, OacPresentmentRequestSchema, type OfflineClaimAlgorithm, OfflineClaimArtifactSchema, type OfflineClaimSigner, type OfflinePaymentAuthorization, type OfflinePaymentAuthorizationArtifact, OfflinePaymentAuthorizationArtifactSchema, OfflinePaymentAuthorizationSchema, type OfflinePaymentRequest, OfflinePaymentRequestSchema, type OfflineSmsSettleInput, type OfflineSmsSettleSigner, type OfflineStatusResult, OfflineStatusResultSchema, type OfflineToken, OfflineTokenSchema, type OnboardingCompleteInput, type OnboardingCompleteResponse, type OnboardingFallback, type OnboardingRiskReason, type OnboardingStartInput, type OnboardingStartResponse, type P256EnrollmentChallengeInput, P256EnrollmentChallengeInputSchema, type P256EnrollmentChallengeResult, P256EnrollmentChallengeResultSchema, PARTNER_FUNDING_DIRECTIONS, PARTNER_FUNDING_STATUSES, PARTNER_KINDS, PARTNER_PROFILE_STATUSES, PARTNER_SCOPES, PASS_KINDS, PASS_STATES, PAYLOAD_FORMAT_INDICATOR_VALUE, PAYOUT_DESTINATION_STATUSES, POINT_OF_INITIATION, type ParsedNQR, type PartnerClientOptions, type PartnerCollectionsClient, type PartnerFunding, type PartnerFundingClient, type PartnerFundingDirection, type PartnerFundingEventInput, PartnerFundingEventInputSchema, PartnerFundingSchema, type PartnerFundingStatus, type PartnerKind, type PartnerProfile, type PartnerProfileAdminClient, type PartnerProfileAdminClientOptions, PartnerProfileSchema, type PartnerProfileStatus, type PartnerScope, type PartnerSignResult, type Pass, PassArtifactSchema, type PassKind, type PassMetadata, PassMetadataSchema, PassSchema, type PassState, type PassesClient, type PassesClientOptions, type PayCollectionInput, PayCollectionInputSchema, type PayCollectionOptions, type PayCollectionResponse, type PaymentClaim, PaymentClaimSchema, PaymentIntentArtifactSchema, type PayoutDestination, PayoutDestinationSchema, type PayoutDestinationStatus, type PayoutEventInput, PayoutEventInputSchema, type PinSetInput, type PinVerifyInput, type ProviderEventInput, ProviderEventInputSchema, type ProviderEventRecord, ProviderEventRecordSchema, type PublicCollectionIntent, PublicCollectionIntentSchema, type PushPlatform, type PushRegisterInput, RECEIPT_CHANNELS, RECEIPT_KINDS, REPLAY_WINDOW_MS, type Receipt, type ReceiptArtifact, ReceiptArtifactSchema, type ReceiptChannel, type ReceiptKind, type ReceiptPayload, ReceiptPayloadSchema, ReceiptSchema, type ReceiptsClient, type ReceiptsClientOptions, type RecipientResolveInput, type RecipientResolveResponse, type ReconciliationReport, ReconciliationReportSchema, type RecordPayoutEventResult, RecordPayoutEventResultSchema, type RedeemPassResponse, type Redemption, RedemptionSchema, type RegisterDeviceInput, type RegisterDeviceKeyP256Input, RegisterDeviceKeyP256InputSchema, type RegisterDeviceResponse, type RegisterSendDeviceKeyInput, type ResolveCollectionOptions, type ResolveCollectionResponse, type ResolvePayLinkResponse, ReversalRecordArtifactSchema, RevokeDeviceKeyInputSchema, type RevokePassInput, type RoutingHint, SETTLEMENT_SCHEDULES, type SendChallengeInput, type SendChallengeResponse, type SendMoneyInput, type SendMoneyOptions, type SendVerifyInput, type SendVerifyResponse, type SettleResponse, SettleResponseSchema, type Settlement, SettlementRecordArtifactSchema, SettlementSchema, type SignedArtifact, type SignedConsumerOAC, SignedConsumerOACSchema, type SignerPublicKey, StatementArtifactSchema, type SubscribeOptions, type TLVField, type TransactionDetailResponse, type TransactionDirection, type TransactionsListResponse, type TransferInput, type TransferResponse, type TransferStatus, type TrustedIssuerKey, type UnsignedConsumerPaymentRequest, type UnsignedOAC, type UnsignedOfflinePaymentAuthorization, type UnsignedOfflinePaymentRequest, type UnsignedPass, type UnsignedReceipt, type UnsignedRedemption, type UpsertMerchantProfileInput, UpsertMerchantProfileInputSchema, type UpsertPartnerProfileInput, UpsertPartnerProfileInputSchema, type VerifiedArtifact, type VerifyArtifactOptions, type VerifyClaimSignatureInput, type VerifyOacOfflineOptions, type VerifyOacOfflineResult, WITHDRAWAL_STATES, type Withdrawal, WithdrawalSchema, type WithdrawalState, base64UrlDecode, base64UrlEncode, bodySha256Hex, buildArtifactBody, buildAuthorization, buildConsumerPaymentRequest, buildOAC, buildPass, buildPaymentRequest, buildReceipt, buildRedemption, buildSmsSettleHeader, domainTag as buildSmsSettleSignedBytes, canonicalClaimSigningBytes, canonicalClaimSigningPayload, canonicalJSONBytes, canonicalJSONStringify, canonicalRequestString, computeConsumerClaimEncounterId, computeEncounterId, constantTimeEqual, consumerOacSigningPayload, consumerPaymentRequestSigningBytes, consumerPaymentRequestSigningPayload, consumerSettlementSigningPayload, crc16ccitt, crc16ccittHex, createAccountsClient, createApiCredentialsAdminClient, createArtifactUri, createCollectionsClient, createConsumerCollectionsClient, createConsumerWithdrawalsClient, createFlurPartnerClient, createHmacFetch, createMeOfflineClient, createOfflinePaymentAuthorizationArtifactUri, createOfflineSettlementsClient, createPartnerCollectionsClient, createPartnerFundingClient, createPartnerProfileAdminClient, createPassesClient, createReceiptArtifactUri, createReceiptsClient, createSoftwareP256Signer, decodeArtifactUri, decodeAuthorizationQR, decodeBase45, decodeConsumerOacRequest, decodeConsumerSettlementReceiptQR, decodeOfflineClaimSmsMessage, decodeOfflineSmsSettleToken, decodePaymentRequestQR, decodeUnverifiedConsumerOacQR, decodeUnverifiedConsumerSettlementReceiptQR, derToRawP256Signature, encodeArtifactUri, encodeAuthorizationQR, encodeBase45, encodeConsumerOacQR, encodeConsumerSettlementReceiptQR, encodeNQR, encodeOfflineClaimSmsMessage, encodeOfflineSmsSettleToken, encodePaymentRequestQR, extractOfflineClaimSmsToken, extractOfflineSmsSettleToken, formatAmount, generateDynamicQR, generateStaticQR, init, isConsumerOacQR, isConsumerPaymentRequestExpired, isHardenedArtifactType, isKnownArtifactType, isPassWithinValidity, moneyMinorToNumber, normalizeE164, parseAmountInput, parseNQR, parseQR, readTLV, routingHint, signArtifact, signAuthorization, signConsumerPaymentRequest, signOAC, signPartnerRequest, signPass, signPaymentRequest, signReceipt, signRedemption, signRequestHMAC, verifyArtifactSignature, verifyArtifactUri, verifyAuthorization, verifyClaimSignature, verifyConsumerPaymentRequest, verifyConsumerSettlement, verifyConsumerSettlementReceiptQR, verifyOAC, verifyOacOffline, verifyOfflineSmsSettleToken, verifyPass, verifyPaymentRequest, verifyReceipt, verifyRedemption, verifyRequestHMAC, writeTLV };
|
|
6839
|
+
export { ACCOUNT_FUNDED_OAC_MAX_TTL_MS, ACCOUNT_STATUSES, ACCOUNT_TYPES, ADDITIONAL_DATA_SUBFIELD, ARTIFACT_BODY_SCHEMAS, ARTIFACT_TYPES, type Account, type AccountActivityItem, type AccountMembership, AccountMembershipSchema, AccountSchema, type AccountStatus, type AccountSummaryResponse, type AccountType, type AccountsClient, type AccountsClientOptions, type AddMemberInput, type AdditionalData, type ApiCredentialPublic, ApiCredentialPublicSchema, type ApiCredentialsAdminClient, type ArtifactBody, type ArtifactHeader, ArtifactHeaderSchema, type ArtifactType, type AtomicRedeemReceiptInput, type AtomicRedeemResponse, type AttestationSecurityLevel, AttestationSecurityLevelSchema, type AuthLogoutInput, type AuthRefreshInput, type AuthRefreshResponse, type AuthorizeSendWithBiometricInput, type AuthorizedOptions, type BiometricSigner, type BuildPassInput, type BuildReceiptInput, type BuildRedemptionInput, CLAIM_DOMAIN_V2, COLLECTION_INTENT_STATUSES, COLLECTION_PAYMENT_STATUSES, CONSUMER_OAC_DOMAIN, CONSUMER_OAC_QR_PREFIX, CONSUMER_OFFLINE_CLAIM_SUBMIT_GRACE_MS, CONSUMER_PAYMENT_REQUEST_DOMAIN, CONSUMER_REVOCATION_DOMAIN, CONSUMER_SETTLEMENT_DOMAIN, CONSUMER_SETTLEMENT_RECEIPT_QR_PREFIX, CUSTODIAL_MODES, type CanonicalClaimInput, type CashNamespace, type ClaimSignature, type CollectionIntent, CollectionIntentSchema, type CollectionPayment, type CollectionPaymentResult, CollectionPaymentResultSchema, CollectionPaymentSchema, type CollectionReportSummary, CollectionReportSummarySchema, type CollectionStatement, CollectionStatementSchema, type CollectionsClient, type CollectionsClientOptions, type ConsumerCollectionsClient, type ConsumerOAC, type OACRecord as ConsumerOACRecord, OACRecordSchema as ConsumerOACRecordSchema, ConsumerOACSchema, type ConsumerPaymentClaim, ConsumerPaymentClaimSchema, type ConsumerPaymentRequestEnvelope, ConsumerPaymentRequestEnvelopeSchema, type ConsumerSettleResult, ConsumerSettleResultSchema, type ConsumerSettlement, ConsumerSettlementSchema, type ConsumerWithdrawalsClient, type ConsumerWithdrawalsClientOptions, type CreateBusinessAccountInput, type CreateCollectionIntentInput, CreateCollectionIntentInputSchema, type CreatePayLinkResponse, type CreatePayoutDestinationInput, CreatePayoutDestinationInputSchema, type CreatePayoutInput, CreatePayoutInputSchema, type CreateTransferOptions, type CreateWithdrawalInput, CreateWithdrawalInputSchema, type CreateWithdrawalResult, CreateWithdrawalResultSchema, type CustodialMode, type DecodedArtifactUri, type DecodedOfflineSmsSettleToken, type DeviceKeyAlg, DeviceKeyAlgSchema, type DeviceKeyRecord, DeviceKeyRecordSchema, type DeviceTrustState, FIELD, FLUR_ARTIFACT_URI_PREFIX, FLUR_ARTIFACT_URI_SCHEME, FLUR_ARTIFACT_VERSION, FlurApiError, FlurArtifactError, FlurCapExceededError, FlurClient, type FlurClientOptions, FlurError, type FlurErrorCode, FlurExpiredError, type FlurHandle, type FlurInitOptions, type FlurOfflineSettlementsClient, type FlurPartnerClient, type FlurPaymentEvent, FlurReplayError, HARDENED_ARTIFACT_TYPES, IdentityArtifactSchema, type IngestFundingResult, IngestFundingResultSchema, type IssueAccountOacInput, IssueAccountOacInputSchema, type IssueOfflineTokenInput, type IssuePassInput, type IssueReceiptInput, type IssuerTrustBundle, IssuerTrustBundleSchema, type IssuerTrustKey, IssuerTrustKeySchema, LedgerJournalEntryArtifactSchema, type ListPassesInput, type ListPassesResponse, type ListPayoutDestinationsResult, ListPayoutDestinationsResultSchema, type ListReceiptsInput, type ListReceiptsResponse, type ListTransactionsOptions, MEMBERSHIP_ROLES, MERCHANT_PAYOUT_STATUSES, MERCHANT_PROFILE_STATUSES, type MeOfflineClient, type MeOfflineClientOptions, type MembershipRole, type MerchantAccountInfo, type MerchantPayout, MerchantPayoutSchema, type MerchantProfile, MerchantProfileSchema, type MintedApiCredential, MintedApiCredentialSchema, type Money, NGN_CURRENCY_CODE, NG_COUNTRY_CODE, NQRParseError, type NQRPayloadInput, NqrPaymentRequestArtifactSchema, type OAC, OACSchema, OAC_DEFAULT_CUMULATIVE_KOBO, OAC_DEFAULT_PER_TX_KOBO, OAC_DEFAULT_VALIDITY_MS, OFFLINE_CLAIM_SMS_PREFIX, OFFLINE_SMS_SETTLE_DOMAIN, OFFLINE_SMS_SETTLE_HEADER_BYTES, OFFLINE_SMS_SETTLE_PREFIX, OFFLINE_SMS_SETTLE_SIGNATURE_BYTES, OFFLINE_SMS_SETTLE_TOKEN_BYTES, OFFLINE_SMS_SETTLE_VERSION, type OacOfflineIdentity, type OacPresentmentRequest, OacPresentmentRequestSchema, type OfflineClaimAlgorithm, OfflineClaimArtifactSchema, type OfflineClaimSigner, type OfflinePaymentAuthorization, type OfflinePaymentAuthorizationArtifact, OfflinePaymentAuthorizationArtifactSchema, OfflinePaymentAuthorizationSchema, type OfflinePaymentRequest, OfflinePaymentRequestSchema, type OfflineSmsSettleInput, type OfflineSmsSettleSigner, type OfflineStatusResult, OfflineStatusResultSchema, type OfflineToken, OfflineTokenSchema, type OnboardingCompleteInput, type OnboardingCompleteResponse, type OnboardingFallback, type OnboardingRiskReason, type OnboardingStartInput, type OnboardingStartResponse, type P256EnrollmentChallengeInput, P256EnrollmentChallengeInputSchema, type P256EnrollmentChallengeResult, P256EnrollmentChallengeResultSchema, PARTNER_FUNDING_DIRECTIONS, PARTNER_FUNDING_STATUSES, PARTNER_KINDS, PARTNER_PROFILE_STATUSES, PARTNER_SCOPES, PASS_KINDS, PASS_STATES, PAYLOAD_FORMAT_INDICATOR_VALUE, PAYOUT_DESTINATION_STATUSES, POINT_OF_INITIATION, type ParsedNQR, type PartnerClientOptions, type PartnerCollectionsClient, type PartnerFunding, type PartnerFundingClient, type PartnerFundingDirection, type PartnerFundingEventInput, PartnerFundingEventInputSchema, PartnerFundingSchema, type PartnerFundingStatus, type PartnerKind, type PartnerProfile, type PartnerProfileAdminClient, type PartnerProfileAdminClientOptions, PartnerProfileSchema, type PartnerProfileStatus, type PartnerScope, type PartnerSignResult, type Pass, PassArtifactSchema, type PassKind, type PassMetadata, PassMetadataSchema, PassSchema, type PassState, type PassesClient, type PassesClientOptions, type PayCollectionInput, PayCollectionInputSchema, type PayCollectionOptions, type PayCollectionResponse, type PaymentClaim, PaymentClaimSchema, PaymentIntentArtifactSchema, type PayoutDestination, PayoutDestinationSchema, type PayoutDestinationStatus, type PayoutEventInput, PayoutEventInputSchema, type PinSetInput, type PinVerifyInput, type ProviderEventInput, ProviderEventInputSchema, type ProviderEventRecord, ProviderEventRecordSchema, type PublicCollectionIntent, PublicCollectionIntentSchema, type PushPlatform, type PushRegisterInput, RECEIPT_CHANNELS, RECEIPT_KINDS, REVOCATION_LIST_MAX_ENTRIES, type Receipt, type ReceiptArtifact, ReceiptArtifactSchema, type ReceiptChannel, type ReceiptKind, type ReceiptPayload, ReceiptPayloadSchema, ReceiptSchema, type ReceiptsClient, type ReceiptsClientOptions, type RecipientResolveInput, type RecipientResolveResponse, type ReconciliationReport, ReconciliationReportSchema, type RecordPayoutEventResult, RecordPayoutEventResultSchema, type RedeemPassResponse, type Redemption, RedemptionSchema, type RegisterDeviceInput, type RegisterDeviceKeyP256Input, RegisterDeviceKeyP256InputSchema, type RegisterDeviceResponse, type RegisterSendDeviceKeyInput, type ResolveCollectionOptions, type ResolveCollectionResponse, type ResolvePayLinkResponse, ReversalRecordArtifactSchema, type RevocationList, RevocationListSchema, RevokeDeviceKeyInputSchema, type RevokePassInput, type RoutingHint, SETTLEMENT_SCHEDULES, type SendChallengeInput, type SendChallengeResponse, type SendMoneyInput, type SendMoneyOptions, type SendVerifyInput, type SendVerifyResponse, type SettleResponse, SettleResponseSchema, type Settlement, SettlementRecordArtifactSchema, SettlementSchema, type SignedArtifact, type SignedConsumerOAC, SignedConsumerOACSchema, type SignedRevocationList, SignedRevocationListSchema, type SignerPublicKey, StatementArtifactSchema, type SubscribeOptions, type TLVField, type TransactionDetailResponse, type TransactionDirection, type TransactionsListResponse, type TransferInput, type TransferResponse, type TransferStatus, type TrustedIssuerKey, type UnsignedConsumerPaymentRequest, type UnsignedOAC, type UnsignedOfflinePaymentAuthorization, type UnsignedOfflinePaymentRequest, type UnsignedPass, type UnsignedReceipt, type UnsignedRedemption, type UpsertMerchantProfileInput, UpsertMerchantProfileInputSchema, type UpsertPartnerProfileInput, UpsertPartnerProfileInputSchema, type VerifiedArtifact, type VerifyArtifactOptions, type VerifyClaimSignatureInput, type VerifyOacOfflineOptions, type VerifyOacOfflineResult, type VerifyRevocationListOptions, type VerifyRevocationListResult, WITHDRAWAL_STATES, type Withdrawal, WithdrawalSchema, type WithdrawalState, base64UrlDecode, base64UrlEncode, bodySha256Hex, buildArtifactBody, buildAuthorization, buildConsumerPaymentRequest, buildOAC, buildPass, buildPaymentRequest, buildReceipt, buildRedemption, buildSmsSettleHeader, domainTag as buildSmsSettleSignedBytes, canonicalClaimSigningBytes, canonicalClaimSigningPayload, canonicalJSONBytes, canonicalJSONStringify, canonicalRequestString, computeConsumerClaimEncounterId, computeEncounterId, constantTimeEqual, consumerOacSigningPayload, consumerPaymentRequestSigningBytes, consumerPaymentRequestSigningPayload, consumerSettlementSigningPayload, crc16ccitt, crc16ccittHex, createAccountsClient, createApiCredentialsAdminClient, createArtifactUri, createCollectionsClient, createConsumerCollectionsClient, createConsumerWithdrawalsClient, createFlurPartnerClient, createMeOfflineClient, createOfflinePaymentAuthorizationArtifactUri, createOfflineSettlementsClient, createPartnerCollectionsClient, createPartnerFundingClient, createPartnerProfileAdminClient, createPassesClient, createReceiptArtifactUri, createReceiptsClient, createSoftwareP256Signer, decodeArtifactUri, decodeAuthorizationQR, decodeBase45, decodeConsumerOacRequest, decodeOfflineClaimSmsMessage, decodeOfflineSmsSettleToken, decodePaymentRequestQR, decodeUnverifiedConsumerOacQR, decodeUnverifiedConsumerSettlementReceiptQR, derToRawP256Signature, encodeArtifactUri, encodeAuthorizationQR, encodeBase45, encodeConsumerOacQR, encodeConsumerSettlementReceiptQR, encodeNQR, encodeOfflineClaimSmsMessage, encodeOfflineSmsSettleToken, encodePaymentRequestQR, extractOfflineClaimSmsToken, extractOfflineSmsSettleToken, formatAmount, generateDynamicQR, generateStaticQR, init, isConsumerOacQR, isConsumerPaymentRequestExpired, isHardenedArtifactType, isKnownArtifactType, isOacRevoked, isPassWithinValidity, moneyMinorToNumber, normalizeE164, parseAmountInput, parseNQR, parseQR, readTLV, revocationListSigningPayload, routingHint, signArtifact, signAuthorization, signConsumerPaymentRequest, signOAC, signPartnerRequest, signPass, signPaymentRequest, signReceipt, signRedemption, signRequestHMAC, verifyArtifactSignature, verifyArtifactUri, verifyAuthorization, verifyClaimSignature, verifyConsumerPaymentRequest, verifyConsumerSettlement, verifyConsumerSettlementReceiptQR, verifyOAC, verifyOacOffline, verifyOfflineSmsSettleToken, verifyPass, verifyPaymentRequest, verifyReceipt, verifyRedemption, verifyRequestHMAC, verifyRevocationList, writeTLV };
|