@purveyors/sdk 0.34.0 → 0.36.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/index.d.ts +491 -13
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -2626,6 +2626,7 @@ interface paths {
|
|
|
2626
2626
|
pricePerLbMax?: number | null;
|
|
2627
2627
|
elevationMinMasl?: number | null;
|
|
2628
2628
|
elevationMaxMasl?: number | null;
|
|
2629
|
+
includeUnknownElevation?: "true" | "false";
|
|
2629
2630
|
processing_base_method?: string;
|
|
2630
2631
|
fermentation_type?: string;
|
|
2631
2632
|
process_additive?: string;
|
|
@@ -2706,7 +2707,7 @@ interface paths {
|
|
|
2706
2707
|
};
|
|
2707
2708
|
/**
|
|
2708
2709
|
* Map projection over the caller-visible catalog
|
|
2709
|
-
* @description Returns deterministic lightweight clusters and place features after applying the canonical catalog visibility, filters, and entitlement policy. Global unique/unplaced totals remain separate from viewport placement totals; multi-origin placement counts are intentionally non-additive. Public/demo callers receive country/region-safe features, while canonical place navigation, bounding boxes, and elevation profiles are available to member sessions and customer API keys. Green map projections inspect at most 25 catalog rows; feature counts follow the aggregate map grouping rather than the collection-item cap. These catalog routes require a Supabase session JWT or Parchment API key. For entitlement-gated params, strict callers (non-demo API keys, bearer-session JWTs) receive a 401/403; lenient callers (first-party cookie-session and the configured public-demo API key) get the params stripped with a `meta.notices` entry. Send `Prefer: handling=strict` to opt into strict enforcement; `Prefer: handling=lenient` is honored only for callers already lenient-eligible and cannot downgrade a strict caller's enforcement.
|
|
2710
|
+
* @description Returns deterministic lightweight clusters, semantic location groups, and place features after applying the canonical catalog visibility, filters, and entitlement policy. The optional locations projection groups placements by canonical place identity so contained coffees can be selected without inventing screen-space coordinates. Global unique/unplaced totals remain separate from viewport placement totals; multi-origin placement counts are intentionally non-additive. Public/demo callers receive country/region-safe features, while canonical place navigation, bounding boxes, and elevation profiles are available to member sessions and customer API keys. Green map projections inspect at most 25 catalog rows; feature counts follow the aggregate map grouping rather than the collection-item cap. These catalog routes require a Supabase session JWT or Parchment API key. For entitlement-gated params, strict callers (non-demo API keys, bearer-session JWTs) receive a 401/403; lenient callers (first-party cookie-session and the configured public-demo API key) get the params stripped with a `meta.notices` entry. Send `Prefer: handling=strict` to opt into strict enforcement; `Prefer: handling=lenient` is honored only for callers already lenient-eligible and cannot downgrade a strict caller's enforcement.
|
|
2710
2711
|
*/
|
|
2711
2712
|
get: {
|
|
2712
2713
|
parameters: {
|
|
@@ -2738,6 +2739,7 @@ interface paths {
|
|
|
2738
2739
|
pricePerLbMax?: number | null;
|
|
2739
2740
|
elevationMinMasl?: number | null;
|
|
2740
2741
|
elevationMaxMasl?: number | null;
|
|
2742
|
+
includeUnknownElevation?: "true" | "false";
|
|
2741
2743
|
processing_base_method?: string;
|
|
2742
2744
|
fermentation_type?: string;
|
|
2743
2745
|
process_additive?: string;
|
|
@@ -2748,6 +2750,7 @@ interface paths {
|
|
|
2748
2750
|
bbox?: string;
|
|
2749
2751
|
zoom?: number;
|
|
2750
2752
|
lens?: "catalog" | "elevation";
|
|
2753
|
+
projection?: "clusters" | "locations";
|
|
2751
2754
|
};
|
|
2752
2755
|
header?: {
|
|
2753
2756
|
Prefer?: string;
|
|
@@ -2884,6 +2887,7 @@ interface paths {
|
|
|
2884
2887
|
pricePerLbMax?: number | null;
|
|
2885
2888
|
elevationMinMasl?: number | null;
|
|
2886
2889
|
elevationMaxMasl?: number | null;
|
|
2890
|
+
includeUnknownElevation?: "true" | "false";
|
|
2887
2891
|
processing_base_method?: string;
|
|
2888
2892
|
fermentation_type?: string;
|
|
2889
2893
|
process_additive?: string;
|
|
@@ -5117,6 +5121,147 @@ interface paths {
|
|
|
5117
5121
|
patch?: never;
|
|
5118
5122
|
trace?: never;
|
|
5119
5123
|
};
|
|
5124
|
+
"/v1/confirmed-actions/execute": {
|
|
5125
|
+
parameters: {
|
|
5126
|
+
query?: never;
|
|
5127
|
+
header?: never;
|
|
5128
|
+
path?: never;
|
|
5129
|
+
cookie?: never;
|
|
5130
|
+
};
|
|
5131
|
+
get?: never;
|
|
5132
|
+
put?: never;
|
|
5133
|
+
/**
|
|
5134
|
+
* Execute a user-confirmed product action
|
|
5135
|
+
* @description Execute one of five closed product actions for the authenticated session owner. The stable executionId provides payload-bound replay, and owner plus entitlement checks run again inside the same database transaction as the mutation. API keys are not accepted.
|
|
5136
|
+
*/
|
|
5137
|
+
post: {
|
|
5138
|
+
parameters: {
|
|
5139
|
+
query?: never;
|
|
5140
|
+
header?: never;
|
|
5141
|
+
path?: never;
|
|
5142
|
+
cookie?: never;
|
|
5143
|
+
};
|
|
5144
|
+
requestBody: {
|
|
5145
|
+
content: {
|
|
5146
|
+
"application/json": components["schemas"]["ConfirmedActionExecuteRequest"];
|
|
5147
|
+
};
|
|
5148
|
+
};
|
|
5149
|
+
responses: {
|
|
5150
|
+
/** @description Executed result or exact replay of an earlier result */
|
|
5151
|
+
200: {
|
|
5152
|
+
headers: {
|
|
5153
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
5154
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
5155
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
5156
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
5157
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
5158
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
5159
|
+
[name: string]: unknown;
|
|
5160
|
+
};
|
|
5161
|
+
content: {
|
|
5162
|
+
"application/json": components["schemas"]["ConfirmedActionExecuteResponse"];
|
|
5163
|
+
};
|
|
5164
|
+
};
|
|
5165
|
+
/** @description Invalid or unsupported confirmed-action payload */
|
|
5166
|
+
400: {
|
|
5167
|
+
headers: {
|
|
5168
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
5169
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
5170
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
5171
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
5172
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
5173
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
5174
|
+
[name: string]: unknown;
|
|
5175
|
+
};
|
|
5176
|
+
content: {
|
|
5177
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5178
|
+
};
|
|
5179
|
+
};
|
|
5180
|
+
/** @description Authentication required */
|
|
5181
|
+
401: {
|
|
5182
|
+
headers: {
|
|
5183
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
5184
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
5185
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
5186
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
5187
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
5188
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
5189
|
+
[name: string]: unknown;
|
|
5190
|
+
};
|
|
5191
|
+
content: {
|
|
5192
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5193
|
+
};
|
|
5194
|
+
};
|
|
5195
|
+
/** @description Insufficient entitlement (plan or role) */
|
|
5196
|
+
403: {
|
|
5197
|
+
headers: {
|
|
5198
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
5199
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
5200
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
5201
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
5202
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
5203
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
5204
|
+
[name: string]: unknown;
|
|
5205
|
+
};
|
|
5206
|
+
content: {
|
|
5207
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5208
|
+
};
|
|
5209
|
+
};
|
|
5210
|
+
/** @description The execution id conflicts with another payload or has no replayable result */
|
|
5211
|
+
409: {
|
|
5212
|
+
headers: {
|
|
5213
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
5214
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
5215
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
5216
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
5217
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
5218
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
5219
|
+
[name: string]: unknown;
|
|
5220
|
+
};
|
|
5221
|
+
content: {
|
|
5222
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5223
|
+
};
|
|
5224
|
+
};
|
|
5225
|
+
/** @description Per-user mutation throttle exceeded; retry after a short wait Customer API keys may also receive an account monthly or machine burst quota rejection. */
|
|
5226
|
+
429: {
|
|
5227
|
+
headers: {
|
|
5228
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
5229
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
5230
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
5231
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
5232
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
5233
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
5234
|
+
"Retry-After": components["headers"]["Retry-After"];
|
|
5235
|
+
"X-RateLimit-Blocked-By": components["headers"]["X-RateLimit-Blocked-By"];
|
|
5236
|
+
[name: string]: unknown;
|
|
5237
|
+
};
|
|
5238
|
+
content: {
|
|
5239
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5240
|
+
};
|
|
5241
|
+
};
|
|
5242
|
+
/** @description Confirmed-action execution is temporarily unavailable */
|
|
5243
|
+
503: {
|
|
5244
|
+
headers: {
|
|
5245
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
5246
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
5247
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
5248
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
5249
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
5250
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
5251
|
+
[name: string]: unknown;
|
|
5252
|
+
};
|
|
5253
|
+
content: {
|
|
5254
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5255
|
+
};
|
|
5256
|
+
};
|
|
5257
|
+
};
|
|
5258
|
+
};
|
|
5259
|
+
delete?: never;
|
|
5260
|
+
options?: never;
|
|
5261
|
+
head?: never;
|
|
5262
|
+
patch?: never;
|
|
5263
|
+
trace?: never;
|
|
5264
|
+
};
|
|
5120
5265
|
"/v1/inventory": {
|
|
5121
5266
|
parameters: {
|
|
5122
5267
|
query?: never;
|
|
@@ -9849,6 +9994,26 @@ interface components {
|
|
|
9849
9994
|
placement_count: number;
|
|
9850
9995
|
unique_coffee_count: number;
|
|
9851
9996
|
catalog_ids: number[];
|
|
9997
|
+
} | {
|
|
9998
|
+
/** @enum {string} */
|
|
9999
|
+
type: "location";
|
|
10000
|
+
id: string;
|
|
10001
|
+
/** Format: uuid */
|
|
10002
|
+
place_id: string | null;
|
|
10003
|
+
canonical_name: string;
|
|
10004
|
+
/** @enum {string} */
|
|
10005
|
+
place_type: "continent" | "country" | "region" | "subregion" | "locality" | "site";
|
|
10006
|
+
longitude: number;
|
|
10007
|
+
latitude: number;
|
|
10008
|
+
/** @enum {string} */
|
|
10009
|
+
geographic_precision: "none" | "continent" | "country" | "region" | "subregion" | "locality" | "site" | "exact_site";
|
|
10010
|
+
/** @enum {string} */
|
|
10011
|
+
coordinate_kind: "none" | "centroid" | "exact_point";
|
|
10012
|
+
/** @enum {string} */
|
|
10013
|
+
place_provenance: "reference_dataset" | "source_evidence" | "deterministic_resolution" | "manual_review";
|
|
10014
|
+
placement_count: number;
|
|
10015
|
+
unique_coffee_count: number;
|
|
10016
|
+
catalog_ids: number[];
|
|
9852
10017
|
} | {
|
|
9853
10018
|
/** @enum {string} */
|
|
9854
10019
|
type: "place";
|
|
@@ -9925,6 +10090,8 @@ interface components {
|
|
|
9925
10090
|
zoom: number;
|
|
9926
10091
|
/** @enum {string} */
|
|
9927
10092
|
lens: "catalog" | "elevation";
|
|
10093
|
+
/** @enum {string} */
|
|
10094
|
+
projection: "clusters" | "locations";
|
|
9928
10095
|
/** Format: uuid */
|
|
9929
10096
|
place_id: string | null;
|
|
9930
10097
|
bbox: {
|
|
@@ -11464,6 +11631,104 @@ interface components {
|
|
|
11464
11631
|
};
|
|
11465
11632
|
};
|
|
11466
11633
|
};
|
|
11634
|
+
ConfirmedActionExecuteResponse: {
|
|
11635
|
+
data: {
|
|
11636
|
+
/** @enum {boolean} */
|
|
11637
|
+
success: true;
|
|
11638
|
+
id: number;
|
|
11639
|
+
/** @enum {string} */
|
|
11640
|
+
message: "Bean added to inventory" | "Bean updated" | "Roast session created" | "Roast notes updated" | "Sale recorded";
|
|
11641
|
+
replayed: boolean;
|
|
11642
|
+
};
|
|
11643
|
+
meta: {
|
|
11644
|
+
/** @enum {string} */
|
|
11645
|
+
resource: "confirmed-actions";
|
|
11646
|
+
/** @enum {string} */
|
|
11647
|
+
namespace: "/v1/confirmed-actions";
|
|
11648
|
+
/** @enum {string} */
|
|
11649
|
+
version: "v1";
|
|
11650
|
+
auth: {
|
|
11651
|
+
/** @enum {string} */
|
|
11652
|
+
kind: "session";
|
|
11653
|
+
/** @enum {string} */
|
|
11654
|
+
role: "admin" | "member" | "viewer";
|
|
11655
|
+
/** @enum {string} */
|
|
11656
|
+
apiPlan: "viewer" | "member" | "enterprise";
|
|
11657
|
+
};
|
|
11658
|
+
};
|
|
11659
|
+
};
|
|
11660
|
+
ConfirmedActionExecuteRequest: {
|
|
11661
|
+
/** @description Stable operation id. Repeating it with the same action payload replays the stored result; changing the payload returns 409. */
|
|
11662
|
+
executionId: string;
|
|
11663
|
+
/** @enum {string} */
|
|
11664
|
+
actionType: "add_bean_to_inventory";
|
|
11665
|
+
fields: {
|
|
11666
|
+
catalog_id?: number | string;
|
|
11667
|
+
coffee_bean?: number | string;
|
|
11668
|
+
manual_name?: string;
|
|
11669
|
+
purchased_qty_lbs: number | string;
|
|
11670
|
+
cost_per_lb?: number | string;
|
|
11671
|
+
tax_ship_cost?: number | string;
|
|
11672
|
+
purchase_date?: "" | string;
|
|
11673
|
+
notes?: string;
|
|
11674
|
+
source_filter?: string;
|
|
11675
|
+
_bean_sources?: {
|
|
11676
|
+
[key: string]: string;
|
|
11677
|
+
};
|
|
11678
|
+
catalog_options_notice?: string;
|
|
11679
|
+
total_bean_cost?: number | string;
|
|
11680
|
+
};
|
|
11681
|
+
} | {
|
|
11682
|
+
/** @description Stable operation id. Repeating it with the same action payload replays the stored result; changing the payload returns 409. */
|
|
11683
|
+
executionId: string;
|
|
11684
|
+
/** @enum {string} */
|
|
11685
|
+
actionType: "update_bean";
|
|
11686
|
+
fields: {
|
|
11687
|
+
bean_id: number | string;
|
|
11688
|
+
rank?: number | string | null;
|
|
11689
|
+
notes?: string | null;
|
|
11690
|
+
stocked?: boolean | ("true" | "false");
|
|
11691
|
+
purchased_qty_lbs?: number | string;
|
|
11692
|
+
};
|
|
11693
|
+
} | {
|
|
11694
|
+
/** @description Stable operation id. Repeating it with the same action payload replays the stored result; changing the payload returns 409. */
|
|
11695
|
+
executionId: string;
|
|
11696
|
+
/** @enum {string} */
|
|
11697
|
+
actionType: "create_roast_session";
|
|
11698
|
+
fields: {
|
|
11699
|
+
coffee_id: number | string;
|
|
11700
|
+
coffee_name?: string;
|
|
11701
|
+
batch_name: string;
|
|
11702
|
+
roast_date?: "" | string;
|
|
11703
|
+
oz_in?: number | string;
|
|
11704
|
+
roast_notes?: string;
|
|
11705
|
+
roaster_type?: string;
|
|
11706
|
+
};
|
|
11707
|
+
} | {
|
|
11708
|
+
/** @description Stable operation id. Repeating it with the same action payload replays the stored result; changing the payload returns 409. */
|
|
11709
|
+
executionId: string;
|
|
11710
|
+
/** @enum {string} */
|
|
11711
|
+
actionType: "update_roast_notes";
|
|
11712
|
+
fields: {
|
|
11713
|
+
roast_id: number | string;
|
|
11714
|
+
roast_notes?: string | null;
|
|
11715
|
+
roast_targets?: string | null;
|
|
11716
|
+
};
|
|
11717
|
+
} | {
|
|
11718
|
+
/** @description Stable operation id. Repeating it with the same action payload replays the stored result; changing the payload returns 409. */
|
|
11719
|
+
executionId: string;
|
|
11720
|
+
/** @enum {string} */
|
|
11721
|
+
actionType: "record_sale";
|
|
11722
|
+
fields: {
|
|
11723
|
+
green_coffee_inv_id: number | string;
|
|
11724
|
+
batch_name?: string;
|
|
11725
|
+
oz_sold: number | string;
|
|
11726
|
+
price: number | string;
|
|
11727
|
+
buyer?: string;
|
|
11728
|
+
sell_date?: "" | string;
|
|
11729
|
+
purchase_date?: "" | string;
|
|
11730
|
+
};
|
|
11731
|
+
};
|
|
11467
11732
|
InventoryCatalog: {
|
|
11468
11733
|
id: number;
|
|
11469
11734
|
name: string | null;
|
|
@@ -12793,6 +13058,8 @@ type TrackedLotsListQuery = NonNullable<paths["/v1/portfolio/tracked-lots"]["get
|
|
|
12793
13058
|
type TrackedLotSummary = components["schemas"]["TrackedLotSummary"];
|
|
12794
13059
|
/** State returned by tracked-lot PUT and DELETE mutations. */
|
|
12795
13060
|
type TrackedLotMutation = components["schemas"]["TrackedLotMutationResponse"];
|
|
13061
|
+
/** Closed session-only command for {@link ParchmentClient.confirmedActions.execute}. */
|
|
13062
|
+
type ConfirmedActionExecuteRequest = NonNullable<paths["/v1/confirmed-actions/execute"]["post"]["requestBody"]>["content"]["application/json"];
|
|
12796
13063
|
/** Query parameters for {@link ParchmentClient.inventory.list}. */
|
|
12797
13064
|
type InventoryListQuery = NonNullable<paths["/v1/inventory"]["get"]["parameters"]["query"]>;
|
|
12798
13065
|
/** Request body for {@link ParchmentClient.inventory.create}. */
|
|
@@ -13897,7 +14164,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
13897
14164
|
[name: string]: unknown;
|
|
13898
14165
|
};
|
|
13899
14166
|
content: {
|
|
13900
|
-
"application/json": components["schemas"]["MarketBriefDraftResponse"];
|
|
14167
|
+
"application/json": components["schemas"] /** Approve a request using the client's authenticated user session. */["MarketBriefDraftResponse"];
|
|
13901
14168
|
};
|
|
13902
14169
|
};
|
|
13903
14170
|
202: {
|
|
@@ -14100,7 +14367,9 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14100
14367
|
[name: string]: unknown;
|
|
14101
14368
|
};
|
|
14102
14369
|
content: {
|
|
14103
|
-
"application/json":
|
|
14370
|
+
"application/json":
|
|
14371
|
+
/** Query parameters for {@link ParchmentClient.roasts.chartData}. */
|
|
14372
|
+
components["schemas"]["ErrorResponse"];
|
|
14104
14373
|
};
|
|
14105
14374
|
};
|
|
14106
14375
|
413: {
|
|
@@ -14108,7 +14377,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14108
14377
|
[name: string]: unknown;
|
|
14109
14378
|
};
|
|
14110
14379
|
content: {
|
|
14111
|
-
"application/json": components["schemas"]["ErrorResponse"];
|
|
14380
|
+
"application/json": components["schemas"] /** Request body for {@link ParchmentClient.roasts.create}. */["ErrorResponse"];
|
|
14112
14381
|
};
|
|
14113
14382
|
};
|
|
14114
14383
|
503: {
|
|
@@ -14298,7 +14567,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14298
14567
|
[name: string]: unknown;
|
|
14299
14568
|
};
|
|
14300
14569
|
content: {
|
|
14301
|
-
"application/json": components["schemas"]["ErrorResponse"];
|
|
14570
|
+
"application/json": components["schemas"] /** List the caller's saved sourcing briefs. */["ErrorResponse"];
|
|
14302
14571
|
};
|
|
14303
14572
|
};
|
|
14304
14573
|
503: {
|
|
@@ -14354,7 +14623,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14354
14623
|
[name: string]: unknown;
|
|
14355
14624
|
};
|
|
14356
14625
|
content: {
|
|
14357
|
-
"application/json": components["schemas"]["ErrorResponse"];
|
|
14626
|
+
"application/json": components["schemas"] /** List the caller's saved sourcing briefs. */["ErrorResponse"];
|
|
14358
14627
|
};
|
|
14359
14628
|
};
|
|
14360
14629
|
503: {
|
|
@@ -14462,7 +14731,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14462
14731
|
/** Read bounded canonical-entitlement discrepancies. */
|
|
14463
14732
|
discrepancies: () => Promise<openapi_fetch.FetchResponse<{
|
|
14464
14733
|
parameters: {
|
|
14465
|
-
query
|
|
14734
|
+
query?: never;
|
|
14466
14735
|
header?: never;
|
|
14467
14736
|
path?: never;
|
|
14468
14737
|
cookie?: never;
|
|
@@ -14518,7 +14787,10 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14518
14787
|
[name: string]: unknown;
|
|
14519
14788
|
};
|
|
14520
14789
|
content: {
|
|
14521
|
-
"application/json": components["schemas"]
|
|
14790
|
+
"application/json": components["schemas"] /**
|
|
14791
|
+
* Update one of the caller's own roast profiles. Pass `ifMatch` (the
|
|
14792
|
+
* row's `last_updated`) to enable optimistic concurrency (409 on mismatch).
|
|
14793
|
+
*/["ErrorResponse"];
|
|
14522
14794
|
};
|
|
14523
14795
|
};
|
|
14524
14796
|
429: components["responses"]["ApiRateLimitExceeded"];
|
|
@@ -14539,7 +14811,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14539
14811
|
};
|
|
14540
14812
|
}, openapi_fetch.FetchOptions<{
|
|
14541
14813
|
parameters: {
|
|
14542
|
-
query
|
|
14814
|
+
query?: never;
|
|
14543
14815
|
header?: never;
|
|
14544
14816
|
path?: never;
|
|
14545
14817
|
cookie?: never;
|
|
@@ -14595,7 +14867,10 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14595
14867
|
[name: string]: unknown;
|
|
14596
14868
|
};
|
|
14597
14869
|
content: {
|
|
14598
|
-
"application/json": components["schemas"]
|
|
14870
|
+
"application/json": components["schemas"] /**
|
|
14871
|
+
* Update one of the caller's own roast profiles. Pass `ifMatch` (the
|
|
14872
|
+
* row's `last_updated`) to enable optimistic concurrency (409 on mismatch).
|
|
14873
|
+
*/["ErrorResponse"];
|
|
14599
14874
|
};
|
|
14600
14875
|
};
|
|
14601
14876
|
429: components["responses"]["ApiRateLimitExceeded"];
|
|
@@ -14630,7 +14905,12 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14630
14905
|
200: {
|
|
14631
14906
|
headers: {
|
|
14632
14907
|
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
14633
|
-
"X-RateLimit-Remaining": components["headers"]
|
|
14908
|
+
"X-RateLimit-Remaining": components["headers"] /**
|
|
14909
|
+
* Replace the Artisan import data on one of the caller's existing roasts,
|
|
14910
|
+
* re-deriving its curve, events, and computed metrics while preserving the
|
|
14911
|
+
* roast's identity. Pass `ifMatch` (the roast's `last_updated`) to enable
|
|
14912
|
+
* optimistic concurrency (409 on mismatch).
|
|
14913
|
+
*/["X-RateLimit-Remaining"];
|
|
14634
14914
|
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
14635
14915
|
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
14636
14916
|
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
@@ -14648,7 +14928,13 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
14648
14928
|
headers: {
|
|
14649
14929
|
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
14650
14930
|
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
14651
|
-
"X-RateLimit-Reset": components["headers"]
|
|
14931
|
+
"X-RateLimit-Reset": components["headers"] /**
|
|
14932
|
+
* Record a sale against one of the caller's own green-coffee inventory
|
|
14933
|
+
* lots. Requires a session or an owner-bound API key carrying the exact
|
|
14934
|
+
* `sales:write` scope. Pass `idempotencyKey` to make retries safe: the
|
|
14935
|
+
* same key replays the original result, and a concurrent duplicate gets
|
|
14936
|
+
* 409 while the first is in flight.
|
|
14937
|
+
*/["X-RateLimit-Reset"];
|
|
14652
14938
|
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
14653
14939
|
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
14654
14940
|
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
@@ -15335,6 +15621,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15335
15621
|
pricePerLbMax?: number | null;
|
|
15336
15622
|
elevationMinMasl?: number | null;
|
|
15337
15623
|
elevationMaxMasl?: number | null;
|
|
15624
|
+
includeUnknownElevation?: "true" | "false";
|
|
15338
15625
|
processing_base_method?: string;
|
|
15339
15626
|
fermentation_type?: string;
|
|
15340
15627
|
process_additive?: string;
|
|
@@ -15429,6 +15716,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15429
15716
|
pricePerLbMax?: number | null;
|
|
15430
15717
|
elevationMinMasl?: number | null;
|
|
15431
15718
|
elevationMaxMasl?: number | null;
|
|
15719
|
+
includeUnknownElevation?: "true" | "false";
|
|
15432
15720
|
processing_base_method?: string;
|
|
15433
15721
|
fermentation_type?: string;
|
|
15434
15722
|
process_additive?: string;
|
|
@@ -15472,6 +15760,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15472
15760
|
pricePerLbMax?: number | null;
|
|
15473
15761
|
elevationMinMasl?: number | null;
|
|
15474
15762
|
elevationMaxMasl?: number | null;
|
|
15763
|
+
includeUnknownElevation?: "true" | "false";
|
|
15475
15764
|
processing_base_method?: string;
|
|
15476
15765
|
fermentation_type?: string;
|
|
15477
15766
|
process_additive?: string;
|
|
@@ -15482,6 +15771,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15482
15771
|
bbox?: string;
|
|
15483
15772
|
zoom?: number;
|
|
15484
15773
|
lens?: "catalog" | "elevation";
|
|
15774
|
+
projection?: "clusters" | "locations";
|
|
15485
15775
|
};
|
|
15486
15776
|
header?: {
|
|
15487
15777
|
Prefer?: string;
|
|
@@ -15593,6 +15883,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15593
15883
|
pricePerLbMax?: number | null;
|
|
15594
15884
|
elevationMinMasl?: number | null;
|
|
15595
15885
|
elevationMaxMasl?: number | null;
|
|
15886
|
+
includeUnknownElevation?: "true" | "false";
|
|
15596
15887
|
processing_base_method?: string;
|
|
15597
15888
|
fermentation_type?: string;
|
|
15598
15889
|
process_additive?: string;
|
|
@@ -15603,6 +15894,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15603
15894
|
bbox?: string;
|
|
15604
15895
|
zoom?: number;
|
|
15605
15896
|
lens?: "catalog" | "elevation";
|
|
15897
|
+
projection?: "clusters" | "locations";
|
|
15606
15898
|
} | undefined;
|
|
15607
15899
|
header: {
|
|
15608
15900
|
Prefer?: string;
|
|
@@ -15643,6 +15935,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15643
15935
|
pricePerLbMax?: number | null;
|
|
15644
15936
|
elevationMinMasl?: number | null;
|
|
15645
15937
|
elevationMaxMasl?: number | null;
|
|
15938
|
+
includeUnknownElevation?: "true" | "false";
|
|
15646
15939
|
processing_base_method?: string;
|
|
15647
15940
|
fermentation_type?: string;
|
|
15648
15941
|
process_additive?: string;
|
|
@@ -15732,6 +16025,7 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
15732
16025
|
pricePerLbMax?: number | null;
|
|
15733
16026
|
elevationMinMasl?: number | null;
|
|
15734
16027
|
elevationMaxMasl?: number | null;
|
|
16028
|
+
includeUnknownElevation?: "true" | "false";
|
|
15735
16029
|
processing_base_method?: string;
|
|
15736
16030
|
fermentation_type?: string;
|
|
15737
16031
|
process_additive?: string;
|
|
@@ -17917,6 +18211,190 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
17917
18211
|
}, `${string}/${string}`>>;
|
|
17918
18212
|
};
|
|
17919
18213
|
};
|
|
18214
|
+
confirmedActions: {
|
|
18215
|
+
/**
|
|
18216
|
+
* Execute or replay one user-confirmed product action. Session-only;
|
|
18217
|
+
* executionId is the durable payload-bound replay key.
|
|
18218
|
+
*/
|
|
18219
|
+
execute: (body: ConfirmedActionExecuteRequest) => Promise<openapi_fetch.FetchResponse<{
|
|
18220
|
+
parameters: {
|
|
18221
|
+
query?: never;
|
|
18222
|
+
header?: never;
|
|
18223
|
+
path?: never;
|
|
18224
|
+
cookie?: never;
|
|
18225
|
+
};
|
|
18226
|
+
requestBody: {
|
|
18227
|
+
content: {
|
|
18228
|
+
"application/json": components["schemas"]["ConfirmedActionExecuteRequest"];
|
|
18229
|
+
};
|
|
18230
|
+
};
|
|
18231
|
+
responses: {
|
|
18232
|
+
200: {
|
|
18233
|
+
headers: {
|
|
18234
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
18235
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
18236
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
18237
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
18238
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
18239
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
18240
|
+
[name: string]: unknown;
|
|
18241
|
+
};
|
|
18242
|
+
content: {
|
|
18243
|
+
"application/json": components["schemas"]["ConfirmedActionExecuteResponse"];
|
|
18244
|
+
};
|
|
18245
|
+
};
|
|
18246
|
+
400: {
|
|
18247
|
+
headers: {
|
|
18248
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
18249
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
18250
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
18251
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
18252
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
18253
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
18254
|
+
[name: string]: unknown;
|
|
18255
|
+
};
|
|
18256
|
+
content: {
|
|
18257
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
18258
|
+
};
|
|
18259
|
+
};
|
|
18260
|
+
401: {
|
|
18261
|
+
headers: {
|
|
18262
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
18263
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
18264
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
18265
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
18266
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
18267
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
18268
|
+
[name: string]: unknown;
|
|
18269
|
+
};
|
|
18270
|
+
content: {
|
|
18271
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
18272
|
+
};
|
|
18273
|
+
};
|
|
18274
|
+
403: {
|
|
18275
|
+
headers: {
|
|
18276
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
18277
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
18278
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
18279
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
18280
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
18281
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
18282
|
+
[name: string]: unknown;
|
|
18283
|
+
};
|
|
18284
|
+
content: {
|
|
18285
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
18286
|
+
};
|
|
18287
|
+
};
|
|
18288
|
+
409: {
|
|
18289
|
+
headers: {
|
|
18290
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
18291
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
18292
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
18293
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
18294
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
18295
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
18296
|
+
[name: string]: unknown;
|
|
18297
|
+
};
|
|
18298
|
+
content: {
|
|
18299
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
18300
|
+
};
|
|
18301
|
+
};
|
|
18302
|
+
429: {
|
|
18303
|
+
headers: {
|
|
18304
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
18305
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
18306
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
18307
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
18308
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
18309
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
18310
|
+
"Retry-After": components["headers"]["Retry-After"];
|
|
18311
|
+
"X-RateLimit-Blocked-By": components["headers"]["X-RateLimit-Blocked-By"];
|
|
18312
|
+
[name: string]: unknown;
|
|
18313
|
+
};
|
|
18314
|
+
content: {
|
|
18315
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
18316
|
+
};
|
|
18317
|
+
};
|
|
18318
|
+
503: {
|
|
18319
|
+
headers: {
|
|
18320
|
+
"X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
|
|
18321
|
+
"X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
|
|
18322
|
+
"X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
|
|
18323
|
+
"X-RateLimit-Burst-Limit": components["headers"]["X-RateLimit-Burst-Limit"];
|
|
18324
|
+
"X-RateLimit-Burst-Remaining": components["headers"]["X-RateLimit-Burst-Remaining"];
|
|
18325
|
+
"X-RateLimit-Burst-Reset": components["headers"]["X-RateLimit-Burst-Reset"];
|
|
18326
|
+
[name: string]: unknown;
|
|
18327
|
+
};
|
|
18328
|
+
content: {
|
|
18329
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
18330
|
+
};
|
|
18331
|
+
};
|
|
18332
|
+
};
|
|
18333
|
+
}, {
|
|
18334
|
+
body: {
|
|
18335
|
+
executionId: string;
|
|
18336
|
+
actionType: "add_bean_to_inventory";
|
|
18337
|
+
fields: {
|
|
18338
|
+
catalog_id?: number | string;
|
|
18339
|
+
coffee_bean?: number | string;
|
|
18340
|
+
manual_name?: string;
|
|
18341
|
+
purchased_qty_lbs: number | string;
|
|
18342
|
+
cost_per_lb?: number | string;
|
|
18343
|
+
tax_ship_cost?: number | string;
|
|
18344
|
+
purchase_date?: "" | string;
|
|
18345
|
+
notes?: string;
|
|
18346
|
+
source_filter?: string;
|
|
18347
|
+
_bean_sources?: {
|
|
18348
|
+
[key: string]: string;
|
|
18349
|
+
};
|
|
18350
|
+
catalog_options_notice?: string;
|
|
18351
|
+
total_bean_cost?: number | string;
|
|
18352
|
+
};
|
|
18353
|
+
} | {
|
|
18354
|
+
executionId: string;
|
|
18355
|
+
actionType: "update_bean";
|
|
18356
|
+
fields: {
|
|
18357
|
+
bean_id: number | string;
|
|
18358
|
+
rank?: number | string | null;
|
|
18359
|
+
notes?: string | null;
|
|
18360
|
+
stocked?: boolean | ("true" | "false");
|
|
18361
|
+
purchased_qty_lbs?: number | string;
|
|
18362
|
+
};
|
|
18363
|
+
} | {
|
|
18364
|
+
executionId: string;
|
|
18365
|
+
actionType: "create_roast_session";
|
|
18366
|
+
fields: {
|
|
18367
|
+
coffee_id: number | string;
|
|
18368
|
+
coffee_name?: string;
|
|
18369
|
+
batch_name: string;
|
|
18370
|
+
roast_date?: "" | string;
|
|
18371
|
+
oz_in?: number | string;
|
|
18372
|
+
roast_notes?: string;
|
|
18373
|
+
roaster_type?: string;
|
|
18374
|
+
};
|
|
18375
|
+
} | {
|
|
18376
|
+
executionId: string;
|
|
18377
|
+
actionType: "update_roast_notes";
|
|
18378
|
+
fields: {
|
|
18379
|
+
roast_id: number | string;
|
|
18380
|
+
roast_notes?: string | null;
|
|
18381
|
+
roast_targets?: string | null;
|
|
18382
|
+
};
|
|
18383
|
+
} | {
|
|
18384
|
+
executionId: string;
|
|
18385
|
+
actionType: "record_sale";
|
|
18386
|
+
fields: {
|
|
18387
|
+
green_coffee_inv_id: number | string;
|
|
18388
|
+
batch_name?: string;
|
|
18389
|
+
oz_sold: number | string;
|
|
18390
|
+
price: number | string;
|
|
18391
|
+
buyer?: string;
|
|
18392
|
+
sell_date?: "" | string;
|
|
18393
|
+
purchase_date?: "" | string;
|
|
18394
|
+
};
|
|
18395
|
+
};
|
|
18396
|
+
}, `${string}/${string}`>>;
|
|
18397
|
+
};
|
|
17920
18398
|
inventory: {
|
|
17921
18399
|
/** List the caller's own green-coffee inventory (owner-scoped). */
|
|
17922
18400
|
list: (query?: InventoryListQuery) => Promise<openapi_fetch.FetchResponse<{
|
|
@@ -22185,4 +22663,4 @@ declare function createParchmentClient(options: ParchmentClientOptions): {
|
|
|
22185
22663
|
};
|
|
22186
22664
|
type ParchmentClient = ReturnType<typeof createParchmentClient>;
|
|
22187
22665
|
|
|
22188
|
-
export { type AccountDeletionOperation, type AccountDeletionRequest, type BillingCheckoutCreateRequest, type BillingCheckoutSession, type BillingManualEntitlementsRequest, type BillingSubscriptionMutationRequest, type BillingSubscriptionOperation, type BriefMatchesQuery, type CatalogInventoryBatchLifecycle, type CatalogInventoryBatchReserveRequest, type CatalogInventoryBatchResult, type CatalogItem, type CatalogListQuery, type CatalogMapHeaders, type CatalogMapQuery, type CatalogMapResponse, type CatalogProofSummary, type CatalogSimilarQuery, type InventoryCreateRequest, type InventoryShareCatalog, type InventoryShareGrant, type InventoryShareGrantCreateRequest, type InventoryShareGrantRedeemRequest, type InventoryShareInventory, type InventoryShareRoastSummary, type InventoryUpdateRequest, type MarketOverview, type MarketSignalsQuery, type MetadataIndexQuery, type OwnerApiUsage, type OwnerApiUsageQuery, type ParchmentClient, type ParchmentClientOptions, type PriceIndexQuery, type PriceIndexStatsQuery, type ProfitItem, type ProfitListQuery, type RoastBatchCreateRequest, type RoastChartDataQuery, type RoastLiveCurveRequest, type SalesCreateRequest, type SalesListQuery, type SalesUpdateRequest, type SourcingBriefCreateRequest, type TrackedLotMutation, type TrackedLotSummary, type TrackedLotsListQuery, type components, createParchmentClient, type paths };
|
|
22666
|
+
export { type AccountDeletionOperation, type AccountDeletionRequest, type BillingCheckoutCreateRequest, type BillingCheckoutSession, type BillingManualEntitlementsRequest, type BillingSubscriptionMutationRequest, type BillingSubscriptionOperation, type BriefMatchesQuery, type CatalogInventoryBatchLifecycle, type CatalogInventoryBatchReserveRequest, type CatalogInventoryBatchResult, type CatalogItem, type CatalogListQuery, type CatalogMapHeaders, type CatalogMapQuery, type CatalogMapResponse, type CatalogProofSummary, type CatalogSimilarQuery, type ConfirmedActionExecuteRequest, type InventoryCreateRequest, type InventoryShareCatalog, type InventoryShareGrant, type InventoryShareGrantCreateRequest, type InventoryShareGrantRedeemRequest, type InventoryShareInventory, type InventoryShareRoastSummary, type InventoryUpdateRequest, type MarketOverview, type MarketSignalsQuery, type MetadataIndexQuery, type OwnerApiUsage, type OwnerApiUsageQuery, type ParchmentClient, type ParchmentClientOptions, type PriceIndexQuery, type PriceIndexStatsQuery, type ProfitItem, type ProfitListQuery, type RoastBatchCreateRequest, type RoastChartDataQuery, type RoastLiveCurveRequest, type SalesCreateRequest, type SalesListQuery, type SalesUpdateRequest, type SourcingBriefCreateRequest, type TrackedLotMutation, type TrackedLotSummary, type TrackedLotsListQuery, type components, createParchmentClient, type paths };
|
package/dist/index.js
CHANGED
|
@@ -214,6 +214,13 @@ function createParchmentClient(options) {
|
|
|
214
214
|
})
|
|
215
215
|
}
|
|
216
216
|
},
|
|
217
|
+
confirmedActions: {
|
|
218
|
+
/**
|
|
219
|
+
* Execute or replay one user-confirmed product action. Session-only;
|
|
220
|
+
* executionId is the durable payload-bound replay key.
|
|
221
|
+
*/
|
|
222
|
+
execute: (body) => client.POST("/v1/confirmed-actions/execute", { body })
|
|
223
|
+
},
|
|
217
224
|
inventory: {
|
|
218
225
|
/** List the caller's own green-coffee inventory (owner-scoped). */
|
|
219
226
|
list: (query) => client.GET("/v1/inventory", { params: { query } }),
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/client.ts"],"sourcesContent":["import createClient, { type ClientOptions } from \"openapi-fetch\";\nimport type { components, paths } from \"./schema\";\n\nexport interface ParchmentClientOptions {\n /** Base URL of the Parchment API, e.g. https://api.purveyors.io */\n baseUrl: string;\n /**\n * Optional bearer token (a Supabase JWT, API key, or dedicated machine\n * credential). Sent as\n * `Authorization: Bearer <token>`. Auth is resolved server-side at the route\n * boundary; the SDK only forwards the credential.\n */\n token?: string;\n /** Override the fetch implementation (useful for tests or custom runtimes). */\n fetch?: ClientOptions[\"fetch\"];\n}\n\n/** Query parameters for {@link ParchmentClient.catalog.list}. */\nexport type CatalogListQuery = NonNullable<\n paths[\"/v1/catalog\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** A catalog row returned by the canonical listing resource. */\nexport type CatalogItem = components[\"schemas\"][\"CatalogItem\"];\n/** API-owned row-level trust summary returned when `include=proof`. */\nexport type CatalogProofSummary = components[\"schemas\"][\"CatalogProofSummary\"];\n/** Query parameters for {@link ParchmentClient.catalog.facets}. */\nexport type CatalogFacetsQuery = NonNullable<\n paths[\"/v1/catalog/facets\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/**\n * Optional headers for {@link ParchmentClient.catalog.list}, notably the\n * RFC 7240 `Prefer: handling=lenient|strict` override (PADR-0013 §7). Sending\n * `handling=lenient` opts a strict caller (API key or bearer-session JWT) back\n * into strip-with-notice degradation instead of a 401/403 hard-deny.\n */\nexport type CatalogListHeaders = NonNullable<\n paths[\"/v1/catalog\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.map}. */\nexport type CatalogMapQuery = NonNullable<\n paths[\"/v1/catalog/map\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Optional handling headers for {@link ParchmentClient.catalog.map}. */\nexport type CatalogMapHeaders = NonNullable<\n paths[\"/v1/catalog/map\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Lightweight map projection over the caller-visible catalog. */\nexport type CatalogMapResponse = components[\"schemas\"][\"CatalogMapResponse\"];\n/** Optional headers for {@link ParchmentClient.catalog.facets}; see {@link CatalogListHeaders}. */\nexport type CatalogFacetsHeaders = NonNullable<\n paths[\"/v1/catalog/facets\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.originPriceStats}. */\nexport type CatalogOriginPriceStatsQuery = NonNullable<\n paths[\"/v1/catalog/origin-price-stats\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.stats}. */\nexport type CatalogStatsQuery = NonNullable<\n paths[\"/v1/catalog/stats\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.rank}. */\nexport type CatalogRankQuery = NonNullable<\n paths[\"/v1/catalog/rank\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.rankPremium}. */\nexport type CatalogRankPremiumQuery = NonNullable<\n paths[\"/v1/catalog/rank-premium\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.suppliers}. */\nexport type CatalogSuppliersQuery = NonNullable<\n paths[\"/v1/catalog/suppliers\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.supplierDetail}. */\nexport type CatalogSupplierDetailQuery = NonNullable<\n paths[\"/v1/catalog/suppliers/detail\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.supplierRank}. */\nexport type CatalogSupplierRankQuery = NonNullable<\n paths[\"/v1/catalog/suppliers/rank\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Optional headers for ranking endpoints; see {@link CatalogListHeaders}. */\nexport type CatalogRankHeaders = NonNullable<\n paths[\"/v1/catalog/rank\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Optional headers for premium ranking endpoints; see {@link CatalogListHeaders}. */\nexport type CatalogRankPremiumHeaders = NonNullable<\n paths[\"/v1/catalog/rank-premium\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Optional headers for supplier aggregate endpoints; see {@link CatalogListHeaders}. */\nexport type CatalogSupplierHeaders = NonNullable<\n paths[\"/v1/catalog/suppliers\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.similar}. */\nexport type CatalogSimilarQuery = NonNullable<\n paths[\"/v1/catalog/{id}/similar\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.priceIndex.list}. */\nexport type PriceIndexQuery = NonNullable<\n paths[\"/v1/price-index\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.priceIndex.history}. */\nexport type PriceIndexHistoryQuery = NonNullable<\n paths[\"/v1/price-index/history\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.market.signals}. */\nexport type MarketSignalsQuery = NonNullable<\n paths[\"/v1/market/signals\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Aggregate-only public green-coffee market evidence. */\nexport type MarketOverview = components[\"schemas\"][\"MarketOverviewResponse\"];\n/** Named public-catalog and supplier evidence for Parchment Intelligence callers. */\nexport type MarketEvidence = components[\"schemas\"][\"MarketEvidenceResponse\"];\n/** Query parameters for {@link ParchmentClient.priceIndex.stats}. */\nexport type PriceIndexStatsQuery = NonNullable<\n paths[\"/v1/price-index/stats\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.market.metadataIndex}. */\nexport type MetadataIndexQuery = NonNullable<\n paths[\"/v1/market/metadata-index\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.procurement.briefs.matches}. */\nexport type BriefMatchesQuery = NonNullable<\n paths[\"/v1/procurement/briefs/{id}/matches\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.procurement.briefs.create}. */\nexport type SourcingBriefCreateRequest =\n components[\"schemas\"][\"SourcingBriefCreateRequest\"];\n/** Query parameters for {@link ParchmentClient.portfolio.trackedLots.list}. */\nexport type TrackedLotsListQuery = NonNullable<\n paths[\"/v1/portfolio/tracked-lots\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** A tracked catalog lot enriched with current catalog and price state. */\nexport type TrackedLotSummary = components[\"schemas\"][\"TrackedLotSummary\"];\n/** State returned by tracked-lot PUT and DELETE mutations. */\nexport type TrackedLotMutation =\n components[\"schemas\"][\"TrackedLotMutationResponse\"];\n/** Query parameters for {@link ParchmentClient.inventory.list}. */\nexport type InventoryListQuery = NonNullable<\n paths[\"/v1/inventory\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.inventory.create}. */\nexport type InventoryCreateRequest = NonNullable<\n paths[\"/v1/inventory\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Stable-operation request for {@link ParchmentClient.inventory.shareGrants.create}. */\nexport type InventoryShareGrantCreateRequest = NonNullable<\n paths[\"/v1/inventory/share-grants\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** The one-time raw-token grant returned by create or same-operation replay. */\nexport type InventoryShareGrant = components[\"schemas\"][\"InventoryShareGrant\"];\n/** Anonymous capability body for {@link ParchmentClient.inventory.shareGrants.redeem}. */\nexport type InventoryShareGrantRedeemRequest = NonNullable<\n paths[\"/v1/inventory/share-grants/redeem\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Safe legacy-oriented inventory row returned by capability redemption. */\nexport type InventoryShareInventory =\n components[\"schemas\"][\"InventoryShareInventory\"];\n/** Catalog allowlist nested in a shared inventory row. */\nexport type InventoryShareCatalog =\n components[\"schemas\"][\"InventoryShareCatalog\"];\n/** Six-field roast summary nested in member/admin shares. */\nexport type InventoryShareRoastSummary =\n components[\"schemas\"][\"InventoryShareRoastSummary\"];\ntype CatalogInventoryCreateRequest =\n components[\"schemas\"][\"CatalogInventoryCreateRequest\"];\ntype ManualInventoryCreateRequest =\n components[\"schemas\"][\"ManualInventoryCreateRequest\"];\n/** Request body for {@link ParchmentClient.inventory.createManualBatch}. */\nexport type ManualInventoryBatchCreateRequest = NonNullable<\n paths[\"/v1/inventory/manual-batches\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for reserving durable server-owned manual-batch intent. */\nexport type ManualInventoryBatchReserveRequest = NonNullable<\n paths[\"/v1/inventory/manual-batches/reservations\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Complete canonical intent accepted by the catalog-batch reservation lane. */\nexport type CatalogInventoryBatchReserveRequest = NonNullable<\n paths[\"/v1/inventory/catalog-batches/reservations\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable catalog-batch state returned by reserve, commit, and status. */\nexport type CatalogInventoryBatchLifecycle =\n components[\"schemas\"][\"CatalogInventoryBatchLifecycle\"];\n/** Identity-only terminal result; catalog resources remain a separate read. */\nexport type CatalogInventoryBatchResult =\n components[\"schemas\"][\"CatalogInventoryBatchResult\"];\n/** Request body for {@link ParchmentClient.inventory.update}. */\nexport type InventoryUpdateRequest = NonNullable<\n paths[\"/v1/inventory/{id}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for {@link ParchmentClient.roasts.list}. */\nexport type RoastListQuery = NonNullable<\n paths[\"/v1/roasts\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.roasts.get}. */\nexport type RoastGetQuery = NonNullable<\n paths[\"/v1/roasts/{id}\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.roasts.chartData}. */\nexport type RoastChartDataQuery = NonNullable<\n paths[\"/v1/roasts/{id}/chart-data\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.roasts.classify}. */\nexport type RoastClassificationRequest = NonNullable<\n paths[\"/v1/roasts/classify\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.create}. */\nexport type RoastCreateRequest = NonNullable<\n paths[\"/v1/roasts\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Atomic named-batch body for {@link ParchmentClient.roasts.createBatch}. */\nexport type RoastBatchCreateRequest = NonNullable<\n paths[\"/v1/roasts/batches\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.update}. */\nexport type RoastUpdateRequest = NonNullable<\n paths[\"/v1/roasts/{id}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Source-aware live curve body for {@link ParchmentClient.roasts.replaceLiveCurve}. */\nexport type RoastLiveCurveRequest = NonNullable<\n paths[\"/v1/roasts/{id}/live-curve\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.import}. */\nexport type RoastImportRequest = NonNullable<\n paths[\"/v1/roasts/imports\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.replaceArtisanImport}. */\nexport type RoastArtisanImportReplaceRequest = NonNullable<\n paths[\"/v1/roasts/{id}/artisan-import\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for {@link ParchmentClient.sales.list}. */\nexport type SalesListQuery = NonNullable<\n paths[\"/v1/sales\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.profit.list}. */\nexport type ProfitListQuery = NonNullable<\n paths[\"/v1/profit\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** One owner inventory lot's canonical cost, revenue, and roast summary. */\nexport type ProfitItem = components[\"schemas\"][\"ProfitItem\"];\n/** Request body for {@link ParchmentClient.sales.create}. */\nexport type SalesCreateRequest = NonNullable<\n paths[\"/v1/sales\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.sales.update}. */\nexport type SalesUpdateRequest = NonNullable<\n paths[\"/v1/sales/{id}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for {@link ParchmentClient.tasting.get}. */\nexport type TastingGetQuery = NonNullable<\n paths[\"/v1/tasting/{catalogId}\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.tasting.rate}. */\nexport type TastingRateRequest = NonNullable<\n paths[\"/v1/tasting/inventory/{inventoryId}\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.apiKeys.create}. */\nexport type ApiKeyCreateRequest = NonNullable<\n paths[\"/v1/api-keys\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for the session owner's API-key traffic analytics. */\nexport type OwnerApiUsageQuery = NonNullable<\n paths[\"/v1/api-usage\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Bounded owner API-key traffic analytics (not session or billing usage). */\nexport type OwnerApiUsage = components[\"schemas\"][\"OwnerApiUsageResponse\"];\n/** Request body for {@link ParchmentClient.emailSubscriptions.setMarketRead}. */\nexport type MarketReadPreferenceRequest = NonNullable<\n paths[\"/v1/email-subscriptions/market-read\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.emailSubscriptions.unsubscribeMarketRead}. */\nexport type MarketReadUnsubscribeRequest = NonNullable<\n paths[\"/v1/email-subscriptions/market-read/unsubscribe\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Immutable deployed projection accepted by {@link ParchmentClient.marketBrief.drafts.create}. */\nexport type MarketBriefDraftCreateRequest = NonNullable<\n paths[\"/v1/market-brief/drafts\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable Parchment-owned provider-draft state. */\nexport type MarketBriefDraftState =\n components[\"schemas\"][\"MarketBriefDraftState\"];\n/** Account-owned Market Read email preference. */\nexport type EmailSubscriptionPreference =\n components[\"schemas\"][\"EmailSubscriptionPreference\"];\n/** Durable state returned by an account-deletion request. */\nexport type AccountDeletionOperation =\n components[\"schemas\"][\"AccountDeletionOperation\"];\n/** Purpose-bound recent-reauthentication assertion for account deletion. */\nexport type AccountDeletionRequest = NonNullable<\n paths[\"/v1/account-deletion\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Purchase-key request for dormant direct Parchment Checkout creation/replay. */\nexport type BillingCheckoutCreateRequest = NonNullable<\n paths[\"/v1/billing/checkout-sessions\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable Checkout admission state; provider Session id stays server-side. */\nexport type BillingCheckoutSession =\n components[\"schemas\"][\"BillingCheckoutSession\"];\n/** Durable cancellation/resume request. */\nexport type BillingSubscriptionMutationRequest = NonNullable<\n paths[\"/v1/billing/subscriptions/{subscriptionId}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable provider subscription-operation state. */\nexport type BillingSubscriptionOperation =\n components[\"schemas\"][\"BillingSubscriptionOperation\"];\n/** Manual entitlement baseline update for administrators. */\nexport type BillingManualEntitlementsRequest = NonNullable<\n paths[\"/v1/admin/billing-entitlements/{ownerId}/manual\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthRequestCreate = NonNullable<\n paths[\"/v1/cli-auth/requests\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthInspectRequest = NonNullable<\n paths[\"/v1/cli-auth/inspect\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthApproveRequest = NonNullable<\n paths[\"/v1/cli-auth/approve\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthExchangeRequest = NonNullable<\n paths[\"/v1/cli-auth/token\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n\n/**\n * Create a typed Parchment API client.\n *\n * The generated core (openapi-fetch over the generated `paths` types) is the\n * contract truth; the named helpers below are the hand-maintained ergonomic\n * layer and grow as endpoints land. `raw` always exposes the underlying typed\n * client for direct path access to anything not yet wrapped.\n */\nexport function createParchmentClient(options: ParchmentClientOptions) {\n const { baseUrl, token, fetch: fetchImpl } = options;\n\n const client = createClient<paths>({\n baseUrl,\n fetch: fetchImpl,\n headers: token ? { Authorization: `Bearer ${token}` } : undefined,\n });\n\n const postInventory = (\n body: InventoryCreateRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/inventory\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n });\n\n function createInventory(\n body: ManualInventoryCreateRequest,\n options: { idempotencyKey: string },\n ): ReturnType<typeof postInventory>;\n function createInventory(\n body: CatalogInventoryCreateRequest,\n options?: { idempotencyKey?: string },\n ): ReturnType<typeof postInventory>;\n function createInventory(\n body: InventoryCreateRequest,\n options?: { idempotencyKey?: string },\n ): ReturnType<typeof postInventory> {\n return postInventory(body, options);\n }\n\n return {\n /** The underlying typed openapi-fetch client for direct path access. */\n raw: client,\n /** Liveness and service identity. */\n health: () => client.GET(\"/health\"),\n /** Resolved principal and entitlements for the caller. */\n me: () => client.GET(\"/v1/me\"),\n apiKeys: {\n /** List API keys owned by the authenticated session user. */\n list: () => client.GET(\"/v1/api-keys\"),\n /** Create an API key. The raw secret is returned only once. */\n create: (body: ApiKeyCreateRequest) =>\n client.POST(\"/v1/api-keys\", { body }),\n /** Revoke an API key owned by the authenticated session user. */\n revoke: (id: string) =>\n client.DELETE(\"/v1/api-keys/{id}\", {\n params: { path: { id } },\n }),\n /** Rotate an API key and return the replacement secret once. */\n rotate: (id: string) =>\n client.POST(\"/v1/api-keys/{id}/rotate\", {\n params: { path: { id } },\n }),\n },\n apiUsage: {\n /**\n * Read bounded API-key traffic analytics for the authenticated session\n * owner. Headline monthly/hourly counts are exact; daily/per-key series\n * carry explicit truncation metadata.\n */\n get: (query?: OwnerApiUsageQuery) =>\n client.GET(\"/v1/api-usage\", { params: { query } }),\n },\n emailSubscriptions: {\n /** Get the authenticated session user's Market Read preference. */\n get: () => client.GET(\"/v1/email-subscriptions\"),\n /** Idempotently set the authenticated session user's Market Read preference. */\n setMarketRead: (body: MarketReadPreferenceRequest) =>\n client.PUT(\"/v1/email-subscriptions/market-read\", { body }),\n /** Idempotently unsubscribe using an opaque capability without requiring a session. */\n unsubscribeMarketRead: (body: MarketReadUnsubscribeRequest) =>\n client.POST(\"/v1/email-subscriptions/market-read/unsubscribe\", {\n body,\n }),\n },\n marketBrief: {\n drafts: {\n /** Accept, create, or recover one immutable deployed edition version. */\n create: (body: MarketBriefDraftCreateRequest) =>\n client.POST(\"/v1/market-brief/drafts\", { body }),\n },\n },\n accountDeletion: {\n /** Accept or replay deletion using a purpose-bound reauthentication assertion. */\n request: (body: AccountDeletionRequest) =>\n client.POST(\"/v1/account-deletion\", { body }),\n },\n billing: {\n checkout: {\n /** Create or replay an embedded Checkout Session after activation. */\n create: (body: BillingCheckoutCreateRequest) =>\n client.POST(\"/v1/billing/checkout-sessions\", { body }),\n /** Read owner-bound durable admission state. */\n get: (admissionId: string) =>\n client.GET(\"/v1/billing/checkout-sessions/{admissionId}\", {\n params: { path: { admissionId } },\n }),\n /** Authoritatively reconcile an admission with Stripe. */\n reconcile: (admissionId: string) =>\n client.POST(\"/v1/billing/checkout-sessions/{admissionId}/reconcile\", {\n params: { path: { admissionId } },\n }),\n },\n subscriptions: {\n /** List canonical owner subscription snapshots. */\n list: () => client.GET(\"/v1/billing/subscriptions\"),\n /** Durably cancel or resume the complete provider subscription. */\n mutate: (\n subscriptionId: string,\n body: BillingSubscriptionMutationRequest,\n ) =>\n client.PATCH(\"/v1/billing/subscriptions/{subscriptionId}\", {\n params: { path: { subscriptionId } },\n body,\n }),\n },\n },\n billingAdministration: {\n /** Read bounded canonical-entitlement discrepancies. */\n discrepancies: () =>\n client.GET(\"/v1/admin/billing-entitlement-discrepancies\"),\n /** Recompute billing contribution without changing manual grants. */\n recompute: (ownerId: string) =>\n client.POST(\n \"/v1/admin/billing-entitlement-discrepancies/{ownerId}/recompute\",\n { params: { path: { ownerId } } },\n ),\n /** Update the preserved manual entitlement baseline. */\n setManual: (ownerId: string, body: BillingManualEntitlementsRequest) =>\n client.PATCH(\"/v1/admin/billing-entitlements/{ownerId}/manual\", {\n params: { path: { ownerId } },\n body,\n }),\n },\n cliAuth: {\n /** Create a signed, short-lived login request bound to a PKCE challenge. */\n create: (body: CliAuthRequestCreate) =>\n client.POST(\"/v1/cli-auth/requests\", { body }),\n /** Inspect a signed request before displaying the web consent screen. */\n inspect: (body: CliAuthInspectRequest) =>\n client.POST(\"/v1/cli-auth/inspect\", { body }),\n /** Approve a request using the client's authenticated user session. */\n approve: (body: CliAuthApproveRequest) =>\n client.POST(\"/v1/cli-auth/approve\", { body }),\n /** Exchange an approved request and verifier for the one-time raw key. */\n exchange: (body: CliAuthExchangeRequest) =>\n client.POST(\"/v1/cli-auth/token\", { body }),\n },\n catalog: {\n /** Catalog capabilities and visibility for the caller. */\n access: () => client.GET(\"/v1/catalog/access\"),\n /**\n * List public catalog coffees (paginated). Pass `headers` to send the\n * `Prefer: handling=lenient|strict` override (see {@link CatalogListHeaders}).\n */\n list: (query?: CatalogListQuery, headers?: CatalogListHeaders) =>\n client.GET(\"/v1/catalog\", { params: { query, header: headers } }),\n /** Deterministic clusters, canonical place features, and elevation profile. */\n map: (query?: CatalogMapQuery, headers?: CatalogMapHeaders) =>\n client.GET(\"/v1/catalog/map\", {\n params: { query, header: headers },\n }),\n /**\n * Catalog filter metadata and counted facets. Pass `headers` to send the\n * `Prefer: handling=lenient|strict` override (see {@link CatalogFacetsHeaders}).\n */\n facets: (query?: CatalogFacetsQuery, headers?: CatalogFacetsHeaders) =>\n client.GET(\"/v1/catalog/facets\", {\n params: { query, header: headers },\n }),\n /** Live catalog price context by origin. */\n originPriceStats: (query?: CatalogOriginPriceStatsQuery) =>\n client.GET(\"/v1/catalog/origin-price-stats\", { params: { query } }),\n /** Aggregate stats over the caller-visible catalog. */\n stats: (query?: CatalogStatsQuery) =>\n client.GET(\"/v1/catalog/stats\", { params: { query } }),\n /** Rank caller-visible catalog coffees by deterministic objectives. */\n rank: (query?: CatalogRankQuery, headers?: CatalogRankHeaders) =>\n client.GET(\"/v1/catalog/rank\", {\n params: { query, header: headers },\n }),\n /** Rank premium catalog candidates by Purveyor Score. */\n rankPremium: (\n query?: CatalogRankPremiumQuery,\n headers?: CatalogRankPremiumHeaders,\n ) =>\n client.GET(\"/v1/catalog/rank-premium\", {\n params: { query, header: headers },\n }),\n /** List supplier aggregates over caller-visible catalog coffees. */\n suppliers: (\n query?: CatalogSuppliersQuery,\n headers?: CatalogSupplierHeaders,\n ) =>\n client.GET(\"/v1/catalog/suppliers\", {\n params: { query, header: headers },\n }),\n /** Return aggregate detail for a supplier query. */\n supplierDetail: (\n query: CatalogSupplierDetailQuery,\n headers?: CatalogSupplierHeaders,\n ) =>\n client.GET(\"/v1/catalog/suppliers/detail\", {\n params: { query, header: headers },\n }),\n /** Rank suppliers by catalog score and availability. */\n supplierRank: (\n query?: CatalogSupplierRankQuery,\n headers?: CatalogSupplierHeaders,\n ) =>\n client.GET(\"/v1/catalog/suppliers/rank\", {\n params: { query, header: headers },\n }),\n /** Aggregate proof-coverage over the public catalog. */\n proofCoverage: () => client.GET(\"/v1/catalog/proof-coverage\"),\n /** Find catalog coffees similar to a target coffee. */\n similar: (id: string, query?: CatalogSimilarQuery) =>\n client.GET(\"/v1/catalog/{id}/similar\", {\n params: { path: { id }, query },\n }),\n },\n priceIndex: {\n /** Parchment Price Index (aggregate snapshots). */\n list: (query?: PriceIndexQuery) =>\n client.GET(\"/v1/price-index\", { params: { query } }),\n /** Tier-one price-index chart history. */\n history: (query?: PriceIndexHistoryQuery) =>\n client.GET(\"/v1/price-index/history\", { params: { query } }),\n /** Price movement significance stats (precomputed). */\n stats: (query?: PriceIndexStatsQuery) =>\n client.GET(\"/v1/price-index/stats\", { params: { query } }),\n },\n market: {\n /** Aggregate daily changes, catalog coverage, movement, processing, and origin prices. */\n overview: () => client.GET(\"/v1/market/overview\"),\n /** Entitled named-lot and supplier evidence over the public catalog. */\n evidence: () => client.GET(\"/v1/market/evidence\"),\n /** Actionable market value signals. */\n signals: (query?: MarketSignalsQuery) =>\n client.GET(\"/v1/market/signals\", { params: { query } }),\n /** Metadata-trend index (process/disclosure/Purveyor Score over time). */\n metadataIndex: (query?: MetadataIndexQuery) =>\n client.GET(\"/v1/market/metadata-index\", { params: { query } }),\n },\n procurement: {\n briefs: {\n /** List the caller's saved sourcing briefs. */\n list: () => client.GET(\"/v1/procurement/briefs\"),\n /** Create a saved sourcing brief. */\n create: (body: SourcingBriefCreateRequest) =>\n client.POST(\"/v1/procurement/briefs\", { body }),\n /** Fetch one of the caller's sourcing briefs by id. */\n get: (id: string) =>\n client.GET(\"/v1/procurement/briefs/{id}\", {\n params: { path: { id } },\n }),\n /** Run a saved brief against the catalog (paginated matches). */\n matches: (id: string, query?: BriefMatchesQuery) =>\n client.GET(\"/v1/procurement/briefs/{id}/matches\", {\n params: { path: { id }, query },\n }),\n },\n },\n portfolio: {\n trackedLots: {\n /**\n * List an owner-scoped tracked catalog-id page and bounded recent\n * summaries enriched with live catalog state. Follow nextCursor when\n * a capped response reports truncation.\n */\n list: (query?: TrackedLotsListQuery) =>\n client.GET(\"/v1/portfolio/tracked-lots\", {\n params: { query },\n }),\n /** Idempotently set a visible catalog lot to tracked. */\n track: (catalogId: number) =>\n client.PUT(\"/v1/portfolio/tracked-lots/{catalogId}\", {\n params: { path: { catalogId } },\n }),\n /** Idempotently set an owner catalog lot to untracked. */\n untrack: (catalogId: number) =>\n client.DELETE(\"/v1/portfolio/tracked-lots/{catalogId}\", {\n params: { path: { catalogId } },\n }),\n },\n },\n inventory: {\n /** List the caller's own green-coffee inventory (owner-scoped). */\n list: (query?: InventoryListQuery) =>\n client.GET(\"/v1/inventory\", { params: { query } }),\n shareGrants: {\n /**\n * Mint or replay a bounded cross-principal inventory capability. The\n * operation UUID is payload-bound and the raw token is returned only\n * by this response.\n */\n create: (body: InventoryShareGrantCreateRequest) =>\n client.POST(\"/v1/inventory/share-grants\", { body }),\n /**\n * Redeem a capability supplied in JSON (never in a URL). This helper\n * does not require the client to be configured with a bearer token.\n */\n redeem: (body: InventoryShareGrantRedeemRequest) =>\n client.POST(\"/v1/inventory/share-grants/redeem\", { body }),\n },\n /**\n * Create an owner inventory lot. Requires a session or an owner-bound API\n * key carrying the exact `inventory:write` scope. Manual coffee creates\n * require `idempotencyKey`; catalog-backed creates accept it optionally.\n * The same key and payload replay the original result.\n */\n create: createInventory,\n /**\n * Atomically create owner-private manual inventory lots. The required\n * idempotency UUID is the stable batch identity and can be reconciled\n * with `getManualBatch` after an uncertain response.\n */\n createManualBatch: (\n body: ManualInventoryBatchCreateRequest,\n options: { idempotencyKey: string },\n ) =>\n client.POST(\"/v1/inventory/manual-batches\", {\n params: {\n header: { \"idempotency-key\": options.idempotencyKey },\n },\n body,\n }),\n /** Return the durable terminal result for a manual inventory batch. */\n getManualBatch: (batchId: string) =>\n client.GET(\"/v1/inventory/manual-batches/{batchId}\", {\n params: { path: { batchId } },\n }),\n /**\n * Durably reserve a complete manual-batch request. Once accepted, clients\n * only need to persist the batch UUID.\n */\n reserveManualBatch: (body: ManualInventoryBatchReserveRequest) =>\n client.POST(\"/v1/inventory/manual-batches/reservations\", { body }),\n /** Commit a reserved batch by UUID with no request body. */\n commitManualBatch: (batchId: string) =>\n client.POST(\"/v1/inventory/manual-batches/{batchId}/commit\", {\n params: { path: { batchId } },\n }),\n /**\n * Get unknown, accepted, in-progress, completed, or terminal-rejected\n * state. Unknown is explicitly nonterminal, including missing or\n * cross-tenant UUIDs, so clients retain the UUID and retry.\n */\n getManualBatchStatus: (batchId: string) =>\n client.GET(\"/v1/inventory/manual-batches/{batchId}/status\", {\n params: { path: { batchId } },\n }),\n /** Durably reserve canonical catalog-backed inventory intent. */\n reserveCatalogBatch: (body: CatalogInventoryBatchReserveRequest) =>\n client.POST(\"/v1/inventory/catalog-batches/reservations\", { body }),\n /** Atomically commit a reserved catalog batch by UUID, with no body. */\n commitCatalogBatch: (batchId: string) =>\n client.POST(\"/v1/inventory/catalog-batches/{batchId}/commit\", {\n params: { path: { batchId } },\n }),\n /** Recover the owner-scoped lifecycle; missing batches remain unknown. */\n getCatalogBatchStatus: (batchId: string) =>\n client.GET(\"/v1/inventory/catalog-batches/{batchId}/status\", {\n params: { path: { batchId } },\n }),\n /**\n * Update one of the caller's own inventory rows. Pass `ifMatch` (the\n * row's `last_updated`) to enable optimistic concurrency (409 on mismatch).\n */\n update: (\n id: number,\n body: InventoryUpdateRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PATCH(\"/v1/inventory/{id}\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /**\n * Delete one of the caller's own inventory rows. Returns 409 if dependent\n * roast profiles or sales exist (no force-cascade).\n */\n delete: (id: number) =>\n client.DELETE(\"/v1/inventory/{id}\", { params: { path: { id } } }),\n },\n roasts: {\n /** Match Artisan roast metadata to one of the supplied inventory rows. */\n classify: (body: RoastClassificationRequest) =>\n client.POST(\"/v1/roasts/classify\", { body }),\n /** List the caller's own roast profiles (owner-scoped). */\n list: (query?: RoastListQuery) =>\n client.GET(\"/v1/roasts\", { params: { query } }),\n /**\n * Fetch one of the caller's roast profiles by id, optionally with its\n * temperature curve (`includeTemps`) and event markers (`includeEvents`).\n */\n get: (id: string, query?: RoastGetQuery) =>\n client.GET(\"/v1/roasts/{id}\", { params: { path: { id }, query } }),\n /** Fetch an owner roast's adaptively sampled chart curve and metadata. */\n chartData: (id: string, query?: RoastChartDataQuery) =>\n client.GET(\"/v1/roasts/{id}/chart-data\", {\n params: { path: { id }, query },\n }),\n /**\n * Create an owner roast profile, optionally with nested temperature/event\n * rows. Requires a session or an owner-bound API key carrying the exact\n * `roast:write` scope. Pass `idempotencyKey` to make retries safe.\n */\n create: (\n body: RoastCreateRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/roasts\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n }),\n /**\n * Create every profile in one named batch atomically. The required\n * payload-bound idempotency key makes transport retries safe.\n */\n createBatch: (body: RoastBatchCreateRequest, idempotencyKey: string) =>\n client.POST(\"/v1/roasts/batches\", {\n body,\n params: { header: { \"idempotency-key\": idempotencyKey } },\n }),\n /**\n * Update one of the caller's own roast profiles. Pass `ifMatch` (the\n * row's `last_updated`) to enable optimistic concurrency (409 on mismatch).\n */\n update: (\n id: number,\n body: RoastUpdateRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PATCH(\"/v1/roasts/{id}\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /** Delete one of the caller's own roast profiles. */\n delete: (id: number) =>\n client.DELETE(\"/v1/roasts/{id}\", { params: { path: { id } } }),\n /** Delete every owner roast carrying one exact batch name. Session-only. */\n deleteBatch: (batchName: string) =>\n client.DELETE(\"/v1/roasts/batches/{batchName}\", {\n params: { path: { batchName } },\n }),\n /**\n * Replace live temperature samples and all event markers atomically,\n * while preserving non-live temperatures and deriving milestone fields.\n */\n replaceLiveCurve: (\n id: number,\n body: RoastLiveCurveRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PUT(\"/v1/roasts/{id}/live-curve\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /**\n * Create a roast profile from an Artisan `.alog` file against one of the\n * caller's green-coffee lots, persisting the imported curve, events, and\n * an artisan_import_log entry atomically. Requires a session or an\n * owner-bound API key carrying the exact `roast:write` scope. Pass\n * `idempotencyKey` to make retries safe.\n */\n import: (\n body: RoastImportRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/roasts/imports\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n }),\n /**\n * Replace the Artisan import data on one of the caller's existing roasts,\n * re-deriving its curve, events, and computed metrics while preserving the\n * roast's identity. Pass `ifMatch` (the roast's `last_updated`) to enable\n * optimistic concurrency (409 on mismatch).\n */\n replaceArtisanImport: (\n id: number,\n body: RoastArtisanImportReplaceRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PUT(\"/v1/roasts/{id}/artisan-import\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /**\n * Clear import-derived curve, events, metrics, and provenance data from\n * one of the caller's existing roasts without deleting the roast profile.\n */\n clearArtisanImport: (id: number) =>\n client.DELETE(\"/v1/roasts/{id}/artisan-import\", {\n params: { path: { id } },\n }),\n },\n sales: {\n /** List the caller's own sales (owner-scoped). */\n list: (query?: SalesListQuery) =>\n client.GET(\"/v1/sales\", { params: { query } }),\n /**\n * Record a sale against one of the caller's own green-coffee inventory\n * lots. Requires a session or an owner-bound API key carrying the exact\n * `sales:write` scope. Pass `idempotencyKey` to make retries safe: the\n * same key replays the original result, and a concurrent duplicate gets\n * 409 while the first is in flight.\n */\n create: (\n body: SalesCreateRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/sales\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n }),\n /**\n * Update one of the caller's own sales. The sales table carries no\n * `last_updated` column, so no If-Match optimistic concurrency is\n * offered.\n */\n update: (id: number, body: SalesUpdateRequest) =>\n client.PATCH(\"/v1/sales/{id}\", {\n params: { path: { id } },\n body,\n }),\n /** Delete one of the caller's own sales. */\n delete: (id: number) =>\n client.DELETE(\"/v1/sales/{id}\", { params: { path: { id } } }),\n },\n profit: {\n /**\n * List the caller's owner-scoped profit summaries. API keys require\n * inventory:read, roast:read, and sales:read. Use pagination.total to\n * exhaust the complete owner result set.\n */\n list: (query?: ProfitListQuery) =>\n client.GET(\"/v1/profit\", { params: { query } }),\n },\n tasting: {\n /** Fetch supplier notes plus the caller's own latest tasting notes. */\n get: (catalogId: string, query?: TastingGetQuery) =>\n client.GET(\"/v1/tasting/{catalogId}\", {\n params: { path: { catalogId }, query },\n }),\n /** Replace the caller's rating for one owned inventory lot. */\n rate: (inventoryId: number, body: TastingRateRequest) =>\n client.PUT(\"/v1/tasting/inventory/{inventoryId}\", {\n params: { path: { inventoryId } },\n body,\n }),\n },\n };\n}\n\nexport type ParchmentClient = ReturnType<typeof createParchmentClient>;\n"],"mappings":";AAAA,OAAO,kBAA0C;AAyU1C,SAAS,sBAAsB,SAAiC;AACrE,QAAM,EAAE,SAAS,OAAO,OAAO,UAAU,IAAI;AAE7C,QAAM,SAAS,aAAoB;AAAA,IACjC;AAAA,IACA,OAAO;AAAA,IACP,SAAS,QAAQ,EAAE,eAAe,UAAU,KAAK,GAAG,IAAI;AAAA,EAC1D,CAAC;AAED,QAAM,gBAAgB,CACpB,MACAA,aAEA,OAAO,KAAK,iBAAiB;AAAA,IAC3B;AAAA,IACA,QAAQA,UAAS,iBACb,EAAE,QAAQ,EAAE,mBAAmBA,SAAQ,eAAe,EAAE,IACxD;AAAA,EACN,CAAC;AAUH,WAAS,gBACP,MACAA,UACkC;AAClC,WAAO,cAAc,MAAMA,QAAO;AAAA,EACpC;AAEA,SAA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AAG,EAAE;AAAA,QACvB;AAAA,MACF,CAAC;AAAA;AAAA,MAEH,QAAQ,CAAC,OACP,OAAO,OAAO,kBAAkB,EAAE,QAAQ,EAAE,MAAM,EAAE,GAAG,EAAE,EAAE,CAAC;AAAA,IAChE;AAAA,IACA,QAAQ;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,MAMN,MAAM,CAAC,UACL,OAAO,IAAI,cAAc,EAAE,QAAQ,EAAE,MAAM,EAAE,CAAC;AAAA,IAClD;AAAA,IACA,SAAS;AAAA;AAAA,MAEP,KAAK,CAAC,WAAmB,UACvB,OAAO,IAAI,2BAA2B;AAAA,QACpC,QAAQ,EAAE,MAAM,EAAE,UAAU,GAAG,MAAM;AAAA,MACvC,CAAC;AAAA;AAAA,MAEH,MAAM,CAAC,aAAqB,SAC1B,OAAO,IAAI,uCAAuC;AAAA,QAChD,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE;AAAA,QAChC;AAAA,MACF,CAAC;AAAA,IACL;AAAA,EACF;AACF;","names":["options"]}
|
|
1
|
+
{"version":3,"sources":["../src/client.ts"],"sourcesContent":["import createClient, { type ClientOptions } from \"openapi-fetch\";\nimport type { components, paths } from \"./schema\";\n\nexport interface ParchmentClientOptions {\n /** Base URL of the Parchment API, e.g. https://api.purveyors.io */\n baseUrl: string;\n /**\n * Optional bearer token (a Supabase JWT, API key, or dedicated machine\n * credential). Sent as\n * `Authorization: Bearer <token>`. Auth is resolved server-side at the route\n * boundary; the SDK only forwards the credential.\n */\n token?: string;\n /** Override the fetch implementation (useful for tests or custom runtimes). */\n fetch?: ClientOptions[\"fetch\"];\n}\n\n/** Query parameters for {@link ParchmentClient.catalog.list}. */\nexport type CatalogListQuery = NonNullable<\n paths[\"/v1/catalog\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** A catalog row returned by the canonical listing resource. */\nexport type CatalogItem = components[\"schemas\"][\"CatalogItem\"];\n/** API-owned row-level trust summary returned when `include=proof`. */\nexport type CatalogProofSummary = components[\"schemas\"][\"CatalogProofSummary\"];\n/** Query parameters for {@link ParchmentClient.catalog.facets}. */\nexport type CatalogFacetsQuery = NonNullable<\n paths[\"/v1/catalog/facets\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/**\n * Optional headers for {@link ParchmentClient.catalog.list}, notably the\n * RFC 7240 `Prefer: handling=lenient|strict` override (PADR-0013 §7). Sending\n * `handling=lenient` opts a strict caller (API key or bearer-session JWT) back\n * into strip-with-notice degradation instead of a 401/403 hard-deny.\n */\nexport type CatalogListHeaders = NonNullable<\n paths[\"/v1/catalog\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.map}. */\nexport type CatalogMapQuery = NonNullable<\n paths[\"/v1/catalog/map\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Optional handling headers for {@link ParchmentClient.catalog.map}. */\nexport type CatalogMapHeaders = NonNullable<\n paths[\"/v1/catalog/map\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Lightweight map projection over the caller-visible catalog. */\nexport type CatalogMapResponse = components[\"schemas\"][\"CatalogMapResponse\"];\n/** Optional headers for {@link ParchmentClient.catalog.facets}; see {@link CatalogListHeaders}. */\nexport type CatalogFacetsHeaders = NonNullable<\n paths[\"/v1/catalog/facets\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.originPriceStats}. */\nexport type CatalogOriginPriceStatsQuery = NonNullable<\n paths[\"/v1/catalog/origin-price-stats\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.stats}. */\nexport type CatalogStatsQuery = NonNullable<\n paths[\"/v1/catalog/stats\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.rank}. */\nexport type CatalogRankQuery = NonNullable<\n paths[\"/v1/catalog/rank\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.rankPremium}. */\nexport type CatalogRankPremiumQuery = NonNullable<\n paths[\"/v1/catalog/rank-premium\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.suppliers}. */\nexport type CatalogSuppliersQuery = NonNullable<\n paths[\"/v1/catalog/suppliers\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.supplierDetail}. */\nexport type CatalogSupplierDetailQuery = NonNullable<\n paths[\"/v1/catalog/suppliers/detail\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.supplierRank}. */\nexport type CatalogSupplierRankQuery = NonNullable<\n paths[\"/v1/catalog/suppliers/rank\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Optional headers for ranking endpoints; see {@link CatalogListHeaders}. */\nexport type CatalogRankHeaders = NonNullable<\n paths[\"/v1/catalog/rank\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Optional headers for premium ranking endpoints; see {@link CatalogListHeaders}. */\nexport type CatalogRankPremiumHeaders = NonNullable<\n paths[\"/v1/catalog/rank-premium\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Optional headers for supplier aggregate endpoints; see {@link CatalogListHeaders}. */\nexport type CatalogSupplierHeaders = NonNullable<\n paths[\"/v1/catalog/suppliers\"][\"get\"][\"parameters\"][\"header\"]\n>;\n/** Query parameters for {@link ParchmentClient.catalog.similar}. */\nexport type CatalogSimilarQuery = NonNullable<\n paths[\"/v1/catalog/{id}/similar\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.priceIndex.list}. */\nexport type PriceIndexQuery = NonNullable<\n paths[\"/v1/price-index\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.priceIndex.history}. */\nexport type PriceIndexHistoryQuery = NonNullable<\n paths[\"/v1/price-index/history\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.market.signals}. */\nexport type MarketSignalsQuery = NonNullable<\n paths[\"/v1/market/signals\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Aggregate-only public green-coffee market evidence. */\nexport type MarketOverview = components[\"schemas\"][\"MarketOverviewResponse\"];\n/** Named public-catalog and supplier evidence for Parchment Intelligence callers. */\nexport type MarketEvidence = components[\"schemas\"][\"MarketEvidenceResponse\"];\n/** Query parameters for {@link ParchmentClient.priceIndex.stats}. */\nexport type PriceIndexStatsQuery = NonNullable<\n paths[\"/v1/price-index/stats\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.market.metadataIndex}. */\nexport type MetadataIndexQuery = NonNullable<\n paths[\"/v1/market/metadata-index\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.procurement.briefs.matches}. */\nexport type BriefMatchesQuery = NonNullable<\n paths[\"/v1/procurement/briefs/{id}/matches\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.procurement.briefs.create}. */\nexport type SourcingBriefCreateRequest =\n components[\"schemas\"][\"SourcingBriefCreateRequest\"];\n/** Query parameters for {@link ParchmentClient.portfolio.trackedLots.list}. */\nexport type TrackedLotsListQuery = NonNullable<\n paths[\"/v1/portfolio/tracked-lots\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** A tracked catalog lot enriched with current catalog and price state. */\nexport type TrackedLotSummary = components[\"schemas\"][\"TrackedLotSummary\"];\n/** State returned by tracked-lot PUT and DELETE mutations. */\nexport type TrackedLotMutation =\n components[\"schemas\"][\"TrackedLotMutationResponse\"];\n/** Closed session-only command for {@link ParchmentClient.confirmedActions.execute}. */\nexport type ConfirmedActionExecuteRequest = NonNullable<\n paths[\"/v1/confirmed-actions/execute\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for {@link ParchmentClient.inventory.list}. */\nexport type InventoryListQuery = NonNullable<\n paths[\"/v1/inventory\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.inventory.create}. */\nexport type InventoryCreateRequest = NonNullable<\n paths[\"/v1/inventory\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Stable-operation request for {@link ParchmentClient.inventory.shareGrants.create}. */\nexport type InventoryShareGrantCreateRequest = NonNullable<\n paths[\"/v1/inventory/share-grants\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** The one-time raw-token grant returned by create or same-operation replay. */\nexport type InventoryShareGrant = components[\"schemas\"][\"InventoryShareGrant\"];\n/** Anonymous capability body for {@link ParchmentClient.inventory.shareGrants.redeem}. */\nexport type InventoryShareGrantRedeemRequest = NonNullable<\n paths[\"/v1/inventory/share-grants/redeem\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Safe legacy-oriented inventory row returned by capability redemption. */\nexport type InventoryShareInventory =\n components[\"schemas\"][\"InventoryShareInventory\"];\n/** Catalog allowlist nested in a shared inventory row. */\nexport type InventoryShareCatalog =\n components[\"schemas\"][\"InventoryShareCatalog\"];\n/** Six-field roast summary nested in member/admin shares. */\nexport type InventoryShareRoastSummary =\n components[\"schemas\"][\"InventoryShareRoastSummary\"];\ntype CatalogInventoryCreateRequest =\n components[\"schemas\"][\"CatalogInventoryCreateRequest\"];\ntype ManualInventoryCreateRequest =\n components[\"schemas\"][\"ManualInventoryCreateRequest\"];\n/** Request body for {@link ParchmentClient.inventory.createManualBatch}. */\nexport type ManualInventoryBatchCreateRequest = NonNullable<\n paths[\"/v1/inventory/manual-batches\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for reserving durable server-owned manual-batch intent. */\nexport type ManualInventoryBatchReserveRequest = NonNullable<\n paths[\"/v1/inventory/manual-batches/reservations\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Complete canonical intent accepted by the catalog-batch reservation lane. */\nexport type CatalogInventoryBatchReserveRequest = NonNullable<\n paths[\"/v1/inventory/catalog-batches/reservations\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable catalog-batch state returned by reserve, commit, and status. */\nexport type CatalogInventoryBatchLifecycle =\n components[\"schemas\"][\"CatalogInventoryBatchLifecycle\"];\n/** Identity-only terminal result; catalog resources remain a separate read. */\nexport type CatalogInventoryBatchResult =\n components[\"schemas\"][\"CatalogInventoryBatchResult\"];\n/** Request body for {@link ParchmentClient.inventory.update}. */\nexport type InventoryUpdateRequest = NonNullable<\n paths[\"/v1/inventory/{id}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for {@link ParchmentClient.roasts.list}. */\nexport type RoastListQuery = NonNullable<\n paths[\"/v1/roasts\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.roasts.get}. */\nexport type RoastGetQuery = NonNullable<\n paths[\"/v1/roasts/{id}\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.roasts.chartData}. */\nexport type RoastChartDataQuery = NonNullable<\n paths[\"/v1/roasts/{id}/chart-data\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.roasts.classify}. */\nexport type RoastClassificationRequest = NonNullable<\n paths[\"/v1/roasts/classify\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.create}. */\nexport type RoastCreateRequest = NonNullable<\n paths[\"/v1/roasts\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Atomic named-batch body for {@link ParchmentClient.roasts.createBatch}. */\nexport type RoastBatchCreateRequest = NonNullable<\n paths[\"/v1/roasts/batches\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.update}. */\nexport type RoastUpdateRequest = NonNullable<\n paths[\"/v1/roasts/{id}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Source-aware live curve body for {@link ParchmentClient.roasts.replaceLiveCurve}. */\nexport type RoastLiveCurveRequest = NonNullable<\n paths[\"/v1/roasts/{id}/live-curve\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.import}. */\nexport type RoastImportRequest = NonNullable<\n paths[\"/v1/roasts/imports\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.roasts.replaceArtisanImport}. */\nexport type RoastArtisanImportReplaceRequest = NonNullable<\n paths[\"/v1/roasts/{id}/artisan-import\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for {@link ParchmentClient.sales.list}. */\nexport type SalesListQuery = NonNullable<\n paths[\"/v1/sales\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Query parameters for {@link ParchmentClient.profit.list}. */\nexport type ProfitListQuery = NonNullable<\n paths[\"/v1/profit\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** One owner inventory lot's canonical cost, revenue, and roast summary. */\nexport type ProfitItem = components[\"schemas\"][\"ProfitItem\"];\n/** Request body for {@link ParchmentClient.sales.create}. */\nexport type SalesCreateRequest = NonNullable<\n paths[\"/v1/sales\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.sales.update}. */\nexport type SalesUpdateRequest = NonNullable<\n paths[\"/v1/sales/{id}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for {@link ParchmentClient.tasting.get}. */\nexport type TastingGetQuery = NonNullable<\n paths[\"/v1/tasting/{catalogId}\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Request body for {@link ParchmentClient.tasting.rate}. */\nexport type TastingRateRequest = NonNullable<\n paths[\"/v1/tasting/inventory/{inventoryId}\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.apiKeys.create}. */\nexport type ApiKeyCreateRequest = NonNullable<\n paths[\"/v1/api-keys\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Query parameters for the session owner's API-key traffic analytics. */\nexport type OwnerApiUsageQuery = NonNullable<\n paths[\"/v1/api-usage\"][\"get\"][\"parameters\"][\"query\"]\n>;\n/** Bounded owner API-key traffic analytics (not session or billing usage). */\nexport type OwnerApiUsage = components[\"schemas\"][\"OwnerApiUsageResponse\"];\n/** Request body for {@link ParchmentClient.emailSubscriptions.setMarketRead}. */\nexport type MarketReadPreferenceRequest = NonNullable<\n paths[\"/v1/email-subscriptions/market-read\"][\"put\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Request body for {@link ParchmentClient.emailSubscriptions.unsubscribeMarketRead}. */\nexport type MarketReadUnsubscribeRequest = NonNullable<\n paths[\"/v1/email-subscriptions/market-read/unsubscribe\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Immutable deployed projection accepted by {@link ParchmentClient.marketBrief.drafts.create}. */\nexport type MarketBriefDraftCreateRequest = NonNullable<\n paths[\"/v1/market-brief/drafts\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable Parchment-owned provider-draft state. */\nexport type MarketBriefDraftState =\n components[\"schemas\"][\"MarketBriefDraftState\"];\n/** Account-owned Market Read email preference. */\nexport type EmailSubscriptionPreference =\n components[\"schemas\"][\"EmailSubscriptionPreference\"];\n/** Durable state returned by an account-deletion request. */\nexport type AccountDeletionOperation =\n components[\"schemas\"][\"AccountDeletionOperation\"];\n/** Purpose-bound recent-reauthentication assertion for account deletion. */\nexport type AccountDeletionRequest = NonNullable<\n paths[\"/v1/account-deletion\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Purchase-key request for dormant direct Parchment Checkout creation/replay. */\nexport type BillingCheckoutCreateRequest = NonNullable<\n paths[\"/v1/billing/checkout-sessions\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable Checkout admission state; provider Session id stays server-side. */\nexport type BillingCheckoutSession =\n components[\"schemas\"][\"BillingCheckoutSession\"];\n/** Durable cancellation/resume request. */\nexport type BillingSubscriptionMutationRequest = NonNullable<\n paths[\"/v1/billing/subscriptions/{subscriptionId}\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n/** Durable provider subscription-operation state. */\nexport type BillingSubscriptionOperation =\n components[\"schemas\"][\"BillingSubscriptionOperation\"];\n/** Manual entitlement baseline update for administrators. */\nexport type BillingManualEntitlementsRequest = NonNullable<\n paths[\"/v1/admin/billing-entitlements/{ownerId}/manual\"][\"patch\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthRequestCreate = NonNullable<\n paths[\"/v1/cli-auth/requests\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthInspectRequest = NonNullable<\n paths[\"/v1/cli-auth/inspect\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthApproveRequest = NonNullable<\n paths[\"/v1/cli-auth/approve\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\nexport type CliAuthExchangeRequest = NonNullable<\n paths[\"/v1/cli-auth/token\"][\"post\"][\"requestBody\"]\n>[\"content\"][\"application/json\"];\n\n/**\n * Create a typed Parchment API client.\n *\n * The generated core (openapi-fetch over the generated `paths` types) is the\n * contract truth; the named helpers below are the hand-maintained ergonomic\n * layer and grow as endpoints land. `raw` always exposes the underlying typed\n * client for direct path access to anything not yet wrapped.\n */\nexport function createParchmentClient(options: ParchmentClientOptions) {\n const { baseUrl, token, fetch: fetchImpl } = options;\n\n const client = createClient<paths>({\n baseUrl,\n fetch: fetchImpl,\n headers: token ? { Authorization: `Bearer ${token}` } : undefined,\n });\n\n const postInventory = (\n body: InventoryCreateRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/inventory\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n });\n\n function createInventory(\n body: ManualInventoryCreateRequest,\n options: { idempotencyKey: string },\n ): ReturnType<typeof postInventory>;\n function createInventory(\n body: CatalogInventoryCreateRequest,\n options?: { idempotencyKey?: string },\n ): ReturnType<typeof postInventory>;\n function createInventory(\n body: InventoryCreateRequest,\n options?: { idempotencyKey?: string },\n ): ReturnType<typeof postInventory> {\n return postInventory(body, options);\n }\n\n return {\n /** The underlying typed openapi-fetch client for direct path access. */\n raw: client,\n /** Liveness and service identity. */\n health: () => client.GET(\"/health\"),\n /** Resolved principal and entitlements for the caller. */\n me: () => client.GET(\"/v1/me\"),\n apiKeys: {\n /** List API keys owned by the authenticated session user. */\n list: () => client.GET(\"/v1/api-keys\"),\n /** Create an API key. The raw secret is returned only once. */\n create: (body: ApiKeyCreateRequest) =>\n client.POST(\"/v1/api-keys\", { body }),\n /** Revoke an API key owned by the authenticated session user. */\n revoke: (id: string) =>\n client.DELETE(\"/v1/api-keys/{id}\", {\n params: { path: { id } },\n }),\n /** Rotate an API key and return the replacement secret once. */\n rotate: (id: string) =>\n client.POST(\"/v1/api-keys/{id}/rotate\", {\n params: { path: { id } },\n }),\n },\n apiUsage: {\n /**\n * Read bounded API-key traffic analytics for the authenticated session\n * owner. Headline monthly/hourly counts are exact; daily/per-key series\n * carry explicit truncation metadata.\n */\n get: (query?: OwnerApiUsageQuery) =>\n client.GET(\"/v1/api-usage\", { params: { query } }),\n },\n emailSubscriptions: {\n /** Get the authenticated session user's Market Read preference. */\n get: () => client.GET(\"/v1/email-subscriptions\"),\n /** Idempotently set the authenticated session user's Market Read preference. */\n setMarketRead: (body: MarketReadPreferenceRequest) =>\n client.PUT(\"/v1/email-subscriptions/market-read\", { body }),\n /** Idempotently unsubscribe using an opaque capability without requiring a session. */\n unsubscribeMarketRead: (body: MarketReadUnsubscribeRequest) =>\n client.POST(\"/v1/email-subscriptions/market-read/unsubscribe\", {\n body,\n }),\n },\n marketBrief: {\n drafts: {\n /** Accept, create, or recover one immutable deployed edition version. */\n create: (body: MarketBriefDraftCreateRequest) =>\n client.POST(\"/v1/market-brief/drafts\", { body }),\n },\n },\n accountDeletion: {\n /** Accept or replay deletion using a purpose-bound reauthentication assertion. */\n request: (body: AccountDeletionRequest) =>\n client.POST(\"/v1/account-deletion\", { body }),\n },\n billing: {\n checkout: {\n /** Create or replay an embedded Checkout Session after activation. */\n create: (body: BillingCheckoutCreateRequest) =>\n client.POST(\"/v1/billing/checkout-sessions\", { body }),\n /** Read owner-bound durable admission state. */\n get: (admissionId: string) =>\n client.GET(\"/v1/billing/checkout-sessions/{admissionId}\", {\n params: { path: { admissionId } },\n }),\n /** Authoritatively reconcile an admission with Stripe. */\n reconcile: (admissionId: string) =>\n client.POST(\"/v1/billing/checkout-sessions/{admissionId}/reconcile\", {\n params: { path: { admissionId } },\n }),\n },\n subscriptions: {\n /** List canonical owner subscription snapshots. */\n list: () => client.GET(\"/v1/billing/subscriptions\"),\n /** Durably cancel or resume the complete provider subscription. */\n mutate: (\n subscriptionId: string,\n body: BillingSubscriptionMutationRequest,\n ) =>\n client.PATCH(\"/v1/billing/subscriptions/{subscriptionId}\", {\n params: { path: { subscriptionId } },\n body,\n }),\n },\n },\n billingAdministration: {\n /** Read bounded canonical-entitlement discrepancies. */\n discrepancies: () =>\n client.GET(\"/v1/admin/billing-entitlement-discrepancies\"),\n /** Recompute billing contribution without changing manual grants. */\n recompute: (ownerId: string) =>\n client.POST(\n \"/v1/admin/billing-entitlement-discrepancies/{ownerId}/recompute\",\n { params: { path: { ownerId } } },\n ),\n /** Update the preserved manual entitlement baseline. */\n setManual: (ownerId: string, body: BillingManualEntitlementsRequest) =>\n client.PATCH(\"/v1/admin/billing-entitlements/{ownerId}/manual\", {\n params: { path: { ownerId } },\n body,\n }),\n },\n cliAuth: {\n /** Create a signed, short-lived login request bound to a PKCE challenge. */\n create: (body: CliAuthRequestCreate) =>\n client.POST(\"/v1/cli-auth/requests\", { body }),\n /** Inspect a signed request before displaying the web consent screen. */\n inspect: (body: CliAuthInspectRequest) =>\n client.POST(\"/v1/cli-auth/inspect\", { body }),\n /** Approve a request using the client's authenticated user session. */\n approve: (body: CliAuthApproveRequest) =>\n client.POST(\"/v1/cli-auth/approve\", { body }),\n /** Exchange an approved request and verifier for the one-time raw key. */\n exchange: (body: CliAuthExchangeRequest) =>\n client.POST(\"/v1/cli-auth/token\", { body }),\n },\n catalog: {\n /** Catalog capabilities and visibility for the caller. */\n access: () => client.GET(\"/v1/catalog/access\"),\n /**\n * List public catalog coffees (paginated). Pass `headers` to send the\n * `Prefer: handling=lenient|strict` override (see {@link CatalogListHeaders}).\n */\n list: (query?: CatalogListQuery, headers?: CatalogListHeaders) =>\n client.GET(\"/v1/catalog\", { params: { query, header: headers } }),\n /** Deterministic clusters, canonical place features, and elevation profile. */\n map: (query?: CatalogMapQuery, headers?: CatalogMapHeaders) =>\n client.GET(\"/v1/catalog/map\", {\n params: { query, header: headers },\n }),\n /**\n * Catalog filter metadata and counted facets. Pass `headers` to send the\n * `Prefer: handling=lenient|strict` override (see {@link CatalogFacetsHeaders}).\n */\n facets: (query?: CatalogFacetsQuery, headers?: CatalogFacetsHeaders) =>\n client.GET(\"/v1/catalog/facets\", {\n params: { query, header: headers },\n }),\n /** Live catalog price context by origin. */\n originPriceStats: (query?: CatalogOriginPriceStatsQuery) =>\n client.GET(\"/v1/catalog/origin-price-stats\", { params: { query } }),\n /** Aggregate stats over the caller-visible catalog. */\n stats: (query?: CatalogStatsQuery) =>\n client.GET(\"/v1/catalog/stats\", { params: { query } }),\n /** Rank caller-visible catalog coffees by deterministic objectives. */\n rank: (query?: CatalogRankQuery, headers?: CatalogRankHeaders) =>\n client.GET(\"/v1/catalog/rank\", {\n params: { query, header: headers },\n }),\n /** Rank premium catalog candidates by Purveyor Score. */\n rankPremium: (\n query?: CatalogRankPremiumQuery,\n headers?: CatalogRankPremiumHeaders,\n ) =>\n client.GET(\"/v1/catalog/rank-premium\", {\n params: { query, header: headers },\n }),\n /** List supplier aggregates over caller-visible catalog coffees. */\n suppliers: (\n query?: CatalogSuppliersQuery,\n headers?: CatalogSupplierHeaders,\n ) =>\n client.GET(\"/v1/catalog/suppliers\", {\n params: { query, header: headers },\n }),\n /** Return aggregate detail for a supplier query. */\n supplierDetail: (\n query: CatalogSupplierDetailQuery,\n headers?: CatalogSupplierHeaders,\n ) =>\n client.GET(\"/v1/catalog/suppliers/detail\", {\n params: { query, header: headers },\n }),\n /** Rank suppliers by catalog score and availability. */\n supplierRank: (\n query?: CatalogSupplierRankQuery,\n headers?: CatalogSupplierHeaders,\n ) =>\n client.GET(\"/v1/catalog/suppliers/rank\", {\n params: { query, header: headers },\n }),\n /** Aggregate proof-coverage over the public catalog. */\n proofCoverage: () => client.GET(\"/v1/catalog/proof-coverage\"),\n /** Find catalog coffees similar to a target coffee. */\n similar: (id: string, query?: CatalogSimilarQuery) =>\n client.GET(\"/v1/catalog/{id}/similar\", {\n params: { path: { id }, query },\n }),\n },\n priceIndex: {\n /** Parchment Price Index (aggregate snapshots). */\n list: (query?: PriceIndexQuery) =>\n client.GET(\"/v1/price-index\", { params: { query } }),\n /** Tier-one price-index chart history. */\n history: (query?: PriceIndexHistoryQuery) =>\n client.GET(\"/v1/price-index/history\", { params: { query } }),\n /** Price movement significance stats (precomputed). */\n stats: (query?: PriceIndexStatsQuery) =>\n client.GET(\"/v1/price-index/stats\", { params: { query } }),\n },\n market: {\n /** Aggregate daily changes, catalog coverage, movement, processing, and origin prices. */\n overview: () => client.GET(\"/v1/market/overview\"),\n /** Entitled named-lot and supplier evidence over the public catalog. */\n evidence: () => client.GET(\"/v1/market/evidence\"),\n /** Actionable market value signals. */\n signals: (query?: MarketSignalsQuery) =>\n client.GET(\"/v1/market/signals\", { params: { query } }),\n /** Metadata-trend index (process/disclosure/Purveyor Score over time). */\n metadataIndex: (query?: MetadataIndexQuery) =>\n client.GET(\"/v1/market/metadata-index\", { params: { query } }),\n },\n procurement: {\n briefs: {\n /** List the caller's saved sourcing briefs. */\n list: () => client.GET(\"/v1/procurement/briefs\"),\n /** Create a saved sourcing brief. */\n create: (body: SourcingBriefCreateRequest) =>\n client.POST(\"/v1/procurement/briefs\", { body }),\n /** Fetch one of the caller's sourcing briefs by id. */\n get: (id: string) =>\n client.GET(\"/v1/procurement/briefs/{id}\", {\n params: { path: { id } },\n }),\n /** Run a saved brief against the catalog (paginated matches). */\n matches: (id: string, query?: BriefMatchesQuery) =>\n client.GET(\"/v1/procurement/briefs/{id}/matches\", {\n params: { path: { id }, query },\n }),\n },\n },\n portfolio: {\n trackedLots: {\n /**\n * List an owner-scoped tracked catalog-id page and bounded recent\n * summaries enriched with live catalog state. Follow nextCursor when\n * a capped response reports truncation.\n */\n list: (query?: TrackedLotsListQuery) =>\n client.GET(\"/v1/portfolio/tracked-lots\", {\n params: { query },\n }),\n /** Idempotently set a visible catalog lot to tracked. */\n track: (catalogId: number) =>\n client.PUT(\"/v1/portfolio/tracked-lots/{catalogId}\", {\n params: { path: { catalogId } },\n }),\n /** Idempotently set an owner catalog lot to untracked. */\n untrack: (catalogId: number) =>\n client.DELETE(\"/v1/portfolio/tracked-lots/{catalogId}\", {\n params: { path: { catalogId } },\n }),\n },\n },\n confirmedActions: {\n /**\n * Execute or replay one user-confirmed product action. Session-only;\n * executionId is the durable payload-bound replay key.\n */\n execute: (body: ConfirmedActionExecuteRequest) =>\n client.POST(\"/v1/confirmed-actions/execute\", { body }),\n },\n inventory: {\n /** List the caller's own green-coffee inventory (owner-scoped). */\n list: (query?: InventoryListQuery) =>\n client.GET(\"/v1/inventory\", { params: { query } }),\n shareGrants: {\n /**\n * Mint or replay a bounded cross-principal inventory capability. The\n * operation UUID is payload-bound and the raw token is returned only\n * by this response.\n */\n create: (body: InventoryShareGrantCreateRequest) =>\n client.POST(\"/v1/inventory/share-grants\", { body }),\n /**\n * Redeem a capability supplied in JSON (never in a URL). This helper\n * does not require the client to be configured with a bearer token.\n */\n redeem: (body: InventoryShareGrantRedeemRequest) =>\n client.POST(\"/v1/inventory/share-grants/redeem\", { body }),\n },\n /**\n * Create an owner inventory lot. Requires a session or an owner-bound API\n * key carrying the exact `inventory:write` scope. Manual coffee creates\n * require `idempotencyKey`; catalog-backed creates accept it optionally.\n * The same key and payload replay the original result.\n */\n create: createInventory,\n /**\n * Atomically create owner-private manual inventory lots. The required\n * idempotency UUID is the stable batch identity and can be reconciled\n * with `getManualBatch` after an uncertain response.\n */\n createManualBatch: (\n body: ManualInventoryBatchCreateRequest,\n options: { idempotencyKey: string },\n ) =>\n client.POST(\"/v1/inventory/manual-batches\", {\n params: {\n header: { \"idempotency-key\": options.idempotencyKey },\n },\n body,\n }),\n /** Return the durable terminal result for a manual inventory batch. */\n getManualBatch: (batchId: string) =>\n client.GET(\"/v1/inventory/manual-batches/{batchId}\", {\n params: { path: { batchId } },\n }),\n /**\n * Durably reserve a complete manual-batch request. Once accepted, clients\n * only need to persist the batch UUID.\n */\n reserveManualBatch: (body: ManualInventoryBatchReserveRequest) =>\n client.POST(\"/v1/inventory/manual-batches/reservations\", { body }),\n /** Commit a reserved batch by UUID with no request body. */\n commitManualBatch: (batchId: string) =>\n client.POST(\"/v1/inventory/manual-batches/{batchId}/commit\", {\n params: { path: { batchId } },\n }),\n /**\n * Get unknown, accepted, in-progress, completed, or terminal-rejected\n * state. Unknown is explicitly nonterminal, including missing or\n * cross-tenant UUIDs, so clients retain the UUID and retry.\n */\n getManualBatchStatus: (batchId: string) =>\n client.GET(\"/v1/inventory/manual-batches/{batchId}/status\", {\n params: { path: { batchId } },\n }),\n /** Durably reserve canonical catalog-backed inventory intent. */\n reserveCatalogBatch: (body: CatalogInventoryBatchReserveRequest) =>\n client.POST(\"/v1/inventory/catalog-batches/reservations\", { body }),\n /** Atomically commit a reserved catalog batch by UUID, with no body. */\n commitCatalogBatch: (batchId: string) =>\n client.POST(\"/v1/inventory/catalog-batches/{batchId}/commit\", {\n params: { path: { batchId } },\n }),\n /** Recover the owner-scoped lifecycle; missing batches remain unknown. */\n getCatalogBatchStatus: (batchId: string) =>\n client.GET(\"/v1/inventory/catalog-batches/{batchId}/status\", {\n params: { path: { batchId } },\n }),\n /**\n * Update one of the caller's own inventory rows. Pass `ifMatch` (the\n * row's `last_updated`) to enable optimistic concurrency (409 on mismatch).\n */\n update: (\n id: number,\n body: InventoryUpdateRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PATCH(\"/v1/inventory/{id}\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /**\n * Delete one of the caller's own inventory rows. Returns 409 if dependent\n * roast profiles or sales exist (no force-cascade).\n */\n delete: (id: number) =>\n client.DELETE(\"/v1/inventory/{id}\", { params: { path: { id } } }),\n },\n roasts: {\n /** Match Artisan roast metadata to one of the supplied inventory rows. */\n classify: (body: RoastClassificationRequest) =>\n client.POST(\"/v1/roasts/classify\", { body }),\n /** List the caller's own roast profiles (owner-scoped). */\n list: (query?: RoastListQuery) =>\n client.GET(\"/v1/roasts\", { params: { query } }),\n /**\n * Fetch one of the caller's roast profiles by id, optionally with its\n * temperature curve (`includeTemps`) and event markers (`includeEvents`).\n */\n get: (id: string, query?: RoastGetQuery) =>\n client.GET(\"/v1/roasts/{id}\", { params: { path: { id }, query } }),\n /** Fetch an owner roast's adaptively sampled chart curve and metadata. */\n chartData: (id: string, query?: RoastChartDataQuery) =>\n client.GET(\"/v1/roasts/{id}/chart-data\", {\n params: { path: { id }, query },\n }),\n /**\n * Create an owner roast profile, optionally with nested temperature/event\n * rows. Requires a session or an owner-bound API key carrying the exact\n * `roast:write` scope. Pass `idempotencyKey` to make retries safe.\n */\n create: (\n body: RoastCreateRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/roasts\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n }),\n /**\n * Create every profile in one named batch atomically. The required\n * payload-bound idempotency key makes transport retries safe.\n */\n createBatch: (body: RoastBatchCreateRequest, idempotencyKey: string) =>\n client.POST(\"/v1/roasts/batches\", {\n body,\n params: { header: { \"idempotency-key\": idempotencyKey } },\n }),\n /**\n * Update one of the caller's own roast profiles. Pass `ifMatch` (the\n * row's `last_updated`) to enable optimistic concurrency (409 on mismatch).\n */\n update: (\n id: number,\n body: RoastUpdateRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PATCH(\"/v1/roasts/{id}\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /** Delete one of the caller's own roast profiles. */\n delete: (id: number) =>\n client.DELETE(\"/v1/roasts/{id}\", { params: { path: { id } } }),\n /** Delete every owner roast carrying one exact batch name. Session-only. */\n deleteBatch: (batchName: string) =>\n client.DELETE(\"/v1/roasts/batches/{batchName}\", {\n params: { path: { batchName } },\n }),\n /**\n * Replace live temperature samples and all event markers atomically,\n * while preserving non-live temperatures and deriving milestone fields.\n */\n replaceLiveCurve: (\n id: number,\n body: RoastLiveCurveRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PUT(\"/v1/roasts/{id}/live-curve\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /**\n * Create a roast profile from an Artisan `.alog` file against one of the\n * caller's green-coffee lots, persisting the imported curve, events, and\n * an artisan_import_log entry atomically. Requires a session or an\n * owner-bound API key carrying the exact `roast:write` scope. Pass\n * `idempotencyKey` to make retries safe.\n */\n import: (\n body: RoastImportRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/roasts/imports\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n }),\n /**\n * Replace the Artisan import data on one of the caller's existing roasts,\n * re-deriving its curve, events, and computed metrics while preserving the\n * roast's identity. Pass `ifMatch` (the roast's `last_updated`) to enable\n * optimistic concurrency (409 on mismatch).\n */\n replaceArtisanImport: (\n id: number,\n body: RoastArtisanImportReplaceRequest,\n options?: { ifMatch?: string },\n ) =>\n client.PUT(\"/v1/roasts/{id}/artisan-import\", {\n params: {\n path: { id },\n header: options?.ifMatch\n ? { \"if-match\": options.ifMatch }\n : undefined,\n },\n body,\n }),\n /**\n * Clear import-derived curve, events, metrics, and provenance data from\n * one of the caller's existing roasts without deleting the roast profile.\n */\n clearArtisanImport: (id: number) =>\n client.DELETE(\"/v1/roasts/{id}/artisan-import\", {\n params: { path: { id } },\n }),\n },\n sales: {\n /** List the caller's own sales (owner-scoped). */\n list: (query?: SalesListQuery) =>\n client.GET(\"/v1/sales\", { params: { query } }),\n /**\n * Record a sale against one of the caller's own green-coffee inventory\n * lots. Requires a session or an owner-bound API key carrying the exact\n * `sales:write` scope. Pass `idempotencyKey` to make retries safe: the\n * same key replays the original result, and a concurrent duplicate gets\n * 409 while the first is in flight.\n */\n create: (\n body: SalesCreateRequest,\n options?: { idempotencyKey?: string },\n ) =>\n client.POST(\"/v1/sales\", {\n body,\n params: options?.idempotencyKey\n ? { header: { \"idempotency-key\": options.idempotencyKey } }\n : undefined,\n }),\n /**\n * Update one of the caller's own sales. The sales table carries no\n * `last_updated` column, so no If-Match optimistic concurrency is\n * offered.\n */\n update: (id: number, body: SalesUpdateRequest) =>\n client.PATCH(\"/v1/sales/{id}\", {\n params: { path: { id } },\n body,\n }),\n /** Delete one of the caller's own sales. */\n delete: (id: number) =>\n client.DELETE(\"/v1/sales/{id}\", { params: { path: { id } } }),\n },\n profit: {\n /**\n * List the caller's owner-scoped profit summaries. API keys require\n * inventory:read, roast:read, and sales:read. Use pagination.total to\n * exhaust the complete owner result set.\n */\n list: (query?: ProfitListQuery) =>\n client.GET(\"/v1/profit\", { params: { query } }),\n },\n tasting: {\n /** Fetch supplier notes plus the caller's own latest tasting notes. */\n get: (catalogId: string, query?: TastingGetQuery) =>\n client.GET(\"/v1/tasting/{catalogId}\", {\n params: { path: { catalogId }, query },\n }),\n /** Replace the caller's rating for one owned inventory lot. */\n rate: (inventoryId: number, body: TastingRateRequest) =>\n client.PUT(\"/v1/tasting/inventory/{inventoryId}\", {\n params: { path: { inventoryId } },\n body,\n }),\n },\n };\n}\n\nexport type ParchmentClient = ReturnType<typeof createParchmentClient>;\n"],"mappings":";AAAA,OAAO,kBAA0C;AA6U1C,SAAS,sBAAsB,SAAiC;AACrE,QAAM,EAAE,SAAS,OAAO,OAAO,UAAU,IAAI;AAE7C,QAAM,SAAS,aAAoB;AAAA,IACjC;AAAA,IACA,OAAO;AAAA,IACP,SAAS,QAAQ,EAAE,eAAe,UAAU,KAAK,GAAG,IAAI;AAAA,EAC1D,CAAC;AAED,QAAM,gBAAgB,CACpB,MACAA,aAEA,OAAO,KAAK,iBAAiB;AAAA,IAC3B;AAAA,IACA,QAAQA,UAAS,iBACb,EAAE,QAAQ,EAAE,mBAAmBA,SAAQ,eAAe,EAAE,IACxD;AAAA,EACN,CAAC;AAUH,WAAS,gBACP,MACAA,UACkC;AAClC,WAAO,cAAc,MAAMA,QAAO;AAAA,EACpC;AAEA,SAAO;AAAA;AAAA,IAEL,KAAK;AAAA;AAAA,IAEL,QAAQ,MAAM,OAAO,IAAI,SAAS;AAAA;AAAA,IAElC,IAAI,MAAM,OAAO,IAAI,QAAQ;AAAA,IAC7B,SAAS;AAAA;AAAA,MAEP,MAAM,MAAM,OAAO,IAAI,cAAc;AAAA;AAAA,MAErC,QAAQ,CAAC,SACP,OAAO,KAAK,gBAAgB,EAAE,KAAK,CAAC;AAAA;AAAA,MAEtC,QAAQ,CAAC,OACP,OAAO,OAAO,qBAAqB;AAAA,QACjC,QAAQ,EAAE,MAAM,EAAE,GAAG,EAAE;AAAA,MACzB,CAAC;AAAA;AAAA,MAEH,QAAQ,CAAC,OACP,OAAO,KAAK,4BAA4B;AAAA,QACtC,QAAQ,EAAE,MAAM,EAAE,GAAG,EAAE;AAAA,MACzB,CAAC;AAAA,IACL;AAAA,IACA,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA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