@endora-commerce/contracts 0.108.0 → 0.110.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 (309) hide show
  1. package/dist/actor.d.ts +16 -0
  2. package/dist/actor.d.ts.map +1 -1
  3. package/dist/addresses.d.ts +35 -0
  4. package/dist/addresses.d.ts.map +1 -1
  5. package/dist/addresses.js +8 -1
  6. package/dist/addresses.js.map +1 -1
  7. package/dist/admin-actions.d.ts +12 -3
  8. package/dist/admin-actions.d.ts.map +1 -1
  9. package/dist/admin-actions.js +34 -3
  10. package/dist/admin-actions.js.map +1 -1
  11. package/dist/admin-contributions.d.ts +94 -10
  12. package/dist/admin-contributions.d.ts.map +1 -1
  13. package/dist/admin-contributions.js +65 -0
  14. package/dist/admin-contributions.js.map +1 -1
  15. package/dist/admin-notifications.d.ts +17 -1
  16. package/dist/admin-notifications.d.ts.map +1 -1
  17. package/dist/admin-preferences.d.ts +108 -0
  18. package/dist/admin-preferences.d.ts.map +1 -0
  19. package/dist/admin-preferences.js +133 -0
  20. package/dist/admin-preferences.js.map +1 -0
  21. package/dist/admin-roles.d.ts +8 -2
  22. package/dist/admin-roles.d.ts.map +1 -1
  23. package/dist/admin-roles.js.map +1 -1
  24. package/dist/admin-users.d.ts +9 -0
  25. package/dist/admin-users.d.ts.map +1 -1
  26. package/dist/admin.d.ts +92 -5
  27. package/dist/admin.d.ts.map +1 -1
  28. package/dist/admin.js +86 -3
  29. package/dist/admin.js.map +1 -1
  30. package/dist/assets-library.d.ts +123 -3
  31. package/dist/assets-library.d.ts.map +1 -1
  32. package/dist/assets-library.js +11 -3
  33. package/dist/assets-library.js.map +1 -1
  34. package/dist/audit-logs.d.ts +12 -0
  35. package/dist/audit-logs.d.ts.map +1 -1
  36. package/dist/audit-logs.js +12 -0
  37. package/dist/audit-logs.js.map +1 -1
  38. package/dist/blog.d.ts +431 -14
  39. package/dist/blog.d.ts.map +1 -1
  40. package/dist/blog.js +251 -7
  41. package/dist/blog.js.map +1 -1
  42. package/dist/carts.d.ts +507 -92
  43. package/dist/carts.d.ts.map +1 -1
  44. package/dist/carts.js +197 -21
  45. package/dist/carts.js.map +1 -1
  46. package/dist/catalog.d.ts +515 -144
  47. package/dist/catalog.d.ts.map +1 -1
  48. package/dist/catalog.js +356 -68
  49. package/dist/catalog.js.map +1 -1
  50. package/dist/cms-brand.d.ts +2233 -0
  51. package/dist/cms-brand.d.ts.map +1 -0
  52. package/dist/cms-brand.js +311 -0
  53. package/dist/cms-brand.js.map +1 -0
  54. package/dist/cms-contact-form.d.ts +55 -0
  55. package/dist/cms-contact-form.d.ts.map +1 -0
  56. package/dist/cms-contact-form.js +100 -0
  57. package/dist/cms-contact-form.js.map +1 -0
  58. package/dist/cms.d.ts +576 -17
  59. package/dist/cms.d.ts.map +1 -1
  60. package/dist/cms.js +251 -0
  61. package/dist/cms.js.map +1 -1
  62. package/dist/common.d.ts +23 -6
  63. package/dist/common.d.ts.map +1 -1
  64. package/dist/common.js +25 -2
  65. package/dist/common.js.map +1 -1
  66. package/dist/comparisons.d.ts +28 -21
  67. package/dist/comparisons.d.ts.map +1 -1
  68. package/dist/comparisons.js +2 -1
  69. package/dist/comparisons.js.map +1 -1
  70. package/dist/credit-limits.d.ts +1 -0
  71. package/dist/credit-limits.d.ts.map +1 -1
  72. package/dist/credit-limits.js +14 -0
  73. package/dist/credit-limits.js.map +1 -1
  74. package/dist/crm-rich-text.d.ts +10 -61
  75. package/dist/crm-rich-text.d.ts.map +1 -1
  76. package/dist/crm-rich-text.js +10 -300
  77. package/dist/crm-rich-text.js.map +1 -1
  78. package/dist/crm.d.ts +173 -115
  79. package/dist/crm.d.ts.map +1 -1
  80. package/dist/crm.js +35 -88
  81. package/dist/crm.js.map +1 -1
  82. package/dist/custom-fields.d.ts +54 -22
  83. package/dist/custom-fields.d.ts.map +1 -1
  84. package/dist/custom-fields.js +21 -1
  85. package/dist/custom-fields.js.map +1 -1
  86. package/dist/customer-accounts.d.ts +216 -22
  87. package/dist/customer-accounts.d.ts.map +1 -1
  88. package/dist/customer-accounts.js +70 -0
  89. package/dist/customer-accounts.js.map +1 -1
  90. package/dist/customers.d.ts +40 -73
  91. package/dist/customers.d.ts.map +1 -1
  92. package/dist/customers.js +45 -10
  93. package/dist/customers.js.map +1 -1
  94. package/dist/document-templates.d.ts +35 -23
  95. package/dist/document-templates.d.ts.map +1 -1
  96. package/dist/document-values.d.ts +8 -0
  97. package/dist/document-values.d.ts.map +1 -1
  98. package/dist/document-values.js +24 -6
  99. package/dist/document-values.js.map +1 -1
  100. package/dist/email.d.ts +5 -0
  101. package/dist/email.d.ts.map +1 -1
  102. package/dist/errors.d.ts +224 -1
  103. package/dist/errors.d.ts.map +1 -1
  104. package/dist/errors.js +269 -1
  105. package/dist/errors.js.map +1 -1
  106. package/dist/forms-logic.d.ts +79 -0
  107. package/dist/forms-logic.d.ts.map +1 -0
  108. package/dist/forms-logic.fixtures.d.ts +52 -0
  109. package/dist/forms-logic.fixtures.d.ts.map +1 -0
  110. package/dist/forms-logic.fixtures.js +610 -0
  111. package/dist/forms-logic.fixtures.js.map +1 -0
  112. package/dist/forms-logic.js +699 -0
  113. package/dist/forms-logic.js.map +1 -0
  114. package/dist/forms.d.ts +9833 -0
  115. package/dist/forms.d.ts.map +1 -0
  116. package/dist/forms.js +827 -0
  117. package/dist/forms.js.map +1 -0
  118. package/dist/import-export.d.ts +180 -0
  119. package/dist/import-export.d.ts.map +1 -1
  120. package/dist/import-export.js +60 -0
  121. package/dist/import-export.js.map +1 -1
  122. package/dist/index.d.ts +22 -1
  123. package/dist/index.d.ts.map +1 -1
  124. package/dist/index.js +45 -1
  125. package/dist/index.js.map +1 -1
  126. package/dist/inventory.d.ts +6 -6
  127. package/dist/invoice-ledger.d.ts +7 -7
  128. package/dist/invoices.d.ts +6 -2
  129. package/dist/invoices.d.ts.map +1 -1
  130. package/dist/invoices.js +7 -0
  131. package/dist/invoices.js.map +1 -1
  132. package/dist/megamenu.d.ts +674 -0
  133. package/dist/megamenu.d.ts.map +1 -1
  134. package/dist/megamenu.js +96 -3
  135. package/dist/megamenu.js.map +1 -1
  136. package/dist/mfa.d.ts +125 -4
  137. package/dist/mfa.d.ts.map +1 -1
  138. package/dist/mfa.js +54 -2
  139. package/dist/mfa.js.map +1 -1
  140. package/dist/modules.d.ts +44 -5
  141. package/dist/modules.d.ts.map +1 -1
  142. package/dist/modules.js +73 -0
  143. package/dist/modules.js.map +1 -1
  144. package/dist/money-decimal.d.ts +54 -0
  145. package/dist/money-decimal.d.ts.map +1 -1
  146. package/dist/money-decimal.js +95 -0
  147. package/dist/money-decimal.js.map +1 -1
  148. package/dist/newsletter.d.ts +7 -7
  149. package/dist/orders.d.ts +128 -10
  150. package/dist/orders.d.ts.map +1 -1
  151. package/dist/orders.js +74 -4
  152. package/dist/orders.js.map +1 -1
  153. package/dist/organization-registry-lookup.d.ts +362 -0
  154. package/dist/organization-registry-lookup.d.ts.map +1 -0
  155. package/dist/organization-registry-lookup.js +196 -0
  156. package/dist/organization-registry-lookup.js.map +1 -0
  157. package/dist/organization-roles.d.ts +340 -0
  158. package/dist/organization-roles.d.ts.map +1 -0
  159. package/dist/organization-roles.js +211 -0
  160. package/dist/organization-roles.js.map +1 -0
  161. package/dist/organizations.d.ts +123 -89
  162. package/dist/organizations.d.ts.map +1 -1
  163. package/dist/organizations.js +68 -24
  164. package/dist/organizations.js.map +1 -1
  165. package/dist/page-builder-props.d.ts +1401 -0
  166. package/dist/page-builder-props.d.ts.map +1 -0
  167. package/dist/page-builder-props.js +266 -0
  168. package/dist/page-builder-props.js.map +1 -0
  169. package/dist/page-builder-values.d.ts +95 -0
  170. package/dist/page-builder-values.d.ts.map +1 -0
  171. package/dist/page-builder-values.js +164 -0
  172. package/dist/page-builder-values.js.map +1 -0
  173. package/dist/pim-connector.d.ts +6 -2
  174. package/dist/pim-connector.d.ts.map +1 -1
  175. package/dist/pim-connector.js +6 -2
  176. package/dist/pim-connector.js.map +1 -1
  177. package/dist/pim-field-path.d.ts +5 -1
  178. package/dist/pim-field-path.d.ts.map +1 -1
  179. package/dist/pim-field-path.js +37 -81
  180. package/dist/pim-field-path.js.map +1 -1
  181. package/dist/pim-locale-mapping.d.ts +131 -0
  182. package/dist/pim-locale-mapping.d.ts.map +1 -0
  183. package/dist/pim-locale-mapping.js +193 -0
  184. package/dist/pim-locale-mapping.js.map +1 -0
  185. package/dist/platform-language.d.ts +9 -0
  186. package/dist/platform-language.d.ts.map +1 -1
  187. package/dist/platform-language.js +14 -0
  188. package/dist/platform-language.js.map +1 -1
  189. package/dist/price-books.d.ts +47 -43
  190. package/dist/price-books.d.ts.map +1 -1
  191. package/dist/price-books.js +6 -2
  192. package/dist/price-books.js.map +1 -1
  193. package/dist/price-lists.d.ts +48 -14
  194. package/dist/price-lists.d.ts.map +1 -1
  195. package/dist/price-lists.js +24 -1
  196. package/dist/price-lists.js.map +1 -1
  197. package/dist/product-feeds.d.ts +144 -84
  198. package/dist/product-feeds.d.ts.map +1 -1
  199. package/dist/product-feeds.js +23 -0
  200. package/dist/product-feeds.js.map +1 -1
  201. package/dist/product-scope-model.d.ts +161 -0
  202. package/dist/product-scope-model.d.ts.map +1 -0
  203. package/dist/product-scope-model.js +161 -0
  204. package/dist/product-scope-model.js.map +1 -0
  205. package/dist/product-scope-overrides.d.ts +0 -103
  206. package/dist/product-scope-overrides.d.ts.map +1 -1
  207. package/dist/product-scope-overrides.js +0 -54
  208. package/dist/product-scope-overrides.js.map +1 -1
  209. package/dist/product-scoped-values.d.ts +2610 -0
  210. package/dist/product-scoped-values.d.ts.map +1 -0
  211. package/dist/product-scoped-values.js +425 -0
  212. package/dist/product-scoped-values.js.map +1 -0
  213. package/dist/product-scopes.d.ts +746 -0
  214. package/dist/product-scopes.d.ts.map +1 -0
  215. package/dist/product-scopes.js +436 -0
  216. package/dist/product-scopes.js.map +1 -0
  217. package/dist/product-summary-text.d.ts +23 -0
  218. package/dist/product-summary-text.d.ts.map +1 -0
  219. package/dist/product-summary-text.js +64 -0
  220. package/dist/product-summary-text.js.map +1 -0
  221. package/dist/product-tax-rates.d.ts +38 -0
  222. package/dist/product-tax-rates.d.ts.map +1 -0
  223. package/dist/product-tax-rates.js +45 -0
  224. package/dist/product-tax-rates.js.map +1 -0
  225. package/dist/product-url-keys.d.ts +210 -0
  226. package/dist/product-url-keys.d.ts.map +1 -0
  227. package/dist/product-url-keys.js +200 -0
  228. package/dist/product-url-keys.js.map +1 -0
  229. package/dist/product-value-resolver.d.ts +37 -60
  230. package/dist/product-value-resolver.d.ts.map +1 -1
  231. package/dist/product-value-resolver.js +36 -96
  232. package/dist/product-value-resolver.js.map +1 -1
  233. package/dist/projects.d.ts +2370 -0
  234. package/dist/projects.d.ts.map +1 -0
  235. package/dist/projects.js +843 -0
  236. package/dist/projects.js.map +1 -0
  237. package/dist/promotions.d.ts +10 -10
  238. package/dist/prompt-actions.d.ts +19 -1
  239. package/dist/prompt-actions.d.ts.map +1 -1
  240. package/dist/prompt-actions.js +31 -2
  241. package/dist/prompt-actions.js.map +1 -1
  242. package/dist/pwa.d.ts +2 -2
  243. package/dist/quick-order.d.ts +150 -7
  244. package/dist/quick-order.d.ts.map +1 -1
  245. package/dist/quick-order.js +76 -2
  246. package/dist/quick-order.js.map +1 -1
  247. package/dist/quote-requests.d.ts +99 -13
  248. package/dist/quote-requests.d.ts.map +1 -1
  249. package/dist/quote-requests.js +66 -1
  250. package/dist/quote-requests.js.map +1 -1
  251. package/dist/record-references.d.ts +252 -0
  252. package/dist/record-references.d.ts.map +1 -0
  253. package/dist/record-references.js +178 -0
  254. package/dist/record-references.js.map +1 -0
  255. package/dist/record-rich-text.d.ts +66 -0
  256. package/dist/record-rich-text.d.ts.map +1 -0
  257. package/dist/record-rich-text.js +304 -0
  258. package/dist/record-rich-text.js.map +1 -0
  259. package/dist/returns.d.ts +234 -52
  260. package/dist/returns.d.ts.map +1 -1
  261. package/dist/returns.js +139 -26
  262. package/dist/returns.js.map +1 -1
  263. package/dist/sales-channels.d.ts +51 -7
  264. package/dist/sales-channels.d.ts.map +1 -1
  265. package/dist/sales-channels.js +38 -4
  266. package/dist/sales-channels.js.map +1 -1
  267. package/dist/saved-list-views.d.ts +56 -0
  268. package/dist/saved-list-views.d.ts.map +1 -1
  269. package/dist/saved-list-views.js +27 -1
  270. package/dist/saved-list-views.js.map +1 -1
  271. package/dist/scoped-write-encoding.d.ts +100 -0
  272. package/dist/scoped-write-encoding.d.ts.map +1 -0
  273. package/dist/scoped-write-encoding.js +135 -0
  274. package/dist/scoped-write-encoding.js.map +1 -0
  275. package/dist/search.d.ts +25 -15
  276. package/dist/search.d.ts.map +1 -1
  277. package/dist/seo.d.ts +127 -15
  278. package/dist/seo.d.ts.map +1 -1
  279. package/dist/seo.js +38 -4
  280. package/dist/seo.js.map +1 -1
  281. package/dist/settings.d.ts +161 -3
  282. package/dist/settings.d.ts.map +1 -1
  283. package/dist/settings.js +73 -3
  284. package/dist/settings.js.map +1 -1
  285. package/dist/shopping-lists.d.ts +24 -3
  286. package/dist/shopping-lists.d.ts.map +1 -1
  287. package/dist/shopping-lists.js +20 -0
  288. package/dist/shopping-lists.js.map +1 -1
  289. package/dist/storefront-cache-tags.d.ts +41 -0
  290. package/dist/storefront-cache-tags.d.ts.map +1 -1
  291. package/dist/storefront-cache-tags.js +36 -0
  292. package/dist/storefront-cache-tags.js.map +1 -1
  293. package/dist/storefront-language-path.d.ts +77 -0
  294. package/dist/storefront-language-path.d.ts.map +1 -0
  295. package/dist/storefront-language-path.js +123 -0
  296. package/dist/storefront-language-path.js.map +1 -0
  297. package/dist/storefront-value-overrides.d.ts +18 -56
  298. package/dist/storefront-value-overrides.d.ts.map +1 -1
  299. package/dist/storefront-value-overrides.js +11 -86
  300. package/dist/storefront-value-overrides.js.map +1 -1
  301. package/dist/tasks.d.ts +2842 -0
  302. package/dist/tasks.d.ts.map +1 -0
  303. package/dist/tasks.js +901 -0
  304. package/dist/tasks.js.map +1 -0
  305. package/dist/transactional-emails.d.ts +14 -11
  306. package/dist/transactional-emails.d.ts.map +1 -1
  307. package/dist/transactional-emails.js +13 -0
  308. package/dist/transactional-emails.js.map +1 -1
  309. package/package.json +3 -3
package/dist/crm.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import { z } from 'zod';
2
+ import { type RecordReferenceType } from './record-references.js';
2
3
  /**
3
4
  * CRM — Sales Opportunities (`specs/143-crm-sales-opportunities/`).
4
5
  *
@@ -34,9 +35,9 @@ export declare const opportunityValueModeSchema: z.ZodEnum<{
34
35
  }>;
35
36
  export type OpportunityValueMode = z.infer<typeof opportunityValueModeSchema>;
36
37
  export declare const opportunitySourceSchema: z.ZodEnum<{
38
+ manual: "manual";
37
39
  order: "order";
38
40
  quote_request: "quote_request";
39
- manual: "manual";
40
41
  }>;
41
42
  export type OpportunitySource = z.infer<typeof opportunitySourceSchema>;
42
43
  export declare const opportunityDocumentKindSchema: z.ZodEnum<{
@@ -67,8 +68,8 @@ export declare const propagationOutcomeKindSchema: z.ZodEnum<{
67
68
  pending: "pending";
68
69
  failed: "failed";
69
70
  skipped: "skipped";
70
- not_found: "not_found";
71
71
  applied: "applied";
72
+ not_found: "not_found";
72
73
  already_there: "already_there";
73
74
  unknown_status: "unknown_status";
74
75
  not_permitted: "not_permitted";
@@ -81,78 +82,34 @@ export declare const opportunityCommentKindSchema: z.ZodEnum<{
81
82
  }>;
82
83
  export type OpportunityCommentKind = z.infer<typeof opportunityCommentKindSchema>;
83
84
  /**
84
- * What a free text can refer to. `admin_user` is a person — a user of the Admin
85
- * UI, under the name the platform has for one everywhere else (the bell's
86
- * audience, `assignedAdminUserId`); `user` alone would also read as a customer.
85
+ * What a free text can refer to — the shared reference types of
86
+ * `record-references.ts` (`specs/163-projects-and-tasks/` research R-14): a
87
+ * Product, an Order, a person (`admin_user`), and since that feature a Quote
88
+ * Request and a Task. An alias, not a copy: CRM and Projects read one grammar.
87
89
  */
88
90
  export declare const opportunityReferenceTypeSchema: z.ZodEnum<{
91
+ product: "product";
89
92
  order: "order";
90
93
  admin_user: "admin_user";
91
- product: "product";
94
+ quote_request: "quote_request";
95
+ task: "task";
96
+ opportunity: "opportunity";
97
+ project: "project";
92
98
  }>;
93
- export type OpportunityReferenceType = z.infer<typeof opportunityReferenceTypeSchema>;
99
+ export type OpportunityReferenceType = RecordReferenceType;
94
100
  /** The six `QuoteRequestStatus` values — a fixed union, unlike Order statuses. */
95
101
  export declare const QUOTE_REQUEST_STATUS_VALUES: readonly ["Created from admin", "Pending", "Canceled", "Approved", "Completed", "Expired"];
96
- export interface OpportunityReferenceToken {
97
- type: OpportunityReferenceType;
98
- id: string;
99
- }
100
- export declare function formatOpportunityReferenceToken(type: OpportunityReferenceType, id: string): string;
101
- /** Every well-formed token in `text`, in first-appearance order, each target once. */
102
- export declare function extractOpportunityReferenceTokens(text: string): OpportunityReferenceToken[];
103
- /** A stretch of plain text, or one well-formed token, in the order they appear. */
104
- export type OpportunityReferenceTextPart = {
105
- kind: 'text';
106
- text: string;
107
- } | ({
108
- kind: 'reference';
109
- } & OpportunityReferenceToken);
110
102
  /**
111
- * `text` cut at its well-formed tokens, for a screen that shows each token as
112
- * a link: the parts, joined back, are the text. A malformed token stays text.
113
- */
114
- export declare function splitOpportunityReferenceText(text: string): OpportunityReferenceTextPart[];
115
- /** The people a text mentions, each once, in first-appearance order. */
116
- export declare function mentionedAdminUserIds(text: string | null | undefined): string[];
117
- /**
118
- * A resolved reference, returned beside every free-text field. A target the
119
- * reader may not see, or that is gone, is `available: false` with no label.
120
- * A person has a `label` — their name — and never a `url`: the screen of an
121
- * administrator is `admin_users`', behind a permission of its own.
122
- */
123
- /**
124
- * What an available Order reference says beyond its number
125
- * (`specs/158-crm-opportunity-inline-editing/`, FR-012): its status code — the
126
- * screen names it from `orders`' statuses — its total, when it was placed and
127
- * for whom (the billing company, else the billing recipient).
103
+ * The reference-token grammar: `[[<type>:<uuid>]]` for the five types of
104
+ * {@link opportunityReferenceTypeSchema}.
105
+ *
106
+ * Written once, in `record-references.ts` (`specs/163-projects-and-tasks/`
107
+ * research R-14, FR-044), and exported here under the names CRM has always
108
+ * exported — each an **alias** of the shared function or schema, never a copy,
109
+ * so CRM and Projects cannot drift. What a person types to get one — `@`, `@@`,
110
+ * `@@@` — is the composer's and is never stored.
128
111
  */
129
- export declare const OpportunityReferenceOrderSchema: z.ZodObject<{
130
- status: z.ZodString;
131
- total: z.ZodString;
132
- currency: z.ZodString;
133
- placedAt: z.ZodString;
134
- customerName: z.ZodNullable<z.ZodString>;
135
- }, z.core.$strip>;
136
- export type OpportunityReferenceOrder = z.infer<typeof OpportunityReferenceOrderSchema>;
137
- export declare const OpportunityReferenceSchema: z.ZodObject<{
138
- type: z.ZodEnum<{
139
- order: "order";
140
- admin_user: "admin_user";
141
- product: "product";
142
- }>;
143
- id: z.ZodString;
144
- available: z.ZodBoolean;
145
- label: z.ZodNullable<z.ZodString>;
146
- url: z.ZodNullable<z.ZodString>;
147
- order: z.ZodOptional<z.ZodObject<{
148
- status: z.ZodString;
149
- total: z.ZodString;
150
- currency: z.ZodString;
151
- placedAt: z.ZodString;
152
- customerName: z.ZodNullable<z.ZodString>;
153
- }, z.core.$strip>>;
154
- }, z.core.$strip>;
155
- export type OpportunityReference = z.infer<typeof OpportunityReferenceSchema>;
112
+ export { extractRecordReferenceTokens as extractOpportunityReferenceTokens, formatRecordReferenceToken as formatOpportunityReferenceToken, mentionedAdminUserIds, RecordReferenceOrderSchema as OpportunityReferenceOrderSchema, RecordReferenceSchema as OpportunityReferenceSchema, splitRecordReferenceText as splitOpportunityReferenceText, type RecordReference as OpportunityReference, type RecordReferenceOrder as OpportunityReferenceOrder, type RecordReferenceTextPart as OpportunityReferenceTextPart, type RecordReferenceToken as OpportunityReferenceToken, } from './record-references.js';
156
113
  export declare const opportunityStateSchema: z.ZodEnum<{
157
114
  open: "open";
158
115
  won: "won";
@@ -182,10 +139,10 @@ export declare const opportunityBoardFieldKindSchema: z.ZodEnum<{
182
139
  boolean: "boolean";
183
140
  date: "date";
184
141
  text: "text";
185
- select: "select";
186
- tags: "tags";
187
142
  contact: "contact";
188
143
  multiselect: "multiselect";
144
+ select: "select";
145
+ tags: "tags";
189
146
  organization: "organization";
190
147
  salesChannel: "salesChannel";
191
148
  assignee: "assignee";
@@ -204,10 +161,10 @@ export declare const OpportunityBoardCardFieldSchema: z.ZodObject<{
204
161
  boolean: "boolean";
205
162
  date: "date";
206
163
  text: "text";
207
- select: "select";
208
- tags: "tags";
209
164
  contact: "contact";
210
165
  multiselect: "multiselect";
166
+ select: "select";
167
+ tags: "tags";
211
168
  organization: "organization";
212
169
  salesChannel: "salesChannel";
213
170
  assignee: "assignee";
@@ -239,10 +196,10 @@ export declare const OpportunityBoardCardConfigSchema: z.ZodObject<{
239
196
  boolean: "boolean";
240
197
  date: "date";
241
198
  text: "text";
242
- select: "select";
243
- tags: "tags";
244
199
  contact: "contact";
245
200
  multiselect: "multiselect";
201
+ select: "select";
202
+ tags: "tags";
246
203
  organization: "organization";
247
204
  salesChannel: "salesChannel";
248
205
  assignee: "assignee";
@@ -268,10 +225,10 @@ export declare const OpportunityBoardCardConfigSchema: z.ZodObject<{
268
225
  boolean: "boolean";
269
226
  date: "date";
270
227
  text: "text";
271
- select: "select";
272
- tags: "tags";
273
228
  contact: "contact";
274
229
  multiselect: "multiselect";
230
+ select: "select";
231
+ tags: "tags";
275
232
  organization: "organization";
276
233
  salesChannel: "salesChannel";
277
234
  assignee: "assignee";
@@ -302,10 +259,10 @@ export declare const OpportunityBoardCardConfigResponseSchema: z.ZodObject<{
302
259
  boolean: "boolean";
303
260
  date: "date";
304
261
  text: "text";
305
- select: "select";
306
- tags: "tags";
307
262
  contact: "contact";
308
263
  multiselect: "multiselect";
264
+ select: "select";
265
+ tags: "tags";
309
266
  organization: "organization";
310
267
  salesChannel: "salesChannel";
311
268
  assignee: "assignee";
@@ -331,10 +288,10 @@ export declare const OpportunityBoardCardConfigResponseSchema: z.ZodObject<{
331
288
  boolean: "boolean";
332
289
  date: "date";
333
290
  text: "text";
334
- select: "select";
335
- tags: "tags";
336
291
  contact: "contact";
337
292
  multiselect: "multiselect";
293
+ select: "select";
294
+ tags: "tags";
338
295
  organization: "organization";
339
296
  salesChannel: "salesChannel";
340
297
  assignee: "assignee";
@@ -448,10 +405,10 @@ export type CreateOpportunityRequest = z.infer<typeof CreateOpportunityRequestSc
448
405
  export declare const UpdateOpportunityRequestSchema: z.ZodObject<{
449
406
  description: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
450
407
  title: z.ZodOptional<z.ZodString>;
451
- salesChannelId: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
452
408
  customerAccountId: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
453
- tagIds: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodString>>>;
454
409
  customFieldValues: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
410
+ salesChannelId: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
411
+ tagIds: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodString>>>;
455
412
  assignedAdminUserId: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
456
413
  expectedCloseDate: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
457
414
  valueMode: z.ZodOptional<z.ZodOptional<z.ZodEnum<{
@@ -554,6 +511,11 @@ export declare const OpportunityLinkSchema: z.ZodObject<{
554
511
  status: z.ZodOptional<z.ZodString>;
555
512
  total: z.ZodOptional<z.ZodString>;
556
513
  currency: z.ZodOptional<z.ZodString>;
514
+ agreement: z.ZodOptional<z.ZodEnum<{
515
+ none: "none";
516
+ agreed: "agreed";
517
+ partial: "partial";
518
+ }>>;
557
519
  syncStatus: z.ZodBoolean;
558
520
  linkSource: z.ZodEnum<{
559
521
  manual: "manual";
@@ -581,8 +543,8 @@ export declare const PropagationOutcomeSchema: z.ZodObject<{
581
543
  outcome: z.ZodEnum<{
582
544
  failed: "failed";
583
545
  skipped: "skipped";
584
- not_found: "not_found";
585
546
  applied: "applied";
547
+ not_found: "not_found";
586
548
  already_there: "already_there";
587
549
  unknown_status: "unknown_status";
588
550
  not_permitted: "not_permitted";
@@ -648,9 +610,13 @@ export declare const OpportunityDetailSchema: z.ZodObject<{
648
610
  description: z.ZodNullable<z.ZodString>;
649
611
  references: z.ZodArray<z.ZodObject<{
650
612
  type: z.ZodEnum<{
613
+ product: "product";
651
614
  order: "order";
652
615
  admin_user: "admin_user";
653
- product: "product";
616
+ quote_request: "quote_request";
617
+ task: "task";
618
+ opportunity: "opportunity";
619
+ project: "project";
654
620
  }>;
655
621
  id: z.ZodString;
656
622
  available: z.ZodBoolean;
@@ -680,9 +646,9 @@ export declare const OpportunityDetailSchema: z.ZodObject<{
680
646
  reason: z.ZodString;
681
647
  }, z.core.$strip>>;
682
648
  source: z.ZodEnum<{
649
+ manual: "manual";
683
650
  order: "order";
684
651
  quote_request: "quote_request";
685
- manual: "manual";
686
652
  }>;
687
653
  version: z.ZodNumber;
688
654
  allowedTransitions: z.ZodArray<z.ZodObject<{
@@ -707,6 +673,11 @@ export declare const OpportunityDetailSchema: z.ZodObject<{
707
673
  status: z.ZodOptional<z.ZodString>;
708
674
  total: z.ZodOptional<z.ZodString>;
709
675
  currency: z.ZodOptional<z.ZodString>;
676
+ agreement: z.ZodOptional<z.ZodEnum<{
677
+ none: "none";
678
+ agreed: "agreed";
679
+ partial: "partial";
680
+ }>>;
710
681
  syncStatus: z.ZodBoolean;
711
682
  linkSource: z.ZodEnum<{
712
683
  manual: "manual";
@@ -728,8 +699,8 @@ export declare const OpportunityDetailSchema: z.ZodObject<{
728
699
  outcome: z.ZodEnum<{
729
700
  failed: "failed";
730
701
  skipped: "skipped";
731
- not_found: "not_found";
732
702
  applied: "applied";
703
+ not_found: "not_found";
733
704
  already_there: "already_there";
734
705
  unknown_status: "unknown_status";
735
706
  not_permitted: "not_permitted";
@@ -793,9 +764,13 @@ export declare const OpportunityTransitionResultSchema: z.ZodObject<{
793
764
  description: z.ZodNullable<z.ZodString>;
794
765
  references: z.ZodArray<z.ZodObject<{
795
766
  type: z.ZodEnum<{
767
+ product: "product";
796
768
  order: "order";
797
769
  admin_user: "admin_user";
798
- product: "product";
770
+ quote_request: "quote_request";
771
+ task: "task";
772
+ opportunity: "opportunity";
773
+ project: "project";
799
774
  }>;
800
775
  id: z.ZodString;
801
776
  available: z.ZodBoolean;
@@ -825,9 +800,9 @@ export declare const OpportunityTransitionResultSchema: z.ZodObject<{
825
800
  reason: z.ZodString;
826
801
  }, z.core.$strip>>;
827
802
  source: z.ZodEnum<{
803
+ manual: "manual";
828
804
  order: "order";
829
805
  quote_request: "quote_request";
830
- manual: "manual";
831
806
  }>;
832
807
  version: z.ZodNumber;
833
808
  allowedTransitions: z.ZodArray<z.ZodObject<{
@@ -852,6 +827,11 @@ export declare const OpportunityTransitionResultSchema: z.ZodObject<{
852
827
  status: z.ZodOptional<z.ZodString>;
853
828
  total: z.ZodOptional<z.ZodString>;
854
829
  currency: z.ZodOptional<z.ZodString>;
830
+ agreement: z.ZodOptional<z.ZodEnum<{
831
+ none: "none";
832
+ agreed: "agreed";
833
+ partial: "partial";
834
+ }>>;
855
835
  syncStatus: z.ZodBoolean;
856
836
  linkSource: z.ZodEnum<{
857
837
  manual: "manual";
@@ -873,8 +853,8 @@ export declare const OpportunityTransitionResultSchema: z.ZodObject<{
873
853
  outcome: z.ZodEnum<{
874
854
  failed: "failed";
875
855
  skipped: "skipped";
876
- not_found: "not_found";
877
856
  applied: "applied";
857
+ not_found: "not_found";
878
858
  already_there: "already_there";
879
859
  unknown_status: "unknown_status";
880
860
  not_permitted: "not_permitted";
@@ -903,8 +883,8 @@ export declare const OpportunityTransitionResultSchema: z.ZodObject<{
903
883
  outcome: z.ZodEnum<{
904
884
  failed: "failed";
905
885
  skipped: "skipped";
906
- not_found: "not_found";
907
886
  applied: "applied";
887
+ not_found: "not_found";
908
888
  already_there: "already_there";
909
889
  unknown_status: "unknown_status";
910
890
  not_permitted: "not_permitted";
@@ -1062,9 +1042,13 @@ export declare const OpportunityDetailResponseSchema: z.ZodObject<{
1062
1042
  description: z.ZodNullable<z.ZodString>;
1063
1043
  references: z.ZodArray<z.ZodObject<{
1064
1044
  type: z.ZodEnum<{
1045
+ product: "product";
1065
1046
  order: "order";
1066
1047
  admin_user: "admin_user";
1067
- product: "product";
1048
+ quote_request: "quote_request";
1049
+ task: "task";
1050
+ opportunity: "opportunity";
1051
+ project: "project";
1068
1052
  }>;
1069
1053
  id: z.ZodString;
1070
1054
  available: z.ZodBoolean;
@@ -1094,9 +1078,9 @@ export declare const OpportunityDetailResponseSchema: z.ZodObject<{
1094
1078
  reason: z.ZodString;
1095
1079
  }, z.core.$strip>>;
1096
1080
  source: z.ZodEnum<{
1081
+ manual: "manual";
1097
1082
  order: "order";
1098
1083
  quote_request: "quote_request";
1099
- manual: "manual";
1100
1084
  }>;
1101
1085
  version: z.ZodNumber;
1102
1086
  allowedTransitions: z.ZodArray<z.ZodObject<{
@@ -1121,6 +1105,11 @@ export declare const OpportunityDetailResponseSchema: z.ZodObject<{
1121
1105
  status: z.ZodOptional<z.ZodString>;
1122
1106
  total: z.ZodOptional<z.ZodString>;
1123
1107
  currency: z.ZodOptional<z.ZodString>;
1108
+ agreement: z.ZodOptional<z.ZodEnum<{
1109
+ none: "none";
1110
+ agreed: "agreed";
1111
+ partial: "partial";
1112
+ }>>;
1124
1113
  syncStatus: z.ZodBoolean;
1125
1114
  linkSource: z.ZodEnum<{
1126
1115
  manual: "manual";
@@ -1142,8 +1131,8 @@ export declare const OpportunityDetailResponseSchema: z.ZodObject<{
1142
1131
  outcome: z.ZodEnum<{
1143
1132
  failed: "failed";
1144
1133
  skipped: "skipped";
1145
- not_found: "not_found";
1146
1134
  applied: "applied";
1135
+ not_found: "not_found";
1147
1136
  already_there: "already_there";
1148
1137
  unknown_status: "unknown_status";
1149
1138
  not_permitted: "not_permitted";
@@ -1172,6 +1161,11 @@ export declare const OpportunityLinkResponseSchema: z.ZodObject<{
1172
1161
  status: z.ZodOptional<z.ZodString>;
1173
1162
  total: z.ZodOptional<z.ZodString>;
1174
1163
  currency: z.ZodOptional<z.ZodString>;
1164
+ agreement: z.ZodOptional<z.ZodEnum<{
1165
+ none: "none";
1166
+ agreed: "agreed";
1167
+ partial: "partial";
1168
+ }>>;
1175
1169
  syncStatus: z.ZodBoolean;
1176
1170
  linkSource: z.ZodEnum<{
1177
1171
  manual: "manual";
@@ -1231,9 +1225,13 @@ export declare const OpportunityTransitionResponseSchema: z.ZodObject<{
1231
1225
  description: z.ZodNullable<z.ZodString>;
1232
1226
  references: z.ZodArray<z.ZodObject<{
1233
1227
  type: z.ZodEnum<{
1228
+ product: "product";
1234
1229
  order: "order";
1235
1230
  admin_user: "admin_user";
1236
- product: "product";
1231
+ quote_request: "quote_request";
1232
+ task: "task";
1233
+ opportunity: "opportunity";
1234
+ project: "project";
1237
1235
  }>;
1238
1236
  id: z.ZodString;
1239
1237
  available: z.ZodBoolean;
@@ -1263,9 +1261,9 @@ export declare const OpportunityTransitionResponseSchema: z.ZodObject<{
1263
1261
  reason: z.ZodString;
1264
1262
  }, z.core.$strip>>;
1265
1263
  source: z.ZodEnum<{
1264
+ manual: "manual";
1266
1265
  order: "order";
1267
1266
  quote_request: "quote_request";
1268
- manual: "manual";
1269
1267
  }>;
1270
1268
  version: z.ZodNumber;
1271
1269
  allowedTransitions: z.ZodArray<z.ZodObject<{
@@ -1290,6 +1288,11 @@ export declare const OpportunityTransitionResponseSchema: z.ZodObject<{
1290
1288
  status: z.ZodOptional<z.ZodString>;
1291
1289
  total: z.ZodOptional<z.ZodString>;
1292
1290
  currency: z.ZodOptional<z.ZodString>;
1291
+ agreement: z.ZodOptional<z.ZodEnum<{
1292
+ none: "none";
1293
+ agreed: "agreed";
1294
+ partial: "partial";
1295
+ }>>;
1293
1296
  syncStatus: z.ZodBoolean;
1294
1297
  linkSource: z.ZodEnum<{
1295
1298
  manual: "manual";
@@ -1311,8 +1314,8 @@ export declare const OpportunityTransitionResponseSchema: z.ZodObject<{
1311
1314
  outcome: z.ZodEnum<{
1312
1315
  failed: "failed";
1313
1316
  skipped: "skipped";
1314
- not_found: "not_found";
1315
1317
  applied: "applied";
1318
+ not_found: "not_found";
1316
1319
  already_there: "already_there";
1317
1320
  unknown_status: "unknown_status";
1318
1321
  not_permitted: "not_permitted";
@@ -1341,8 +1344,8 @@ export declare const OpportunityTransitionResponseSchema: z.ZodObject<{
1341
1344
  outcome: z.ZodEnum<{
1342
1345
  failed: "failed";
1343
1346
  skipped: "skipped";
1344
- not_found: "not_found";
1345
1347
  applied: "applied";
1348
+ not_found: "not_found";
1346
1349
  already_there: "already_there";
1347
1350
  unknown_status: "unknown_status";
1348
1351
  not_permitted: "not_permitted";
@@ -1366,8 +1369,8 @@ export declare const PropagationOutcomeResponseSchema: z.ZodObject<{
1366
1369
  outcome: z.ZodEnum<{
1367
1370
  failed: "failed";
1368
1371
  skipped: "skipped";
1369
- not_found: "not_found";
1370
1372
  applied: "applied";
1373
+ not_found: "not_found";
1371
1374
  already_there: "already_there";
1372
1375
  unknown_status: "unknown_status";
1373
1376
  not_permitted: "not_permitted";
@@ -1394,12 +1397,12 @@ export type CreateOpportunityStatusRequest = z.infer<typeof CreateOpportunitySta
1394
1397
  /** `code` is immutable; strict, so a body naming it is refused. */
1395
1398
  export declare const UpdateOpportunityStatusRequestSchema: z.ZodObject<{
1396
1399
  weight: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
1400
+ name: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>>;
1397
1401
  kind: z.ZodOptional<z.ZodEnum<{
1398
1402
  open: "open";
1399
1403
  won: "won";
1400
1404
  lost: "lost";
1401
1405
  }>>;
1402
- name: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>>;
1403
1406
  color: z.ZodOptional<z.ZodOptional<z.ZodString>>;
1404
1407
  defaultName: z.ZodOptional<z.ZodString>;
1405
1408
  isInitial: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
@@ -1592,9 +1595,13 @@ export declare const OpportunityCommentSchema: z.ZodObject<{
1592
1595
  body: z.ZodString;
1593
1596
  references: z.ZodArray<z.ZodObject<{
1594
1597
  type: z.ZodEnum<{
1598
+ product: "product";
1595
1599
  order: "order";
1596
1600
  admin_user: "admin_user";
1597
- product: "product";
1601
+ quote_request: "quote_request";
1602
+ task: "task";
1603
+ opportunity: "opportunity";
1604
+ project: "project";
1598
1605
  }>;
1599
1606
  id: z.ZodString;
1600
1607
  available: z.ZodBoolean;
@@ -1626,9 +1633,13 @@ export declare const OpportunityCommentResponseSchema: z.ZodObject<{
1626
1633
  body: z.ZodString;
1627
1634
  references: z.ZodArray<z.ZodObject<{
1628
1635
  type: z.ZodEnum<{
1636
+ product: "product";
1629
1637
  order: "order";
1630
1638
  admin_user: "admin_user";
1631
- product: "product";
1639
+ quote_request: "quote_request";
1640
+ task: "task";
1641
+ opportunity: "opportunity";
1642
+ project: "project";
1632
1643
  }>;
1633
1644
  id: z.ZodString;
1634
1645
  available: z.ZodBoolean;
@@ -1665,9 +1676,13 @@ export declare const OpportunityCommentListResponseSchema: z.ZodObject<{
1665
1676
  body: z.ZodString;
1666
1677
  references: z.ZodArray<z.ZodObject<{
1667
1678
  type: z.ZodEnum<{
1679
+ product: "product";
1668
1680
  order: "order";
1669
1681
  admin_user: "admin_user";
1670
- product: "product";
1682
+ quote_request: "quote_request";
1683
+ task: "task";
1684
+ opportunity: "opportunity";
1685
+ project: "project";
1671
1686
  }>;
1672
1687
  id: z.ZodString;
1673
1688
  available: z.ZodBoolean;
@@ -1947,10 +1962,10 @@ export declare const OpportunityBoardSchema: z.ZodObject<{
1947
1962
  boolean: "boolean";
1948
1963
  date: "date";
1949
1964
  text: "text";
1950
- select: "select";
1951
- tags: "tags";
1952
1965
  contact: "contact";
1953
1966
  multiselect: "multiselect";
1967
+ select: "select";
1968
+ tags: "tags";
1954
1969
  organization: "organization";
1955
1970
  salesChannel: "salesChannel";
1956
1971
  assignee: "assignee";
@@ -2043,10 +2058,10 @@ export declare const OpportunityBoardResponseSchema: z.ZodObject<{
2043
2058
  boolean: "boolean";
2044
2059
  date: "date";
2045
2060
  text: "text";
2046
- select: "select";
2047
- tags: "tags";
2048
2061
  contact: "contact";
2049
2062
  multiselect: "multiselect";
2063
+ select: "select";
2064
+ tags: "tags";
2050
2065
  organization: "organization";
2051
2066
  salesChannel: "salesChannel";
2052
2067
  assignee: "assignee";
@@ -2173,6 +2188,20 @@ export declare const OpportunityQuoteRequestLookupQuerySchema: z.ZodObject<{
2173
2188
  limit: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
2174
2189
  }, z.core.$strip>;
2175
2190
  export type OpportunityQuoteRequestLookupQuery = z.infer<typeof OpportunityQuoteRequestLookupQuerySchema>;
2191
+ /**
2192
+ * `GET /crm/lookups/documents` — the `@@` document list of an Opportunity's
2193
+ * texts (`specs/163-projects-and-tasks/` FR-044). The answer is the shared
2194
+ * `RecordDocumentLookupResponse` (`record-references.ts`), the one Projects
2195
+ * serves too. Orders and Quote Requests are those of the Opportunity's
2196
+ * Organization — or, on the create form before there is an Opportunity, of the
2197
+ * Organization chosen there; with neither, the list offers Tasks only.
2198
+ */
2199
+ export declare const OpportunityDocumentLookupQuerySchema: z.ZodObject<{
2200
+ opportunityId: z.ZodOptional<z.ZodString>;
2201
+ organizationId: z.ZodOptional<z.ZodString>;
2202
+ q: z.ZodOptional<z.ZodString>;
2203
+ }, z.core.$strip>;
2204
+ export type OpportunityDocumentLookupQuery = z.infer<typeof OpportunityDocumentLookupQuerySchema>;
2176
2205
  export declare const OpportunityQuoteRequestOptionSchema: z.ZodObject<{
2177
2206
  id: z.ZodString;
2178
2207
  number: z.ZodString;
@@ -2204,9 +2233,13 @@ export declare const OpportunityHistoryEntrySchema: z.ZodObject<{
2204
2233
  after: z.ZodNullable<z.ZodUnknown>;
2205
2234
  references: z.ZodArray<z.ZodObject<{
2206
2235
  type: z.ZodEnum<{
2236
+ product: "product";
2207
2237
  order: "order";
2208
2238
  admin_user: "admin_user";
2209
- product: "product";
2239
+ quote_request: "quote_request";
2240
+ task: "task";
2241
+ opportunity: "opportunity";
2242
+ project: "project";
2210
2243
  }>;
2211
2244
  id: z.ZodString;
2212
2245
  available: z.ZodBoolean;
@@ -2242,9 +2275,13 @@ export declare const OpportunityHistoryResponseSchema: z.ZodObject<{
2242
2275
  after: z.ZodNullable<z.ZodUnknown>;
2243
2276
  references: z.ZodArray<z.ZodObject<{
2244
2277
  type: z.ZodEnum<{
2278
+ product: "product";
2245
2279
  order: "order";
2246
2280
  admin_user: "admin_user";
2247
- product: "product";
2281
+ quote_request: "quote_request";
2282
+ task: "task";
2283
+ opportunity: "opportunity";
2284
+ project: "project";
2248
2285
  }>;
2249
2286
  id: z.ZodString;
2250
2287
  available: z.ZodBoolean;
@@ -2458,9 +2495,9 @@ export type OpportunityEventRule = z.infer<typeof opportunityEventRuleSchema>;
2458
2495
  * being sent right now is reported as `scheduled`.
2459
2496
  */
2460
2497
  export declare const opportunityEventReminderStateSchema: z.ZodEnum<{
2498
+ scheduled: "scheduled";
2461
2499
  no_recipient: "no_recipient";
2462
2500
  sent: "sent";
2463
- scheduled: "scheduled";
2464
2501
  paused: "paused";
2465
2502
  missed: "missed";
2466
2503
  undeliverable: "undeliverable";
@@ -2506,9 +2543,9 @@ export type UpdateOpportunityEventRequest = z.infer<typeof UpdateOpportunityEven
2506
2543
  export declare const OpportunityEventReminderSchema: z.ZodObject<{
2507
2544
  at: z.ZodString;
2508
2545
  state: z.ZodEnum<{
2546
+ scheduled: "scheduled";
2509
2547
  no_recipient: "no_recipient";
2510
2548
  sent: "sent";
2511
- scheduled: "scheduled";
2512
2549
  paused: "paused";
2513
2550
  missed: "missed";
2514
2551
  undeliverable: "undeliverable";
@@ -2534,9 +2571,9 @@ export declare const OpportunityEventSchema: z.ZodObject<{
2534
2571
  reminder: z.ZodNullable<z.ZodObject<{
2535
2572
  at: z.ZodString;
2536
2573
  state: z.ZodEnum<{
2574
+ scheduled: "scheduled";
2537
2575
  no_recipient: "no_recipient";
2538
2576
  sent: "sent";
2539
- scheduled: "scheduled";
2540
2577
  paused: "paused";
2541
2578
  missed: "missed";
2542
2579
  undeliverable: "undeliverable";
@@ -2570,9 +2607,9 @@ export declare const OpportunityEventResponseSchema: z.ZodObject<{
2570
2607
  reminder: z.ZodNullable<z.ZodObject<{
2571
2608
  at: z.ZodString;
2572
2609
  state: z.ZodEnum<{
2610
+ scheduled: "scheduled";
2573
2611
  no_recipient: "no_recipient";
2574
2612
  sent: "sent";
2575
- scheduled: "scheduled";
2576
2613
  paused: "paused";
2577
2614
  missed: "missed";
2578
2615
  undeliverable: "undeliverable";
@@ -2606,9 +2643,9 @@ export declare const OpportunityEventListResponseSchema: z.ZodObject<{
2606
2643
  reminder: z.ZodNullable<z.ZodObject<{
2607
2644
  at: z.ZodString;
2608
2645
  state: z.ZodEnum<{
2646
+ scheduled: "scheduled";
2609
2647
  no_recipient: "no_recipient";
2610
2648
  sent: "sent";
2611
- scheduled: "scheduled";
2612
2649
  paused: "paused";
2613
2650
  missed: "missed";
2614
2651
  undeliverable: "undeliverable";
@@ -2787,8 +2824,8 @@ export declare const OpportunityStatusChangedEventV1Schema: z.ZodObject<{
2787
2824
  adminUserId: z.ZodOptional<z.ZodString>;
2788
2825
  }, z.core.$strict>;
2789
2826
  cause: z.ZodEnum<{
2790
- system: "system";
2791
2827
  manual: "manual";
2828
+ system: "system";
2792
2829
  order_status: "order_status";
2793
2830
  }>;
2794
2831
  causeOrderId: z.ZodOptional<z.ZodString>;
@@ -2803,9 +2840,9 @@ export declare const OpportunityCreatedEventV1Schema: z.ZodObject<{
2803
2840
  number: z.ZodString;
2804
2841
  organizationId: z.ZodString;
2805
2842
  source: z.ZodEnum<{
2843
+ manual: "manual";
2806
2844
  order: "order";
2807
2845
  quote_request: "quote_request";
2808
- manual: "manual";
2809
2846
  }>;
2810
2847
  eventId: z.ZodString;
2811
2848
  occurredAt: z.ZodString;
@@ -2857,8 +2894,8 @@ export declare const CRM_WEBHOOK_EVENT_SCHEMAS: {
2857
2894
  adminUserId: z.ZodOptional<z.ZodString>;
2858
2895
  }, z.core.$strict>;
2859
2896
  cause: z.ZodEnum<{
2860
- system: "system";
2861
2897
  manual: "manual";
2898
+ system: "system";
2862
2899
  order_status: "order_status";
2863
2900
  }>;
2864
2901
  causeOrderId: z.ZodOptional<z.ZodString>;
@@ -2871,9 +2908,9 @@ export declare const CRM_WEBHOOK_EVENT_SCHEMAS: {
2871
2908
  number: z.ZodString;
2872
2909
  organizationId: z.ZodString;
2873
2910
  source: z.ZodEnum<{
2911
+ manual: "manual";
2874
2912
  order: "order";
2875
2913
  quote_request: "quote_request";
2876
- manual: "manual";
2877
2914
  }>;
2878
2915
  eventId: z.ZodString;
2879
2916
  occurredAt: z.ZodString;
@@ -2976,7 +3013,29 @@ export interface OpportunityReadPort {
2976
3013
  findById(id: string): Promise<OpportunityRecord | null>;
2977
3014
  findByDocument(kind: OpportunityDocumentKind, documentId: string): Promise<OpportunityRecord | null>;
2978
3015
  listOpenForOrganization(organizationId: string): Promise<OpportunityRecord[]>;
3016
+ /**
3017
+ * The Opportunities of `ids` in the caller's tenant scope, in no particular
3018
+ * order — a missing or malformed id is simply absent. One query for a page of
3019
+ * references (`specs/165-task-management/` R-5). Checks no permission: the
3020
+ * caller checks `crm:read`, as for every other method.
3021
+ */
3022
+ findByIds(ids: readonly string[]): Promise<OpportunityRecord[]>;
3023
+ /**
3024
+ * Opportunities in the caller's tenant scope whose number or title contains
3025
+ * `q` (case-insensitively; every one for an empty `q`), newest first, at most
3026
+ * `limit` (≤ 20) — the Opportunities group of the `@@` list and the Tasks
3027
+ * link picker (R-5, R-16).
3028
+ */
3029
+ search(query: OpportunitySearchQuery): Promise<OpportunityRecord[]>;
3030
+ }
3031
+ /** What `OpportunityReadPort.search` is asked. */
3032
+ export interface OpportunitySearchQuery {
3033
+ q?: string;
3034
+ /** At most {@link OPPORTUNITY_READ_PORT_SEARCH_MAX}. */
3035
+ limit: number;
2979
3036
  }
3037
+ /** The most Opportunities one `OpportunityReadPort.search` answers. */
3038
+ export declare const OPPORTUNITY_READ_PORT_SEARCH_MAX = 20;
2980
3039
  /** Why a requested transition did not happen. */
2981
3040
  export declare const OPPORTUNITY_TRANSITION_REFUSALS: readonly ["not_found", "unknown_status", "not_permitted", "vetoed"];
2982
3041
  export type OpportunityTransitionRefusal = (typeof OPPORTUNITY_TRANSITION_REFUSALS)[number];
@@ -3020,5 +3079,4 @@ export interface OpportunityTransitionPort {
3020
3079
  reason?: string | null;
3021
3080
  }): Promise<OpportunityTransitionOutcome>;
3022
3081
  }
3023
- export {};
3024
3082
  //# sourceMappingURL=crm.d.ts.map