@passflow/core 0.29.0 → 0.30.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 +13 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +26 -1
- package/dist/index.d.ts +26 -1
- package/dist/index.mjs +623 -606
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1059,7 +1059,9 @@ export declare enum PassflowEndpointPaths {
|
|
|
1059
1059
|
TwoFactorTrustedDeviceRevoke = "/v2/user/2fa/trusted-devices/:id",
|
|
1060
1060
|
cliAuthStatus = "/cli/auth/status/:sessionId",
|
|
1061
1061
|
cliAuthComplete = "/cli/auth/complete",
|
|
1062
|
-
upgradeStart = "/auth/upgrade/start"
|
|
1062
|
+
upgradeStart = "/auth/upgrade/start",
|
|
1063
|
+
hostedUpgradeStart = "/auth/session/upgrade/start",
|
|
1064
|
+
hostedUpgrade = "/auth/session/upgrade"
|
|
1063
1065
|
}
|
|
1064
1066
|
export declare enum PassflowAdminEndpointPaths {
|
|
1065
1067
|
passkeyRegisterStart = "/admin/auth/passkey/register/start",
|
|
@@ -1205,6 +1207,7 @@ export type UpgradeStartWire = {
|
|
|
1205
1207
|
};
|
|
1206
1208
|
/**
|
|
1207
1209
|
* The `upgrade` field of `POST /auth/refresh` — the commit round.
|
|
1210
|
+
* Also the whole body of `POST /auth/session/upgrade`.
|
|
1208
1211
|
*
|
|
1209
1212
|
* The server types `assertion` as `json.RawMessage`, so a new factor can extend
|
|
1210
1213
|
* the payload without a wire-format change.
|
|
@@ -2709,6 +2712,17 @@ export declare class UpgradeAPI {
|
|
|
2709
2712
|
* behind the user's back.
|
|
2710
2713
|
*/
|
|
2711
2714
|
startUpgrade(payload: UpgradeStartPayload): Promise<UpgradeStartWire>;
|
|
2715
|
+
/**
|
|
2716
|
+
* Issues an upgrade challenge for the hosted sign-in session. Authenticated by the session
|
|
2717
|
+
* cookie alone: no bearer is sent and no stored token is refreshed first (see `AxiosClient`).
|
|
2718
|
+
* Same answer shape as `startUpgrade`.
|
|
2719
|
+
*/
|
|
2720
|
+
startHostedUpgrade(payload: UpgradeStartPayload): Promise<UpgradeStartWire>;
|
|
2721
|
+
/**
|
|
2722
|
+
* Proves the factor for the hosted sign-in session. The body is the proof itself, not wrapped.
|
|
2723
|
+
* The server answers 204 and issues nothing, so nothing is stored.
|
|
2724
|
+
*/
|
|
2725
|
+
commitHostedUpgrade(upgrade: UpgradeRefreshField): Promise<void>;
|
|
2712
2726
|
}
|
|
2713
2727
|
export declare class UserAPI {
|
|
2714
2728
|
protected axiosClient: AxiosClient;
|
|
@@ -5527,6 +5541,17 @@ export declare class Passflow {
|
|
|
5527
5541
|
* a global or install a prompt.
|
|
5528
5542
|
*/
|
|
5529
5543
|
readonly upgrade: UpgradeFacade;
|
|
5544
|
+
/**
|
|
5545
|
+
* Step-up of the hosted sign-in session, the HttpOnly cookie the hosted login page holds. Same
|
|
5546
|
+
* surface as `upgrade`, over `POST /auth/session/upgrade/start` and `POST /auth/session/upgrade`:
|
|
5547
|
+
* no bearer is sent, and the server issues nothing, so no tokens are stored. Never touches the
|
|
5548
|
+
* token session that `upgrade` steps up.
|
|
5549
|
+
*
|
|
5550
|
+
* Use only `enable({ prompt })`, called once, then `elevate(challenge, { kind: 'imperative' })`.
|
|
5551
|
+
* Do not pass `interceptFetch` and do not use `withAuth` or `attachAuth`: each of them would step
|
|
5552
|
+
* up the cookie session on a challenge from an unrelated call.
|
|
5553
|
+
*/
|
|
5554
|
+
readonly hostedUpgrade: UpgradeFacade;
|
|
5530
5555
|
/**
|
|
5531
5556
|
* Passflow's own API as an interception scope ("domain 1"), resolved ONCE
|
|
5532
5557
|
* here from `PassflowConfig.url` so no adapter or wrapper ever derives it.
|
package/dist/index.d.ts
CHANGED
|
@@ -1059,7 +1059,9 @@ export declare enum PassflowEndpointPaths {
|
|
|
1059
1059
|
TwoFactorTrustedDeviceRevoke = "/v2/user/2fa/trusted-devices/:id",
|
|
1060
1060
|
cliAuthStatus = "/cli/auth/status/:sessionId",
|
|
1061
1061
|
cliAuthComplete = "/cli/auth/complete",
|
|
1062
|
-
upgradeStart = "/auth/upgrade/start"
|
|
1062
|
+
upgradeStart = "/auth/upgrade/start",
|
|
1063
|
+
hostedUpgradeStart = "/auth/session/upgrade/start",
|
|
1064
|
+
hostedUpgrade = "/auth/session/upgrade"
|
|
1063
1065
|
}
|
|
1064
1066
|
export declare enum PassflowAdminEndpointPaths {
|
|
1065
1067
|
passkeyRegisterStart = "/admin/auth/passkey/register/start",
|
|
@@ -1205,6 +1207,7 @@ export type UpgradeStartWire = {
|
|
|
1205
1207
|
};
|
|
1206
1208
|
/**
|
|
1207
1209
|
* The `upgrade` field of `POST /auth/refresh` — the commit round.
|
|
1210
|
+
* Also the whole body of `POST /auth/session/upgrade`.
|
|
1208
1211
|
*
|
|
1209
1212
|
* The server types `assertion` as `json.RawMessage`, so a new factor can extend
|
|
1210
1213
|
* the payload without a wire-format change.
|
|
@@ -2709,6 +2712,17 @@ export declare class UpgradeAPI {
|
|
|
2709
2712
|
* behind the user's back.
|
|
2710
2713
|
*/
|
|
2711
2714
|
startUpgrade(payload: UpgradeStartPayload): Promise<UpgradeStartWire>;
|
|
2715
|
+
/**
|
|
2716
|
+
* Issues an upgrade challenge for the hosted sign-in session. Authenticated by the session
|
|
2717
|
+
* cookie alone: no bearer is sent and no stored token is refreshed first (see `AxiosClient`).
|
|
2718
|
+
* Same answer shape as `startUpgrade`.
|
|
2719
|
+
*/
|
|
2720
|
+
startHostedUpgrade(payload: UpgradeStartPayload): Promise<UpgradeStartWire>;
|
|
2721
|
+
/**
|
|
2722
|
+
* Proves the factor for the hosted sign-in session. The body is the proof itself, not wrapped.
|
|
2723
|
+
* The server answers 204 and issues nothing, so nothing is stored.
|
|
2724
|
+
*/
|
|
2725
|
+
commitHostedUpgrade(upgrade: UpgradeRefreshField): Promise<void>;
|
|
2712
2726
|
}
|
|
2713
2727
|
export declare class UserAPI {
|
|
2714
2728
|
protected axiosClient: AxiosClient;
|
|
@@ -5527,6 +5541,17 @@ export declare class Passflow {
|
|
|
5527
5541
|
* a global or install a prompt.
|
|
5528
5542
|
*/
|
|
5529
5543
|
readonly upgrade: UpgradeFacade;
|
|
5544
|
+
/**
|
|
5545
|
+
* Step-up of the hosted sign-in session, the HttpOnly cookie the hosted login page holds. Same
|
|
5546
|
+
* surface as `upgrade`, over `POST /auth/session/upgrade/start` and `POST /auth/session/upgrade`:
|
|
5547
|
+
* no bearer is sent, and the server issues nothing, so no tokens are stored. Never touches the
|
|
5548
|
+
* token session that `upgrade` steps up.
|
|
5549
|
+
*
|
|
5550
|
+
* Use only `enable({ prompt })`, called once, then `elevate(challenge, { kind: 'imperative' })`.
|
|
5551
|
+
* Do not pass `interceptFetch` and do not use `withAuth` or `attachAuth`: each of them would step
|
|
5552
|
+
* up the cookie session on a challenge from an unrelated call.
|
|
5553
|
+
*/
|
|
5554
|
+
readonly hostedUpgrade: UpgradeFacade;
|
|
5530
5555
|
/**
|
|
5531
5556
|
* Passflow's own API as an interception scope ("domain 1"), resolved ONCE
|
|
5532
5557
|
* here from `PassflowConfig.url` so no adapter or wrapper ever derives it.
|