@curless/hotel-storefront 0.58.2 → 0.60.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/account/fake-mall.d.ts +19 -0
- package/dist/account/fake-mall.d.ts.map +1 -1
- package/dist/account/fake-mall.js +81 -10
- package/dist/account/fake-mall.js.map +1 -1
- package/dist/account/index.d.ts +75 -3
- package/dist/account/index.d.ts.map +1 -1
- package/dist/account/index.js +765 -31
- package/dist/account/index.js.map +1 -1
- package/dist/account/mall.d.ts +3 -1
- package/dist/account/mall.d.ts.map +1 -1
- package/dist/account/mall.js +17 -2
- package/dist/account/mall.js.map +1 -1
- package/dist/account/ota-member.d.ts +72 -0
- package/dist/account/ota-member.d.ts.map +1 -0
- package/dist/account/ota-member.js +127 -0
- package/dist/account/ota-member.js.map +1 -0
- package/dist/account/pages.d.ts +99 -4
- package/dist/account/pages.d.ts.map +1 -1
- package/dist/account/pages.js +221 -16
- package/dist/account/pages.js.map +1 -1
- package/dist/account/requests.d.ts +13 -1
- package/dist/account/requests.d.ts.map +1 -1
- package/dist/account/requests.js +2 -1
- package/dist/account/requests.js.map +1 -1
- package/dist/account/store.d.ts +8 -0
- package/dist/account/store.d.ts.map +1 -1
- package/dist/account/store.js.map +1 -1
- package/dist/aggregate/places.d.ts +10 -0
- package/dist/aggregate/places.d.ts.map +1 -1
- package/dist/aggregate/places.js +21 -0
- package/dist/aggregate/places.js.map +1 -1
- package/dist/card.generated.d.ts +1 -1
- package/dist/card.generated.js +2 -2
- package/dist/card.generated.js.map +1 -1
- package/dist/choices.d.ts +88 -0
- package/dist/choices.d.ts.map +1 -0
- package/dist/choices.js +126 -0
- package/dist/choices.js.map +1 -0
- package/dist/otaless/backend.d.ts +28 -0
- package/dist/otaless/backend.d.ts.map +1 -1
- package/dist/otaless/backend.js +349 -93
- package/dist/otaless/backend.js.map +1 -1
- package/dist/otaless/client.d.ts +46 -4
- package/dist/otaless/client.d.ts.map +1 -1
- package/dist/otaless/client.js +138 -35
- package/dist/otaless/client.js.map +1 -1
- package/dist/otaless/limits.d.ts +58 -0
- package/dist/otaless/limits.d.ts.map +1 -0
- package/dist/otaless/limits.js +132 -0
- package/dist/otaless/limits.js.map +1 -0
- package/dist/otaless/make.d.ts.map +1 -1
- package/dist/otaless/make.js +14 -1
- package/dist/otaless/make.js.map +1 -1
- package/dist/otaless/places.d.ts +40 -4
- package/dist/otaless/places.d.ts.map +1 -1
- package/dist/otaless/places.js +152 -2
- package/dist/otaless/places.js.map +1 -1
- package/dist/present.d.ts +12 -1
- package/dist/present.d.ts.map +1 -1
- package/dist/present.js +27 -1
- package/dist/present.js.map +1 -1
- package/dist/server.d.ts +2 -2
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +53 -35
- package/dist/server.js.map +1 -1
- package/dist/sessions.d.ts +23 -4
- package/dist/sessions.d.ts.map +1 -1
- package/dist/sessions.js +57 -7
- package/dist/sessions.js.map +1 -1
- package/dist/supplier.d.ts +6 -0
- package/dist/supplier.d.ts.map +1 -1
- package/dist/supplier.js.map +1 -1
- package/dist/surface.js +1 -1
- package/dist/surface.js.map +1 -1
- package/dist/tools.d.ts +11 -1
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +424 -169
- package/dist/tools.js.map +1 -1
- package/dist/trip-ids.d.ts +35 -4
- package/dist/trip-ids.d.ts.map +1 -1
- package/dist/trip-ids.js +87 -19
- package/dist/trip-ids.js.map +1 -1
- package/dist/types.d.ts +35 -6
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -34,7 +34,26 @@ export type FakeMall = {
|
|
|
34
34
|
fault: (on: boolean) => void;
|
|
35
35
|
/** The next request to this path waits until the function handed back is called - a mall keeping one caller waiting. */
|
|
36
36
|
holdNext: (path: string) => () => void;
|
|
37
|
+
/**
|
|
38
|
+
* The backend's hotel-group memberships (`/api/v1/ota/*`, 0.58.0), by
|
|
39
|
+
* `group:email`. ⚠️ AS THE DEV BACKEND IS (questions #48): a sign-in with no
|
|
40
|
+
* password answers `signedIn: true` with a token and a sign-in form for its
|
|
41
|
+
* payload - what our side must refuse.
|
|
42
|
+
*/
|
|
43
|
+
otaMembers: Map<string, FakeOtaMember>;
|
|
44
|
+
/** The membership tokens issued and not signed out: token → `group:email`. */
|
|
45
|
+
otaTokens: Map<string, string>;
|
|
37
46
|
};
|
|
47
|
+
export type FakeOtaMember = {
|
|
48
|
+
group: string;
|
|
49
|
+
email: string;
|
|
50
|
+
password: string;
|
|
51
|
+
name: string;
|
|
52
|
+
memberNo: string;
|
|
53
|
+
label: string;
|
|
54
|
+
};
|
|
55
|
+
/** A ready-made Atour membership on the fake backend - a test's, never a real one. */
|
|
56
|
+
export declare const FAKE_OTA_MEMBER: FakeOtaMember;
|
|
38
57
|
export declare const createFakeMall: (opts?: {
|
|
39
58
|
tenant?: string;
|
|
40
59
|
expireIn?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fake-mall.d.ts","sourceRoot":"","sources":["../../src/account/fake-mall.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fake-mall.d.ts","sourceRoot":"","sources":["../../src/account/fake-mall.ts"],"names":[],"mappings":"AAYA,MAAM,MAAM,UAAU,GAAG;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,yDAAyD;AACzD,eAAO,MAAM,WAAW,EAAE,IAAI,CAAC,UAAU,EAAE,IAAI,CAO9C,CAAC;AAEF,6FAA6F;AAC7F,MAAM,MAAM,YAAY,GAAG;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE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AAQ,CAAC,EAAE,MAAM,CAAA;CAAO,KAAG,QA+MlF,CAAC"}
|
|
@@ -1,13 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
// preview - never a deployment, and never the dev backend (robin, 2026-11-06:
|
|
3
|
-
// he makes his own account there). Its answers are the shapes Nexva One reads
|
|
4
|
-
// from the same API (marketplace evals/mall.mjs): an envelope with its own
|
|
5
|
-
// `code`, `data.access_token` and `data.user_info` from a sign-in, and
|
|
6
|
-
// member/info answering HTTP 200 with nothing at all to a token that is not a
|
|
7
|
-
// member's - as apidev did on 2026-11-06.
|
|
8
|
-
//
|
|
9
|
-
// One member is there from the start - a made-up person (example.com, a 555
|
|
10
|
-
// number) - and any account made on it is kept in this process only.
|
|
1
|
+
import { randomBytes } from 'node:crypto';
|
|
11
2
|
/** Who is there from the start: `lin` / `Lin-demo-1`. */
|
|
12
3
|
export const FAKE_MEMBER = {
|
|
13
4
|
userName: 'lin',
|
|
@@ -17,9 +8,22 @@ export const FAKE_MEMBER = {
|
|
|
17
8
|
email: 'lin.wei@example.com',
|
|
18
9
|
mobile: '+1 555 0134 2288',
|
|
19
10
|
};
|
|
11
|
+
/** A ready-made Atour membership on the fake backend - a test's, never a real one. */
|
|
12
|
+
export const FAKE_OTA_MEMBER = {
|
|
13
|
+
group: 'atour',
|
|
14
|
+
email: 'lin@example.com',
|
|
15
|
+
password: 'Atour-demo-1',
|
|
16
|
+
name: 'Lin Xiaoyu',
|
|
17
|
+
memberNo: 'AT88123456',
|
|
18
|
+
label: 'ACARD Gold (AT88123456)',
|
|
19
|
+
};
|
|
20
20
|
export const createFakeMall = (opts = {}) => {
|
|
21
21
|
const members = new Map([['lin', { id: 30001, ...FAKE_MEMBER }]]);
|
|
22
22
|
const tokens = new Map(); // access token → user name
|
|
23
|
+
const otaMembers = new Map([
|
|
24
|
+
[`${FAKE_OTA_MEMBER.group}:${FAKE_OTA_MEMBER.email}`, { ...FAKE_OTA_MEMBER }],
|
|
25
|
+
]);
|
|
26
|
+
const otaTokens = new Map();
|
|
23
27
|
const refreshes = new Map(); // refresh token → user name
|
|
24
28
|
const calls = [];
|
|
25
29
|
const bodies = [];
|
|
@@ -131,6 +135,71 @@ export const createFakeMall = (opts = {}) => {
|
|
|
131
135
|
refreshes.delete(String(body.refresh_token));
|
|
132
136
|
return ok(issue(u));
|
|
133
137
|
}
|
|
138
|
+
if (path.startsWith('/api/v1/ota/')) {
|
|
139
|
+
const bearer = (headers.get('authorization') ?? '').replace(/^Bearer\s+/i, '');
|
|
140
|
+
const buyer = tokens.get(bearer);
|
|
141
|
+
const group = String(body.providerCode ?? '').toLowerCase();
|
|
142
|
+
if (path === '/api/v1/ota/sign-in' && method === 'POST') {
|
|
143
|
+
const id = `${group}:${String(body.username ?? '').toLowerCase()}`;
|
|
144
|
+
if (!body.password)
|
|
145
|
+
// The dev backend's answer to a sign-in with nothing in it (questions #48).
|
|
146
|
+
return ok({
|
|
147
|
+
providerCode: group,
|
|
148
|
+
success: true,
|
|
149
|
+
signedIn: true,
|
|
150
|
+
accessToken: `satoken_${randomBytes(8).toString('hex')}`,
|
|
151
|
+
expireIn: 7200,
|
|
152
|
+
mcpToken: null,
|
|
153
|
+
rawPayload: { _card: 'market_login', identity_field: 'email' },
|
|
154
|
+
});
|
|
155
|
+
const m = otaMembers.get(id);
|
|
156
|
+
if (!m || m.password !== body.password || !buyer)
|
|
157
|
+
return bad(500, '登录失败');
|
|
158
|
+
const access = `satoken_${randomBytes(12).toString('hex')}`;
|
|
159
|
+
otaTokens.set(access, id);
|
|
160
|
+
return ok({
|
|
161
|
+
providerCode: group,
|
|
162
|
+
success: true,
|
|
163
|
+
signedIn: true,
|
|
164
|
+
accessToken: access,
|
|
165
|
+
tokenType: 'Bearer',
|
|
166
|
+
expireIn: 7200,
|
|
167
|
+
mcpToken: `${group}_tok_${randomBytes(6).toString('hex')}`,
|
|
168
|
+
sessionToken: 'same',
|
|
169
|
+
accountLabel: m.label,
|
|
170
|
+
newlyEnrolled: false,
|
|
171
|
+
});
|
|
172
|
+
}
|
|
173
|
+
if (path === '/api/v1/ota/member/register' && method === 'POST') {
|
|
174
|
+
if (!body.password || !body.email || !body.name)
|
|
175
|
+
return bad(500, '参数不完整');
|
|
176
|
+
const id = `${group}:${String(body.email).toLowerCase()}`;
|
|
177
|
+
if (otaMembers.has(id))
|
|
178
|
+
return ok({ providerCode: group, success: true, alreadyRegistered: true });
|
|
179
|
+
const memberNo = `${group.slice(0, 2).toUpperCase()}${70000000 + otaMembers.size}`;
|
|
180
|
+
otaMembers.set(id, {
|
|
181
|
+
group,
|
|
182
|
+
email: String(body.email).toLowerCase(),
|
|
183
|
+
password: String(body.password),
|
|
184
|
+
name: String(body.name),
|
|
185
|
+
memberNo,
|
|
186
|
+
label: `Member (${memberNo})`,
|
|
187
|
+
});
|
|
188
|
+
return ok({
|
|
189
|
+
providerCode: group,
|
|
190
|
+
success: true,
|
|
191
|
+
alreadyRegistered: false,
|
|
192
|
+
memberNo,
|
|
193
|
+
tier: 'classic',
|
|
194
|
+
});
|
|
195
|
+
}
|
|
196
|
+
if (path === '/api/v1/ota/sign-out' && method === 'POST') {
|
|
197
|
+
for (const [t, id] of [...otaTokens])
|
|
198
|
+
if (id.startsWith(`${group}:`))
|
|
199
|
+
otaTokens.delete(t);
|
|
200
|
+
return ok({ providerCode: group, success: true, signedOut: true });
|
|
201
|
+
}
|
|
202
|
+
}
|
|
134
203
|
if (path === '/api/v1/member/logout' && method === 'POST') {
|
|
135
204
|
tokens.delete(token);
|
|
136
205
|
return ok(null);
|
|
@@ -156,6 +225,8 @@ export const createFakeMall = (opts = {}) => {
|
|
|
156
225
|
fault: (on) => {
|
|
157
226
|
isFault = on;
|
|
158
227
|
},
|
|
228
|
+
otaMembers,
|
|
229
|
+
otaTokens,
|
|
159
230
|
holdNext: (path) => {
|
|
160
231
|
let release = () => { };
|
|
161
232
|
holds.set(path, new Promise((ok) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fake-mall.js","sourceRoot":"","sources":["../../src/account/fake-mall.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"fake-mall.js","sourceRoot":"","sources":["../../src/account/fake-mall.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAsB1C,yDAAyD;AACzD,MAAM,CAAC,MAAM,WAAW,GAA2B;IACjD,QAAQ,EAAE,KAAK;IACf,QAAQ,EAAE,YAAY;IACtB,QAAQ,EAAE,KAAK;IACf,IAAI,EAAE,SAAS;IACf,KAAK,EAAE,qBAAqB;IAC5B,MAAM,EAAE,kBAAkB;CAC3B,CAAC;AA6CF,sFAAsF;AACtF,MAAM,CAAC,MAAM,eAAe,GAAkB;IAC5C,KAAK,EAAE,OAAO;IACd,KAAK,EAAE,iBAAiB;IACxB,QAAQ,EAAE,cAAc;IACxB,IAAI,EAAE,YAAY;IAClB,QAAQ,EAAE,YAAY;IACtB,KAAK,EAAE,yBAAyB;CACjC,CAAC;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,OAA+C,EAAE,EAAY,EAAE;IAC5F,MAAM,OAAO,GAAG,IAAI,GAAG,CAAqB,CAAC,CAAC,KAAK,EAAE,EAAE,EAAE,EAAE,KAAK,EAAE,GAAG,WAAW,EAAE,CAAC,CAAC,CAAC,CAAC;IACtF,MAAM,MAAM,GAAG,IAAI,GAAG,EAAkB,CAAC,CAAC,2BAA2B;IACrE,MAAM,UAAU,GAAG,IAAI,GAAG,CAAwB;QAChD,CAAC,GAAG,eAAe,CAAC,KAAK,IAAI,eAAe,CAAC,KAAK,EAAE,EAAE,EAAE,GAAG,eAAe,EAAE,CAAC;KAC9E,CAAC,CAAC;IACH,MAAM,SAAS,GAAG,IAAI,GAAG,EAAkB,CAAC;IAC5C,MAAM,SAAS,GAAG,IAAI,GAAG,EAAkB,CAAC,CAAC,4BAA4B;IACzE,MAAM,KAAK,GAAmB,EAAE,CAAC;IACjC,MAAM,MAAM,GAAs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AAC,IAAI,CAAC,GAAG,SAAS,CAAC;gBAAE,IAAI,CAAC,KAAK,QAAQ;oBAAE,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;QAC/E,CAAC;QACD,IAAI,EAAE,CAAC,EAAE,EAAE,EAAE;YACX,MAAM,GAAG,EAAE,CAAC;QACd,CAAC;QACD,KAAK,EAAE,CAAC,EAAE,EAAE,EAAE;YACZ,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,UAAU;QACV,SAAS;QACT,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;YACjB,IAAI,OAAO,GAAG,GAAG,EAAE,GAAE,CAAC,CAAC;YACvB,KAAK,CAAC,GAAG,CACP,IAAI,EACJ,IAAI,OAAO,CAAO,CAAC,EAAE,EAAE,EAAE;gBACvB,OAAO,GAAG,EAAE,CAAC;YACf,CAAC,CAAC,CACH,CAAC;YACF,OAAO,GAAG,EAAE,CAAC,OAAO,EAAE,CAAC;QACzB,CAAC;KACF,CAAC;AACJ,CAAC,CAAC"}
|
package/dist/account/index.d.ts
CHANGED
|
@@ -7,6 +7,24 @@ export type AccountConfig = {
|
|
|
7
7
|
tenant?: string;
|
|
8
8
|
/** `<envPrefix>_API_URL` / `<envPrefix>_TENANT_ID` win over the two above. Default `ACCOUNT`. */
|
|
9
9
|
envPrefix?: string;
|
|
10
|
+
/**
|
|
11
|
+
* The hotel groups whose membership can be linked to the account (0.58.0) -
|
|
12
|
+
* by the backend's `providerCode`. None listed, none can: no tool, no row,
|
|
13
|
+
* no page says a word of it.
|
|
14
|
+
*/
|
|
15
|
+
memberships?: AccountMembershipConfig[];
|
|
16
|
+
};
|
|
17
|
+
export type AccountMembershipConfig = {
|
|
18
|
+
code: string;
|
|
19
|
+
/** The group as the guest knows it - "Atour"; the code where absent. */
|
|
20
|
+
name?: string;
|
|
21
|
+
names?: {
|
|
22
|
+
zh?: string;
|
|
23
|
+
};
|
|
24
|
+
/** An existing membership can be linked. Default true. */
|
|
25
|
+
signIn?: boolean;
|
|
26
|
+
/** A new membership can be made and linked. Default false. */
|
|
27
|
+
join?: boolean;
|
|
10
28
|
};
|
|
11
29
|
/**
|
|
12
30
|
* The tools, by the deployment's prefix: three the assistant calls -
|
|
@@ -24,12 +42,15 @@ export declare const accountToolNames: (prefix: string) => {
|
|
|
24
42
|
readonly view: `view_${string}account`;
|
|
25
43
|
readonly signOut: `sign_out_${string}account`;
|
|
26
44
|
readonly card: `card_${string}account`;
|
|
45
|
+
readonly link: `link_${string}membership`;
|
|
27
46
|
};
|
|
28
47
|
export type AccountToolNames = ReturnType<typeof accountToolNames>;
|
|
29
48
|
/** Beside every answer of a deployment with an account, for the card's header. */
|
|
30
49
|
export declare const ACCOUNT_META_KEY = "curless/account";
|
|
31
50
|
/** Beside a sign-in's answer where a card is drawn: the link and its short code, the card's alone. */
|
|
32
51
|
export declare const SIGN_IN_META_KEY = "curless/account-sign-in";
|
|
52
|
+
/** …and beside a membership link's answer (0.58.0): the same, with the group. */
|
|
53
|
+
export declare const LINK_META_KEY = "curless/account-link";
|
|
33
54
|
/** The mall is asked at most this often whether a sign-in is still theirs. */
|
|
34
55
|
export declare const CHECK_EVERY_MS: number;
|
|
35
56
|
export declare const COOKIE = "__Host-hotel_account";
|
|
@@ -81,13 +102,25 @@ export type Account = {
|
|
|
81
102
|
has: (name: string) => boolean;
|
|
82
103
|
handle: (name: string, args: Record<string, unknown>, call: AccountCall) => Promise<AccountAnswer>;
|
|
83
104
|
/**
|
|
84
|
-
* What every answer carries for the card's header. `cards`: the session
|
|
85
|
-
* cards
|
|
105
|
+
* What every answer carries for the card's header. `cards`: the session said
|
|
106
|
+
* it draws cards; `ours`: the call acted on its own conversation, naming no
|
|
107
|
+
* trip or its own. Only with both is the user name in it (0.56.1, 0.59.0).
|
|
86
108
|
*/
|
|
87
|
-
meta: (key: string,
|
|
109
|
+
meta: (key: string, who: {
|
|
110
|
+
cards: boolean;
|
|
111
|
+
ours: boolean;
|
|
112
|
+
}) => Record<string, unknown>;
|
|
88
113
|
instructions: (noCards: boolean) => string;
|
|
89
114
|
mount: (app: Hono) => void;
|
|
90
115
|
health: () => Record<string, number>;
|
|
116
|
+
/**
|
|
117
|
+
* The backend's token for this conversation's linked membership of a group -
|
|
118
|
+
* for its prices (otaless/client.ts), never shown, logged or kept anywhere
|
|
119
|
+
* else. Undefined: not linked, or its session is over.
|
|
120
|
+
*/
|
|
121
|
+
tokenFor: (key: string, group: string) => string | undefined;
|
|
122
|
+
/** The backend said the group's session is over (its 4012): the link goes. */
|
|
123
|
+
expired: (key: string, group: string) => void;
|
|
91
124
|
};
|
|
92
125
|
export type AccountOptions = {
|
|
93
126
|
account: AccountConfig;
|
|
@@ -110,6 +143,19 @@ export declare const ipOf: (c: Context) => string;
|
|
|
110
143
|
export declare const addressKey: (ip: string) => string;
|
|
111
144
|
export declare const langOf: (v: unknown) => Lang | undefined;
|
|
112
145
|
export declare const acceptLang: (h: string | undefined) => Lang;
|
|
146
|
+
/**
|
|
147
|
+
* A mall failure that says the sign-in is not theirs any more - not a blip on the way.
|
|
148
|
+
*
|
|
149
|
+
* ⚠️ A NO, NOT EVERY ENVELOPE (0.59.0, review C3). Any envelope that was not 200
|
|
150
|
+
* counted - and their envelope says 500 for a fault of their own too (Nexva's
|
|
151
|
+
* audit M-18): one 500 on a renewal a minute before the token lapsed signed the
|
|
152
|
+
* guest out, and ended their token at the mall. Now only a 4xx - HTTP's or the
|
|
153
|
+
* envelope's - is a no: the request was not theirs to grant. A 5xx, a timeout,
|
|
154
|
+
* an answer that is not JSON, a code that is not a number, and 408 / 429 (wait
|
|
155
|
+
* and ask again) leave them signed in, asked again next time. The refresh
|
|
156
|
+
* token's own lapse is the store's (store.ts), not this.
|
|
157
|
+
*/
|
|
158
|
+
export declare const refused: (e: unknown) => boolean;
|
|
113
159
|
/**
|
|
114
160
|
* ⚠️ A POST COMES FROM OUR OWN PAGE (and with the form's token): its Origin is
|
|
115
161
|
* this site - the public origin, or the Host it was sent to (https; http only
|
|
@@ -119,5 +165,31 @@ export declare const acceptLang: (h: string | undefined) => Lang;
|
|
|
119
165
|
export declare const cameFromOurPage: (c: Context, origin: string) => boolean;
|
|
120
166
|
/** A form our page posted - urlencoded, at most 20 fields - or null. */
|
|
121
167
|
export declare const readForm: (c: Context) => Promise<Record<string, unknown> | null>;
|
|
168
|
+
/**
|
|
169
|
+
* ⚠️ A USER NAME'S WRONG GUESSES (review C8, robin 11-09): only a no from the
|
|
170
|
+
* mall counts - a sign-in that works clears the name, and a mall that did not
|
|
171
|
+
* answer is nobody's mistake. `enter` reserves a try BEFORE the mall is asked
|
|
172
|
+
* (it counts the tries still in flight with the failures, so a burst of posts
|
|
173
|
+
* on many links cannot all pass at "7 of 8"); `leave` settles it. No await sits
|
|
174
|
+
* between the check and the reservation. Idle names are forgotten first when
|
|
175
|
+
* the table is full, as WindowCounter does.
|
|
176
|
+
*/
|
|
177
|
+
export declare class NameFailures {
|
|
178
|
+
private readonly windowMs;
|
|
179
|
+
private readonly now;
|
|
180
|
+
private readonly maxKeys;
|
|
181
|
+
private readonly fails;
|
|
182
|
+
private readonly busy;
|
|
183
|
+
constructor(windowMs: number, now: () => number, maxKeys?: number);
|
|
184
|
+
private recent;
|
|
185
|
+
/** Whether this name is shut (failures in the window, with tries in flight, at the limit). */
|
|
186
|
+
shut(key: string, max: number): boolean;
|
|
187
|
+
/** Reserve one try; false (nothing reserved) when the name is shut. */
|
|
188
|
+
enter(key: string, max: number): boolean;
|
|
189
|
+
/** The try is over: `failed` is counted, `ok` clears the name, `unknown` (no answer) counts nothing. */
|
|
190
|
+
leave(key: string, outcome: 'failed' | 'ok' | 'unknown'): void;
|
|
191
|
+
}
|
|
192
|
+
/** How long renewals may go unanswered, the access token lapsed, before the sign-in goes (C3). */
|
|
193
|
+
export declare const RENEW_GIVE_UP_MS: number;
|
|
122
194
|
export declare const makeAccount: (opts: AccountOptions) => Account;
|
|
123
195
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/account/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/account/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AA4B1C,OAAO,EAEL,KAAK,IAAI,EAMV,MAAM,eAAe,CAAC;AA2CvB,MAAM,MAAM,aAAa,GAAG;IAC1B,8DAA8D;IAC9D,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,iGAAiG;IACjG,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,WAAW,CAAC,EAAE,uBAAuB,EAAE,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,uBAAuB,GAAG;IACpC,IAAI,EAAE,MAAM,CAAC;IACb,wEAAwE;IACxE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE;QAAE,EAAE,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IACxB,0DAA0D;IAC1D,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,8DAA8D;IAC9D,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB,CAAC;AAEF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gBAAgB,GAAI,QAAQ,MAAM;;;;;;CASlC,CAAC;AACd,MAAM,MAAM,gBAAgB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEnE,kFAAkF;AAClF,eAAO,MAAM,gBAAgB,oBAAoB,CAAC;AAClD,sGAAsG;AACtG,eAAO,MAAM,gBAAgB,4BAA4B,CAAC;AAC1D,iFAAiF;AACjF,eAAO,MAAM,aAAa,yBAAyB,CAAC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