@helyx/bot 0.4.19 → 0.4.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,36 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.4.22
4
+
5
+ ### Patch Changes
6
+
7
+ - Avoid consuming Verification start limits for active challenges and explain active-link and rate-limit responses safely.
8
+ - Updated dependencies
9
+ - @helyx/database@0.7.5
10
+ - @helyx/platform@0.4.6
11
+
12
+ ## 0.4.21
13
+
14
+ ### Patch Changes
15
+
16
+ - Add Verification re-verification reset support and browser assessment progress contracts.
17
+ - Updated dependencies
18
+ - @helyx/verification-contracts@0.3.0
19
+ - @helyx/database@0.7.4
20
+ - @helyx/sdk@0.6.2
21
+ - @helyx/platform@0.4.5
22
+ - @helyx/core@0.1.15
23
+ - @helyx/framework@0.1.15
24
+
25
+ ## 0.4.20
26
+
27
+ ### Patch Changes
28
+
29
+ - Normalize published package manifest formatting.
30
+ - Updated dependencies
31
+ - @helyx/database@0.7.3
32
+ - @helyx/platform@0.4.4
33
+
3
34
  ## 0.4.19
4
35
 
5
36
  ### Patch Changes
package/dist/events.js CHANGED
@@ -872,6 +872,7 @@ export class DiscordVerificationMemberService {
872
872
  safeDisplayName: (member.displayName || member.user.username)
873
873
  .normalize("NFC")
874
874
  .slice(0, 100),
875
+ safeServerName: guild.name.normalize("NFC").slice(0, 100),
875
876
  guildOwnerId: guild.ownerId,
876
877
  accountCreatedAt: member.user.createdAt.toISOString(),
877
878
  joinedAt: member.joinedAt?.toISOString() ?? null,
@@ -426,14 +426,16 @@ export declare const shardControlOperationSchema: z.ZodDiscriminatedUnion<[z.Zod
426
426
  }>>;
427
427
  actionBoundary: z.ZodObject<{
428
428
  recommendedAction: z.ZodEnum<{
429
- none: "none";
430
429
  grant_role: "grant_role";
430
+ remove_role: "remove_role";
431
+ none: "none";
431
432
  kick: "kick";
432
433
  ban: "ban";
433
434
  }>;
434
435
  allowedActions: z.ZodArray<z.ZodEnum<{
435
- none: "none";
436
436
  grant_role: "grant_role";
437
+ remove_role: "remove_role";
438
+ none: "none";
437
439
  kick: "kick";
438
440
  ban: "ban";
439
441
  }>>;
@@ -733,14 +735,16 @@ export declare const shardControlRequestSchema: z.ZodObject<{
733
735
  }>>;
734
736
  actionBoundary: z.ZodObject<{
735
737
  recommendedAction: z.ZodEnum<{
736
- none: "none";
737
738
  grant_role: "grant_role";
739
+ remove_role: "remove_role";
740
+ none: "none";
738
741
  kick: "kick";
739
742
  ban: "ban";
740
743
  }>;
741
744
  allowedActions: z.ZodArray<z.ZodEnum<{
742
- none: "none";
743
745
  grant_role: "grant_role";
746
+ remove_role: "remove_role";
747
+ none: "none";
744
748
  kick: "kick";
745
749
  ban: "ban";
746
750
  }>>;
@@ -1545,14 +1549,16 @@ export declare const supervisorMessageSchema: z.ZodDiscriminatedUnion<[z.ZodObje
1545
1549
  }>>;
1546
1550
  actionBoundary: z.ZodObject<{
1547
1551
  recommendedAction: z.ZodEnum<{
1548
- none: "none";
1549
1552
  grant_role: "grant_role";
1553
+ remove_role: "remove_role";
1554
+ none: "none";
1550
1555
  kick: "kick";
1551
1556
  ban: "ban";
1552
1557
  }>;
1553
1558
  allowedActions: z.ZodArray<z.ZodEnum<{
1554
- none: "none";
1555
1559
  grant_role: "grant_role";
1560
+ remove_role: "remove_role";
1561
+ none: "none";
1556
1562
  kick: "kick";
1557
1563
  ban: "ban";
1558
1564
  }>>;
@@ -9,7 +9,7 @@ export declare function createLeaseHeartbeatWatchdog(onExpired: () => void, time
9
9
  };
10
10
  export declare function startShardWorker(processEnvironment?: NodeJS.ProcessEnv, identity?: {
11
11
  version: 1;
12
- mode: "auto" | "fixed";
12
+ mode: "fixed" | "auto";
13
13
  scope: "local" | "coordinated";
14
14
  generation: string;
15
15
  supervisorId: string;
@@ -36,7 +36,7 @@ export declare class HttpVerificationService implements VerificationService {
36
36
  attemptId: string;
37
37
  expectedVersion: number;
38
38
  actorUserId: string;
39
- decision: "approve" | "deny" | "retry" | "dismiss_relationship";
39
+ decision: "approve" | "deny" | "retry" | "reset" | "dismiss_relationship";
40
40
  reason: string;
41
41
  }): Promise<DashboardSafeAttemptDetail>;
42
42
  registerResultHandler(handler: (context: VerificationResultContext) => Promise<ActionReceipt>): () => void;
@@ -138,9 +138,14 @@ export class HttpVerificationService {
138
138
  if (allowNotFound && response.status === 404)
139
139
  return null;
140
140
  if (!response.ok)
141
- throw new Error(response.status >= 500
142
- ? "Verification service is unavailable"
143
- : "Verification request was rejected");
141
+ if (response.status === 409)
142
+ throw new Error("A verification link is already active. Wait for it to expire before requesting another.");
143
+ else if (response.status === 429)
144
+ throw new Error("Verification requests are temporarily limited. Try again shortly.");
145
+ else
146
+ throw new Error(response.status >= 500
147
+ ? "Verification service is unavailable"
148
+ : "Verification request was rejected");
144
149
  try {
145
150
  return await response.json();
146
151
  }
package/package.json CHANGED
@@ -1,70 +1,70 @@
1
- {
2
- "name": "@helyx/bot",
3
- "version": "0.4.19",
4
- "description": "Production Discord runtime for the modular Helyx platform.",
5
- "keywords": [
6
- "helyx",
7
- "discord",
8
- "bot",
9
- "modular"
10
- ],
11
- "private": false,
12
- "license": "HSAL 1.0",
13
- "homepage": "https://helyx.gg/",
14
- "bugs": {
15
- "url": "https://github.com/ZyC0R3/Helyx/issues"
16
- },
17
- "repository": {
18
- "type": "git",
19
- "url": "git+https://github.com/ZyC0R3/Helyx.git",
20
- "directory": "apps/bot"
21
- },
22
- "engines": {
23
- "node": ">=24 <27",
24
- "npm": ">=11"
25
- },
26
- "publishConfig": {
27
- "access": "public",
28
- "provenance": true
29
- },
30
- "type": "module",
31
- "files": [
32
- "dist",
33
- "!dist/*.tsbuildinfo",
34
- "!dist/**/*.map",
35
- "CHANGELOG.md",
36
- "README.md",
37
- "LICENSE"
38
- ],
39
- "exports": {
40
- ".": {
41
- "types": "./dist/index.d.ts",
42
- "default": "./dist/index.js"
43
- }
44
- },
45
- "scripts": {
46
- "build": "tsc -b",
47
- "dev": "node --env-file-if-exists=../../.env --import tsx src/index.ts",
48
- "start": "node --env-file-if-exists=../../.env dist/index.js"
49
- },
50
- "dependencies": {
51
- "@helyx/config": "0.5.0",
52
- "@helyx/control-protocol": "0.3.2",
53
- "@helyx/core": "0.1.14",
54
- "@helyx/database": "0.7.2",
55
- "@helyx/framework": "0.1.14",
56
- "@helyx/module-manifest": "0.6.0",
57
- "@helyx/platform": "0.4.3",
58
- "@helyx/sdk": "0.6.1",
59
- "@helyx/verification-contracts": "0.2.1",
60
- "discord.js": "14.27.0",
61
- "fastify": "5.10.0",
62
- "pino": "10.3.1",
63
- "redis": "6.1.0",
64
- "ws": "8.21.1",
65
- "zod": "4.4.3"
66
- },
67
- "devDependencies": {
68
- "@types/ws": "8.18.1"
69
- }
70
- }
1
+ {
2
+ "name": "@helyx/bot",
3
+ "version": "0.4.22",
4
+ "description": "Production Discord runtime for the modular Helyx platform.",
5
+ "keywords": [
6
+ "helyx",
7
+ "discord",
8
+ "bot",
9
+ "modular"
10
+ ],
11
+ "private": false,
12
+ "license": "HSAL 1.0",
13
+ "homepage": "https://helyx.gg/",
14
+ "bugs": {
15
+ "url": "https://github.com/ZyC0R3/Helyx/issues"
16
+ },
17
+ "repository": {
18
+ "type": "git",
19
+ "url": "git+https://github.com/ZyC0R3/Helyx.git",
20
+ "directory": "apps/bot"
21
+ },
22
+ "engines": {
23
+ "node": ">=24 <27",
24
+ "npm": ">=11"
25
+ },
26
+ "publishConfig": {
27
+ "access": "public",
28
+ "provenance": true
29
+ },
30
+ "type": "module",
31
+ "files": [
32
+ "dist",
33
+ "!dist/*.tsbuildinfo",
34
+ "!dist/**/*.map",
35
+ "CHANGELOG.md",
36
+ "README.md",
37
+ "LICENSE"
38
+ ],
39
+ "exports": {
40
+ ".": {
41
+ "types": "./dist/index.d.ts",
42
+ "default": "./dist/index.js"
43
+ }
44
+ },
45
+ "scripts": {
46
+ "build": "tsc -b",
47
+ "dev": "node --env-file-if-exists=../../.env --import tsx src/index.ts",
48
+ "start": "node --env-file-if-exists=../../.env dist/index.js"
49
+ },
50
+ "dependencies": {
51
+ "@helyx/config": "0.5.0",
52
+ "@helyx/control-protocol": "0.3.2",
53
+ "@helyx/core": "0.1.15",
54
+ "@helyx/database": "0.7.5",
55
+ "@helyx/framework": "0.1.15",
56
+ "@helyx/module-manifest": "0.6.0",
57
+ "@helyx/platform": "0.4.6",
58
+ "@helyx/sdk": "0.6.2",
59
+ "@helyx/verification-contracts": "0.3.0",
60
+ "discord.js": "14.27.0",
61
+ "fastify": "5.10.0",
62
+ "pino": "10.3.1",
63
+ "redis": "6.1.0",
64
+ "ws": "8.21.1",
65
+ "zod": "4.4.3"
66
+ },
67
+ "devDependencies": {
68
+ "@types/ws": "8.18.1"
69
+ }
70
+ }