@instruments/materialgraph 0.32.0 → 0.33.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/by-spec-types.d.ts +1 -2
- package/client.d.ts +19 -3
- package/client.js +24 -3
- package/index.d.ts +1 -0
- package/list-variants-types.d.ts +48 -9
- package/operations.d.ts +1 -1
- package/operations.js +1 -0
- package/package.json +1 -1
- package/response-schemas.generated.d.ts +1 -1
- package/response-schemas.generated.js +28 -25
- package/search-variants-types.d.ts +73 -0
- package/search-variants-types.js +1 -0
package/by-spec-types.d.ts
CHANGED
|
@@ -56,9 +56,8 @@ export type BySpecVerdictCell = {
|
|
|
56
56
|
* Why an `unverified` cell missed the bar; null otherwise.
|
|
57
57
|
* - `below_confidence` — the value is real but scored under the floor.
|
|
58
58
|
* - `basis_unmet` — the value's source is weaker than the criterion demanded.
|
|
59
|
-
* - `proposed` — the value is awaiting acceptance and is not yet on record.
|
|
60
59
|
*/
|
|
61
|
-
trustGap: "below_confidence" | "basis_unmet" |
|
|
60
|
+
trustGap: "below_confidence" | "basis_unmet" | null;
|
|
62
61
|
citation?: VerdictCitation;
|
|
63
62
|
};
|
|
64
63
|
/**
|
package/client.d.ts
CHANGED
|
@@ -20,6 +20,7 @@ import type { MaterialQueryPlan } from "./material-query-plan-types.js";
|
|
|
20
20
|
import type { SourceMaterialBatchReceipt, UploadSourceMaterialInput } from "./run-types.js";
|
|
21
21
|
import type { SchemaResource, SchemaResourceResponse } from "./schema-resource-types.js";
|
|
22
22
|
import type { CardProjectionRequest, SearchCardResponse } from "./search-card-types.js";
|
|
23
|
+
import type { SearchVariantsInput, SearchVariantsOutput } from "./search-variants-types.js";
|
|
23
24
|
import type { ExtractPaletteInput, ExtractPaletteResponse, ListAttributesOptions, ListAttributesResult, PairingsOptions, PairingsResponse, ResolveColourOptions, ResolveColourResponse, SearchGetParams, SearchInput, SearchResponse, WhoamiResponse } from "./types.js";
|
|
24
25
|
import { WorkflowsClient } from "./workflows-client.js";
|
|
25
26
|
export * from "./client-config.js";
|
|
@@ -201,9 +202,9 @@ export declare class MaterialGraphClient extends CatalogueClient {
|
|
|
201
202
|
* it names a real variant outside the materials catalogue, never silently
|
|
202
203
|
* dropped from the page.
|
|
203
204
|
*
|
|
204
|
-
* `filters`/`optionalFilters`/`orderBy` are sent as URL-encoded
|
|
205
|
-
* `attributes`/`include` as comma-separated lists — the server
|
|
206
|
-
* this method does not duplicate that check.
|
|
205
|
+
* `filters`/`optionalFilters`/`orderBy`/`colours` are sent as URL-encoded
|
|
206
|
+
* JSON; `attributes`/`include`/`words` as comma-separated lists — the server
|
|
207
|
+
* validates, this method does not duplicate that check.
|
|
207
208
|
*/
|
|
208
209
|
listVariants(input: ListVariantsInput, signal?: AbortSignal): Promise<ListVariantsOutput>;
|
|
209
210
|
/**
|
|
@@ -214,6 +215,21 @@ export declare class MaterialGraphClient extends CatalogueClient {
|
|
|
214
215
|
* `listVariants()` takes; the server validates both.
|
|
215
216
|
*/
|
|
216
217
|
listVariantFacets(input: ListVariantFacetsInput, signal?: AbortSignal): Promise<ListVariantFacetsOutput>;
|
|
218
|
+
/**
|
|
219
|
+
* THE QUESTION: "which variants match these plain words, and how did you
|
|
220
|
+
* read them?" (POST `/api/v1/variants/search`, MG-2223) — `query` is read
|
|
221
|
+
* into the filters {@link MaterialGraphClient.listVariants} takes, run
|
|
222
|
+
* through it, and answered with `understood` (what each phrase became, or
|
|
223
|
+
* why it did nothing) beside the page. `filters`, `optionalFilters` and
|
|
224
|
+
* `name` are exactly what ran, so the three can be sent to `listVariants()`
|
|
225
|
+
* to narrow or widen the same search; page with this method's own cursor,
|
|
226
|
+
* which `listVariants()` refuses. A phrase with several meanings is
|
|
227
|
+
* answered with one and listed in `choices`; send its `handle` with an
|
|
228
|
+
* alternative's `group` and `id` in `selections` to switch it. A query that
|
|
229
|
+
* applies nothing returns no items, never the whole catalogue; a preference
|
|
230
|
+
* alone still ranks it.
|
|
231
|
+
*/
|
|
232
|
+
searchVariants(input: SearchVariantsInput, signal?: AbortSignal): Promise<SearchVariantsOutput>;
|
|
217
233
|
/**
|
|
218
234
|
* THE QUESTION: "which variants hold, resemble, or can be ranked by, this
|
|
219
235
|
* colour?" (POST `/api/v1/variants/by-colour`, MG-2217/MG-2230/MG-2247).
|
package/client.js
CHANGED
|
@@ -250,9 +250,9 @@ export class MaterialGraphClient extends CatalogueClient {
|
|
|
250
250
|
* it names a real variant outside the materials catalogue, never silently
|
|
251
251
|
* dropped from the page.
|
|
252
252
|
*
|
|
253
|
-
* `filters`/`optionalFilters`/`orderBy` are sent as URL-encoded
|
|
254
|
-
* `attributes`/`include` as comma-separated lists — the server
|
|
255
|
-
* this method does not duplicate that check.
|
|
253
|
+
* `filters`/`optionalFilters`/`orderBy`/`colours` are sent as URL-encoded
|
|
254
|
+
* JSON; `attributes`/`include`/`words` as comma-separated lists — the server
|
|
255
|
+
* validates, this method does not duplicate that check.
|
|
256
256
|
*/
|
|
257
257
|
async listVariants(input, signal) {
|
|
258
258
|
return await this.#get("list_variants", {
|
|
@@ -260,6 +260,9 @@ export class MaterialGraphClient extends CatalogueClient {
|
|
|
260
260
|
? input.attributes.join(",")
|
|
261
261
|
: undefined,
|
|
262
262
|
collapse: input.collapse,
|
|
263
|
+
colours: input.colours?.length
|
|
264
|
+
? JSON.stringify(input.colours)
|
|
265
|
+
: undefined,
|
|
263
266
|
corpusScope: input.corpusScope,
|
|
264
267
|
cursor: input.cursor,
|
|
265
268
|
filters: input.filters ? JSON.stringify(input.filters) : undefined,
|
|
@@ -272,6 +275,7 @@ export class MaterialGraphClient extends CatalogueClient {
|
|
|
272
275
|
orderBy: input.orderBy?.length
|
|
273
276
|
? JSON.stringify(input.orderBy)
|
|
274
277
|
: undefined,
|
|
278
|
+
words: input.words?.length ? input.words.join(",") : undefined,
|
|
275
279
|
}, signal);
|
|
276
280
|
}
|
|
277
281
|
/**
|
|
@@ -284,6 +288,23 @@ export class MaterialGraphClient extends CatalogueClient {
|
|
|
284
288
|
async listVariantFacets(input, signal) {
|
|
285
289
|
return await this.#post("list_variant_facets", input, signal);
|
|
286
290
|
}
|
|
291
|
+
/**
|
|
292
|
+
* THE QUESTION: "which variants match these plain words, and how did you
|
|
293
|
+
* read them?" (POST `/api/v1/variants/search`, MG-2223) — `query` is read
|
|
294
|
+
* into the filters {@link MaterialGraphClient.listVariants} takes, run
|
|
295
|
+
* through it, and answered with `understood` (what each phrase became, or
|
|
296
|
+
* why it did nothing) beside the page. `filters`, `optionalFilters` and
|
|
297
|
+
* `name` are exactly what ran, so the three can be sent to `listVariants()`
|
|
298
|
+
* to narrow or widen the same search; page with this method's own cursor,
|
|
299
|
+
* which `listVariants()` refuses. A phrase with several meanings is
|
|
300
|
+
* answered with one and listed in `choices`; send its `handle` with an
|
|
301
|
+
* alternative's `group` and `id` in `selections` to switch it. A query that
|
|
302
|
+
* applies nothing returns no items, never the whole catalogue; a preference
|
|
303
|
+
* alone still ranks it.
|
|
304
|
+
*/
|
|
305
|
+
async searchVariants(input, signal) {
|
|
306
|
+
return await this.#post("search_variants", input, signal);
|
|
307
|
+
}
|
|
287
308
|
/**
|
|
288
309
|
* THE QUESTION: "which variants hold, resemble, or can be ranked by, this
|
|
289
310
|
* colour?" (POST `/api/v1/variants/by-colour`, MG-2217/MG-2230/MG-2247).
|
package/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ export { MaterialGraphClient, DEFAULT_BASE_URL } from "./client.js";
|
|
|
2
2
|
export type { MaterialGraphClientOptions } from "./client.js";
|
|
3
3
|
export type * from "./list-variants-types.js";
|
|
4
4
|
export type * from "./list-variant-facets-types.js";
|
|
5
|
+
export type * from "./search-variants-types.js";
|
|
5
6
|
export type * from "./list-enum-values-types.js";
|
|
6
7
|
export type * from "./get-variant-types.js";
|
|
7
8
|
export type * from "./image-reference-types.js";
|
package/list-variants-types.d.ts
CHANGED
|
@@ -26,20 +26,33 @@ export type FilterPresenceCondition = {
|
|
|
26
26
|
op: "exists" | "missing";
|
|
27
27
|
};
|
|
28
28
|
/**
|
|
29
|
-
*
|
|
29
|
+
* A term stated under ANY of `fields` (2–8 distinct term attributes), for a
|
|
30
|
+
* concept stored under several of them. `in`: at least one of `values` under
|
|
31
|
+
* at least one field. `not_in`: at least one field stated at all, and none of
|
|
32
|
+
* `values` under any field.
|
|
33
|
+
*/
|
|
34
|
+
export type FilterAnyFieldCondition = {
|
|
35
|
+
fields: string[];
|
|
36
|
+
op: "in" | "not_in";
|
|
37
|
+
values: string[];
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
* One filter condition, whichever of the four fully-required shapes. No
|
|
30
41
|
* `unit` key (a numeric value is in the attribute's own canonical unit).
|
|
31
42
|
*/
|
|
32
|
-
export type FilterCondition = FilterTermCondition | FilterNumericCondition | FilterPresenceCondition;
|
|
43
|
+
export type FilterCondition = FilterTermCondition | FilterNumericCondition | FilterPresenceCondition | FilterAnyFieldCondition;
|
|
33
44
|
/**
|
|
34
45
|
* `filters`: kind-grouped, not a flat list (MG-2222) — `{terms, numbers,
|
|
35
|
-
* presence}`. Every condition across all
|
|
36
|
-
* within one field is `in
|
|
37
|
-
* empty array carries no
|
|
46
|
+
* presence, anyField}`. Every condition across all four arrays must match
|
|
47
|
+
* (AND); OR within one field is `in`, and `anyField` is OR across several
|
|
48
|
+
* fields. Send only the arrays you need; an omitted or empty array carries no
|
|
49
|
+
* conditions.
|
|
38
50
|
*/
|
|
39
51
|
export type FilterGroups = {
|
|
40
52
|
terms?: FilterTermCondition[];
|
|
41
53
|
numbers?: FilterNumericCondition[];
|
|
42
54
|
presence?: FilterPresenceCondition[];
|
|
55
|
+
anyField?: FilterAnyFieldCondition[];
|
|
43
56
|
};
|
|
44
57
|
/** `optionalFilters`: the same kind-grouped shape as `filters`, with every entry also carrying a required `weight` (1–10). Ranks matched items; never excludes. */
|
|
45
58
|
export type OptionalFilterGroups = {
|
|
@@ -52,6 +65,9 @@ export type OptionalFilterGroups = {
|
|
|
52
65
|
presence?: (FilterPresenceCondition & {
|
|
53
66
|
weight: number;
|
|
54
67
|
})[];
|
|
68
|
+
anyField?: (FilterAnyFieldCondition & {
|
|
69
|
+
weight: number;
|
|
70
|
+
})[];
|
|
55
71
|
};
|
|
56
72
|
export type OrderByEntry = {
|
|
57
73
|
direction: "asc" | "desc";
|
|
@@ -59,23 +75,44 @@ export type OrderByEntry = {
|
|
|
59
75
|
field: string;
|
|
60
76
|
};
|
|
61
77
|
export type ListVariantsInclude = "image" | "url";
|
|
62
|
-
export type ListVariantsCollapse = "product";
|
|
78
|
+
export type ListVariantsCollapse = "product" | "colourway";
|
|
79
|
+
/** A region in OKLCh: lightness and chroma as bounds, hue an arc in degrees that wraps when its start is past its end, null for any hue. */
|
|
80
|
+
export type ColourRegion = {
|
|
81
|
+
chroma: [number, number];
|
|
82
|
+
hue: [number, number] | null;
|
|
83
|
+
lightness: [number, number];
|
|
84
|
+
};
|
|
85
|
+
/**
|
|
86
|
+
* A measured-colour condition. `in` keeps a variant with a large swatch inside
|
|
87
|
+
* `range`; `not_in` leaves those out and lets a variant with no measured
|
|
88
|
+
* colour pass. `preferred` only orders and never narrows.
|
|
89
|
+
*/
|
|
90
|
+
export type ColourRangeCondition = {
|
|
91
|
+
/** The colour's own point in the region, `#rrggbb`; it orders matches, nearest first. */
|
|
92
|
+
hex: string;
|
|
93
|
+
intent?: "required" | "preferred";
|
|
94
|
+
op: "in" | "not_in";
|
|
95
|
+
range: ColourRegion;
|
|
96
|
+
};
|
|
63
97
|
export type ListVariantsInput = {
|
|
64
98
|
/** Attribute ids to project under each item's `specifications`. */
|
|
65
99
|
attributes?: string[];
|
|
66
100
|
/**
|
|
67
101
|
* `product`: one row per product, its lead colourway by the page's order,
|
|
68
102
|
* with `variantCount` saying how many colourways stand behind it. The
|
|
69
|
-
* cursor pages products.
|
|
103
|
+
* cursor pages products. `colourway`: one row per colourway, so a colour
|
|
104
|
+
* sold on several substrates is one row.
|
|
70
105
|
*/
|
|
71
106
|
collapse?: ListVariantsCollapse;
|
|
107
|
+
/** Up to four measured-colour regions. */
|
|
108
|
+
colours?: ColourRangeCondition[];
|
|
72
109
|
/**
|
|
73
110
|
* Only variants in this corpus scope: the rows, the page and the cursor.
|
|
74
111
|
* Absent or `all` is every variant.
|
|
75
112
|
*/
|
|
76
113
|
corpusScope?: CorpusScope;
|
|
77
114
|
cursor?: string;
|
|
78
|
-
/** Every condition, across `terms`/`numbers`/`presence`, must match. */
|
|
115
|
+
/** Every condition, across `terms`/`numbers`/`presence`/`anyField`, must match. */
|
|
79
116
|
filters?: FilterGroups;
|
|
80
117
|
include?: ListVariantsInclude[];
|
|
81
118
|
/** 1–50; defaults to 10. */
|
|
@@ -89,10 +126,12 @@ export type ListVariantsInput = {
|
|
|
89
126
|
/** Rank only — never excludes. */
|
|
90
127
|
optionalFilters?: OptionalFilterGroups;
|
|
91
128
|
orderBy?: OrderByEntry[];
|
|
129
|
+
/** Words each variant must name in its text, inside the filters. */
|
|
130
|
+
words?: string[];
|
|
92
131
|
};
|
|
93
132
|
/**
|
|
94
133
|
* `score` sums the weights of the matched `optionalFilters`; `matched` lists
|
|
95
|
-
* their positions in the flattened terms-then-numbers-then-presence order
|
|
134
|
+
* their positions in the flattened terms-then-numbers-then-presence-then-anyField order
|
|
96
135
|
* the server reads `optionalFilters` in, not the caller's own array shape.
|
|
97
136
|
*/
|
|
98
137
|
export type ListVariantsPreference = {
|
package/operations.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const MATERIALGRAPH_API_VERSION = "0.7.0";
|
|
2
|
-
declare const OPERATION_DEFINITIONS: readonly [readonly ["samplizeColorVecCache", "GET", "/api/v1/catalogues/samplize/colorvec", "samplize_colorvec_cache"], readonly ["samplizeCatalogueSearch", "POST", "/api/v1/catalogues/samplize/search", "samplize_catalogue_search"], readonly ["catalogs", "GET", "/api/v1/catalogs", "list_catalog_documents"], readonly ["catalogPages", "GET", "/api/v1/catalogs/{catalogId}/pages", "list_catalog_pages"], readonly ["catalogPageRepresentation", "GET", "/api/v1/catalog-pages/{pageId}/representation", "get_catalog_page_representation"], readonly ["catalogReferences", "GET", "/api/v1/catalogs/{catalogId}/references", "list_catalog_product_references"], readonly ["search", "POST", "/api/v1/search", "search_materials_post"], readonly ["planQuery", "POST", "/api/v1/search/plan", "plan_material_query"], readonly ["samplizeCatalogue", "GET", "/api/v1/catalogues/samplize/products", "samplize_catalogue_products"], readonly ["searchGet", "GET", "/api/v1/search", "search_materials_get"], readonly ["byColour", "GET", "/api/v1/search/colours", "search_by_colour"], readonly ["catalogueReferences", "POST", "/api/v1/catalogues/references", "get_catalogue_references_batch"], readonly ["catalogueCollections", "GET", "/api/v1/catalogues/collections", "list_catalogue_channel_collections"], readonly ["catalogueDocumentAccess", "GET", "/api/v1/catalogues/documents/{documentId}", "get_catalogue_document_access"], readonly ["materialBlocks", "GET", "/api/v1/materials/{variantId}/blocks", "list_material_blocks"], readonly ["listVariantAssets", "GET", "/api/v1/variants/{variantId}/assets", "list_variant_assets"], readonly ["materialDocuments", "GET", "/api/v1/materials/{variantId}/documents", "list_material_documents"], readonly ["schema", "GET", "/api/v1/schema/value-dictionaries", "list_schema_value_dictionaries"], readonly ["pairings", "GET", "/api/v1/materials/{variantId}/pairings", "get_material_pairings"], readonly ["associatedFinishes", "GET", "/api/v1/associated/finishes", "list_associated_finishes"], readonly ["associatedProducts", "GET", "/api/v1/associated/products", "list_associated_products"], readonly ["applicability", "GET", "/api/v1/applicability", "get_applicability"], readonly ["listVariants", "GET", "/api/v1/variants", "list_variants"], readonly ["listVariantFacets", "POST", "/api/v1/variants/facets", "list_variant_facets"], readonly ["findVariantsByColour", "POST", "/api/v1/variants/by-colour", "find_variants_by_colour"], readonly ["findVariantsByVector", "POST", "/api/v1/variants/by-vector", "find_variants_by_vector"], readonly ["findCompanions", "POST", "/api/v1/variants/companions", "find_companions"], readonly ["resolveVariant", "POST", "/api/v1/variants/resolve", "resolve_variant"], readonly ["getVariant", "GET", "/api/v1/variants/{variantId}", "get_variant"], readonly ["resolveColour", "GET", "/api/v1/search/colours/resolve", "resolve_colour_name"], readonly ["listAttributes", "GET", "/api/v1/catalog/attributes", "catalog_list_attributes"], readonly ["listEnumValues", "GET", "/api/v1/catalog/enum-values", "catalog_list_enum_values"], readonly ["categories.list", "GET", "/api/v1/categories", "list_categories"], readonly ["categories.get", "GET", "/api/v1/categories/{id}", "get_category"], readonly ["whoami", "GET", "/api/v1/whoami", "whoami"], readonly ["colours.palette", "POST", "/api/v1/search/palettes", "search_by_palette"], readonly ["extractPalette", "POST", "/api/v1/search/palettes/extract", "extract_image_palette"], readonly ["brands", "GET", "/api/v1/brands", "list_brands"], readonly ["uploadSourceMaterial", "POST", "/api/v1/source-material", "upload_source_material"], readonly ["workflows.start", "POST", "/api/v1/workflows/{workflowId}/runs", "create_public_run"], readonly ["workflows.run", "GET", "/api/v1/workflows/{workflowId}/runs/{runId}", "get_public_run"], readonly ["citation", "GET", "/api/v1/citations/{citationId}", "get_verdict_citation"], readonly ["workflows.streamRunEvents", "GET", "/api/v1/workflows/{workflowId}/runs/{runId}/events", "list_public_run_events"]];
|
|
2
|
+
declare const OPERATION_DEFINITIONS: readonly [readonly ["samplizeColorVecCache", "GET", "/api/v1/catalogues/samplize/colorvec", "samplize_colorvec_cache"], readonly ["samplizeCatalogueSearch", "POST", "/api/v1/catalogues/samplize/search", "samplize_catalogue_search"], readonly ["catalogs", "GET", "/api/v1/catalogs", "list_catalog_documents"], readonly ["catalogPages", "GET", "/api/v1/catalogs/{catalogId}/pages", "list_catalog_pages"], readonly ["catalogPageRepresentation", "GET", "/api/v1/catalog-pages/{pageId}/representation", "get_catalog_page_representation"], readonly ["catalogReferences", "GET", "/api/v1/catalogs/{catalogId}/references", "list_catalog_product_references"], readonly ["search", "POST", "/api/v1/search", "search_materials_post"], readonly ["planQuery", "POST", "/api/v1/search/plan", "plan_material_query"], readonly ["samplizeCatalogue", "GET", "/api/v1/catalogues/samplize/products", "samplize_catalogue_products"], readonly ["searchGet", "GET", "/api/v1/search", "search_materials_get"], readonly ["byColour", "GET", "/api/v1/search/colours", "search_by_colour"], readonly ["catalogueReferences", "POST", "/api/v1/catalogues/references", "get_catalogue_references_batch"], readonly ["catalogueCollections", "GET", "/api/v1/catalogues/collections", "list_catalogue_channel_collections"], readonly ["catalogueDocumentAccess", "GET", "/api/v1/catalogues/documents/{documentId}", "get_catalogue_document_access"], readonly ["materialBlocks", "GET", "/api/v1/materials/{variantId}/blocks", "list_material_blocks"], readonly ["listVariantAssets", "GET", "/api/v1/variants/{variantId}/assets", "list_variant_assets"], readonly ["materialDocuments", "GET", "/api/v1/materials/{variantId}/documents", "list_material_documents"], readonly ["schema", "GET", "/api/v1/schema/value-dictionaries", "list_schema_value_dictionaries"], readonly ["pairings", "GET", "/api/v1/materials/{variantId}/pairings", "get_material_pairings"], readonly ["associatedFinishes", "GET", "/api/v1/associated/finishes", "list_associated_finishes"], readonly ["associatedProducts", "GET", "/api/v1/associated/products", "list_associated_products"], readonly ["applicability", "GET", "/api/v1/applicability", "get_applicability"], readonly ["listVariants", "GET", "/api/v1/variants", "list_variants"], readonly ["listVariantFacets", "POST", "/api/v1/variants/facets", "list_variant_facets"], readonly ["searchVariants", "POST", "/api/v1/variants/search", "search_variants"], readonly ["findVariantsByColour", "POST", "/api/v1/variants/by-colour", "find_variants_by_colour"], readonly ["findVariantsByVector", "POST", "/api/v1/variants/by-vector", "find_variants_by_vector"], readonly ["findCompanions", "POST", "/api/v1/variants/companions", "find_companions"], readonly ["resolveVariant", "POST", "/api/v1/variants/resolve", "resolve_variant"], readonly ["getVariant", "GET", "/api/v1/variants/{variantId}", "get_variant"], readonly ["resolveColour", "GET", "/api/v1/search/colours/resolve", "resolve_colour_name"], readonly ["listAttributes", "GET", "/api/v1/catalog/attributes", "catalog_list_attributes"], readonly ["listEnumValues", "GET", "/api/v1/catalog/enum-values", "catalog_list_enum_values"], readonly ["categories.list", "GET", "/api/v1/categories", "list_categories"], readonly ["categories.get", "GET", "/api/v1/categories/{id}", "get_category"], readonly ["whoami", "GET", "/api/v1/whoami", "whoami"], readonly ["colours.palette", "POST", "/api/v1/search/palettes", "search_by_palette"], readonly ["extractPalette", "POST", "/api/v1/search/palettes/extract", "extract_image_palette"], readonly ["brands", "GET", "/api/v1/brands", "list_brands"], readonly ["uploadSourceMaterial", "POST", "/api/v1/source-material", "upload_source_material"], readonly ["workflows.start", "POST", "/api/v1/workflows/{workflowId}/runs", "create_public_run"], readonly ["workflows.run", "GET", "/api/v1/workflows/{workflowId}/runs/{runId}", "get_public_run"], readonly ["citation", "GET", "/api/v1/citations/{citationId}", "get_verdict_citation"], readonly ["workflows.streamRunEvents", "GET", "/api/v1/workflows/{workflowId}/runs/{runId}/events", "list_public_run_events"]];
|
|
3
3
|
export type SdkOperationId = (typeof OPERATION_DEFINITIONS)[number][3];
|
|
4
4
|
export type SdkOperation = Readonly<{
|
|
5
5
|
clientMethod: (typeof OPERATION_DEFINITIONS)[number][0];
|
package/operations.js
CHANGED
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** The API contract version the schemas were generated from. */
|
|
2
2
|
export declare const RESPONSE_SCHEMA_API_VERSION = "0.7.0";
|
|
3
3
|
/** Every SDK operation whose success response has a published JSON Schema. */
|
|
4
|
-
export declare const RESPONSE_SCHEMA_OPERATION_IDS: readonly ["samplize_colorvec_cache", "samplize_catalogue_search", "list_catalog_documents", "list_catalog_pages", "get_catalog_page_representation", "list_catalog_product_references", "search_materials_post", "plan_material_query", "samplize_catalogue_products", "search_materials_get", "search_by_colour", "get_catalogue_references_batch", "list_catalogue_channel_collections", "get_catalogue_document_access", "list_material_blocks", "list_variant_assets", "list_material_documents", "list_schema_value_dictionaries", "get_material_pairings", "list_associated_finishes", "list_associated_products", "get_applicability", "list_variants", "list_variant_facets", "find_variants_by_colour", "find_variants_by_vector", "find_companions", "resolve_variant", "get_variant", "resolve_colour_name", "catalog_list_attributes", "catalog_list_enum_values", "list_categories", "get_category", "whoami", "search_by_palette", "extract_image_palette", "list_brands", "upload_source_material", "create_public_run", "get_public_run", "get_verdict_citation"];
|
|
4
|
+
export declare const RESPONSE_SCHEMA_OPERATION_IDS: readonly ["samplize_colorvec_cache", "samplize_catalogue_search", "list_catalog_documents", "list_catalog_pages", "get_catalog_page_representation", "list_catalog_product_references", "search_materials_post", "plan_material_query", "samplize_catalogue_products", "search_materials_get", "search_by_colour", "get_catalogue_references_batch", "list_catalogue_channel_collections", "get_catalogue_document_access", "list_material_blocks", "list_variant_assets", "list_material_documents", "list_schema_value_dictionaries", "get_material_pairings", "list_associated_finishes", "list_associated_products", "get_applicability", "list_variants", "list_variant_facets", "search_variants", "find_variants_by_colour", "find_variants_by_vector", "find_companions", "resolve_variant", "get_variant", "resolve_colour_name", "catalog_list_attributes", "catalog_list_enum_values", "list_categories", "get_category", "whoami", "search_by_palette", "extract_image_palette", "list_brands", "upload_source_material", "create_public_run", "get_public_run", "get_verdict_citation"];
|
|
5
5
|
export declare const RESPONSE_SCHEMA_CATALOGUE_JSON: string;
|