@agentforge-io/sdk-server 4.58.0 → 4.60.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.
Files changed (2) hide show
  1. package/dist/types.d.ts +19 -1
  2. package/package.json +1 -1
package/dist/types.d.ts CHANGED
@@ -1126,6 +1126,8 @@ export interface CatalogProduct {
1126
1126
  sortOrder: number;
1127
1127
  origin?: string;
1128
1128
  externalId?: string | null;
1129
+ /** AGF-PRODUCT-SKU — the business's inventory code (SKU, barcode number), unique in the catalog; null = none. */
1130
+ sku?: string | null;
1129
1131
  kind: CatalogProductKind;
1130
1132
  status: CatalogProductStatus;
1131
1133
  priceKind: CatalogPriceKind;
@@ -1162,6 +1164,9 @@ export interface CreateCatalogProductInput {
1162
1164
  stock?: number | null;
1163
1165
  categoryId?: string | null;
1164
1166
  isAvailable?: boolean;
1167
+ /** AGF-PRODUCT-SKU — the inventory code, max 64 chars (trimmed; null or '' clears it).
1168
+ * 409 SKU_CONFLICT when another product of the catalog has it. */
1169
+ sku?: string | null;
1165
1170
  kind?: CatalogProductKind;
1166
1171
  status?: CatalogProductStatus;
1167
1172
  priceKind?: CatalogPriceKind;
@@ -2308,6 +2313,13 @@ export interface CaseReceiptLine {
2308
2313
  productId?: string;
2309
2314
  /** The product's cover photo, when it has one. */
2310
2315
  coverUrl?: string;
2316
+ /** AGF-PRODUCT-SKU — the product's inventory code as it is now (absent: none, or an older platform). */
2317
+ sku?: string;
2318
+ }
2319
+ /** One option group's choice on a proposed alternative: the group and what was picked in it (ids, or names). */
2320
+ export interface CaseProposalSwapOption {
2321
+ group: string;
2322
+ options: string[];
2311
2323
  }
2312
2324
  /** AGF-PDK-DISPATCH-PROPOSAL — one change to a line: out of stock, or swapped for another product. */
2313
2325
  export interface CaseProposalChange {
@@ -2325,8 +2337,12 @@ export interface CaseProposalChange {
2325
2337
  unitCents: number | null;
2326
2338
  currency: string;
2327
2339
  coverUrl: string | null;
2328
- /** What it costs for the line's quantity; null when that cannot be said. */
2340
+ /** What it costs for the line's quantity, options included; null when that cannot be said. */
2329
2341
  amountCents: number | null;
2342
+ /** The choice made on the alternative (group id → option ids). Absent: none, or an older platform. */
2343
+ options?: CaseProposalSwapOption[];
2344
+ /** The choice as the customer reads it («Arroz, Sin cebolla»). */
2345
+ optionsLabel?: string;
2330
2346
  };
2331
2347
  /** The answer to an alternative (an out-of-stock line is always `drop`); absent while pending. */
2332
2348
  answer?: 'keep' | 'drop';
@@ -2358,8 +2374,10 @@ export interface CaseProposalInput {
2358
2374
  out: true;
2359
2375
  } | {
2360
2376
  line: string;
2377
+ /** `options`: required when the alternative has a required option group (refused at propose time otherwise). */
2361
2378
  swap: {
2362
2379
  productId: string;
2380
+ options?: CaseProposalSwapOption[];
2363
2381
  };
2364
2382
  }>;
2365
2383
  /** Words for the customer (≤ 500). */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentforge-io/sdk-server",
3
- "version": "4.58.0",
3
+ "version": "4.60.0",
4
4
  "description": "Server-side SDK for backend apps integrating with AgentForge platform. Auth via ChatToken, ak_live_ API key or App secret (sk_live_), with App installations across tenants.",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",