ultraclaude-agent 0.0.7 → 0.0.8

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.
Files changed (42) hide show
  1. package/node_modules/@ultra-claude/shared/dist/api/schemas/discussions.d.ts +29 -0
  2. package/node_modules/@ultra-claude/shared/dist/api/schemas/discussions.d.ts.map +1 -0
  3. package/node_modules/@ultra-claude/shared/dist/api/schemas/discussions.js +28 -0
  4. package/node_modules/@ultra-claude/shared/dist/api/schemas/discussions.js.map +1 -0
  5. package/node_modules/@ultra-claude/shared/dist/api/schemas/projects.d.ts +16 -0
  6. package/node_modules/@ultra-claude/shared/dist/api/schemas/projects.d.ts.map +1 -0
  7. package/node_modules/@ultra-claude/shared/dist/api/schemas/projects.js +23 -0
  8. package/node_modules/@ultra-claude/shared/dist/api/schemas/projects.js.map +1 -0
  9. package/node_modules/@ultra-claude/shared/dist/api/schemas/snapshots.d.ts +94 -0
  10. package/node_modules/@ultra-claude/shared/dist/api/schemas/snapshots.d.ts.map +1 -0
  11. package/node_modules/@ultra-claude/shared/dist/api/schemas/snapshots.js +31 -0
  12. package/node_modules/@ultra-claude/shared/dist/api/schemas/snapshots.js.map +1 -0
  13. package/node_modules/@ultra-claude/shared/dist/api/schemas/sync.d.ts +53 -0
  14. package/node_modules/@ultra-claude/shared/dist/api/schemas/sync.d.ts.map +1 -0
  15. package/node_modules/@ultra-claude/shared/dist/api/schemas/sync.js +43 -0
  16. package/node_modules/@ultra-claude/shared/dist/api/schemas/sync.js.map +1 -0
  17. package/node_modules/@ultra-claude/shared/dist/api/schemas/usage.d.ts +54 -0
  18. package/node_modules/@ultra-claude/shared/dist/api/schemas/usage.d.ts.map +1 -0
  19. package/node_modules/@ultra-claude/shared/dist/api/schemas/usage.js +23 -0
  20. package/node_modules/@ultra-claude/shared/dist/api/schemas/usage.js.map +1 -0
  21. package/node_modules/@ultra-claude/shared/dist/hashing.d.ts +3 -0
  22. package/node_modules/@ultra-claude/shared/dist/hashing.d.ts.map +1 -0
  23. package/node_modules/@ultra-claude/shared/dist/hashing.js +9 -0
  24. package/node_modules/@ultra-claude/shared/dist/hashing.js.map +1 -0
  25. package/node_modules/@ultra-claude/shared/dist/index.d.ts +10 -0
  26. package/node_modules/@ultra-claude/shared/dist/index.d.ts.map +1 -0
  27. package/node_modules/@ultra-claude/shared/dist/index.js +10 -0
  28. package/node_modules/@ultra-claude/shared/dist/index.js.map +1 -0
  29. package/node_modules/@ultra-claude/shared/dist/result.d.ts +11 -0
  30. package/node_modules/@ultra-claude/shared/dist/result.d.ts.map +1 -0
  31. package/node_modules/@ultra-claude/shared/dist/result.js +9 -0
  32. package/node_modules/@ultra-claude/shared/dist/result.js.map +1 -0
  33. package/node_modules/@ultra-claude/shared/dist/sections.d.ts +16 -0
  34. package/node_modules/@ultra-claude/shared/dist/sections.d.ts.map +1 -0
  35. package/node_modules/@ultra-claude/shared/dist/sections.js +102 -0
  36. package/node_modules/@ultra-claude/shared/dist/sections.js.map +1 -0
  37. package/node_modules/@ultra-claude/shared/dist/types.d.ts +39 -0
  38. package/node_modules/@ultra-claude/shared/dist/types.d.ts.map +1 -0
  39. package/node_modules/@ultra-claude/shared/dist/types.js +5 -0
  40. package/node_modules/@ultra-claude/shared/dist/types.js.map +1 -0
  41. package/node_modules/@ultra-claude/shared/package.json +23 -0
  42. package/package.json +7 -3
@@ -0,0 +1,29 @@
1
+ import { z } from 'zod';
2
+ export declare const createCommentSchema: z.ZodObject<{
3
+ body: z.ZodString;
4
+ parentId: z.ZodOptional<z.ZodString>;
5
+ fileId: z.ZodOptional<z.ZodString>;
6
+ headingSlug: z.ZodOptional<z.ZodString>;
7
+ taskId: z.ZodOptional<z.ZodString>;
8
+ }, z.core.$strip>;
9
+ export type CreateCommentInput = z.infer<typeof createCommentSchema>;
10
+ export declare const commentResponseSchema: z.ZodObject<{
11
+ id: z.ZodString;
12
+ discussionId: z.ZodString;
13
+ parentId: z.ZodNullable<z.ZodString>;
14
+ userId: z.ZodString;
15
+ body: z.ZodString;
16
+ createdAt: z.ZodString;
17
+ updatedAt: z.ZodString;
18
+ }, z.core.$strip>;
19
+ export type CommentResponse = z.infer<typeof commentResponseSchema>;
20
+ export declare const discussionResponseSchema: z.ZodObject<{
21
+ id: z.ZodString;
22
+ projectId: z.ZodString;
23
+ createdAt: z.ZodString;
24
+ commentCount: z.ZodNumber;
25
+ }, z.core.$strip>;
26
+ export type DiscussionResponse = z.infer<typeof discussionResponseSchema>;
27
+ export declare const discussionCountsResponseSchema: z.ZodRecord<z.ZodString, z.ZodNumber>;
28
+ export type DiscussionCountsResponse = z.infer<typeof discussionCountsResponseSchema>;
29
+ //# sourceMappingURL=discussions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"discussions.d.ts","sourceRoot":"","sources":["../../../src/api/schemas/discussions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,mBAAmB;;;;;;iBAO9B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAIrE,eAAO,MAAM,qBAAqB;;;;;;;;iBAQhC,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,wBAAwB;;;;;iBAKnC,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAE1E,eAAO,MAAM,8BAA8B,uCAAyC,CAAC;AAErF,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC"}
@@ -0,0 +1,28 @@
1
+ import { z } from 'zod';
2
+ // --- POST /api/projects/[id]/discussions/[discussionId]/comments ---
3
+ export const createCommentSchema = z.object({
4
+ body: z.string().min(1).max(50_000),
5
+ parentId: z.string().uuid().optional(),
6
+ // For lazy discussion creation (when discussionId === "new"):
7
+ fileId: z.string().uuid().optional(),
8
+ headingSlug: z.string().max(500).optional(),
9
+ taskId: z.string().max(500).optional(),
10
+ });
11
+ // --- Response schemas ---
12
+ export const commentResponseSchema = z.object({
13
+ id: z.string().uuid(),
14
+ discussionId: z.string().uuid(),
15
+ parentId: z.string().uuid().nullable(),
16
+ userId: z.string(),
17
+ body: z.string(),
18
+ createdAt: z.string(),
19
+ updatedAt: z.string(),
20
+ });
21
+ export const discussionResponseSchema = z.object({
22
+ id: z.string().uuid(),
23
+ projectId: z.string().uuid(),
24
+ createdAt: z.string(),
25
+ commentCount: z.number().int(),
26
+ });
27
+ export const discussionCountsResponseSchema = z.record(z.string(), z.number().int());
28
+ //# sourceMappingURL=discussions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"discussions.js","sourceRoot":"","sources":["../../../src/api/schemas/discussions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,sEAAsE;AAEtE,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC;IACnC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IACtC,8DAA8D;IAC9D,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IACpC,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE;IAC3C,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE;CACvC,CAAC,CAAC;AAIH,2BAA2B;AAE3B,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE;IACrB,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE;IAC/B,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IACtC,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE;IAClB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;IAChB,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;CACtB,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC/C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE;IACrB,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE;IAC5B,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE;CAC/B,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC"}
@@ -0,0 +1,16 @@
1
+ import { z } from 'zod';
2
+ export declare const createProjectSchema: z.ZodObject<{
3
+ name: z.ZodString;
4
+ slug: z.ZodOptional<z.ZodString>;
5
+ }, z.core.$strip>;
6
+ export type CreateProjectInput = z.infer<typeof createProjectSchema>;
7
+ export declare const updateProjectSchema: z.ZodObject<{
8
+ name: z.ZodOptional<z.ZodString>;
9
+ slug: z.ZodOptional<z.ZodString>;
10
+ }, z.core.$strip>;
11
+ export type UpdateProjectInput = z.infer<typeof updateProjectSchema>;
12
+ export declare const moveProjectSchema: z.ZodObject<{
13
+ targetOrgId: z.ZodString;
14
+ }, z.core.$strip>;
15
+ export type MoveProjectInput = z.infer<typeof moveProjectSchema>;
16
+ //# sourceMappingURL=projects.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"projects.d.ts","sourceRoot":"","sources":["../../../src/api/schemas/projects.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB;;;iBAQ9B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAErE,eAAO,MAAM,mBAAmB;;;iBAQ9B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAErE,eAAO,MAAM,iBAAiB;;iBAE5B,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC"}
@@ -0,0 +1,23 @@
1
+ import { z } from 'zod';
2
+ export const createProjectSchema = z.object({
3
+ name: z.string().min(1, 'Project name is required').max(200),
4
+ slug: z
5
+ .string()
6
+ .min(1)
7
+ .max(200)
8
+ .regex(/^[a-z0-9][a-z0-9-]*[a-z0-9]$/, 'Slug must be lowercase alphanumeric with hyphens')
9
+ .optional(),
10
+ });
11
+ export const updateProjectSchema = z.object({
12
+ name: z.string().min(1).max(200).optional(),
13
+ slug: z
14
+ .string()
15
+ .min(1)
16
+ .max(200)
17
+ .regex(/^[a-z0-9][a-z0-9-]*[a-z0-9]$/, 'Slug must be lowercase alphanumeric with hyphens')
18
+ .optional(),
19
+ });
20
+ export const moveProjectSchema = z.object({
21
+ targetOrgId: z.string().min(1, 'Target organization ID is required'),
22
+ });
23
+ //# sourceMappingURL=projects.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"projects.js","sourceRoot":"","sources":["../../../src/api/schemas/projects.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,EAAE,0BAA0B,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC;IAC5D,IAAI,EAAE,CAAC;SACJ,MAAM,EAAE;SACR,GAAG,CAAC,CAAC,CAAC;SACN,GAAG,CAAC,GAAG,CAAC;SACR,KAAK,CAAC,8BAA8B,EAAE,kDAAkD,CAAC;SACzF,QAAQ,EAAE;CACd,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE;IAC3C,IAAI,EAAE,CAAC;SACJ,MAAM,EAAE;SACR,GAAG,CAAC,CAAC,CAAC;SACN,GAAG,CAAC,GAAG,CAAC;SACR,KAAK,CAAC,8BAA8B,EAAE,kDAAkD,CAAC;SACzF,QAAQ,EAAE;CACd,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACxC,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,EAAE,oCAAoC,CAAC;CACrE,CAAC,CAAC"}
@@ -0,0 +1,94 @@
1
+ import { z } from 'zod';
2
+ export declare const snapshotCompareQuerySchema: z.ZodObject<{
3
+ base: z.ZodString;
4
+ head: z.ZodString;
5
+ }, z.core.$strip>;
6
+ export type SnapshotCompareQuery = z.infer<typeof snapshotCompareQuerySchema>;
7
+ export declare const snapshotMetaSchema: z.ZodObject<{
8
+ id: z.ZodString;
9
+ name: z.ZodNullable<z.ZodString>;
10
+ commitHash: z.ZodNullable<z.ZodString>;
11
+ createdAt: z.ZodString;
12
+ }, z.core.$strip>;
13
+ export type SnapshotMeta = z.infer<typeof snapshotMetaSchema>;
14
+ export declare const sectionChangeSchema: z.ZodObject<{
15
+ headingSlug: z.ZodString;
16
+ headingText: z.ZodNullable<z.ZodString>;
17
+ status: z.ZodEnum<{
18
+ added: "added";
19
+ modified: "modified";
20
+ deleted: "deleted";
21
+ }>;
22
+ before: z.ZodNullable<z.ZodObject<{
23
+ content: z.ZodString;
24
+ }, z.core.$strip>>;
25
+ after: z.ZodNullable<z.ZodObject<{
26
+ content: z.ZodString;
27
+ }, z.core.$strip>>;
28
+ }, z.core.$strip>;
29
+ export type SectionChange = z.infer<typeof sectionChangeSchema>;
30
+ export declare const fileChangeSchema: z.ZodObject<{
31
+ path: z.ZodString;
32
+ status: z.ZodEnum<{
33
+ added: "added";
34
+ modified: "modified";
35
+ deleted: "deleted";
36
+ }>;
37
+ sections: z.ZodArray<z.ZodObject<{
38
+ headingSlug: z.ZodString;
39
+ headingText: z.ZodNullable<z.ZodString>;
40
+ status: z.ZodEnum<{
41
+ added: "added";
42
+ modified: "modified";
43
+ deleted: "deleted";
44
+ }>;
45
+ before: z.ZodNullable<z.ZodObject<{
46
+ content: z.ZodString;
47
+ }, z.core.$strip>>;
48
+ after: z.ZodNullable<z.ZodObject<{
49
+ content: z.ZodString;
50
+ }, z.core.$strip>>;
51
+ }, z.core.$strip>>;
52
+ unchangedCount: z.ZodNumber;
53
+ }, z.core.$strip>;
54
+ export type FileChange = z.infer<typeof fileChangeSchema>;
55
+ export declare const snapshotCompareResponseSchema: z.ZodObject<{
56
+ base: z.ZodObject<{
57
+ id: z.ZodString;
58
+ name: z.ZodNullable<z.ZodString>;
59
+ commitHash: z.ZodNullable<z.ZodString>;
60
+ createdAt: z.ZodString;
61
+ }, z.core.$strip>;
62
+ head: z.ZodObject<{
63
+ id: z.ZodString;
64
+ name: z.ZodNullable<z.ZodString>;
65
+ commitHash: z.ZodNullable<z.ZodString>;
66
+ createdAt: z.ZodString;
67
+ }, z.core.$strip>;
68
+ files: z.ZodArray<z.ZodObject<{
69
+ path: z.ZodString;
70
+ status: z.ZodEnum<{
71
+ added: "added";
72
+ modified: "modified";
73
+ deleted: "deleted";
74
+ }>;
75
+ sections: z.ZodArray<z.ZodObject<{
76
+ headingSlug: z.ZodString;
77
+ headingText: z.ZodNullable<z.ZodString>;
78
+ status: z.ZodEnum<{
79
+ added: "added";
80
+ modified: "modified";
81
+ deleted: "deleted";
82
+ }>;
83
+ before: z.ZodNullable<z.ZodObject<{
84
+ content: z.ZodString;
85
+ }, z.core.$strip>>;
86
+ after: z.ZodNullable<z.ZodObject<{
87
+ content: z.ZodString;
88
+ }, z.core.$strip>>;
89
+ }, z.core.$strip>>;
90
+ unchangedCount: z.ZodNumber;
91
+ }, z.core.$strip>>;
92
+ }, z.core.$strip>;
93
+ export type SnapshotCompareResponse = z.infer<typeof snapshotCompareResponseSchema>;
94
+ //# sourceMappingURL=snapshots.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"snapshots.d.ts","sourceRoot":"","sources":["../../../src/api/schemas/snapshots.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,0BAA0B;;;iBAGrC,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAE9E,eAAO,MAAM,kBAAkB;;;;;iBAK7B,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAE9D,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;iBAM9B,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;iBAK3B,CAAC;AAEH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAIxC,CAAC;AAEH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC"}
@@ -0,0 +1,31 @@
1
+ import { z } from 'zod';
2
+ // --- GET /api/projects/[id]/snapshots/compare ---
3
+ export const snapshotCompareQuerySchema = z.object({
4
+ base: z.string().uuid(),
5
+ head: z.string().uuid(),
6
+ });
7
+ export const snapshotMetaSchema = z.object({
8
+ id: z.string().uuid(),
9
+ name: z.string().nullable(),
10
+ commitHash: z.string().nullable(),
11
+ createdAt: z.string(),
12
+ });
13
+ export const sectionChangeSchema = z.object({
14
+ headingSlug: z.string(),
15
+ headingText: z.string().nullable(),
16
+ status: z.enum(['added', 'modified', 'deleted']),
17
+ before: z.object({ content: z.string() }).nullable(),
18
+ after: z.object({ content: z.string() }).nullable(),
19
+ });
20
+ export const fileChangeSchema = z.object({
21
+ path: z.string(),
22
+ status: z.enum(['added', 'modified', 'deleted']),
23
+ sections: z.array(sectionChangeSchema),
24
+ unchangedCount: z.number().int().min(0),
25
+ });
26
+ export const snapshotCompareResponseSchema = z.object({
27
+ base: snapshotMetaSchema,
28
+ head: snapshotMetaSchema,
29
+ files: z.array(fileChangeSchema),
30
+ });
31
+ //# sourceMappingURL=snapshots.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"snapshots.js","sourceRoot":"","sources":["../../../src/api/schemas/snapshots.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,mDAAmD;AAEnD,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC,MAAM,CAAC;IACjD,IAAI,EAAE,CAAC,CAAC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AE,CAAC,GAAG,CAAC,CAAC,CAAC;CACxC,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,CAAC,MAAM,CAAC;IACpD,IAAI,EAAE,kBAAkB;IACxB,IAAI,EAAE,kBAAkB;IACxB,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,gBAAgB,CAAC;CACjC,CAAC,CAAC"}
@@ -0,0 +1,53 @@
1
+ import { z } from 'zod';
2
+ export declare const sectionItemSchema: z.ZodObject<{
3
+ slug: z.ZodString;
4
+ heading: z.ZodNullable<z.ZodString>;
5
+ level: z.ZodNullable<z.ZodNumber>;
6
+ position: z.ZodNumber;
7
+ content: z.ZodString;
8
+ content_hash: z.ZodString;
9
+ }, z.core.$strip>;
10
+ export declare const syncSectionsSchema: z.ZodObject<{
11
+ projectId: z.ZodString;
12
+ file: z.ZodString;
13
+ file_hash: z.ZodString;
14
+ sections: z.ZodArray<z.ZodObject<{
15
+ slug: z.ZodString;
16
+ heading: z.ZodNullable<z.ZodString>;
17
+ level: z.ZodNullable<z.ZodNumber>;
18
+ position: z.ZodNumber;
19
+ content: z.ZodString;
20
+ content_hash: z.ZodString;
21
+ }, z.core.$strip>>;
22
+ removedSlugs: z.ZodOptional<z.ZodArray<z.ZodString>>;
23
+ }, z.core.$strip>;
24
+ export type SyncSectionsInput = z.infer<typeof syncSectionsSchema>;
25
+ export type SectionItem = z.infer<typeof sectionItemSchema>;
26
+ export declare const syncFileItemSchema: z.ZodObject<{
27
+ path: z.ZodString;
28
+ content: z.ZodString;
29
+ hash: z.ZodString;
30
+ size: z.ZodNumber;
31
+ }, z.core.$strip>;
32
+ export declare const syncFilesSchema: z.ZodObject<{
33
+ projectId: z.ZodString;
34
+ files: z.ZodArray<z.ZodObject<{
35
+ path: z.ZodString;
36
+ content: z.ZodString;
37
+ hash: z.ZodString;
38
+ size: z.ZodNumber;
39
+ }, z.core.$strip>>;
40
+ }, z.core.$strip>;
41
+ export type SyncFilesInput = z.infer<typeof syncFilesSchema>;
42
+ export declare const createSnapshotSchema: z.ZodObject<{
43
+ projectId: z.ZodString;
44
+ name: z.ZodOptional<z.ZodString>;
45
+ commitHash: z.ZodOptional<z.ZodString>;
46
+ trigger: z.ZodOptional<z.ZodEnum<{
47
+ manual: "manual";
48
+ git_commit: "git_commit";
49
+ plan_completion: "plan_completion";
50
+ }>>;
51
+ }, z.core.$strip>;
52
+ export type CreateSnapshotInput = z.infer<typeof createSnapshotSchema>;
53
+ //# sourceMappingURL=sync.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.d.ts","sourceRoot":"","sources":["../../../src/api/schemas/sync.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAaxB,eAAO,MAAM,iBAAiB;;;;;;;iBAO5B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;iBAM7B,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AACnE,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAI5D,eAAO,MAAM,kBAAkB;;;;;iBAK7B,CAAC;AAEH,eAAO,MAAM,eAAe;;;;;;;;iBAG1B,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAI7D,eAAO,MAAM,oBAAoB;;;;;;;;;iBAK/B,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
@@ -0,0 +1,43 @@
1
+ import { z } from 'zod';
2
+ const SHA256_PATTERN = /^sha256:[a-f0-9]{64}$/;
3
+ const safePath = z
4
+ .string()
5
+ .min(1)
6
+ .max(500)
7
+ .refine((p) => !p.includes('..'), 'Path traversal not allowed')
8
+ .refine((p) => !p.startsWith('/'), 'Absolute paths not allowed');
9
+ // --- POST /api/sync/sections ---
10
+ export const sectionItemSchema = z.object({
11
+ slug: z.string().min(1).max(500),
12
+ heading: z.string().max(500).nullable(),
13
+ level: z.number().int().min(1).max(6).nullable(),
14
+ position: z.number().int().nonnegative(),
15
+ content: z.string().max(1_048_576),
16
+ content_hash: z.string().regex(SHA256_PATTERN, 'Invalid SHA256 hash format'),
17
+ });
18
+ export const syncSectionsSchema = z.object({
19
+ projectId: z.string().uuid(),
20
+ file: safePath,
21
+ file_hash: z.string().regex(SHA256_PATTERN, 'Invalid SHA256 hash format'),
22
+ sections: z.array(sectionItemSchema).min(1).max(500),
23
+ removedSlugs: z.array(z.string().max(500)).max(500).optional(),
24
+ });
25
+ // --- POST /api/sync/files ---
26
+ export const syncFileItemSchema = z.object({
27
+ path: safePath,
28
+ content: z.string().max(1_048_576),
29
+ hash: z.string().regex(SHA256_PATTERN, 'Invalid SHA256 hash format'),
30
+ size: z.number().int().nonnegative(),
31
+ });
32
+ export const syncFilesSchema = z.object({
33
+ projectId: z.string().uuid(),
34
+ files: z.array(syncFileItemSchema).min(1).max(100),
35
+ });
36
+ // --- POST /api/sync/snapshot ---
37
+ export const createSnapshotSchema = z.object({
38
+ projectId: z.string().uuid(),
39
+ name: z.string().min(1).max(200).optional(),
40
+ commitHash: z.string().max(64).optional(),
41
+ trigger: z.enum(['manual', 'git_commit', 'plan_completion']).optional(),
42
+ });
43
+ //# sourceMappingURL=sync.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.js","sourceRoot":"","sources":["../../../src/api/schemas/sync.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,cAAc,GAAG,uBAAuB,CAAC;AAE/C,MAAM,QAAQ,GAAG,CAAC;KACf,MAAM,EAAE;KACR,GAAG,CAAC,CAAC,CAAC;KACN,GAAG,CAAC,GAAG,CAAC;KACR,MAAM,CAAC,CAAC,CAAC,EAAE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AE;CACxE,CAAC,CAAC"}
@@ -0,0 +1,54 @@
1
+ import { z } from 'zod';
2
+ export declare const syncUsageAccountSchema: z.ZodObject<{
3
+ account_id: z.ZodString;
4
+ email: z.ZodOptional<z.ZodString>;
5
+ org_name: z.ZodOptional<z.ZodString>;
6
+ subscription_type: z.ZodOptional<z.ZodString>;
7
+ rate_limits: z.ZodObject<{
8
+ five_hour: z.ZodObject<{
9
+ used_percentage: z.ZodNumber;
10
+ resets_at: z.ZodNumber;
11
+ }, z.core.$strip>;
12
+ seven_day: z.ZodObject<{
13
+ used_percentage: z.ZodNumber;
14
+ resets_at: z.ZodNumber;
15
+ }, z.core.$strip>;
16
+ }, z.core.$strip>;
17
+ updated_at: z.ZodString;
18
+ }, z.core.$strip>;
19
+ export declare const syncUsageRequestSchema: z.ZodObject<{
20
+ accounts: z.ZodRecord<z.ZodString, z.ZodObject<{
21
+ account_id: z.ZodString;
22
+ email: z.ZodOptional<z.ZodString>;
23
+ org_name: z.ZodOptional<z.ZodString>;
24
+ subscription_type: z.ZodOptional<z.ZodString>;
25
+ rate_limits: z.ZodObject<{
26
+ five_hour: z.ZodObject<{
27
+ used_percentage: z.ZodNumber;
28
+ resets_at: z.ZodNumber;
29
+ }, z.core.$strip>;
30
+ seven_day: z.ZodObject<{
31
+ used_percentage: z.ZodNumber;
32
+ resets_at: z.ZodNumber;
33
+ }, z.core.$strip>;
34
+ }, z.core.$strip>;
35
+ updated_at: z.ZodString;
36
+ }, z.core.$strip>>;
37
+ }, z.core.$strip>;
38
+ export type SyncUsageRequest = z.infer<typeof syncUsageRequestSchema>;
39
+ export type SyncUsageAccount = z.infer<typeof syncUsageAccountSchema>;
40
+ export interface UsageAccount {
41
+ id: string;
42
+ userId: string;
43
+ accountId: string;
44
+ email: string | null;
45
+ orgName: string | null;
46
+ subscriptionType: string | null;
47
+ fiveHourPct: string | null;
48
+ fiveHourResetsAt: string | null;
49
+ sevenDayPct: string | null;
50
+ sevenDayResetsAt: string | null;
51
+ updatedAt: string;
52
+ createdAt: string;
53
+ }
54
+ //# sourceMappingURL=usage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usage.d.ts","sourceRoot":"","sources":["../../../src/api/schemas/usage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;iBAUjC,CAAC;AAIH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;iBAEjC,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AACtE,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAItE,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,gBAAgB,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,gBAAgB,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,gBAAgB,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;CACnB"}
@@ -0,0 +1,23 @@
1
+ import { z } from 'zod';
2
+ // --- Rate limit window ---
3
+ const rateLimitWindowSchema = z.object({
4
+ used_percentage: z.number().min(0),
5
+ resets_at: z.number().int(), // Unix epoch seconds
6
+ });
7
+ // --- Individual account in sync payload ---
8
+ export const syncUsageAccountSchema = z.object({
9
+ account_id: z.string().min(1).max(200),
10
+ email: z.string().max(320).optional(),
11
+ org_name: z.string().max(200).optional(),
12
+ subscription_type: z.string().max(50).optional(),
13
+ rate_limits: z.object({
14
+ five_hour: rateLimitWindowSchema,
15
+ seven_day: rateLimitWindowSchema,
16
+ }),
17
+ updated_at: z.string().datetime(),
18
+ });
19
+ // --- POST /api/sync/usage ---
20
+ export const syncUsageRequestSchema = z.object({
21
+ accounts: z.record(z.string(), syncUsageAccountSchema),
22
+ });
23
+ //# sourceMappingURL=usage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usage.js","sourceRoot":"","sources":["../../../src/api/schemas/usage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,4BAA4B;AAE5B,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IACrC,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IAClC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,EAAE,qBAAqB;CACnD,CAAC,CAAC;AAEH,6CAA6C;AAE7C,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7C,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC;IACtC,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE;IACrC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE;IACxC,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,QAAQ,EAAE;IAChD,WAAW,EAAE,CAAC,CAAC,MAAM,CAAC;QACpB,SAAS,EAAE,qBAAqB;QAChC,SAAS,EAAE,qBAAqB;KACjC,CAAC;IACF,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAClC,CAAC,CAAC;AAEH,+BAA+B;AAE/B,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7C,QAAQ,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,sBAAsB,CAAC;CACvD,CAAC,CAAC"}
@@ -0,0 +1,3 @@
1
+ export declare function computeContentHash(content: string): string;
2
+ export declare function verifyContentHash(content: string, declaredHash: string): boolean;
3
+ //# sourceMappingURL=hashing.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hashing.d.ts","sourceRoot":"","sources":["../src/hashing.ts"],"names":[],"mappings":"AAEA,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAG1D;AAED,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,GAAG,OAAO,CAEhF"}
@@ -0,0 +1,9 @@
1
+ import { createHash } from 'node:crypto';
2
+ export function computeContentHash(content) {
3
+ const normalized = content.trim().replace(/\r\n/g, '\n');
4
+ return `sha256:${createHash('sha256').update(normalized, 'utf8').digest('hex')}`;
5
+ }
6
+ export function verifyContentHash(content, declaredHash) {
7
+ return computeContentHash(content) === declaredHash;
8
+ }
9
+ //# sourceMappingURL=hashing.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hashing.js","sourceRoot":"","sources":["../src/hashing.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,MAAM,UAAU,kBAAkB,CAAC,OAAe;IAChD,MAAM,UAAU,GAAG,OAAO,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;IACzD,OAAO,UAAU,UAAU,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC;AACnF,CAAC;AAED,MAAM,UAAU,iBAAiB,CAAC,OAAe,EAAE,YAAoB;IACrE,OAAO,kBAAkB,CAAC,OAAO,CAAC,KAAK,YAAY,CAAC;AACtD,CAAC"}
@@ -0,0 +1,10 @@
1
+ export { createProjectSchema, updateProjectSchema, moveProjectSchema, type CreateProjectInput, type UpdateProjectInput, type MoveProjectInput, } from './api/schemas/projects.js';
2
+ export { syncSectionsSchema, sectionItemSchema, syncFilesSchema, syncFileItemSchema, createSnapshotSchema, type SyncSectionsInput, type SectionItem, type SyncFilesInput, type CreateSnapshotInput, } from './api/schemas/sync.js';
3
+ export { computeContentHash, verifyContentHash } from './hashing.js';
4
+ export { parseMarkdownSections, generateSlug } from './sections.js';
5
+ export type { SectionData, ManifestEntry, ProjectRegistryEntry, ProjectRegistry, AgentCredentials, } from './types.js';
6
+ export { ok, err, type Result } from './result.js';
7
+ export { createCommentSchema, commentResponseSchema, discussionResponseSchema, discussionCountsResponseSchema, type CreateCommentInput, type CommentResponse, type DiscussionResponse, type DiscussionCountsResponse, } from './api/schemas/discussions.js';
8
+ export { syncUsageRequestSchema, syncUsageAccountSchema, type SyncUsageRequest, type SyncUsageAccount, type UsageAccount, } from './api/schemas/usage.js';
9
+ export { snapshotCompareQuerySchema, snapshotMetaSchema, sectionChangeSchema, fileChangeSchema, snapshotCompareResponseSchema, type SnapshotCompareQuery, type SnapshotMeta, type SectionChange, type FileChange, type SnapshotCompareResponse, } from './api/schemas/snapshots.js';
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,mBAAmB,EACnB,mBAAmB,EACnB,iBAAiB,EACjB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,GACtB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,eAAe,EACf,kBAAkB,EAClB,oBAAoB,EACpB,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,KAAK,cAAc,EACnB,KAAK,mBAAmB,GACzB,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAErE,OAAO,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAEpE,YAAY,EACV,WAAW,EACX,aAAa,EACb,oBAAoB,EACpB,eAAe,EACf,gBAAgB,GACjB,MAAM,YAAY,CAAC;AAEpB,OAAO,EAAE,EAAE,EAAE,GAAG,EAAE,KAAK,MAAM,EAAE,MAAM,aAAa,CAAC;AAEnD,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,EACxB,8BAA8B,EAC9B,KAAK,kBAAkB,EACvB,KAAK,eAAe,EACpB,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,GAC9B,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EACL,sBAAsB,EACtB,sBAAsB,EACtB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,YAAY,GAClB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EACL,0BAA0B,EAC1B,kBAAkB,EAClB,mBAAmB,EACnB,gBAAgB,EAChB,6BAA6B,EAC7B,KAAK,oBAAoB,EACzB,KAAK,YAAY,EACjB,KAAK,aAAa,EAClB,KAAK,UAAU,EACf,KAAK,uBAAuB,GAC7B,MAAM,4BAA4B,CAAC"}
@@ -0,0 +1,10 @@
1
+ // @ultra-claude/shared — shared types, API contracts, block parsing
2
+ export { createProjectSchema, updateProjectSchema, moveProjectSchema, } from './api/schemas/projects.js';
3
+ export { syncSectionsSchema, sectionItemSchema, syncFilesSchema, syncFileItemSchema, createSnapshotSchema, } from './api/schemas/sync.js';
4
+ export { computeContentHash, verifyContentHash } from './hashing.js';
5
+ export { parseMarkdownSections, generateSlug } from './sections.js';
6
+ export { ok, err } from './result.js';
7
+ export { createCommentSchema, commentResponseSchema, discussionResponseSchema, discussionCountsResponseSchema, } from './api/schemas/discussions.js';
8
+ export { syncUsageRequestSchema, syncUsageAccountSchema, } from './api/schemas/usage.js';
9
+ export { snapshotCompareQuerySchema, snapshotMetaSchema, sectionChangeSchema, fileChangeSchema, snapshotCompareResponseSchema, } from './api/schemas/snapshots.js';
10
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,oEAAoE;AAEpE,OAAO,EACL,mBAAmB,EACnB,mBAAmB,EACnB,iBAAiB,GAIlB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,eAAe,EACf,kBAAkB,EAClB,oBAAoB,GAKrB,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAErE,OAAO,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAUpE,OAAO,EAAE,EAAE,EAAE,GAAG,EAAe,MAAM,aAAa,CAAC;AAEnD,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,EACxB,8BAA8B,GAK/B,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EACL,sBAAsB,EACtB,sBAAsB,GAIvB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EACL,0BAA0B,EAC1B,kBAAkB,EAClB,mBAAmB,EACnB,gBAAgB,EAChB,6BAA6B,GAM9B,MAAM,4BAA4B,CAAC"}
@@ -0,0 +1,11 @@
1
+ export type Result<T, E extends string = string> = {
2
+ success: true;
3
+ data: T;
4
+ } | {
5
+ success: false;
6
+ error: E;
7
+ message: string;
8
+ };
9
+ export declare function ok<T>(data: T): Result<T, never>;
10
+ export declare function err<E extends string>(error: E, message: string): Result<never, E>;
11
+ //# sourceMappingURL=result.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"result.d.ts","sourceRoot":"","sources":["../src/result.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,MAAM,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,GAAG,MAAM,IAC3C;IAAE,OAAO,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,CAAC,CAAA;CAAE,GAC1B;IAAE,OAAO,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,CAAC,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AAElD,wBAAgB,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,GAAG,MAAM,CAAC,CAAC,EAAE,KAAK,CAAC,CAE/C;AAED,wBAAgB,GAAG,CAAC,CAAC,SAAS,MAAM,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAAC,KAAK,EAAE,CAAC,CAAC,CAEjF"}
@@ -0,0 +1,9 @@
1
+ // Result type for typed error handling without exceptions
2
+ // See: documentation/technology/standards/error-handling.md §Result Types
3
+ export function ok(data) {
4
+ return { success: true, data };
5
+ }
6
+ export function err(error, message) {
7
+ return { success: false, error, message };
8
+ }
9
+ //# sourceMappingURL=result.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"result.js","sourceRoot":"","sources":["../src/result.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAC1D,0EAA0E;AAM1E,MAAM,UAAU,EAAE,CAAI,IAAO;IAC3B,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;AACjC,CAAC;AAED,MAAM,UAAU,GAAG,CAAmB,KAAQ,EAAE,OAAe;IAC7D,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC;AAC5C,CAAC"}
@@ -0,0 +1,16 @@
1
+ import type { SectionData } from './types.js';
2
+ /**
3
+ * Generate a URL-friendly slug from heading text.
4
+ * Lowercase, replace non-alphanumeric runs with hyphens, trim hyphens.
5
+ */
6
+ export declare function generateSlug(text: string): string;
7
+ /**
8
+ * Parse a markdown string into heading-based sections.
9
+ *
10
+ * Each section is everything under a heading until the next heading of equal or higher level.
11
+ * Slugs are hierarchical: "parent-heading/child-heading".
12
+ * Content before the first heading becomes the "_root" section.
13
+ * Duplicate headings under the same parent get "-2", "-3" suffixes.
14
+ */
15
+ export declare function parseMarkdownSections(content: string): SectionData[];
16
+ //# sourceMappingURL=sections.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sections.d.ts","sourceRoot":"","sources":["../src/sections.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAG9C;;;GAGG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAKjD;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAC,OAAO,EAAE,MAAM,GAAG,WAAW,EAAE,CAwFpE"}
@@ -0,0 +1,102 @@
1
+ // Heading-based markdown section parser using unified/remark AST
2
+ // Used by both daemon (to split files before push) and server (for validation)
3
+ import { unified } from 'unified';
4
+ import remarkParse from 'remark-parse';
5
+ import { toString } from 'mdast-util-to-string';
6
+ import { computeContentHash } from './hashing.js';
7
+ /**
8
+ * Generate a URL-friendly slug from heading text.
9
+ * Lowercase, replace non-alphanumeric runs with hyphens, trim hyphens.
10
+ */
11
+ export function generateSlug(text) {
12
+ return text
13
+ .toLowerCase()
14
+ .replace(/[^a-z0-9]+/g, '-')
15
+ .replace(/^-+|-+$/g, '');
16
+ }
17
+ /**
18
+ * Parse a markdown string into heading-based sections.
19
+ *
20
+ * Each section is everything under a heading until the next heading of equal or higher level.
21
+ * Slugs are hierarchical: "parent-heading/child-heading".
22
+ * Content before the first heading becomes the "_root" section.
23
+ * Duplicate headings under the same parent get "-2", "-3" suffixes.
24
+ */
25
+ export function parseMarkdownSections(content) {
26
+ const tree = unified().use(remarkParse).parse(content);
27
+ const sections = [];
28
+ const headingStack = [];
29
+ const slugCounts = new Map();
30
+ let position = 0;
31
+ // Extract all headings with their source offsets
32
+ const headings = tree.children
33
+ .filter((n) => n.type === 'heading')
34
+ .map((h) => ({
35
+ node: h,
36
+ depth: h.depth,
37
+ text: toString(h),
38
+ startOffset: h.position.start.offset,
39
+ endOffset: h.position.end.offset,
40
+ }));
41
+ // Content before first heading → _root section
42
+ if (headings.length === 0) {
43
+ // No headings at all — entire file is _root
44
+ const trimmed = content.trim();
45
+ if (trimmed) {
46
+ sections.push({
47
+ slug: '_root',
48
+ heading: '',
49
+ level: 0,
50
+ position: position++,
51
+ content: trimmed,
52
+ contentHash: computeContentHash(trimmed),
53
+ });
54
+ }
55
+ return sections;
56
+ }
57
+ const firstHeadingOffset = headings[0].startOffset;
58
+ if (firstHeadingOffset > 0) {
59
+ const rootContent = content.slice(0, firstHeadingOffset).trim();
60
+ if (rootContent) {
61
+ sections.push({
62
+ slug: '_root',
63
+ heading: '',
64
+ level: 0,
65
+ position: position++,
66
+ content: rootContent,
67
+ contentHash: computeContentHash(rootContent),
68
+ });
69
+ }
70
+ }
71
+ // Process each heading: slice content from end of heading line to start of next heading
72
+ for (let i = 0; i < headings.length; i++) {
73
+ const h = headings[i];
74
+ const nextStart = i + 1 < headings.length ? headings[i + 1].startOffset : content.length;
75
+ const level = h.depth;
76
+ const rawSlug = generateSlug(h.text);
77
+ // Build hierarchical slug from parent chain
78
+ while (headingStack.length > 0 && headingStack[headingStack.length - 1].level >= level) {
79
+ headingStack.pop();
80
+ }
81
+ const parentSlug = headingStack.length > 0 ? headingStack[headingStack.length - 1].slug + '/' : '';
82
+ const baseSlug = parentSlug + rawSlug;
83
+ // Handle duplicate slugs
84
+ const count = (slugCounts.get(baseSlug) ?? 0) + 1;
85
+ slugCounts.set(baseSlug, count);
86
+ const slug = count === 1 ? baseSlug : `${baseSlug}-${count}`;
87
+ headingStack.push({ level, slug });
88
+ // Heading line from source, content is everything after heading until next heading
89
+ const headingLine = content.slice(h.startOffset, h.endOffset);
90
+ const sectionContent = content.slice(h.endOffset, nextStart).trim();
91
+ sections.push({
92
+ slug,
93
+ heading: headingLine,
94
+ level,
95
+ position: position++,
96
+ content: sectionContent,
97
+ contentHash: computeContentHash(sectionContent),
98
+ });
99
+ }
100
+ return sections;
101
+ }
102
+ //# sourceMappingURL=sections.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sections.js","sourceRoot":"","sources":["../src/sections.ts"],"names":[],"mappings":"AAAA,iEAAiE;AACjE,+EAA+E;AAE/E,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,WAAW,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAGhD,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD;;;GAGG;AACH,MAAM,UAAU,YAAY,CAAC,IAAY;IACvC,OAAO,IAAI;SACR,WAAW,EAAE;SACb,OAAO,CAAC,aAAa,EAAE,GAAG,CAAC;SAC3B,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC;AAC7B,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,qBAAqB,CAAC,OAAe;IACnD,MAAM,IAAI,GAAS,OAAO,EAAE,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAC7D,MAAM,QAAQ,GAAkB,EAAE,CAAC;IACnC,MAAM,YAAY,GAAsC,EAAE,CAAC;IAC3D,MAAM,UAAU,GAAG,IAAI,GAAG,EAAkB,CAAC;IAC7C,IAAI,QAAQ,GAAG,CAAC,CAAC;IAEjB,iDAAiD;IACjD,MAAM,QAAQ,GAAG,IAAI,CAAC,QAAQ;SAC3B,MAAM,CAAC,CAAC,CAAC,EAAgB,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,SAAS,CAAC;SACjD,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAA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,MAAM,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC;QAC9D,MAAM,cAAc,GAAG,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC,IAAI,EAAE,CAAC;QAEpE,QAAQ,CAAC,IAAI,CAAC;YACZ,IAAI;YACJ,OAAO,EAAE,WAAW;YACpB,KAAK;YACL,QAAQ,EAAE,QAAQ,EAAE;YACpB,OAAO,EAAE,cAAc;YACvB,WAAW,EAAE,kBAAkB,CAAC,cAAc,CAAC;SAChD,CAAC,CAAC;IACL,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC"}
@@ -0,0 +1,39 @@
1
+ /** A heading-based section parsed from a markdown file */
2
+ export interface SectionData {
3
+ /** Hierarchical slug path, e.g. "architecture/components/web-application" or "_root" */
4
+ slug: string;
5
+ /** Raw heading line, e.g. "### Web Application" — empty string for _root */
6
+ heading: string;
7
+ /** Heading depth 1-6, or 0 for _root */
8
+ level: number;
9
+ /** Order in file (0-based) */
10
+ position: number;
11
+ /** Raw markdown content under this heading until next heading of equal/higher level */
12
+ content: string;
13
+ /** SHA-256 content hash prefixed with "sha256:" */
14
+ contentHash: string;
15
+ }
16
+ /** Single entry in the manifest returned by GET /api/sync/manifest */
17
+ export interface ManifestEntry {
18
+ filePath: string;
19
+ headingSlug: string;
20
+ contentHash: string;
21
+ }
22
+ /** A project entry in ~/.claude/dashboard-projects.json */
23
+ export interface ProjectRegistryEntry {
24
+ /** Absolute path to project root */
25
+ path: string;
26
+ /** Project display name */
27
+ name: string;
28
+ }
29
+ /** Shape of ~/.claude/dashboard-projects.json */
30
+ export interface ProjectRegistry {
31
+ projects: ProjectRegistryEntry[];
32
+ }
33
+ /** Stored credentials at ~/.config/ultraclaude-dashboard-agent/credentials.json */
34
+ export interface AgentCredentials {
35
+ apiKey: string;
36
+ userId: string;
37
+ serverUrl: string;
38
+ }
39
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAIA,0DAA0D;AAC1D,MAAM,WAAW,WAAW;IAC1B,wFAAwF;IACxF,IAAI,EAAE,MAAM,CAAC;IACb,4EAA4E;IAC5E,OAAO,EAAE,MAAM,CAAC;IAChB,wCAAwC;IACxC,KAAK,EAAE,MAAM,CAAC;IACd,8BAA8B;IAC9B,QAAQ,EAAE,MAAM,CAAC;IACjB,uFAAuF;IACvF,OAAO,EAAE,MAAM,CAAC;IAChB,mDAAmD;IACnD,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,sEAAsE;AACtE,MAAM,WAAW,aAAa;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,2DAA2D;AAC3D,MAAM,WAAW,oBAAoB;IACnC,oCAAoC;IACpC,IAAI,EAAE,MAAM,CAAC;IACb,2BAA2B;IAC3B,IAAI,EAAE,MAAM,CAAC;CACd;AAED,iDAAiD;AACjD,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,oBAAoB,EAAE,CAAC;CAClC;AAED,mFAAmF;AACnF,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;CACnB"}
@@ -0,0 +1,5 @@
1
+ // Shared types for sync protocol between daemon (packages/agent) and server (packages/web)
2
+ // Note: Zod-validated request schemas are in ./api/schemas/sync.ts — these types are for
3
+ // the section parser output and agent-specific structures.
4
+ export {};
5
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,2FAA2F;AAC3F,yFAAyF;AACzF,2DAA2D"}
@@ -0,0 +1,23 @@
1
+ {
2
+ "name": "@ultra-claude/shared",
3
+ "version": "0.0.1",
4
+ "type": "module",
5
+ "exports": {
6
+ ".": "./dist/index.js"
7
+ },
8
+ "scripts": {
9
+ "typecheck": "tsc --noEmit",
10
+ "build": "tsc --project tsconfig.build.json",
11
+ "test": "vitest run",
12
+ "test:watch": "vitest"
13
+ },
14
+ "dependencies": {
15
+ "mdast-util-to-string": "^4.0.0",
16
+ "remark-parse": "^11.0.0",
17
+ "unified": "^11.0.5",
18
+ "zod": "^4.3.6"
19
+ },
20
+ "devDependencies": {
21
+ "vitest": "^4.1.2"
22
+ }
23
+ }
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "ultraclaude-agent",
3
- "version": "0.0.7",
3
+ "version": "0.0.8",
4
4
  "type": "module",
5
5
  "bin": {
6
- "ultraclaude-dashboard-agent": "./dist/cli.js"
6
+ "ultraclaude-agent": "./dist/cli.js"
7
7
  },
8
8
  "scripts": {
9
9
  "typecheck": "tsc --noEmit",
@@ -20,9 +20,13 @@
20
20
  "@ultra-claude/shared": "*",
21
21
  "chokidar": "^5.0.0",
22
22
  "commander": "^14.0.3",
23
+ "mdast-util-to-string": "^4.0.0",
23
24
  "open": "^11.0.0",
24
25
  "pino": "^10.3.1",
25
- "pino-pretty": "^13.1.3"
26
+ "pino-pretty": "^13.1.3",
27
+ "remark-parse": "^11.0.0",
28
+ "unified": "^11.0.5",
29
+ "zod": "^4.3.6"
26
30
  },
27
31
  "devDependencies": {
28
32
  "@types/node": "^25.5.2",