@cat-factory/contracts 0.297.0 → 0.299.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/personal-subscriptions.d.ts +20 -0
- package/dist/personal-subscriptions.d.ts.map +1 -1
- package/dist/personal-subscriptions.js +33 -1
- package/dist/personal-subscriptions.js.map +1 -1
- package/dist/public-api-keys.d.ts +49 -0
- package/dist/public-api-keys.d.ts.map +1 -1
- package/dist/public-api-keys.js +29 -0
- package/dist/public-api-keys.js.map +1 -1
- package/dist/public-provisioning.d.ts +117 -7
- package/dist/public-provisioning.d.ts.map +1 -1
- package/dist/public-provisioning.js +91 -7
- package/dist/public-provisioning.js.map +1 -1
- package/dist/routes/_shared.d.ts +16 -0
- package/dist/routes/_shared.d.ts.map +1 -1
- package/dist/routes/_shared.js +16 -0
- package/dist/routes/_shared.js.map +1 -1
- package/dist/routes/public-api.d.ts +11 -0
- package/dist/routes/public-api.d.ts.map +1 -1
- package/dist/routes/public-api.js +7 -7
- package/dist/routes/public-api.js.map +1 -1
- package/dist/routes/public-decisions.d.ts +80 -0
- package/dist/routes/public-decisions.d.ts.map +1 -1
- package/dist/routes/public-decisions.js +54 -41
- package/dist/routes/public-decisions.js.map +1 -1
- package/dist/routes/public-provisioning.d.ts +100 -0
- package/dist/routes/public-provisioning.d.ts.map +1 -1
- package/dist/routes/public-provisioning.js +29 -1
- package/dist/routes/public-provisioning.js.map +1 -1
- package/dist/tracker.d.ts +50 -4
- package/dist/tracker.d.ts.map +1 -1
- package/dist/tracker.js +52 -4
- package/dist/tracker.js.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"public-provisioning.js","sourceRoot":"","sources":["../../src/routes/public-provisioning.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAC5B,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAA;AAC3D,OAAO,EACL,8BAA8B,EAC9B,oBAAoB,EACpB,6BAA6B,EAC7B,wBAAwB,EACxB,yBAAyB,EACzB,qCAAqC,EACrC,qCAAqC,EACrC,2BAA2B,EAC3B,0BAA0B,EAC1B,6BAA6B,EAC7B,0BAA0B,EAC1B,qCAAqC,EACrC,yBAAyB,
|
|
1
|
+
{"version":3,"file":"public-provisioning.js","sourceRoot":"","sources":["../../src/routes/public-provisioning.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAC5B,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAA;AAC3D,OAAO,EACL,8BAA8B,EAC9B,oBAAoB,EACpB,6BAA6B,EAC7B,wBAAwB,EACxB,yBAAyB,EACzB,qCAAqC,EACrC,qCAAqC,EACrC,2BAA2B,EAC3B,0BAA0B,EAC1B,oCAAoC,EACpC,6BAA6B,EAC7B,0BAA0B,EAC1B,qCAAqC,EACrC,yBAAyB,EACzB,kCAAkC,GACnC,MAAM,2BAA2B,CAAA;AAClC,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAA;AACtD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAE9E,8EAA8E;AAC9E,uEAAuE;AACvE,EAAE;AACF,kGAAkG;AAClG,gGAAgG;AAChG,oGAAoG;AACpG,oEAAoE;AACpE,EAAE;AACF,+FAA+F;AAC/F,oGAAoG;AACpG,iGAAiG;AACjG,+FAA+F;AAC/F,kGAAkG;AAClG,8FAA8F;AAC9F,oFAAoF;AACpF,EAAE;AACF,oGAAoG;AACpG,iGAAiG;AACjG,0BAA0B;AAC1B,8EAA8E;AAE9E,MAAM,WAAW,GAAG,iBAAiB,CAAC,OAAO,CAAC,CAAA;AAC9C,MAAM,eAAe,GAAG,iBAAiB,CAAC,WAAW,CAAC,CAAA;AAEtD,gFAAgF;A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YAAY,EAAE,GAAG,EAAE,CAAC,2BAA2B;IAC/C,iBAAiB,EAAE,kCAAkC;IACrD,qBAAqB,EAAE,EAAE,GAAG,EAAE,oCAAoC,EAAE,GAAG,cAAc,EAAE;CACxF,CAAC,CACH,CAAA"}
|
package/dist/tracker.d.ts
CHANGED
|
@@ -10,20 +10,23 @@ export declare const trackerSettingsSchema: v.ObjectSchema<{
|
|
|
10
10
|
readonly linearTeamId: v.NullableSchema<v.StringSchema<undefined>, undefined>;
|
|
11
11
|
/**
|
|
12
12
|
* Writeback: when a task's PR opens, post a comment on the task's linked tracker
|
|
13
|
-
* issue(s). Per-task overridable via `Block.trackerCommentOnPrOpen
|
|
13
|
+
* issue(s). Per-task overridable via `Block.trackerCommentOnPrOpen`; the default a
|
|
14
|
+
* workspace that has set nothing runs on is {@link DEFAULT_TRACKER_WRITEBACK}.
|
|
14
15
|
*/
|
|
15
16
|
readonly writebackCommentOnPrOpen: v.BooleanSchema<undefined>;
|
|
16
17
|
/**
|
|
17
18
|
* Writeback: when a task's PR merges, comment + close the linked tracker issue(s)
|
|
18
19
|
* as resolved (GitHub closes natively; Jira transitions to its Done category).
|
|
19
|
-
* Per-task overridable via `Block.trackerResolveOnMerge
|
|
20
|
+
* Per-task overridable via `Block.trackerResolveOnMerge`; default
|
|
21
|
+
* {@link DEFAULT_TRACKER_WRITEBACK}.
|
|
20
22
|
*/
|
|
21
23
|
readonly writebackResolveOnMerge: v.BooleanSchema<undefined>;
|
|
22
24
|
/**
|
|
23
25
|
* Writeback: when a HEADLESS run's requirements review parks with open findings, post
|
|
24
26
|
* them — each with its stable finding id — as a comment on the task's linked tracker
|
|
25
27
|
* issue(s), so the loop is answerable from where the work was requested. Per-task
|
|
26
|
-
* overridable via `Block.trackerQuestionsOnPark
|
|
28
|
+
* overridable via `Block.trackerQuestionsOnPark`; default
|
|
29
|
+
* {@link DEFAULT_TRACKER_WRITEBACK}.
|
|
27
30
|
*
|
|
28
31
|
* Deliberately scoped to runs whose `ExecutionInstance.intakeOrigin` is HEADLESS
|
|
29
32
|
* (`isHeadlessIntake`: a `/api/v1` start or a per-ticket tracker dispatch): a task started
|
|
@@ -34,7 +37,50 @@ export declare const trackerSettingsSchema: v.ObjectSchema<{
|
|
|
34
37
|
readonly updatedAt: v.NumberSchema<undefined>;
|
|
35
38
|
}, undefined>;
|
|
36
39
|
export type TrackerSettings = v.InferOutput<typeof trackerSettingsSchema>;
|
|
37
|
-
/**
|
|
40
|
+
/** The three writeback actions, as they are spelled on a workspace's settings row. */
|
|
41
|
+
export type TrackerWritebackFlags = Pick<TrackerSettings, 'writebackCommentOnPrOpen' | 'writebackResolveOnMerge' | 'writebackQuestionsOnPark'>;
|
|
42
|
+
/**
|
|
43
|
+
* What each writeback action does for a workspace that has never set one.
|
|
44
|
+
*
|
|
45
|
+
* **ON, and that is a deliberate change of stance** (it was off for all three). The action only
|
|
46
|
+
* ever touches an issue a task is LINKED to, and nothing links one by accident: a link arrives by
|
|
47
|
+
* an operator importing an issue, by the recurring intake picking one up, or by a headless caller
|
|
48
|
+
* filing a task with `ticket`. Every one of those is a request to work the issue where it was
|
|
49
|
+
* filed, so leaving the loop half-closed by default meant the common outcome was a merged pull
|
|
50
|
+
* request and an issue still sitting open, with nothing on it saying the work had been done. The
|
|
51
|
+
* writeback is what makes the tracker, rather than this platform's own board, the place the
|
|
52
|
+
* reporter can keep watching.
|
|
53
|
+
*
|
|
54
|
+
* ONE constant rather than a literal per reader, because three readers have to agree about it: the
|
|
55
|
+
* settings service (what an absent row reports, and what the row is seeded with on first write),
|
|
56
|
+
* the writeback service (what it does when no row exists), and the SPA's store (what the toggles
|
|
57
|
+
* show before a row does). They disagreed here once already, and the failure is silent both ways
|
|
58
|
+
* round: a reader defaulting off never posts and logs nothing, and one defaulting on closes issues
|
|
59
|
+
* a panel is drawing as off.
|
|
60
|
+
*
|
|
61
|
+
* It is a SEED and never a reset. No write path fills an omitted action in from here: absence means
|
|
62
|
+
* the caller is not moving that action, which is the rule on both the internal PUT and
|
|
63
|
+
* `PATCH /api/v1/tracker/writeback`. Filling one in would make every partial write carry these
|
|
64
|
+
* values into a workspace that had chosen otherwise, and this flip to ON is exactly when that stops
|
|
65
|
+
* being harmless.
|
|
66
|
+
*/
|
|
67
|
+
export declare const DEFAULT_TRACKER_WRITEBACK: TrackerWritebackFlags;
|
|
68
|
+
/**
|
|
69
|
+
* Set a workspace's issue-tracker FILING selection, and optionally move writeback actions with it.
|
|
70
|
+
*
|
|
71
|
+
* The filing half (`tracker` plus that vendor's target) is a wholesale replace, which is why
|
|
72
|
+
* `tracker` is the one required field: those three are one decision, and a caller editing it has
|
|
73
|
+
* the whole of it in front of them.
|
|
74
|
+
*
|
|
75
|
+
* The writeback half MERGES. An omitted action keeps whatever the row holds, and a caller that
|
|
76
|
+
* names none moves none, which is what lets a dialog about something else (the recurring
|
|
77
|
+
* tech-debt schedule, which persists the filing tracker) touch this row without deciding a
|
|
78
|
+
* workspace's writeback policy as a side effect. A caller that wants
|
|
79
|
+
* {@link DEFAULT_TRACKER_WRITEBACK} sends those values.
|
|
80
|
+
*
|
|
81
|
+
* `PATCH /api/v1/tracker/writeback` is the writeback half on its own, for a caller with no business
|
|
82
|
+
* naming a filing tracker.
|
|
83
|
+
*/
|
|
38
84
|
export declare const putTrackerSettingsSchema: v.ObjectSchema<{
|
|
39
85
|
readonly tracker: v.NullableSchema<v.PicklistSchema<["github", "jira", "linear"], undefined>, undefined>;
|
|
40
86
|
readonly jiraProjectKey: v.OptionalSchema<v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>, undefined>;
|
package/dist/tracker.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tracker.d.ts","sourceRoot":"","sources":["../src/tracker.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAY5B,eAAO,MAAM,iBAAiB,2DAA2C,CAAA;AACzE,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,WAAW,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAEjE,oFAAoF;AACpF,eAAO,MAAM,qBAAqB;;IAEhC,mFAAmF;;IAEnF,uEAAuE;;IAEvE
|
|
1
|
+
{"version":3,"file":"tracker.d.ts","sourceRoot":"","sources":["../src/tracker.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAY5B,eAAO,MAAM,iBAAiB,2DAA2C,CAAA;AACzE,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,WAAW,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAEjE,oFAAoF;AACpF,eAAO,MAAM,qBAAqB;;IAEhC,mFAAmF;;IAEnF,uEAAuE;;IAEvE;;;;OAIG;;IAEH;;;;;OAKG;;IAEH;;;;;;;;;;;OAWG;;;aAGH,CAAA;AACF,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,WAAW,CAAC,OAAO,qBAAqB,CAAC,CAAA;AAEzE,sFAAsF;AACtF,MAAM,MAAM,qBAAqB,GAAG,IAAI,CACtC,eAAe,EACf,0BAA0B,GAAG,yBAAyB,GAAG,0BAA0B,CACpF,CAAA;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,yBAAyB,EAAE,qBAIvC,CAAA;AAED;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,wBAAwB;;;;;;;aAOnC,CAAA;AACF,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,WAAW,CAAC,OAAO,wBAAwB,CAAC,CAAA"}
|
package/dist/tracker.js
CHANGED
|
@@ -18,20 +18,23 @@ export const trackerSettingsSchema = v.object({
|
|
|
18
18
|
linearTeamId: v.nullable(v.string()),
|
|
19
19
|
/**
|
|
20
20
|
* Writeback: when a task's PR opens, post a comment on the task's linked tracker
|
|
21
|
-
* issue(s). Per-task overridable via `Block.trackerCommentOnPrOpen
|
|
21
|
+
* issue(s). Per-task overridable via `Block.trackerCommentOnPrOpen`; the default a
|
|
22
|
+
* workspace that has set nothing runs on is {@link DEFAULT_TRACKER_WRITEBACK}.
|
|
22
23
|
*/
|
|
23
24
|
writebackCommentOnPrOpen: v.boolean(),
|
|
24
25
|
/**
|
|
25
26
|
* Writeback: when a task's PR merges, comment + close the linked tracker issue(s)
|
|
26
27
|
* as resolved (GitHub closes natively; Jira transitions to its Done category).
|
|
27
|
-
* Per-task overridable via `Block.trackerResolveOnMerge
|
|
28
|
+
* Per-task overridable via `Block.trackerResolveOnMerge`; default
|
|
29
|
+
* {@link DEFAULT_TRACKER_WRITEBACK}.
|
|
28
30
|
*/
|
|
29
31
|
writebackResolveOnMerge: v.boolean(),
|
|
30
32
|
/**
|
|
31
33
|
* Writeback: when a HEADLESS run's requirements review parks with open findings, post
|
|
32
34
|
* them — each with its stable finding id — as a comment on the task's linked tracker
|
|
33
35
|
* issue(s), so the loop is answerable from where the work was requested. Per-task
|
|
34
|
-
* overridable via `Block.trackerQuestionsOnPark
|
|
36
|
+
* overridable via `Block.trackerQuestionsOnPark`; default
|
|
37
|
+
* {@link DEFAULT_TRACKER_WRITEBACK}.
|
|
35
38
|
*
|
|
36
39
|
* Deliberately scoped to runs whose `ExecutionInstance.intakeOrigin` is HEADLESS
|
|
37
40
|
* (`isHeadlessIntake`: a `/api/v1` start or a per-ticket tracker dispatch): a task started
|
|
@@ -41,7 +44,52 @@ export const trackerSettingsSchema = v.object({
|
|
|
41
44
|
writebackQuestionsOnPark: v.boolean(),
|
|
42
45
|
updatedAt: v.number(),
|
|
43
46
|
});
|
|
44
|
-
/**
|
|
47
|
+
/**
|
|
48
|
+
* What each writeback action does for a workspace that has never set one.
|
|
49
|
+
*
|
|
50
|
+
* **ON, and that is a deliberate change of stance** (it was off for all three). The action only
|
|
51
|
+
* ever touches an issue a task is LINKED to, and nothing links one by accident: a link arrives by
|
|
52
|
+
* an operator importing an issue, by the recurring intake picking one up, or by a headless caller
|
|
53
|
+
* filing a task with `ticket`. Every one of those is a request to work the issue where it was
|
|
54
|
+
* filed, so leaving the loop half-closed by default meant the common outcome was a merged pull
|
|
55
|
+
* request and an issue still sitting open, with nothing on it saying the work had been done. The
|
|
56
|
+
* writeback is what makes the tracker, rather than this platform's own board, the place the
|
|
57
|
+
* reporter can keep watching.
|
|
58
|
+
*
|
|
59
|
+
* ONE constant rather than a literal per reader, because three readers have to agree about it: the
|
|
60
|
+
* settings service (what an absent row reports, and what the row is seeded with on first write),
|
|
61
|
+
* the writeback service (what it does when no row exists), and the SPA's store (what the toggles
|
|
62
|
+
* show before a row does). They disagreed here once already, and the failure is silent both ways
|
|
63
|
+
* round: a reader defaulting off never posts and logs nothing, and one defaulting on closes issues
|
|
64
|
+
* a panel is drawing as off.
|
|
65
|
+
*
|
|
66
|
+
* It is a SEED and never a reset. No write path fills an omitted action in from here: absence means
|
|
67
|
+
* the caller is not moving that action, which is the rule on both the internal PUT and
|
|
68
|
+
* `PATCH /api/v1/tracker/writeback`. Filling one in would make every partial write carry these
|
|
69
|
+
* values into a workspace that had chosen otherwise, and this flip to ON is exactly when that stops
|
|
70
|
+
* being harmless.
|
|
71
|
+
*/
|
|
72
|
+
export const DEFAULT_TRACKER_WRITEBACK = {
|
|
73
|
+
writebackCommentOnPrOpen: true,
|
|
74
|
+
writebackResolveOnMerge: true,
|
|
75
|
+
writebackQuestionsOnPark: true,
|
|
76
|
+
};
|
|
77
|
+
/**
|
|
78
|
+
* Set a workspace's issue-tracker FILING selection, and optionally move writeback actions with it.
|
|
79
|
+
*
|
|
80
|
+
* The filing half (`tracker` plus that vendor's target) is a wholesale replace, which is why
|
|
81
|
+
* `tracker` is the one required field: those three are one decision, and a caller editing it has
|
|
82
|
+
* the whole of it in front of them.
|
|
83
|
+
*
|
|
84
|
+
* The writeback half MERGES. An omitted action keeps whatever the row holds, and a caller that
|
|
85
|
+
* names none moves none, which is what lets a dialog about something else (the recurring
|
|
86
|
+
* tech-debt schedule, which persists the filing tracker) touch this row without deciding a
|
|
87
|
+
* workspace's writeback policy as a side effect. A caller that wants
|
|
88
|
+
* {@link DEFAULT_TRACKER_WRITEBACK} sends those values.
|
|
89
|
+
*
|
|
90
|
+
* `PATCH /api/v1/tracker/writeback` is the writeback half on its own, for a caller with no business
|
|
91
|
+
* naming a filing tracker.
|
|
92
|
+
*/
|
|
45
93
|
export const putTrackerSettingsSchema = v.object({
|
|
46
94
|
tracker: v.nullable(trackerKindSchema),
|
|
47
95
|
jiraProjectKey: v.optional(v.nullable(v.pipe(v.string(), v.trim()))),
|
package/dist/tracker.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tracker.js","sourceRoot":"","sources":["../src/tracker.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B,8EAA8E;AAC9E,8EAA8E;AAC9E,gFAAgF;AAChF,yEAAyE;AACzE,kFAAkF;AAClF,0EAA0E;AAC1E,8EAA8E;AAC9E,oEAAoE;AACpE,8EAA8E;AAE9E,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,QAAQ,CAAC,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC,CAAC,CAAA;AAGzE,oFAAoF;AACpF,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5C,OAAO,EAAE,CAAC,CAAC,QAAQ,CAAC,iBAAiB,CAAC;IACtC,mFAAmF;IACnF,cAAc,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;IACtC,uEAAuE;IACvE,YAAY,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;IACpC
|
|
1
|
+
{"version":3,"file":"tracker.js","sourceRoot":"","sources":["../src/tracker.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B,8EAA8E;AAC9E,8EAA8E;AAC9E,gFAAgF;AAChF,yEA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