@pipelex/sdk 0.64.0 → 0.66.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.
@@ -1,7 +1,8 @@
1
1
  /**
2
2
  * A method's stored layouts: the layout a producer designed for one pipe of a published version,
3
3
  * which the hosted platform stores beside the method (`storeMethodLayout`,
4
- * `POST /v1/methods/{id}/versions/{n}/layouts`) and hands back on the validate of the method by id
4
+ * `POST /v1/methods/{id}/versions/{n}/layouts`), reads back by the version
5
+ * (`listMethodLayouts`, `GET` of the same route) and hands back on the validate of the method by id
5
6
  * that names `layouts` among its `views` (`PipelexValidationReport.layouts`).
6
7
  *
7
8
  * A layout is a data file: a tree of elements written in the vocabulary of a catalog of
@@ -13,7 +14,8 @@
13
14
  * and the `layouts` token are the hosted plane's.
14
15
  *
15
16
  * The readers here check a layout member by member, as `readProblemItems` checks a verdict's
16
- * items: a validate never loses its verdict, nor its other layouts, to one layout it cannot read.
17
+ * items: neither a validate nor a read of a version's layouts loses its other layouts, nor a
18
+ * validate its verdict, to one layout it cannot read.
17
19
  */
18
20
  /**
19
21
  * How a stored layout was made, as its producer stated it when it wrote the layout. Every member
@@ -36,8 +38,8 @@ export interface LayoutProvenance {
36
38
  repair_rounds: number;
37
39
  }
38
40
  /**
39
- * One stored layout — what `storeMethodLayout` answers, and an entry of
40
- * `PipelexValidationReport.layouts`.
41
+ * One stored layout — what `storeMethodLayout` answers, an entry of `listMethodLayouts`'s `items`,
42
+ * and an entry of `PipelexValidationReport.layouts`.
41
43
  *
42
44
  * Its identity is `tree_digest`, `pipe_ref`, `catalog` and `prompt_hash` within one method: it
43
45
  * belongs to the content it was designed for, never to a version number, so it is served for
@@ -69,6 +71,20 @@ export interface MethodLayout {
69
71
  provenance: LayoutProvenance;
70
72
  /** The moment the write that stored it landed, ISO 8601 in UTC: the one member the platform sets. */
71
73
  stored_at: string;
74
+ /**
75
+ * A written sample of the result the layout was designed over, as one JSON text the platform
76
+ * stores and never reads, so a host can draw a designed result page before anyone has run the
77
+ * method; `null` when none was stored, and from a platform that predates it. Parse it yourself,
78
+ * and treat it as untrusted: nothing but the JSON syntax was checked.
79
+ */
80
+ sample_json: string | null;
81
+ }
82
+ /**
83
+ * The layouts stored for a published version's content — what `listMethodLayouts` answers. `items`
84
+ * is newest first, at most 16, and empty when none is stored.
85
+ */
86
+ export interface MethodLayoutList {
87
+ items: MethodLayout[];
72
88
  }
73
89
  /**
74
90
  * The provenance a write states — `MethodLayoutInput.provenance`. A `null` or omitted optional
@@ -89,7 +105,8 @@ export interface LayoutProvenanceInput {
89
105
  /**
90
106
  * The write — `storeMethodLayout`, `POST /v1/methods/{id}/versions/{n}/layouts`: the stored layout
91
107
  * without `stored_at`. The wire body is closed at both levels, so the client sends these members
92
- * and nothing else; a `MethodLayout` read back can be passed as it is, its `stored_at` left out.
108
+ * and nothing else; a `MethodLayout` read back can be passed as it is, its `stored_at` left out and
109
+ * its `sample_json` sent when it holds one.
93
110
  * The bounds below are the platform's, which refuses a member breaking one with a `422`
94
111
  * `request.invalid` naming it, `provenance.<member>` for one of the provenance's.
95
112
  */
@@ -116,18 +133,31 @@ export interface MethodLayoutInput {
116
133
  jsonl: string;
117
134
  /** How it was made. */
118
135
  provenance: LayoutProvenanceInput;
136
+ /**
137
+ * A written sample of the result the layout was designed over, one JSON text of at most 64 KiB of
138
+ * UTF-8, which the platform refuses if it does not parse. A `null` or omitted sample is not sent,
139
+ * and the write stores none, whatever the layout it replaces held.
140
+ *
141
+ * **Only a written sample belongs here, invented from the description of the result and holding
142
+ * no customer's data, never a run's output.** A layout's readers include the method's runners
143
+ * and, for a public method, other organizations, and the platform never reads the sample, so
144
+ * keeping that rule is the producer's.
145
+ */
146
+ sample_json?: string | null;
119
147
  }
120
148
  /**
121
- * The members the write sends besides `provenance`, every one each time. Checked against
122
- * `MethodLayoutInput` with `satisfies`, so a member the interface gains and this list lacks fails
123
- * the build rather than being dropped from the body without a word.
149
+ * The members the write takes besides `provenance`, `required` ones sent each time and `optional`
150
+ * ones only when given and not `null`. Checked against `MethodLayoutInput` with `satisfies`, so a
151
+ * member the interface gains and this list lacks fails the build rather than being dropped from
152
+ * the body without a word.
124
153
  */
125
154
  export declare const LAYOUT_INPUT_MEMBERS: {
126
- readonly tree_digest: true;
127
- readonly pipe_ref: true;
128
- readonly catalog: true;
129
- readonly prompt_hash: true;
130
- readonly jsonl: true;
155
+ readonly tree_digest: "required";
156
+ readonly pipe_ref: "required";
157
+ readonly catalog: "required";
158
+ readonly prompt_hash: "required";
159
+ readonly jsonl: "required";
160
+ readonly sample_json: "optional";
131
161
  };
132
162
  /**
133
163
  * The members of the write's provenance, `required` ones sent each time and `optional` ones only
@@ -150,15 +180,16 @@ export declare const PROVENANCE_INPUT_MEMBERS: {
150
180
  export declare function methodLayoutFault(value: unknown): string | null;
151
181
  /**
152
182
  * `value` read as a stored layout, or `null` when it does not read as one (`methodLayoutFault`).
153
- * The provenance's `seed` and `style` are kept only when each is a string, and read as `null`
154
- * otherwise, and its `repair_rounds` only when it is a non-negative integer, and read as `0`
155
- * otherwise: the platform's own defaults, so each member is what `LayoutProvenance` declares. The
156
- * rest is returned as it came.
183
+ * The layout's `sample_json` and the provenance's `seed` and `style` are kept only when each is a
184
+ * string, and read as `null` otherwise, and its `repair_rounds` only when it is a non-negative
185
+ * integer, and read as `0` otherwise: the platform's own defaults, so each member is what
186
+ * `MethodLayout` and `LayoutProvenance` declare. The rest is returned as it came.
157
187
  */
158
188
  export declare function readMethodLayout(value: unknown): MethodLayout | null;
159
189
  /**
160
- * A valid report's `layouts` read entry by entry: each entry that reads as a layout
161
- * (`readMethodLayout`), in the answer's order, newest first as the platform sends them, and
162
- * anything else left out. A value that is not an array reads as no layout.
190
+ * A list of layouts read entry by entry, a valid report's `layouts` or `listMethodLayouts`'s
191
+ * `items`: each entry that reads as a layout (`readMethodLayout`), in the answer's order, newest
192
+ * first as the platform sends them, and anything else left out. A value that is not an array reads
193
+ * as no layout.
163
194
  */
164
195
  export declare function readMethodLayouts(value: unknown): MethodLayout[];
@@ -1,7 +1,8 @@
1
1
  /**
2
2
  * A method's stored layouts: the layout a producer designed for one pipe of a published version,
3
3
  * which the hosted platform stores beside the method (`storeMethodLayout`,
4
- * `POST /v1/methods/{id}/versions/{n}/layouts`) and hands back on the validate of the method by id
4
+ * `POST /v1/methods/{id}/versions/{n}/layouts`), reads back by the version
5
+ * (`listMethodLayouts`, `GET` of the same route) and hands back on the validate of the method by id
5
6
  * that names `layouts` among its `views` (`PipelexValidationReport.layouts`).
6
7
  *
7
8
  * A layout is a data file: a tree of elements written in the vocabulary of a catalog of
@@ -13,20 +14,23 @@
13
14
  * and the `layouts` token are the hosted plane's.
14
15
  *
15
16
  * The readers here check a layout member by member, as `readProblemItems` checks a verdict's
16
- * items: a validate never loses its verdict, nor its other layouts, to one layout it cannot read.
17
+ * items: neither a validate nor a read of a version's layouts loses its other layouts, nor a
18
+ * validate its verdict, to one layout it cannot read.
17
19
  */
18
20
  import { isPlainObject } from "./records.js";
19
21
  /**
20
- * The members the write sends besides `provenance`, every one each time. Checked against
21
- * `MethodLayoutInput` with `satisfies`, so a member the interface gains and this list lacks fails
22
- * the build rather than being dropped from the body without a word.
22
+ * The members the write takes besides `provenance`, `required` ones sent each time and `optional`
23
+ * ones only when given and not `null`. Checked against `MethodLayoutInput` with `satisfies`, so a
24
+ * member the interface gains and this list lacks fails the build rather than being dropped from
25
+ * the body without a word.
23
26
  */
24
27
  export const LAYOUT_INPUT_MEMBERS = {
25
- tree_digest: true,
26
- pipe_ref: true,
27
- catalog: true,
28
- prompt_hash: true,
29
- jsonl: true,
28
+ tree_digest: "required",
29
+ pipe_ref: "required",
30
+ catalog: "required",
31
+ prompt_hash: "required",
32
+ jsonl: "required",
33
+ sample_json: "optional",
30
34
  };
31
35
  /**
32
36
  * The members of the write's provenance, `required` ones sent each time and `optional` ones only
@@ -76,10 +80,10 @@ export function methodLayoutFault(value) {
76
80
  }
77
81
  /**
78
82
  * `value` read as a stored layout, or `null` when it does not read as one (`methodLayoutFault`).
79
- * The provenance's `seed` and `style` are kept only when each is a string, and read as `null`
80
- * otherwise, and its `repair_rounds` only when it is a non-negative integer, and read as `0`
81
- * otherwise: the platform's own defaults, so each member is what `LayoutProvenance` declares. The
82
- * rest is returned as it came.
83
+ * The layout's `sample_json` and the provenance's `seed` and `style` are kept only when each is a
84
+ * string, and read as `null` otherwise, and its `repair_rounds` only when it is a non-negative
85
+ * integer, and read as `0` otherwise: the platform's own defaults, so each member is what
86
+ * `MethodLayout` and `LayoutProvenance` declare. The rest is returned as it came.
83
87
  */
84
88
  export function readMethodLayout(value) {
85
89
  if (methodLayoutFault(value) !== null)
@@ -88,6 +92,7 @@ export function readMethodLayout(value) {
88
92
  const { seed, style, repair_rounds: rounds } = layout.provenance;
89
93
  return {
90
94
  ...layout,
95
+ sample_json: typeof layout.sample_json === "string" ? layout.sample_json : null,
91
96
  provenance: {
92
97
  ...layout.provenance,
93
98
  seed: typeof seed === "string" ? seed : null,
@@ -97,9 +102,10 @@ export function readMethodLayout(value) {
97
102
  };
98
103
  }
99
104
  /**
100
- * A valid report's `layouts` read entry by entry: each entry that reads as a layout
101
- * (`readMethodLayout`), in the answer's order, newest first as the platform sends them, and
102
- * anything else left out. A value that is not an array reads as no layout.
105
+ * A list of layouts read entry by entry, a valid report's `layouts` or `listMethodLayouts`'s
106
+ * `items`: each entry that reads as a layout (`readMethodLayout`), in the answer's order, newest
107
+ * first as the platform sends them, and anything else left out. A value that is not an array reads
108
+ * as no layout.
103
109
  */
104
110
  export function readMethodLayouts(value) {
105
111
  if (!Array.isArray(value))
@@ -1 +1 @@
1
- {"version":3,"file":"method-layouts.js","sourceRoot":"","sources":["../src/method-layouts.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AA4G7C;;;;GAIG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG;IAClC,WA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OAAO,IAAI,CAAC;IACnD,MAAM,MAAM,GAAG,KAA0E,CAAC;IAC1F,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC,UAAU,CAAC;IACjE,OAAO;QACL,GAAG,MAAM;QACT,WAAW,EAAE,OAAO,MAAM,CAAC,WAAW,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI;QAC/E,UAAU,EAAE;YACV,GAAG,MAAM,CAAC,UAAU;YACpB,IAAI,EAAE,OAAO,IAAI,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI;YAC5C,KAAK,EAAE,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI;YAC/C,aAAa,EAAE,MAAM,CAAC,aAAa,CAAC,MAAM,CAAC,IAAK,MAAiB,IAAI,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;SACpF;KACyB,CAAC;AAC/B,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,iBAAiB,CAAC,KAAc;IAC9C,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IACrC,MAAM,OAAO,GAAmB,EAAE,CAAC;IACnC,KAAK,MAAM,KAAK,IAAI,KAAkB,EAAE,CAAC;QACvC,MAAM,MAAM,GAAG,gBAAgB,CAAC,KAAK,CAAC,CAAC;QACvC,IAAI,MAAM,KAAK,IAAI;YAAE,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IAC5C,CAAC;IACD,OAAO,OAAO,CAAC;AACjB,CAAC"}
@@ -0,0 +1,169 @@
1
+ /**
2
+ * A method's showcases: a completed run of a method, frozen, so that people can see what the method
3
+ * really produces without spending credit. A builder freezes a run (`freezeMethodShowcase`,
4
+ * `POST /v1/methods/{id}/showcases`) and withdraws it (`withdrawMethodShowcase`); every reader of a
5
+ * published version reads the showcases of the tree that version holds
6
+ * (`listMethodVersionShowcases`, `getMethodVersionShowcase`), and the method's own organization
7
+ * reads every showcase across every tree (`listMethodShowcases`, `getMethodShowcase`).
8
+ *
9
+ * A showcase holds real output, unlike a layout's written sample, which is invented, and unlike an
10
+ * example, which is the builder's private test bench whose output is whatever its latest run left.
11
+ * It is keyed by the digest of the method tree of its run, so a run's own content stands behind
12
+ * what is shown. The frozen document names its stored files by `pipelex-storage://` address and
13
+ * holds no signed link; the one place a link appears is a detail read's `files`, signed for that
14
+ * one read over that showcase's own files.
15
+ *
16
+ * The readers here hold a list entry by entry, as `method-layouts.ts` does, so one showcase the SDK
17
+ * cannot read never costs a page the others, and hold a detail and a freeze verdict whole, since
18
+ * the caller acts on what they name.
19
+ */
20
+ import type { InputForm, OutputForm, PipeIOContracts } from "mthds/protocol";
21
+ /**
22
+ * One showcase of a list: what names it and what it was frozen from. The same for every reader,
23
+ * whoever holds the method.
24
+ */
25
+ export interface MethodShowcaseSummary {
26
+ /** The showcase's id, `sc_` and a time-ordered uuid, so a list reads oldest first. */
27
+ showcase_id: string;
28
+ /** The showcase's name, for a person reading a list. */
29
+ name: string;
30
+ /** The namespaced pipe the run ran, `domain_path.pipe_code`. */
31
+ pipe_ref: string;
32
+ /**
33
+ * The digest of the method tree of the run the showcase was frozen from: `sha256:` and 64
34
+ * lowercase hexadecimal characters, as a published version's `tree_digest` states it.
35
+ */
36
+ tree_digest: string;
37
+ /** The moment of the freeze, ISO 8601 in UTC. */
38
+ frozen_at: string;
39
+ }
40
+ /** One stored file of a showcase on a detail read, with a link signed for that read. */
41
+ export interface MethodShowcaseFile {
42
+ /** The file's `pipelex-storage://` address, as the document names it. */
43
+ address: string;
44
+ /** The file's name inside the showcase, which is its content's hash and its extension. */
45
+ file_name: string;
46
+ /** The file's media type, one `type/subtype`. */
47
+ media_type: string;
48
+ /** The file's size in bytes. */
49
+ size_bytes: number;
50
+ /**
51
+ * A short-lived presigned `GET` of the file's bytes. It is a bearer credential: it needs no API
52
+ * key, and anyone holding it can read the file until it expires, so it is never logged and
53
+ * belongs on a server rather than in a browser.
54
+ */
55
+ url: string;
56
+ }
57
+ /**
58
+ * What a showcase shows, frozen from its run and relayed as it was stored, its addresses rewritten
59
+ * to the showcase's own files. A renderer of an HTML output replaces each address with the `url` of
60
+ * the matching entry of `MethodShowcaseDetail.files`.
61
+ */
62
+ export interface MethodShowcaseDocument {
63
+ /** The inputs the run was started with, an integer past the safe range read as a `bigint`. */
64
+ inputs: Record<string, unknown>;
65
+ /** The run's main output. */
66
+ main_stuff: unknown;
67
+ /** The input-form descriptors of the library the run executed against, keyed by `pipe_ref`. */
68
+ input_form: InputForm | null;
69
+ /** The output-form descriptors of that library, keyed by `pipe_ref`. */
70
+ output_form: OutputForm | null;
71
+ /** The per-pipe input and output contracts of that library, keyed by `pipe_ref`. */
72
+ pipe_io_contracts: PipeIOContracts | null;
73
+ }
74
+ /** One showcase in full: its summary, the frozen document and its files, each with a link. */
75
+ export interface MethodShowcaseDetail extends MethodShowcaseSummary {
76
+ /** The frozen inputs and output, and what describes them. */
77
+ document: MethodShowcaseDocument;
78
+ /** Every stored file the document names, each with a link signed for this read. */
79
+ files: MethodShowcaseFile[];
80
+ }
81
+ /**
82
+ * A list of showcases, oldest first, empty when none is frozen — what `listMethodShowcases` and
83
+ * `listMethodVersionShowcases` answer.
84
+ */
85
+ export interface MethodShowcaseList {
86
+ items: MethodShowcaseSummary[];
87
+ }
88
+ /** The freeze — `freezeMethodShowcase`. Its wire body is closed: these members and nothing else. */
89
+ export interface MethodShowcaseInput {
90
+ /** The `pipeline_run_id` of the completed run of this method to freeze. */
91
+ run_id: string;
92
+ /** The showcase's name, 1 to 200 characters and not blank. */
93
+ name: string;
94
+ }
95
+ /** What a freeze did — the discriminant of `MethodShowcaseFreezeResult`. */
96
+ export type MethodShowcaseFreezeOutcome = "frozen" | "unchanged" | "refused";
97
+ /**
98
+ * Why a freeze was refused:
99
+ *
100
+ * - `run_not_usable`: the run is not this method's in this organization, did not complete, kept no
101
+ * results (a blocking execute stores none), stored no output or forms, does not say which pipe
102
+ * it ran, or kept no record of inputs its pipe declares;
103
+ * - `tree_not_current`: the run's tree is neither the draft's nor the latest published version's,
104
+ * or the run records none;
105
+ * - `file_not_readable`: the document names a file that is gone or outside the organization, or
106
+ * holds a signed link the freeze could not rewrite;
107
+ * - `too_large`: a stored artifact of the run, the document, the number of files or their total
108
+ * size is past what one showcase holds;
109
+ * - `too_many`: the tree already holds as many showcases as one tree keeps.
110
+ */
111
+ export type MethodShowcaseRefusalReason = "run_not_usable" | "tree_not_current" | "file_not_readable" | "too_large" | "too_many";
112
+ /** The run was frozen: `showcase` names the new showcase. */
113
+ export interface MethodShowcaseFrozen {
114
+ outcome: "frozen";
115
+ showcase: MethodShowcaseSummary;
116
+ }
117
+ /**
118
+ * This run is already a showcase, whatever has happened to its tree since: `showcase` names the one
119
+ * that stands, nothing was written and the name in the request was ignored.
120
+ */
121
+ export interface MethodShowcaseUnchanged {
122
+ outcome: "unchanged";
123
+ showcase: MethodShowcaseSummary;
124
+ }
125
+ /** The run cannot be frozen, and nothing was written. */
126
+ export interface MethodShowcaseRefused {
127
+ outcome: "refused";
128
+ /**
129
+ * Why: a `MethodShowcaseRefusalReason`, or the raw string of one this SDK does not know, which a
130
+ * later platform may add. A refusal is a verdict whatever its reason, so show its `message` when
131
+ * the reason is one you do not handle.
132
+ */
133
+ reason: MethodShowcaseRefusalReason | (string & {});
134
+ /** What was refused and what to do, for a person. */
135
+ message: string;
136
+ }
137
+ /**
138
+ * The answer of `freezeMethodShowcase`, a `200` discriminated on `outcome`, because a run that
139
+ * cannot be frozen is a verdict about the run and not a failure of the request. Branch on
140
+ * `outcome`, never on the status.
141
+ */
142
+ export type MethodShowcaseFreezeResult = MethodShowcaseFrozen | MethodShowcaseUnchanged | MethodShowcaseRefused;
143
+ /**
144
+ * What keeps `value` from reading as a showcase summary, as the end of a sentence naming it ("a
145
+ * showcase whose `name` is not a string"), or `null` when it reads as one.
146
+ */
147
+ export declare function methodShowcaseSummaryFault(value: unknown): string | null;
148
+ /**
149
+ * A list of showcases read entry by entry, `listMethodShowcases`'s or
150
+ * `listMethodVersionShowcases`'s `items`: each entry that reads as a summary
151
+ * (`methodShowcaseSummaryFault`), in the answer's order, oldest first as the platform sends them,
152
+ * and anything else left out. A value that is not an array reads as no showcase.
153
+ */
154
+ export declare function readMethodShowcaseSummaries(value: unknown): MethodShowcaseSummary[];
155
+ /**
156
+ * What keeps `value` from reading as a showcase detail, as the end of a sentence naming it, or
157
+ * `null` when it reads as one: a summary whose `document` is an object holding an object `inputs`
158
+ * and stating each of its other members, `null` included, and whose `files` is an array of complete
159
+ * entries. Unlike a list of showcases, whose entries
160
+ * stand apart, a detail is held whole: a renderer resolves each address the document names through
161
+ * `files`, so a file it cannot read would leave a result drawn with a hole in it.
162
+ */
163
+ export declare function methodShowcaseDetailFault(value: unknown): string | null;
164
+ /**
165
+ * What keeps `answer` from reading as a freeze's verdict, as the words naming it, or `null` when it
166
+ * reads as one: an `outcome` of `frozen` or `unchanged` with a `showcase` that reads as a summary,
167
+ * or `refused` with a string `reason` and `message`.
168
+ */
169
+ export declare function methodShowcaseFreezeFault(answer: Record<string, unknown>): string | null;
@@ -0,0 +1,139 @@
1
+ /**
2
+ * A method's showcases: a completed run of a method, frozen, so that people can see what the method
3
+ * really produces without spending credit. A builder freezes a run (`freezeMethodShowcase`,
4
+ * `POST /v1/methods/{id}/showcases`) and withdraws it (`withdrawMethodShowcase`); every reader of a
5
+ * published version reads the showcases of the tree that version holds
6
+ * (`listMethodVersionShowcases`, `getMethodVersionShowcase`), and the method's own organization
7
+ * reads every showcase across every tree (`listMethodShowcases`, `getMethodShowcase`).
8
+ *
9
+ * A showcase holds real output, unlike a layout's written sample, which is invented, and unlike an
10
+ * example, which is the builder's private test bench whose output is whatever its latest run left.
11
+ * It is keyed by the digest of the method tree of its run, so a run's own content stands behind
12
+ * what is shown. The frozen document names its stored files by `pipelex-storage://` address and
13
+ * holds no signed link; the one place a link appears is a detail read's `files`, signed for that
14
+ * one read over that showcase's own files.
15
+ *
16
+ * The readers here hold a list entry by entry, as `method-layouts.ts` does, so one showcase the SDK
17
+ * cannot read never costs a page the others, and hold a detail and a freeze verdict whole, since
18
+ * the caller acts on what they name.
19
+ */
20
+ import { isPlainObject } from "./records.js";
21
+ /** The members of a showcase summary, in the order a fault names the first one missing. */
22
+ const SHOWCASE_SUMMARY_STRING_MEMBERS = [
23
+ "showcase_id",
24
+ "name",
25
+ "pipe_ref",
26
+ "tree_digest",
27
+ "frozen_at",
28
+ ];
29
+ /** The members of a showcase's document that must be stated, `null` being a statement. */
30
+ const SHOWCASE_DOCUMENT_STATED_MEMBERS = [
31
+ "main_stuff",
32
+ "input_form",
33
+ "output_form",
34
+ "pipe_io_contracts",
35
+ ];
36
+ /** The members of a showcase's file read as strings. */
37
+ const SHOWCASE_FILE_STRING_MEMBERS = ["address", "file_name", "media_type", "url"];
38
+ /**
39
+ * What keeps `value` from reading as a showcase summary, as the end of a sentence naming it ("a
40
+ * showcase whose `name` is not a string"), or `null` when it reads as one.
41
+ */
42
+ export function methodShowcaseSummaryFault(value) {
43
+ if (!isPlainObject(value))
44
+ return "that is not an object";
45
+ for (const member of SHOWCASE_SUMMARY_STRING_MEMBERS) {
46
+ if (typeof value[member] !== "string")
47
+ return `whose \`${member}\` is not a string`;
48
+ }
49
+ return null;
50
+ }
51
+ /**
52
+ * A list of showcases read entry by entry, `listMethodShowcases`'s or
53
+ * `listMethodVersionShowcases`'s `items`: each entry that reads as a summary
54
+ * (`methodShowcaseSummaryFault`), in the answer's order, oldest first as the platform sends them,
55
+ * and anything else left out. A value that is not an array reads as no showcase.
56
+ */
57
+ export function readMethodShowcaseSummaries(value) {
58
+ if (!Array.isArray(value))
59
+ return [];
60
+ const summaries = [];
61
+ for (const entry of value) {
62
+ if (methodShowcaseSummaryFault(entry) === null) {
63
+ summaries.push(entry);
64
+ }
65
+ }
66
+ return summaries;
67
+ }
68
+ /** What keeps `file` from reading as one file of a detail, or `null` when it reads as one. */
69
+ function showcaseFileFault(file) {
70
+ if (!isPlainObject(file))
71
+ return "that is not an object";
72
+ for (const member of SHOWCASE_FILE_STRING_MEMBERS) {
73
+ if (typeof file[member] !== "string")
74
+ return `whose \`${member}\` is not a string`;
75
+ }
76
+ const size = file.size_bytes;
77
+ if (typeof size !== "number" || !Number.isSafeInteger(size) || size < 0) {
78
+ return "whose `size_bytes` is not a non-negative integer";
79
+ }
80
+ return null;
81
+ }
82
+ /**
83
+ * What keeps `value` from reading as a showcase detail, as the end of a sentence naming it, or
84
+ * `null` when it reads as one: a summary whose `document` is an object holding an object `inputs`
85
+ * and stating each of its other members, `null` included, and whose `files` is an array of complete
86
+ * entries. Unlike a list of showcases, whose entries
87
+ * stand apart, a detail is held whole: a renderer resolves each address the document names through
88
+ * `files`, so a file it cannot read would leave a result drawn with a hole in it.
89
+ */
90
+ export function methodShowcaseDetailFault(value) {
91
+ const summaryFault = methodShowcaseSummaryFault(value);
92
+ if (summaryFault !== null)
93
+ return summaryFault;
94
+ const detail = value;
95
+ const frozen = detail.document;
96
+ const files = detail.files;
97
+ if (!isPlainObject(frozen))
98
+ return "whose `document` is not an object";
99
+ if (!isPlainObject(frozen.inputs))
100
+ return "whose `document.inputs` is not an object";
101
+ for (const member of SHOWCASE_DOCUMENT_STATED_MEMBERS) {
102
+ if (frozen[member] === undefined)
103
+ return `whose \`document.${member}\` is left out`;
104
+ }
105
+ if (!Array.isArray(files))
106
+ return "whose `files` is not an array";
107
+ for (let index = 0; index < files.length; index += 1) {
108
+ const fault = showcaseFileFault(files[index]);
109
+ if (fault !== null)
110
+ return `whose \`files\` holds an entry ${fault}, at [${index}]`;
111
+ }
112
+ return null;
113
+ }
114
+ /**
115
+ * What keeps `answer` from reading as a freeze's verdict, as the words naming it, or `null` when it
116
+ * reads as one: an `outcome` of `frozen` or `unchanged` with a `showcase` that reads as a summary,
117
+ * or `refused` with a string `reason` and `message`.
118
+ */
119
+ export function methodShowcaseFreezeFault(answer) {
120
+ switch (answer.outcome) {
121
+ case "frozen":
122
+ case "unchanged": {
123
+ const fault = methodShowcaseSummaryFault(answer.showcase);
124
+ if (fault === null)
125
+ return null;
126
+ return `a \`${answer.outcome}\` freeze result whose \`showcase\` is one ${fault}`;
127
+ }
128
+ case "refused":
129
+ for (const member of ["reason", "message"]) {
130
+ if (typeof answer[member] !== "string") {
131
+ return `a \`refused\` freeze result whose \`${member}\` is not a string`;
132
+ }
133
+ }
134
+ return null;
135
+ default:
136
+ return "a freeze result whose `outcome` is not `frozen`, `unchanged` or `refused`";
137
+ }
138
+ }
139
+ //# sourceMappingURL=method-showcases.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"method-showcases.js","sourceRoot":"","sources":["../src/method-showcases.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAIH,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AA0I7C,2FAA2F;AAC3F,MAAM,+BAA+B,GAAG;IACtC,aAAa;IACb,MAAM;IACN,UAAU;IACV,aAAa;IACb,WAAW;CACH,CAAC;AAEX,0FAA0F;AAC1F,MAAM,gCAAgC,GAAG;IACvC,YAAY;IACZ,YAAY;IACZ,aAAa;IACb,mBAAmB;CACX,CAAC;AAEX,wDAAwD;AACxD,MAAM,4BAA4B,GAAG,CAAC,SAAS,EAAE,WAAW,EAAE,YAAY,EAAE,KAAK,CAAU,CAAC;AAE5F;;;GAGG;AACH,MAAM,UAAU,0BAA0B,CAAC,KAAc;IACvD,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC;QAAE,OAAO,uBAAuB,CAAC;IAC1D,KAAK,MAAM,MAAM,IAAI,+BAA+B,EAAE,CAAC;QACrD,IAAI,OAAO,KAAK,CAAC,MAAM,CAAC,KAAK,QAAQ;YAAE,OAAO,WAAW,MAAM,oBAAoB,CAAC;IACtF,CAAC;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CAAuC,MAAM,oBAAoB,CAAC;gBAC3E,CAAC;YACH,CAAC;YACD,OAAO,IAAI,CAAC;QACd;YACE,OAAO,2EAA2E,CAAC;IACvF,CAAC;AACH,CAAC"}
@@ -191,6 +191,13 @@ export interface MethodData {
191
191
  * arrives as its raw string. The list rows (`MethodSummary`) do not carry it.
192
192
  */
193
193
  visibility?: MethodVisibility | (string & {});
194
+ /**
195
+ * The ids of the catalogs whose layouts a builder switched off, which no host draws: it draws the
196
+ * plain page instead, and the layouts are kept. Written whole by `setMethodLayoutsOff`, it acts at
197
+ * once and holds across every publish. Absent from a platform that predates it, which means none.
198
+ * The list rows (`MethodSummary`) do not carry it.
199
+ */
200
+ layouts_off?: string[];
194
201
  }
195
202
  /** Who may see a method — `MethodData.visibility`. */
196
203
  export type MethodVisibility = "internal" | "public";
@@ -255,6 +262,11 @@ export interface PublicMethodDetail {
255
262
  latest_published: MethodVersionSummary;
256
263
  /** `public`: another organization reads a method only while it is public. */
257
264
  visibility: MethodVisibility | (string & {});
265
+ /**
266
+ * The ids of the catalogs whose layouts no host draws, as on `MethodData.layouts_off`: a reader
267
+ * of the method draws the plain page for those. Absent from a platform that predates it.
268
+ */
269
+ layouts_off?: string[];
258
270
  /** The latest published version's tree, one entry per file in tree path order. */
259
271
  files: SavedMethodFile[];
260
272
  }
@@ -421,13 +433,15 @@ export type MethodPublishOutcome = "published" | "unchanged" | "refused";
421
433
  * - `thumbnail_invalid`: the method is public, and no file directly under the draft's
422
434
  * `thumbnails/` is a valid thumbnail (a PNG, JPEG or WebP of at least 800×400 pixels);
423
435
  * - `storage_reference`: the method is public, and a `.mthds` file of the draft names a
424
- * `pipelex-storage://` file, which other organizations cannot read.
436
+ * `pipelex-storage://` file, which other organizations cannot read;
437
+ * - `showcase_missing`: the method is public, and the draft's tree holds no showcase for other
438
+ * organizations to look at. Reserved: the platform states it and does not raise it yet.
425
439
  *
426
- * `thumbnail_missing`, `thumbnail_invalid` and `storage_reference` refuse only a public method's
427
- * publish, so that the card of a template never loses its picture and every organization can run
428
- * what it reads.
440
+ * `thumbnail_missing`, `thumbnail_invalid`, `storage_reference` and `showcase_missing` refuse only
441
+ * a public method's publish, so that the card of a template never loses its picture, every
442
+ * organization can run what it reads, and a template never appears with nothing to show.
429
443
  */
430
- export type MethodPublishRefusalReason = "invalid" | "not_runnable" | "thumbnail_missing" | "thumbnail_invalid" | "storage_reference";
444
+ export type MethodPublishRefusalReason = "invalid" | "not_runnable" | "thumbnail_missing" | "thumbnail_invalid" | "storage_reference" | "showcase_missing";
431
445
  /** A publish that wrote a new version. */
432
446
  export interface MethodPublished {
433
447
  outcome: "published";
@@ -642,6 +656,17 @@ export interface MethodCopied {
642
656
  examples_copied: number;
643
657
  /** How many distinct stored files were copied into the destination for the copy's inputs. */
644
658
  stored_files_copied: number;
659
+ /**
660
+ * How many showcases of the tree taken the copy holds, each copied with its files. Reserved: the
661
+ * platform answers `0` until copies carry showcases, and a platform that predates it leaves it
662
+ * out, which means none.
663
+ */
664
+ showcases_copied?: number;
665
+ /**
666
+ * How many layouts of the tree taken the copy holds. Reserved: the platform answers `0` until
667
+ * copies carry layouts, and a platform that predates it leaves it out, which means none.
668
+ */
669
+ layouts_copied?: number;
645
670
  }
646
671
  /**
647
672
  * A copy refused before anything was written: a bundle of the draft names stored files the copy
@@ -717,6 +742,13 @@ export interface MethodExample {
717
742
  * changed. It may name a run deleted since, which then reads as not found.
718
743
  */
719
744
  latest_run_id: string | null;
745
+ /**
746
+ * The showcase frozen from the example's latest run, the output a person may look at without
747
+ * running the method; `null` when none was, and cleared when the inputs change. Reserved: the
748
+ * platform answers `null` until copies born from a showcase fill it, and a platform that predates
749
+ * it leaves it out, which means none.
750
+ */
751
+ showcase_id?: string | null;
720
752
  /** The canonical id of the member who saved the example; it confers nothing. */
721
753
  created_by_user_id: string;
722
754
  /** ISO-8601 UTC instant of the example's creation. */
package/dist/version.d.ts CHANGED
@@ -3,4 +3,4 @@
3
3
  * `User-Agent` without importing the public barrel. Kept in sync with
4
4
  * `package.json` — enforced by `tests/index.test.ts`.
5
5
  */
6
- export declare const SDK_VERSION = "0.64.0";
6
+ export declare const SDK_VERSION = "0.66.0";
package/dist/version.js CHANGED
@@ -3,5 +3,5 @@
3
3
  * `User-Agent` without importing the public barrel. Kept in sync with
4
4
  * `package.json` — enforced by `tests/index.test.ts`.
5
5
  */
6
- export const SDK_VERSION = "0.64.0";
6
+ export const SDK_VERSION = "0.66.0";
7
7
  //# sourceMappingURL=version.js.map