@sixtyninecommerce/admin 0.10.0 → 0.12.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 (302) hide show
  1. package/README.md +5772 -118
  2. package/dist/auth/index.d.ts +7 -1
  3. package/dist/auth/index.js +8 -1
  4. package/dist/catalog/assets.d.ts +120 -8
  5. package/dist/catalog/assets.js +98 -12
  6. package/dist/catalog/collections.d.ts +279 -14
  7. package/dist/catalog/collections.js +246 -15
  8. package/dist/catalog/documents.d.ts +142 -0
  9. package/dist/catalog/documents.js +114 -0
  10. package/dist/catalog/index.d.ts +54 -6
  11. package/dist/catalog/index.js +10 -1
  12. package/dist/catalog/metadata.d.ts +244 -0
  13. package/dist/catalog/metadata.js +220 -0
  14. package/dist/catalog/products.d.ts +159 -19
  15. package/dist/catalog/products.js +88 -13
  16. package/dist/catalog/properties.d.ts +140 -14
  17. package/dist/catalog/properties.js +65 -1
  18. package/dist/catalog/recommendations.d.ts +288 -0
  19. package/dist/catalog/recommendations.js +237 -0
  20. package/dist/catalog/reviews.d.ts +381 -0
  21. package/dist/catalog/reviews.js +325 -0
  22. package/dist/catalog/types.d.ts +17 -1
  23. package/dist/catalog/types.js +10 -0
  24. package/dist/catalog/variant-find.d.ts +136 -0
  25. package/dist/catalog/variant-find.js +239 -0
  26. package/dist/catalog/variants.d.ts +293 -26
  27. package/dist/catalog/variants.js +164 -7
  28. package/dist/catalog/visibility.d.ts +38 -7
  29. package/dist/catalog/visibility.js +19 -1
  30. package/dist/client.d.ts +121 -9
  31. package/dist/client.js +53 -14
  32. package/dist/content/assets.d.ts +285 -0
  33. package/dist/content/assets.js +181 -0
  34. package/dist/content/forms.d.ts +332 -1
  35. package/dist/content/forms.js +140 -4
  36. package/dist/content/items.d.ts +292 -0
  37. package/dist/content/items.js +170 -0
  38. package/dist/content/menus.d.ts +254 -0
  39. package/dist/content/menus.js +70 -0
  40. package/dist/content/strings.d.ts +137 -0
  41. package/dist/content/strings.js +82 -0
  42. package/dist/content/types.d.ts +282 -0
  43. package/dist/content/types.js +100 -0
  44. package/dist/customers/age-verification.d.ts +66 -0
  45. package/dist/customers/age-verification.js +79 -0
  46. package/dist/customers/credit.d.ts +263 -0
  47. package/dist/customers/credit.js +244 -0
  48. package/dist/customers/delivery-preferences.d.ts +120 -0
  49. package/dist/customers/delivery-preferences.js +97 -0
  50. package/dist/customers/delivery-terms.d.ts +44 -0
  51. package/dist/customers/delivery-terms.js +32 -0
  52. package/dist/customers/groups.d.ts +207 -0
  53. package/dist/customers/groups.js +438 -0
  54. package/dist/customers/index.d.ts +462 -37
  55. package/dist/customers/index.js +317 -40
  56. package/dist/customers/invitation-status.d.ts +57 -0
  57. package/dist/customers/invitation-status.js +21 -0
  58. package/dist/customers/notes.d.ts +67 -0
  59. package/dist/customers/notes.js +51 -0
  60. package/dist/customers/notification-recipients.d.ts +97 -0
  61. package/dist/customers/notification-recipients.js +84 -0
  62. package/dist/customers/saved-lists.d.ts +42 -0
  63. package/dist/customers/saved-lists.js +61 -0
  64. package/dist/customers/vat.d.ts +83 -0
  65. package/dist/customers/vat.js +46 -0
  66. package/dist/customers/wire.d.ts +20 -0
  67. package/dist/customers/wire.js +35 -0
  68. package/dist/documents/ar.d.ts +307 -0
  69. package/dist/documents/ar.js +254 -0
  70. package/dist/documents/emails.d.ts +150 -0
  71. package/dist/documents/emails.js +220 -0
  72. package/dist/documents/index.d.ts +744 -21
  73. package/dist/documents/index.js +438 -24
  74. package/dist/documents/pdf.d.ts +2 -0
  75. package/dist/documents/pdf.js +11 -0
  76. package/dist/fulfillments/create.d.ts +167 -0
  77. package/dist/fulfillments/create.js +216 -0
  78. package/dist/fulfillments/index.d.ts +163 -11
  79. package/dist/fulfillments/index.js +135 -6
  80. package/dist/fulfillments/payment-policy.d.ts +64 -0
  81. package/dist/fulfillments/payment-policy.js +140 -0
  82. package/dist/fulfillments/warehouse.d.ts +724 -0
  83. package/dist/fulfillments/warehouse.js +914 -0
  84. package/dist/geo/index.d.ts +119 -0
  85. package/dist/geo/index.js +107 -0
  86. package/dist/index.d.ts +147 -39
  87. package/dist/index.js +51 -12
  88. package/dist/integrations/afas-actions.d.ts +234 -0
  89. package/dist/integrations/afas-actions.js +310 -0
  90. package/dist/integrations/afas-types.d.ts +483 -0
  91. package/dist/integrations/afas-types.js +5 -0
  92. package/dist/integrations/afas.d.ts +234 -0
  93. package/dist/integrations/afas.js +290 -0
  94. package/dist/integrations/connections.d.ts +103 -0
  95. package/dist/integrations/connections.js +55 -0
  96. package/dist/integrations/esp.d.ts +313 -0
  97. package/dist/integrations/esp.js +169 -0
  98. package/dist/integrations/exact-online-types.d.ts +965 -0
  99. package/dist/integrations/exact-online-types.js +6 -0
  100. package/dist/integrations/exact-online.d.ts +784 -0
  101. package/dist/integrations/exact-online.js +1089 -0
  102. package/dist/integrations/index.d.ts +44 -3
  103. package/dist/integrations/index.js +23 -3
  104. package/dist/integrations/pipeline-discoveries.d.ts +65 -0
  105. package/dist/integrations/pipeline-discoveries.js +65 -0
  106. package/dist/integrations/pipeline-keys.d.ts +13 -0
  107. package/dist/integrations/pipeline-keys.js +22 -0
  108. package/dist/integrations/pipeline-runs.d.ts +119 -0
  109. package/dist/integrations/pipeline-runs.js +87 -0
  110. package/dist/integrations/pipelines.d.ts +87 -15
  111. package/dist/integrations/pipelines.js +41 -22
  112. package/dist/integrations/price-import.d.ts +223 -0
  113. package/dist/integrations/price-import.js +124 -0
  114. package/dist/integrations/types.d.ts +367 -3
  115. package/dist/integrations/types.js +4 -3
  116. package/dist/locations/index.d.ts +66 -0
  117. package/dist/locations/index.js +31 -0
  118. package/dist/meta/index.d.ts +172 -0
  119. package/dist/metafields/index.d.ts +8 -1
  120. package/dist/metafields/index.js +10 -0
  121. package/dist/orders/cancel-with-money.d.ts +237 -0
  122. package/dist/orders/cancel-with-money.js +155 -0
  123. package/dist/orders/commit-edit.d.ts +23 -1
  124. package/dist/orders/commit-edit.js +19 -2
  125. package/dist/orders/deposit-policy.d.ts +3 -1
  126. package/dist/orders/drafts.d.ts +800 -0
  127. package/dist/orders/drafts.js +771 -0
  128. package/dist/orders/fields.d.ts +245 -0
  129. package/dist/orders/fields.js +188 -0
  130. package/dist/orders/get.d.ts +29 -19
  131. package/dist/orders/get.js +17 -8
  132. package/dist/orders/index.d.ts +66 -15
  133. package/dist/orders/index.js +25 -2
  134. package/dist/orders/lifecycle.d.ts +128 -0
  135. package/dist/orders/lifecycle.js +158 -0
  136. package/dist/orders/line-price-preview.d.ts +7 -2
  137. package/dist/orders/list.d.ts +243 -0
  138. package/dist/orders/list.js +487 -0
  139. package/dist/orders/manual-discounts.d.ts +13 -5
  140. package/dist/orders/manual-pricing.d.ts +5 -0
  141. package/dist/orders/money-view.d.ts +149 -0
  142. package/dist/orders/money-view.js +99 -0
  143. package/dist/orders/order-entry.d.ts +20 -7
  144. package/dist/orders/plan-edit.d.ts +34 -2
  145. package/dist/orders/plan-edit.js +112 -11
  146. package/dist/orders/settings.d.ts +201 -0
  147. package/dist/orders/settings.js +325 -0
  148. package/dist/orders/status.d.ts +159 -13
  149. package/dist/orders/status.js +21 -0
  150. package/dist/orders/surcharges.d.ts +20 -1
  151. package/dist/orders/surcharges.js +37 -11
  152. package/dist/payments/account-credit.d.ts +46 -0
  153. package/dist/payments/account-credit.js +42 -0
  154. package/dist/payments/ar.d.ts +292 -0
  155. package/dist/payments/ar.js +223 -0
  156. package/dist/payments/connected-account.d.ts +47 -0
  157. package/dist/payments/connected-account.js +61 -0
  158. package/dist/payments/credit-noted-fields.d.ts +19 -0
  159. package/dist/payments/credit-noted-fields.js +69 -0
  160. package/dist/payments/customer-consent.d.ts +30 -0
  161. package/dist/payments/customer-consent.js +49 -0
  162. package/dist/payments/index.d.ts +340 -19
  163. package/dist/payments/index.js +151 -1
  164. package/dist/payments/methods.d.ts +303 -8
  165. package/dist/payments/methods.js +337 -7
  166. package/dist/payments/mollie-methods.d.ts +159 -0
  167. package/dist/payments/mollie-methods.js +141 -0
  168. package/dist/payments/payment-links.d.ts +180 -0
  169. package/dist/payments/payment-links.js +97 -0
  170. package/dist/payments/provider-keys.d.ts +150 -0
  171. package/dist/payments/provider-keys.js +118 -0
  172. package/dist/payments/providers.d.ts +86 -11
  173. package/dist/payments/providers.js +29 -0
  174. package/dist/payments/requests.d.ts +147 -0
  175. package/dist/payments/requests.js +93 -0
  176. package/dist/payments/store-credit-fields.d.ts +15 -0
  177. package/dist/payments/store-credit-fields.js +51 -0
  178. package/dist/pickups/index.d.ts +106 -0
  179. package/dist/pickups/index.js +108 -0
  180. package/dist/platform/channels.d.ts +132 -0
  181. package/dist/platform/channels.js +128 -0
  182. package/dist/platform/email-gateways.d.ts +165 -0
  183. package/dist/platform/email-gateways.js +78 -0
  184. package/dist/platform/geo.d.ts +123 -0
  185. package/dist/platform/geo.js +144 -0
  186. package/dist/platform/tax.d.ts +162 -0
  187. package/dist/platform/tax.js +169 -0
  188. package/dist/pos/anomalies.d.ts +158 -0
  189. package/dist/pos/anomalies.js +64 -0
  190. package/dist/pos/assisted-selling.d.ts +79 -0
  191. package/dist/pos/assisted-selling.js +38 -0
  192. package/dist/pos/exchanges.d.ts +108 -0
  193. package/dist/pos/exchanges.js +22 -0
  194. package/dist/pos/gift-cards.d.ts +135 -0
  195. package/dist/pos/gift-cards.js +47 -0
  196. package/dist/pos/index.d.ts +2370 -58
  197. package/dist/pos/index.js +854 -7
  198. package/dist/pos/no-receipt.d.ts +94 -0
  199. package/dist/pos/no-receipt.js +25 -0
  200. package/dist/pos/offline-sales.d.ts +228 -0
  201. package/dist/pos/offline-sales.js +170 -0
  202. package/dist/pos/pay-by-link.d.ts +143 -0
  203. package/dist/pos/pay-by-link.js +57 -0
  204. package/dist/pos/quick-keys.d.ts +103 -0
  205. package/dist/pos/quick-keys.js +45 -0
  206. package/dist/pos/reports.d.ts +360 -0
  207. package/dist/pos/reports.js +62 -0
  208. package/dist/pos/returns.d.ts +244 -0
  209. package/dist/pos/returns.js +83 -0
  210. package/dist/pricing/bulk-coupons.d.ts +139 -0
  211. package/dist/pricing/bulk-coupons.js +112 -0
  212. package/dist/pricing/index.d.ts +174 -4
  213. package/dist/pricing/index.js +174 -1
  214. package/dist/pricing/price-lists.d.ts +606 -0
  215. package/dist/pricing/price-lists.js +600 -0
  216. package/dist/purchasing/alerts.d.ts +104 -0
  217. package/dist/purchasing/alerts.js +88 -0
  218. package/dist/purchasing/backorders.d.ts +61 -0
  219. package/dist/purchasing/backorders.js +92 -0
  220. package/dist/purchasing/cost.d.ts +110 -0
  221. package/dist/purchasing/cost.js +86 -0
  222. package/dist/purchasing/index.d.ts +54 -0
  223. package/dist/purchasing/index.js +24 -0
  224. package/dist/purchasing/links.d.ts +263 -0
  225. package/dist/purchasing/links.js +192 -0
  226. package/dist/purchasing/purchase-orders.d.ts +551 -0
  227. package/dist/purchasing/purchase-orders.js +491 -0
  228. package/dist/purchasing/receipts.d.ts +396 -0
  229. package/dist/purchasing/receipts.js +287 -0
  230. package/dist/purchasing/replenishment.d.ts +281 -0
  231. package/dist/purchasing/replenishment.js +240 -0
  232. package/dist/purchasing/returns.d.ts +273 -0
  233. package/dist/purchasing/returns.js +229 -0
  234. package/dist/purchasing/settings.d.ts +152 -0
  235. package/dist/purchasing/settings.js +181 -0
  236. package/dist/purchasing/suppliers.d.ts +476 -0
  237. package/dist/purchasing/suppliers.js +438 -0
  238. package/dist/quotes/index.d.ts +518 -0
  239. package/dist/quotes/index.js +439 -0
  240. package/dist/reports/index.d.ts +71 -8
  241. package/dist/reports/index.js +74 -11
  242. package/dist/returns/index.d.ts +675 -21
  243. package/dist/returns/index.js +756 -11
  244. package/dist/search/index.d.ts +76 -1
  245. package/dist/search/index.js +63 -0
  246. package/dist/seo/config.d.ts +128 -0
  247. package/dist/seo/config.js +95 -0
  248. package/dist/seo/redirects.d.ts +125 -0
  249. package/dist/seo/redirects.js +60 -1
  250. package/dist/seo/settings.d.ts +147 -0
  251. package/dist/seo/settings.js +209 -0
  252. package/dist/shipping/definitions.d.ts +29 -0
  253. package/dist/shipping/definitions.js +47 -0
  254. package/dist/shipping/fulfillment-profiles.d.ts +174 -0
  255. package/dist/shipping/fulfillment-profiles.js +104 -0
  256. package/dist/shipping/hendriks.d.ts +97 -0
  257. package/dist/shipping/hendriks.js +50 -0
  258. package/dist/shipping/index.d.ts +54 -0
  259. package/dist/shipping/index.js +27 -0
  260. package/dist/shipping/methods.d.ts +205 -0
  261. package/dist/shipping/methods.js +240 -0
  262. package/dist/shipping/myparcel.d.ts +668 -0
  263. package/dist/shipping/myparcel.js +466 -0
  264. package/dist/shipping/parcel-count-suggestion.d.ts +2 -0
  265. package/dist/shipping/parcel-rule.d.ts +6 -5
  266. package/dist/shipping/parcel-rule.js +21 -23
  267. package/dist/shipping/rate-tables.d.ts +324 -0
  268. package/dist/shipping/rate-tables.js +390 -0
  269. package/dist/shipping/ship-to-countries.d.ts +75 -0
  270. package/dist/shipping/ship-to-countries.js +47 -0
  271. package/dist/stock/by-location.d.ts +86 -0
  272. package/dist/stock/by-location.js +94 -0
  273. package/dist/stock/index.d.ts +18 -4
  274. package/dist/stock/index.js +7 -0
  275. package/dist/stock/locations.d.ts +144 -0
  276. package/dist/stock/locations.js +168 -0
  277. package/dist/stock/settings.d.ts +106 -0
  278. package/dist/stock/settings.js +103 -0
  279. package/dist/stock/transfers.d.ts +386 -52
  280. package/dist/stock/transfers.js +222 -17
  281. package/dist/stored-value/index.d.ts +312 -11
  282. package/dist/stored-value/index.js +223 -4
  283. package/dist/subscriptions/index.d.ts +682 -0
  284. package/dist/subscriptions/index.js +815 -0
  285. package/dist/tax/display-policy.d.ts +105 -0
  286. package/dist/tax/display-policy.js +84 -0
  287. package/dist/tax/index.d.ts +79 -1
  288. package/dist/tax/index.js +52 -0
  289. package/dist/tenant/email-style.d.ts +102 -0
  290. package/dist/tenant/email-style.js +72 -0
  291. package/dist/tenant/email-templates.d.ts +287 -0
  292. package/dist/tenant/email-templates.js +271 -0
  293. package/dist/tenant/notifications.d.ts +23 -17
  294. package/dist/tenant/settings-sources.d.ts +1 -1
  295. package/dist/tenant/time-zone.d.ts +17 -0
  296. package/dist/tenant/time-zone.js +11 -0
  297. package/dist/types.d.ts +50 -3
  298. package/dist/users/index.d.ts +3 -0
  299. package/dist/users/index.js +2 -0
  300. package/dist/users/warehouses.d.ts +50 -0
  301. package/dist/users/warehouses.js +51 -0
  302. package/package.json +2 -2
@@ -0,0 +1,784 @@
1
+ import { type Page, type Transport } from '@sixtyninecommerce/core';
2
+ import type { AuditCall, AuditEvent } from '../audit/index.js';
3
+ import type { Call, ListOptions } from '../types.js';
4
+ import type { ConvertExactShippingMethodInput, ExactAccountStructure, ExactCatalogueStructure, ExactCustomerDeliveryTerms, ExactCustomerPaymentTerms, ExactCustomerPriceList, ExactDeliveryTermsDiagnostics, ExactDeliveryTermsDryRun, ExactIncoterm, ExactOnlineAccountPreview, ExactOnlineConfig, ExactOnlineConnectionLogCallFilter, ExactOnlineConnectionLogEventFilter, ExactOnlineConnectionLogExportFilter, ExactOnlineConnectionLogKind, ExactOnlineItemPreview, ExactOnlineSyncHealth, ExactOnlineSyncLogEntry, ExactOnlineSyncLogOptions, ExactOrderPushResult, ExactOrderRepriceAllResult, ExactOrderRepriceResult, ExactOrderState, ExactOrderSyncState, ExactPaymentCondition, ExactPaymentTermsDiagnostics, ExactPaymentTermsDryRun, ExactPricingStructure, ExactProductStatus, ExactShippingMethodMapping, ExactShippingMethodsView, ExactSyncCursor, ExactSyncEstimate, ExactSyncScheduleInput, ExactWarehouseLink, ExactWebhookStatus, SetExactOnlineCredentialsInput, SetExactShippingMethodMappingInput, UpdateExactOnlineConfigInput } from './exact-online-types.js';
5
+ /**
6
+ * The store's Exact Online connection itself (`admin.integrations.exactOnline.config`).
7
+ */
8
+ export interface ExactOnlineConfigModule {
9
+ /**
10
+ * The store's connection and settings, or `null` when it never had one. Every section reads
11
+ * resolved: a section the store never saved reads the engine's defaults. The client secret,
12
+ * the webhook secret and the OAuth tokens are never read back.
13
+ *
14
+ * @effect read
15
+ * @permission ReadSettings
16
+ */
17
+ get(options?: Call): Promise<ExactOnlineConfig | null>;
18
+ /**
19
+ * Change the settings; the first call creates the store's row (switched off). Answers the saved
20
+ * connection. Every key is optional and one left out keeps the stored value; the sections are
21
+ * judged again when sent (the payment-method mappings, the delivery defaults and readiness), so
22
+ * send only what changed. Sent as the engine's inline arguments, one per key.
23
+ *
24
+ * Refused, with nothing saved:
25
+ * - `INVALID_EXACT_ONLINE_INPUT` (`ValidationError`, 400), before sending: not an input object,
26
+ * a key that is no setting (GraphQL would drop it unread), or an explicit `null` for `region`,
27
+ * `enabled`, `shippingItemCode`, `discountItemCode`, `paymentTerms` or `deliveryTerms` (the
28
+ * engine cannot store one: a database or type error); the key in `error.details[]`;
29
+ * - `PLUGIN_ACCESS_DENIED` (`PermissionDeniedError`, 403): the store has no Exact Online plugin
30
+ * (never for a SuperAdmin);
31
+ * - `FIELD_GROUP_LOCKED` (`BusinessRuleError`, 422): the save switches Exact, or its customer
32
+ * sync, on while an app or API token owns a field group of the store (prices, stock, product
33
+ * or customer details), which Exact would write; `error.details[]` names each owner. The owner
34
+ * releases the group in Settings → Apps first;
35
+ * - `ORGANIZATION_WORKSPACE_NOT_A_STORE` (422): switching Exact on in an organization's
36
+ * workspace;
37
+ * - `USER_INPUT_ERROR` (`ValidationError`, 400): an external-line or surcharge item code over
38
+ * 60 characters once trimmed.
39
+ *
40
+ * The engine's other refusals are not coded yet and arrive as an uncoded error
41
+ * (`GRAPHQL_ERROR`, 500): an unknown `region`, a shipping or discount item code over 60
42
+ * characters, a new-account payment condition missing from the synchronised catalog, a payment
43
+ * method that is not the store's or is mapped twice, the delivery defaults (an Incoterm without
44
+ * a version, a lead time or advice out of range) and operational delivery terms the schedule or
45
+ * the switch cannot serve.
46
+ *
47
+ * @effect write
48
+ * @permission UpdateSettings
49
+ */
50
+ update(input: UpdateExactOnlineConfigInput, options?: Call): Promise<ExactOnlineConfig>;
51
+ }
52
+ /** The store's own Exact app (`admin.integrations.exactOnline.credentials`). */
53
+ export interface ExactOnlineCredentialsModule {
54
+ /**
55
+ * Store the store's own Exact app: its client id and, write-only, its client secret and webhook
56
+ * secret (a secret left out, or blank, keeps the stored one). Needed before connecting; kept
57
+ * across a disconnect. Answers the connection (`hasCustomCredentials` once both id and secret
58
+ * are stored); the first call creates the store's row.
59
+ *
60
+ * Refused: `PLUGIN_ACCESS_DENIED` (403); `ORGANIZATION_WORKSPACE_NOT_A_STORE` (422) in an
61
+ * organization's workspace; `INVALID_EXACT_ONLINE_INPUT` (400), before sending, when `clientId`
62
+ * is not a string.
63
+ *
64
+ * @effect write
65
+ * @permission UpdateSettings
66
+ */
67
+ set(input: SetExactOnlineCredentialsInput, options?: Call): Promise<ExactOnlineConfig>;
68
+ }
69
+ /** Live samples of the connected division (`admin.integrations.exactOnline.samples`). */
70
+ export interface ExactOnlineSamplesModule {
71
+ /**
72
+ * A few CRM Accounts of the connected division, read live from Exact (5 unless `limit` says).
73
+ * Refused `PLUGIN_ACCESS_DENIED` (403); a store that is not connected, or an Exact read that
74
+ * fails, answers an uncoded error (`GRAPHQL_ERROR`, 500; not coded yet).
75
+ *
76
+ * @effect read
77
+ * @permission ReadSettings
78
+ */
79
+ accounts(options?: {
80
+ limit?: number;
81
+ } & Call): Promise<ExactOnlineAccountPreview[]>;
82
+ /**
83
+ * A few logistics Items of the connected division, read live from Exact (5 unless `limit`
84
+ * says). Refusals as {@link accounts}.
85
+ *
86
+ * @effect read
87
+ * @permission ReadSettings
88
+ */
89
+ items(options?: {
90
+ limit?: number;
91
+ } & Call): Promise<ExactOnlineItemPreview[]>;
92
+ }
93
+ /**
94
+ * Read-only probes of how the connected division is organised, for designing the import rules
95
+ * (`admin.integrations.exactOnline.structure`). Each reads Exact live, page by page: slow on a
96
+ * large division. Refused `PLUGIN_ACCESS_DENIED` (403); a store that is not connected, or an
97
+ * Exact read that fails, answers an uncoded error (`GRAPHQL_ERROR`, 500; not coded yet).
98
+ */
99
+ export interface ExactOnlineStructureModule {
100
+ /**
101
+ * How the items group (item groups, classification fields), over the first `sample` items
102
+ * (200 unless said).
103
+ *
104
+ * @effect read
105
+ * @permission ReadSettings
106
+ */
107
+ catalogue(options?: {
108
+ sample?: number;
109
+ } & Call): Promise<ExactCatalogueStructure>;
110
+ /**
111
+ * How the Accounts group (classification dimensions, price lists, resellers), over the first
112
+ * `sample` Accounts (1,000 unless said).
113
+ *
114
+ * @effect read
115
+ * @permission ReadSettings
116
+ */
117
+ customers(options?: {
118
+ sample?: number;
119
+ } & Call): Promise<ExactAccountStructure>;
120
+ /**
121
+ * Named price lists against per-customer item prices in the division.
122
+ *
123
+ * @effect read
124
+ * @permission ReadSettings
125
+ */
126
+ pricing(options?: Call): Promise<ExactPricingStructure>;
127
+ }
128
+ /** The store's Exact webhook subscriptions (`admin.integrations.exactOnline.webhooks`). */
129
+ export interface ExactOnlineWebhooksModule {
130
+ /**
131
+ * The subscriptions live in Exact for the store, read live. A failed Exact read answers
132
+ * `error` with a best-effort rest, never a throw. Refused `PLUGIN_ACCESS_DENIED` (403).
133
+ *
134
+ * @effect read
135
+ * @permission ReadSettings
136
+ */
137
+ status(options?: Call): Promise<ExactWebhookStatus>;
138
+ /**
139
+ * Register (or refresh) the store's subscriptions in Exact. Safe to repeat. Refused
140
+ * `PLUGIN_ACCESS_DENIED` (403) and `FIELD_GROUP_LOCKED` (422) while an app or API token owns a
141
+ * field group of the store; a store that is not connected, or an Exact write that fails,
142
+ * answers an uncoded error (`GRAPHQL_ERROR`, 500; not coded yet).
143
+ *
144
+ * @effect write
145
+ * @permission UpdateSettings
146
+ */
147
+ sync(options?: Call): Promise<boolean>;
148
+ }
149
+ /** The most sync-log rows one {@link ExactOnlineSyncModule.logs} read answers. */
150
+ export declare const EXACT_ONLINE_SYNC_LOG_LIMIT = 100;
151
+ /**
152
+ * The inbound (Exact → platform) sync of the store: how its runs went, and running one by hand
153
+ * (`admin.integrations.exactOnline.sync`). A run is QUEUED: the call answers once the work is on
154
+ * the worker's queue, and its outcome arrives in {@link logs} and {@link health}.
155
+ *
156
+ * Every manual run is refused, with nothing queued:
157
+ * - `FIELD_GROUP_LOCKED` (`BusinessRuleError`, 422) while an app or API token owns a field group
158
+ * of the store (prices, stock levels, product or customer details), a suspended one included:
159
+ * Exact writes all four. The sentence names each owner and where to release it, and
160
+ * `error.details[]` holds one entry per owned group, its message naming the owner;
161
+ * - `PLUGIN_ACCESS_DENIED` (`PermissionDeniedError`, 403): the store has no Exact Online plugin
162
+ * (never for a SuperAdmin).
163
+ *
164
+ * A run does not check that the store is connected or switched on: on a store that is not
165
+ * connected it is queued, and fails on the worker (a `failed` row in {@link logs}). The engine
166
+ * queues a run whatever `enabled` says, so a connected division that is switched off is still
167
+ * written to.
168
+ */
169
+ export interface ExactOnlineSyncModule {
170
+ /**
171
+ * The store's newest sync runs, newest first, across every entity or one (`entity`). Not a
172
+ * page: the newest `limit` runs (20 unless said), never a way to walk the whole log. A store
173
+ * with no connected division answers `[]`.
174
+ *
175
+ * Refused before sending, `INVALID_EXACT_ONLINE_INPUT` (`ValidationError`, 400): a `limit`
176
+ * that is not a whole number from 1 to {@link EXACT_ONLINE_SYNC_LOG_LIMIT} (the engine would
177
+ * otherwise answer fewer rows than asked, unsaid), or an `entity` that is not a non-blank
178
+ * string. `PLUGIN_ACCESS_DENIED` (403).
179
+ *
180
+ * @effect read
181
+ * @permission ReadSettings
182
+ */
183
+ logs(options?: ExactOnlineSyncLogOptions & Call): Promise<ExactOnlineSyncLogEntry[]>;
184
+ /**
185
+ * How the newest real run of each inbound area (customers, catalogue, orders) ended. An area
186
+ * that never ran, or every area of a store with no connected division, is null.
187
+ * `PLUGIN_ACCESS_DENIED` (403).
188
+ *
189
+ * @effect read
190
+ * @permission ReadSettings
191
+ */
192
+ health(options?: Call): Promise<ExactOnlineSyncHealth>;
193
+ /**
194
+ * "Sync now": queue the whole inbound sync of the store: the catalogue (warehouses, items,
195
+ * prices, stock), the customers, the sales orders and the purchase orders, each on its own
196
+ * queue. It overwrites what Exact owns (prices customers pay, stock levels, product and
197
+ * customer details, customer price lists and terms) with Exact's values, which the platform
198
+ * cannot take back, and the order import books Exact's new and changed sales orders as placed
199
+ * orders with a settled payment: it records money. Answers `true` once queued. Refusals: see
200
+ * {@link ExactOnlineSyncModule}.
201
+ *
202
+ * @effect money
203
+ * @permission UpdateSettings
204
+ */
205
+ runCatalogue(options?: Call): Promise<boolean>;
206
+ /**
207
+ * "Import customers": queue a full customer synchronization (Exact Accounts → customers),
208
+ * whatever the customer sync switch says. It overwrites customer details per the store's
209
+ * overwrite policy and assigns the Exact price lists and payment and delivery terms, which the
210
+ * platform cannot take back. Answers `true` once queued. Refusals: see
211
+ * {@link ExactOnlineSyncModule}.
212
+ *
213
+ * @effect irreversible
214
+ * @permission UpdateSettings
215
+ */
216
+ runCustomers(options?: Call): Promise<boolean>;
217
+ /**
218
+ * Queue the price-list reconcile (Exact customer price agreements and named price lists → the
219
+ * store's price lists), which changes what customers pay and cannot be taken back. Answers
220
+ * `false`, queuing nothing, when one is already waiting or running for the store: that run
221
+ * reads Exact fresh when it starts. Refusals: see {@link ExactOnlineSyncModule}.
222
+ *
223
+ * @effect irreversible
224
+ * @permission UpdateSettings
225
+ */
226
+ runPriceLists(options?: Call): Promise<boolean>;
227
+ /**
228
+ * "Re-import pictures": mark every picture the store imported from Exact for import again,
229
+ * and queue a catalogue sweep (the pictures ride it, a capped number per run, so they arrive
230
+ * over the next runs). The sweep writes the whole catalogue, prices and stock included (not
231
+ * the customers or orders {@link runCatalogue} also queues). Answers how many pictures were
232
+ * marked (0 when none was imported yet). Refusals: see {@link ExactOnlineSyncModule}.
233
+ *
234
+ * @effect irreversible
235
+ * @permission UpdateSettings
236
+ */
237
+ reimportPictures(options?: Call): Promise<number>;
238
+ /**
239
+ * The store's persisted Exact Sync API cursors, one per entity stream; `[]` when it has none
240
+ * or is not connected. `PLUGIN_ACCESS_DENIED` (403).
241
+ *
242
+ * @effect read
243
+ * @permission ReadSettings
244
+ */
245
+ cursors(options?: Call): Promise<ExactSyncCursor[]>;
246
+ /**
247
+ * Drop one entity stream's cursor, so the next sweep of it reads Exact from the beginning
248
+ * (slower, more Exact calls; the writes are idempotent). Answers `true`, also when no cursor
249
+ * was stored under `entity`. Refused before sending, `INVALID_EXACT_ONLINE_INPUT` (400): an
250
+ * `entity` that is not a non-blank string. `PLUGIN_ACCESS_DENIED` (403).
251
+ *
252
+ * @effect write
253
+ * @permission UpdateSettings
254
+ */
255
+ resetCursor(entity: string, options?: Call): Promise<boolean>;
256
+ }
257
+ /**
258
+ * The store's shipping methods mapped to Exact's (`admin.integrations.exactOnline.shipping`).
259
+ * Orders pushed to Exact carry the mapped Exact method. A method Exact defines reaches checkout
260
+ * only when it is deliberately activated ({@link import}) or mapped; a catalogue refresh never
261
+ * adds one.
262
+ *
263
+ * The engine's refusals here are not all coded yet: the ones it raises as an input error arrive
264
+ * as `USER_INPUT_ERROR` (`ValidationError`, 400), the others as an uncoded error
265
+ * (`GRAPHQL_ERROR`, 500). Every method is refused `PLUGIN_ACCESS_DENIED` (403) for a store
266
+ * without the Exact Online plugin.
267
+ */
268
+ export interface ExactOnlineShippingModule {
269
+ /**
270
+ * The store's shipping methods (up to 500), each with its Exact mapping and its status live
271
+ * against the synchronized Exact catalogue, and that catalogue. Reads no Exact API.
272
+ *
273
+ * @effect read
274
+ * @permission ReadSettings
275
+ */
276
+ methods(options?: Call): Promise<ExactShippingMethodsView>;
277
+ /**
278
+ * "Refresh Exact catalog": queue a shipping-method synchronization. It refreshes the store's
279
+ * Exact catalogue (a new Exact method stays out of checkout) and re-applies Exact's rate, with
280
+ * its calculator and checker, to every method already activated from Exact, which changes what
281
+ * checkout charges and cannot be taken back. A name the merchant gave an activated method
282
+ * stays: only {@link import} takes Exact's description back. Answers `true` once queued.
283
+ *
284
+ * @effect irreversible
285
+ * @permission UpdateSettings
286
+ */
287
+ runSync(options?: Call): Promise<boolean>;
288
+ /**
289
+ * "Activate" (and "Re-apply Exact name"): create, or update, the checkout method of one Exact
290
+ * method from Exact's description and rate, and map it. On an already activated method it
291
+ * takes Exact's description back over a rename. Answers the mapping.
292
+ *
293
+ * Refused, uncoded (`GRAPHQL_ERROR`, 500): the Exact method is not active and current in the
294
+ * store's synchronized catalogue (refresh it first; a store that is not connected has none),
295
+ * or it has no rate (map it to a method of your own instead: a missing rate never becomes free
296
+ * shipping).
297
+ *
298
+ * @effect write
299
+ * @permission UpdateSettings
300
+ */
301
+ import(exactShippingMethodId: string, options?: Call): Promise<ExactShippingMethodMapping>;
302
+ /**
303
+ * Map a shipping method of the store to an Exact method, or clear its mapping
304
+ * (`exactShippingMethodId: null`). A method shared with other stores is mapped for this store
305
+ * only and stays the store's own (never Exact-managed). Answers the mapping.
306
+ *
307
+ * Clearing the mapping of an Activated method leaves that method in checkout: retire it
308
+ * ({@link retireImported}) or move it ({@link convertToMapping}) instead.
309
+ *
310
+ * Refused before sending, `INVALID_EXACT_ONLINE_INPUT` (400): `exactShippingMethodId` left
311
+ * out, blank, or neither a string nor `null`. The engine would read each as `null` and clear
312
+ * the mapping: a clear is only ever an explicit `null`.
313
+ *
314
+ * Refused, uncoded (`GRAPHQL_ERROR`, 500): the store is not connected to Exact, the shipping
315
+ * method is not the store's, the Exact method is not active and current in the synchronized
316
+ * catalogue, or it is already mapped to another of the store's methods.
317
+ *
318
+ * @effect write
319
+ * @permission UpdateSettings
320
+ */
321
+ setMapping(input: SetExactShippingMethodMappingInput, options?: Call): Promise<ExactShippingMethodMapping>;
322
+ /**
323
+ * [deletes] Move an Activated Exact method onto one of the store's own methods, in one
324
+ * transaction: the mapping now names `vendureShippingMethodId`, and the method Exact created is
325
+ * retired (soft-deleted; orders already shipped on it keep their shipping line). Answers the
326
+ * new mapping.
327
+ *
328
+ * Refused `USER_INPUT_ERROR` (`ValidationError`, 400): the Exact method is not activated in
329
+ * the store, or the target is not a method of the store that Exact does not manage.
330
+ *
331
+ * Needs `DeleteSettings` or `DeleteShippingMethod`, as deleting a shipping method does (either
332
+ * one, so no `@permission` tag: the tag can only say "all of these"); `UpdateSettings` alone
333
+ * is refused `FORBIDDEN` (403).
334
+ *
335
+ * @effect destructive
336
+ */
337
+ convertToMapping(input: ConvertExactShippingMethodInput, options?: Call): Promise<ExactShippingMethodMapping>;
338
+ /**
339
+ * [deletes] Retire one Activated Exact method: its checkout method is soft-deleted and its
340
+ * mapping released (an order placed on it still pushes under the Exact method it was sold
341
+ * under). Answers `true`, also when it was already retired. Activating the Exact method again
342
+ * brings it back.
343
+ *
344
+ * Refused `USER_INPUT_ERROR` (`ValidationError`, 400): the store is not connected to Exact,
345
+ * the Exact method is unknown to the store's catalogue, or it was never activated here.
346
+ *
347
+ * Needs `DeleteSettings` or `DeleteShippingMethod` (either one, so no `@permission` tag);
348
+ * `UpdateSettings` alone is refused `FORBIDDEN` (403).
349
+ *
350
+ * @effect destructive
351
+ */
352
+ retireImported(exactShippingMethodId: string, options?: Call): Promise<boolean>;
353
+ }
354
+ /**
355
+ * The store's Exact connection logs (`admin.integrations.exactOnline.connectionLogs`): every API
356
+ * call between the store and Exact (`calls`), and the Exact sync and lifecycle events (`events`),
357
+ * from the platform's audit trail, newest first. Always the client's own store; a store without
358
+ * the Exact Online plugin reads none (refused `PermissionDeniedError`, 403).
359
+ *
360
+ * The rows are the audit trail's own ({@link AuditCall}, {@link AuditEvent}). An app installation
361
+ * below `customerData: full` reads them with every field that can carry customer data null (the
362
+ * bodies, the error text, the endpoint, the labels, `metadata`), and a text search (`q`) is
363
+ * refused `CUSTOMER_DATA_NOT_GRANTED` (403).
364
+ *
365
+ * A filter the service cannot read (a date that is not ISO-8601, a status that is not a whole
366
+ * number, a cursor it did not hand out) is refused `VALIDATION_ERROR` (`ValidationError`, 400).
367
+ * `limit` is 1 to 200 (50 unless said): the service reads a larger one as 200, and `hasNext`
368
+ * still says whether more follow.
369
+ */
370
+ export interface ExactOnlineConnectionLogsModule {
371
+ /**
372
+ * The store's Exact API calls, newest first, a page at a time (`.next()`, `for await`).
373
+ *
374
+ * @effect read
375
+ * @permission ReadSettings
376
+ */
377
+ calls(filter?: ExactOnlineConnectionLogCallFilter & ListOptions): Promise<Page<AuditCall>>;
378
+ /**
379
+ * The store's Exact sync and lifecycle events (every `exact.*` action), newest first, a page at
380
+ * a time.
381
+ *
382
+ * @effect read
383
+ * @permission ReadSettings
384
+ */
385
+ events(filter?: ExactOnlineConnectionLogEventFilter & ListOptions): Promise<Page<AuditEvent>>;
386
+ /**
387
+ * One log, filtered, over a bounded date range, as CSV text (a header line, then a line per
388
+ * row, newest first). Both dates are required and the range is at most 366 days; the service
389
+ * refuses a missing, reversed or wider range `VALIDATION_ERROR` (400). Refused before sending,
390
+ * `INVALID_EXACT_ONLINE_INPUT` (400): a `kind` that is not `calls` or `events`.
391
+ *
392
+ * @effect read
393
+ * @permission ReadSettings
394
+ */
395
+ export(kind: ExactOnlineConnectionLogKind, filter: ExactOnlineConnectionLogExportFilter, options?: Call): Promise<string>;
396
+ }
397
+ /**
398
+ * The store's Exact payment and delivery terms: the catalogues mirrored from the connected
399
+ * division, how far the customers' assignments reach, and a live check against Exact
400
+ * (`admin.integrations.exactOnline.terms`). Every method reads; none writes, here or in Exact.
401
+ * Each is refused `PLUGIN_ACCESS_DENIED` (`PermissionDeniedError`, 403) for a store without the
402
+ * Exact Online plugin (never for a SuperAdmin).
403
+ */
404
+ export interface ExactOnlineTermsModule {
405
+ /**
406
+ * The ACTIVE payment conditions mirrored from the connected division, by code. `[]` for a store
407
+ * with no connected division. A local read; it calls no Exact.
408
+ *
409
+ * @effect read
410
+ * @permission ReadSettings
411
+ */
412
+ paymentConditions(options?: Call): Promise<ExactPaymentCondition[]>;
413
+ /**
414
+ * How far the customers' Exact payment conditions reach: how many customers hold one, which
415
+ * codes the catalogue does not know, and how the newest reconcile went. Every count 0 for a
416
+ * store with no connected division. A local read.
417
+ *
418
+ * @effect read
419
+ * @permission ReadSettings
420
+ */
421
+ paymentDiagnostics(options?: Call): Promise<ExactPaymentTermsDiagnostics>;
422
+ /**
423
+ * A live check of the division's payment conditions: reads every condition and every Exact
424
+ * Account (sales Accounts only, unless the customer sync takes all) and answers what taking
425
+ * them over would assign, writing nothing, here or in Exact, also while payment-terms
426
+ * synchronization is off. Slow on a large division. A read Exact refuses is named in
427
+ * `resources` (`complete: false`), not thrown.
428
+ *
429
+ * Refused `EXACT_ONLINE_NOT_CONNECTED` (`BusinessRuleError`, 422) for a store that is not
430
+ * connected to a division, before any Exact call; `PLUGIN_ACCESS_DENIED` (403).
431
+ *
432
+ * @effect read
433
+ * @permission ReadSettings
434
+ */
435
+ paymentDryRun(options?: Call): Promise<ExactPaymentTermsDryRun>;
436
+ /**
437
+ * The Incoterms mirrored from the connected division, by code and version. `[]` for a store
438
+ * with no connected division. A local read.
439
+ *
440
+ * @effect read
441
+ * @permission ReadSettings
442
+ */
443
+ incoterms(options?: Call): Promise<ExactIncoterm[]>;
444
+ /**
445
+ * How far the customers' Exact delivery assignments reach, and how the store's shipping
446
+ * methods map onto Exact's. Every count 0 for a store with no connected division. A local read.
447
+ *
448
+ * @effect read
449
+ * @permission ReadSettings
450
+ */
451
+ deliveryDiagnostics(options?: Call): Promise<ExactDeliveryTermsDiagnostics>;
452
+ /**
453
+ * A live check of the division's delivery assignments: reads Exact's shipping methods,
454
+ * Incoterms and Accounts and answers what taking them over would assign, writing nothing. As
455
+ * {@link paymentDryRun}: slow on a large division, a refused read is in `resources`.
456
+ *
457
+ * Refused `EXACT_ONLINE_NOT_CONNECTED` (`BusinessRuleError`, 422) for a store that is not
458
+ * connected to a division, before any Exact call; `PLUGIN_ACCESS_DENIED` (403).
459
+ *
460
+ * @effect read
461
+ * @permission ReadSettings
462
+ */
463
+ deliveryDryRun(options?: Call): Promise<ExactDeliveryTermsDryRun>;
464
+ }
465
+ /**
466
+ * What Exact holds for one customer of the store (`admin.integrations.exactOnline.customers`):
467
+ * the customer page's Exact cards. Local reads of what the sync last wrote; none calls Exact.
468
+ * Read on any store, with or without the Exact Online plugin.
469
+ */
470
+ export interface ExactOnlineCustomersModule {
471
+ /**
472
+ * The customer's Exact payment terms, staged ones included (`managedExternally: false` while
473
+ * the mirror only shadows the store's own terms), with the linked Account. `null` for a store
474
+ * with no connected division, or a customer Exact holds no terms for. The provider-neutral
475
+ * terms an order takes are `customers.credit.paymentTerms`.
476
+ *
477
+ * @effect read
478
+ * @permission ReadCustomer
479
+ */
480
+ paymentTerms(customerId: string, options?: Call): Promise<ExactCustomerPaymentTerms | null>;
481
+ /**
482
+ * The customer's Exact delivery assignment, staged ones included, with the linked Account.
483
+ * `null` when Exact holds none for the customer. The provider-neutral terms an order takes are
484
+ * `customers.deliveryTerms`.
485
+ *
486
+ * @effect read
487
+ * @permission ReadCustomer
488
+ */
489
+ deliveryTerms(customerId: string, options?: Call): Promise<ExactCustomerDeliveryTerms | null>;
490
+ /**
491
+ * The customer's Exact price list against the group and price list the store reconciled for
492
+ * it (see `ExactCustomerPriceListStatus`). A customer the store does not hold, or one not
493
+ * linked to Exact, reads `unlinked`; never `null`.
494
+ *
495
+ * @effect read
496
+ * @permission ReadCustomer
497
+ */
498
+ priceList(customerId: string, options?: Call): Promise<ExactCustomerPriceList>;
499
+ }
500
+ /**
501
+ * The store's orders in Exact (`admin.integrations.exactOnline.orders`): an order's place there,
502
+ * pushing one, and the inbound order import. Every method is refused `PLUGIN_ACCESS_DENIED`
503
+ * (`PermissionDeniedError`, 403) for a store without the Exact Online plugin (never for a
504
+ * SuperAdmin).
505
+ *
506
+ * Exact is the source of truth for an Exact store's figures: nothing here recomputes what an
507
+ * order bills from the platform's side; {@link reprice} and {@link repriceAll} take Exact's VAT
508
+ * rates as they are.
509
+ */
510
+ export interface ExactOnlineOrdersModule {
511
+ /**
512
+ * The order's place in Exact (pushed from here, imported from Exact, or neither), what blocks a
513
+ * push (a guest order, lines not linked to an Exact item) and how Exact's sales order differs
514
+ * from the order. An order the store does not hold reads as not in Exact, with no customer.
515
+ * A local read. An engine that predates `warnings` is asked again without it, and the answer
516
+ * carries `warnings: []`.
517
+ *
518
+ * @effect read
519
+ * @permission ReadOrder
520
+ */
521
+ state(orderId: string, options?: Call): Promise<ExactOrderState>;
522
+ /**
523
+ * An order imported from Exact: its revision, when it was last synced, whether Exact's order
524
+ * drifted from it and whether Exact deleted it. `null` for an order that was never imported,
525
+ * or a store with no connected division. A local read.
526
+ *
527
+ * @effect read
528
+ * @permission ReadOrder
529
+ */
530
+ syncState(orderId: string, options?: Call): Promise<ExactOrderSyncState | null>;
531
+ /**
532
+ * Push the order to Exact as a sales order, linking the customer to their Exact Account and
533
+ * creating one when needed. This writes into the store's Exact division and cannot be undone
534
+ * from the platform. Write-once: an order already in Exact (pushed, or imported from it)
535
+ * answers `alreadyPushed: true` and writes nothing.
536
+ *
537
+ * A refusal is an answer, not a throw: `success: false` with the reason in `error` (and
538
+ * `errorCode` when it has one). Refused that way, with nothing sent to Exact: a guest order,
539
+ * lines not linked to an Exact item, a sandbox store, a store with no active Exact connection,
540
+ * or an order linked to a sales order of another division. What Exact itself refuses arrives
541
+ * the same way. A sales order that came out different from the order (Exact derives each line's
542
+ * VAT itself) answers `success: true` with the differences in `warnings`. An engine that
543
+ * predates `warnings` refuses the document before running it; it is then sent once more
544
+ * without the field, and the answer carries `warnings: null`.
545
+ *
546
+ * The engine takes no idempotency key for it yet, so `options.idempotencyKey` is not sent; the
547
+ * write-once rule above is what keeps a repeat from writing twice.
548
+ *
549
+ * @effect irreversible
550
+ * @permission UpdateOrder
551
+ */
552
+ push(orderId: string, options?: Call): Promise<ExactOrderPushResult>;
553
+ /**
554
+ * Re-split an order imported from Exact at Exact's own per-line VAT rates, read live from its
555
+ * sales order: each line's tax changes, while the order's gross total, code, payment and
556
+ * fulfilment stay. It changes what the order bills, line by line.
557
+ *
558
+ * A refusal is `success: false` with the reason in `error`, not a throw: an order that was not
559
+ * imported from Exact, a store with no connected division, an import link of another division,
560
+ * a sales order Exact no longer holds. `changed: false` when every line already matched.
561
+ *
562
+ * @effect money
563
+ * @permission UpdateOrder
564
+ */
565
+ reprice(orderId: string, options?: Call): Promise<ExactOrderRepriceResult>;
566
+ /**
567
+ * {@link reprice} every order the store imported from the connected division, one by one,
568
+ * reading each sales order from Exact (slow, and Exact calls, on a large history). Answers the
569
+ * counts; one order's failure is counted, never thrown. All zero for a store with no connected
570
+ * division.
571
+ *
572
+ * @effect money
573
+ * @permission UpdateSettings
574
+ */
575
+ repriceAll(options?: Call): Promise<ExactOrderRepriceAllResult>;
576
+ /**
577
+ * Queue an inbound order sync: Exact's new and changed sales orders since the last run are
578
+ * booked as placed orders with a settled payment (it records money). Answers `true` once queued;
579
+ * the outcome arrives in `sync.logs`. Queued on a store that is not connected too, where the
580
+ * run fails on the worker.
581
+ *
582
+ * Refused, with nothing queued: `FIELD_GROUP_LOCKED` (`BusinessRuleError`, 422) while an app or
583
+ * API token owns a field group of the store (the import fills an existing customer's empty name
584
+ * and phone), `error.details[]` naming each owner; `PLUGIN_ACCESS_DENIED` (403).
585
+ *
586
+ * @effect money
587
+ * @permission UpdateSettings
588
+ */
589
+ runSync(options?: Call): Promise<boolean>;
590
+ /**
591
+ * Queue a full order backfill: the order cursor is reset and the whole order history of the
592
+ * division is read again. Orders already imported are skipped by their fingerprint, so it also
593
+ * recovers orders a run failed on; any it had not imported are booked as placed, paid orders.
594
+ * Answers `true`, also for a store that is not connected, where it does nothing. Refusals as
595
+ * {@link runSync}.
596
+ *
597
+ * @effect money
598
+ * @permission UpdateSettings
599
+ */
600
+ runBackfill(options?: Call): Promise<boolean>;
601
+ }
602
+ /** What Exact holds for one product of the store (`admin.integrations.exactOnline.products`). */
603
+ export interface ExactOnlineProductsModule {
604
+ /**
605
+ * Whether Exact owns the product's catalogue data, its Exact item and item group, and whether
606
+ * the catalogue sync switched it off. `null` for a product the store does not hold. Read on any
607
+ * store, with or without the Exact Online plugin. Needs `ReadCatalog` (or `ReadProduct`).
608
+ *
609
+ * @effect read
610
+ */
611
+ status(productId: string, options?: Call): Promise<ExactProductStatus | null>;
612
+ }
613
+ /**
614
+ * The store's Exact Online connection, its settings and its import structure
615
+ * (`admin.integrations.exactOnline`). Always the store the client is scoped to; a SuperAdmin acts
616
+ * on ANOTHER store with `admin.withTenant({ scope: { kind: 'channel', code } })`, or a per-call
617
+ * `tenant`.
618
+ *
619
+ * The connection is OAuth: `authorizationUrl` gives the consent page of the region's Exact host,
620
+ * and Exact's callback stores the division. A store without the Exact Online plugin is refused
621
+ * every method but `config.get` and `disconnect` (`PLUGIN_ACCESS_DENIED`, 403; never for a
622
+ * SuperAdmin). The inbound sync ({@link sync}), the shipping-method mapping ({@link shipping}),
623
+ * the connection logs ({@link connectionLogs}), the payment and delivery terms ({@link terms})
624
+ * and what Exact holds for a customer, an order or a product ({@link customers},
625
+ * {@link orders}, {@link products}) are here too.
626
+ */
627
+ export interface ExactOnlineModule {
628
+ /** The connection's settings. See {@link ExactOnlineConfigModule}. */
629
+ config: ExactOnlineConfigModule;
630
+ /** The store's own Exact app. See {@link ExactOnlineCredentialsModule}. */
631
+ credentials: ExactOnlineCredentialsModule;
632
+ /**
633
+ * The Exact consent page to send the merchant to (open it in a popup): the region's Exact host
634
+ * with the store's own app and an encrypted state. Nothing is stored; the connection is made
635
+ * when Exact calls back. `region` defaults to the engine's (`nl`).
636
+ *
637
+ * Refused: `PLUGIN_ACCESS_DENIED` (403); `ORGANIZATION_WORKSPACE_NOT_A_STORE` (422);
638
+ * `FIELD_GROUP_LOCKED` (422) while an app or API token owns a field group of the store (the URL
639
+ * is withheld). The store has no app credentials yet, or the region is unknown: an uncoded
640
+ * error (`GRAPHQL_ERROR`, 500; not coded yet).
641
+ *
642
+ * @effect read
643
+ * @permission UpdateSettings
644
+ */
645
+ authorizationUrl(region?: string, options?: Call): Promise<string>;
646
+ /**
647
+ * [deletes] Disconnect the store from Exact: the OAuth tokens, the division and the connection
648
+ * are cleared and Exact is switched off. The app credentials and every setting stay, so a
649
+ * reconnect needs only the consent. Answers `true`, or `false` when the store never had a row.
650
+ * Allowed without the plugin (it only removes access).
651
+ *
652
+ * Before clearing, it removes the store's Exact webhook subscriptions while the token still
653
+ * works and marks the store's synced delivery terms stale; either one failing is NOT reported
654
+ * (the engine ignores it), so a subscription can outlive the disconnect in Exact.
655
+ *
656
+ * @effect destructive
657
+ * @permission UpdateSettings
658
+ */
659
+ disconnect(options?: Call): Promise<boolean>;
660
+ /** Live samples of the connected division. See {@link ExactOnlineSamplesModule}. */
661
+ samples: ExactOnlineSamplesModule;
662
+ /** How the connected division is organised. See {@link ExactOnlineStructureModule}. */
663
+ structure: ExactOnlineStructureModule;
664
+ /** The store's webhook subscriptions. See {@link ExactOnlineWebhooksModule}. */
665
+ webhooks: ExactOnlineWebhooksModule;
666
+ /**
667
+ * The Exact API calls a day `schedule` would make, sweep by sweep, and whether that passes the
668
+ * advisory budget. Advice only: nothing is capped by it. The schedule is read as a save would
669
+ * store it: merged over the store's stored schedule (a window left out keeps the stored one)
670
+ * and every interval rounded and clamped to its bounds, which the answer names
671
+ * (`minIntervalMinutes`, `maxIntervalMinutes`). It is never refused for an interval out of
672
+ * bounds. Makes no Exact call.
673
+ *
674
+ * Intervals and the budget are whole numbers (the engine refuses a fraction `BAD_USER_INPUT`,
675
+ * 400). Refused `PLUGIN_ACCESS_DENIED` (403).
676
+ *
677
+ * @effect read
678
+ * @permission ReadSettings
679
+ */
680
+ syncEstimate(schedule: ExactSyncScheduleInput, options?: Call): Promise<ExactSyncEstimate>;
681
+ /** The inbound sync: its runs, its health, its cursors. See {@link ExactOnlineSyncModule}. */
682
+ sync: ExactOnlineSyncModule;
683
+ /**
684
+ * The store's stock locations and the Exact warehouse each mirrors. Read-only: the catalogue
685
+ * sweep links them. `PLUGIN_ACCESS_DENIED` (403).
686
+ *
687
+ * @effect read
688
+ * @permission ReadSettings
689
+ */
690
+ warehouseLinks(options?: Call): Promise<ExactWarehouseLink[]>;
691
+ /** The shipping-method mapping. See {@link ExactOnlineShippingModule}. */
692
+ shipping: ExactOnlineShippingModule;
693
+ /** The API calls and events between the store and Exact. See {@link ExactOnlineConnectionLogsModule}. */
694
+ connectionLogs: ExactOnlineConnectionLogsModule;
695
+ /** The payment and delivery terms. See {@link ExactOnlineTermsModule}. */
696
+ terms: ExactOnlineTermsModule;
697
+ /** What Exact holds for one customer. See {@link ExactOnlineCustomersModule}. */
698
+ customers: ExactOnlineCustomersModule;
699
+ /** The store's orders in Exact. See {@link ExactOnlineOrdersModule}. */
700
+ orders: ExactOnlineOrdersModule;
701
+ /** What Exact holds for one product. See {@link ExactOnlineProductsModule}. */
702
+ products: ExactOnlineProductsModule;
703
+ }
704
+ /**
705
+ * `updateExactOnlineConfig`'s inline arguments, each with its GraphQL type: the SDK takes one
706
+ * object, the wire keeps the arguments (adding an input type would be a second door to keep).
707
+ */
708
+ export declare const EXACT_ONLINE_CONFIG_ARGUMENTS: {
709
+ readonly region: "String";
710
+ readonly enabled: "Boolean";
711
+ readonly shippingItemCode: "String";
712
+ readonly discountItemCode: "String";
713
+ readonly externalLineItemCode: "String";
714
+ readonly pushSurcharges: "Boolean";
715
+ readonly surchargeItemCode: "String";
716
+ readonly negativeSurchargeItemCode: "String";
717
+ readonly autoPush: "ExactAutoPushConfigInput";
718
+ readonly customerSync: "ExactCustomerSyncConfigInput";
719
+ readonly paymentTerms: "ExactPaymentTermsConfigInput";
720
+ readonly deliveryTerms: "ExactDeliveryTermsConfigInput";
721
+ readonly syncSchedule: "ExactSyncScheduleInput";
722
+ readonly catalogueImportPolicy: "ExactCatalogueImportPolicyInput";
723
+ };
724
+ export declare const EXACT_ONLINE_CONFIG_QUERY = "\n query ExactOnlineConfig {\n exactOnlineConfig { \n id\n enabled\n connected\n region\n division\n companyName\n clientId\n hasCustomCredentials\n hasWebhookSecret\n lastConnectedAt\n lastRefreshedAt\n accessTokenExpiresAt\n shippingItemCode\n discountItemCode\n externalLineItemCode\n pushSurcharges\n surchargeItemCode\n negativeSurchargeItemCode\n pushSurchargesWarning\n autoPush { enabled defaultTrigger rules { customerGroupId trigger } }\n customerSync {\n enabled\n webhookEnabled\n pushEnabled\n accountFilter\n overwritePolicy\n fields { name email address }\n }\n paymentTerms {\n enabled\n synchronizationEnabled\n newAccountPaymentConditionCode\n paymentMethodConditions { paymentMethodId conditionCode }\n }\n deliveryTerms {\n enabled\n synchronizationEnabled\n forwardRequestedDeliveryDate\n sendDeliveryAddress\n newAccountShippingMethodId\n newAccountIncotermCode\n newAccountIncotermVersion\n newAccountIncotermAddress\n newAccountShippingLeadDays\n newAccountDeliveryAdvice\n }\n syncSchedule {\n delta { enabled intervalMinutes }\n full { enabled intervalMinutes }\n order { enabled intervalMinutes }\n purchaseOrders { enabled intervalMinutes }\n purchaseOrdersReconcile { enabled intervalMinutes }\n customers { enabled intervalMinutes }\n priceLists { enabled intervalMinutes }\n dailyCallBudget\n }\n catalogueImportPolicy {\n requireWebshopFlag\n nonStockItems\n unpricedItems\n priceBasis\n pictures\n stockBasis\n }\n deltaLastEnqueuedAt\n fullLastEnqueuedAt\n orderLastEnqueuedAt\n purchaseOrderLastEnqueuedAt\n purchaseOrderReconcileLastEnqueuedAt\n customerLastEnqueuedAt\n priceListLastEnqueuedAt\n }\n }\n";
725
+ export declare const UPDATE_EXACT_ONLINE_CONFIG_MUTATION = "\n mutation UpdateExactOnlineConfig(\n $region: String\n $enabled: Boolean\n $shippingItemCode: String\n $discountItemCode: String\n $externalLineItemCode: String\n $pushSurcharges: Boolean\n $surchargeItemCode: String\n $negativeSurchargeItemCode: String\n $autoPush: ExactAutoPushConfigInput\n $customerSync: ExactCustomerSyncConfigInput\n $paymentTerms: ExactPaymentTermsConfigInput\n $deliveryTerms: ExactDeliveryTermsConfigInput\n $syncSchedule: ExactSyncScheduleInput\n $catalogueImportPolicy: ExactCatalogueImportPolicyInput\n ) {\n updateExactOnlineConfig(\n region: $region\n enabled: $enabled\n shippingItemCode: $shippingItemCode\n discountItemCode: $discountItemCode\n externalLineItemCode: $externalLineItemCode\n pushSurcharges: $pushSurcharges\n surchargeItemCode: $surchargeItemCode\n negativeSurchargeItemCode: $negativeSurchargeItemCode\n autoPush: $autoPush\n customerSync: $customerSync\n paymentTerms: $paymentTerms\n deliveryTerms: $deliveryTerms\n syncSchedule: $syncSchedule\n catalogueImportPolicy: $catalogueImportPolicy\n ) {\n \n id\n enabled\n connected\n region\n division\n companyName\n clientId\n hasCustomCredentials\n hasWebhookSecret\n lastConnectedAt\n lastRefreshedAt\n accessTokenExpiresAt\n shippingItemCode\n discountItemCode\n externalLineItemCode\n pushSurcharges\n surchargeItemCode\n negativeSurchargeItemCode\n pushSurchargesWarning\n autoPush { enabled defaultTrigger rules { customerGroupId trigger } }\n customerSync {\n enabled\n webhookEnabled\n pushEnabled\n accountFilter\n overwritePolicy\n fields { name email address }\n }\n paymentTerms {\n enabled\n synchronizationEnabled\n newAccountPaymentConditionCode\n paymentMethodConditions { paymentMethodId conditionCode }\n }\n deliveryTerms {\n enabled\n synchronizationEnabled\n forwardRequestedDeliveryDate\n sendDeliveryAddress\n newAccountShippingMethodId\n newAccountIncotermCode\n newAccountIncotermVersion\n newAccountIncotermAddress\n newAccountShippingLeadDays\n newAccountDeliveryAdvice\n }\n syncSchedule {\n delta { enabled intervalMinutes }\n full { enabled intervalMinutes }\n order { enabled intervalMinutes }\n purchaseOrders { enabled intervalMinutes }\n purchaseOrdersReconcile { enabled intervalMinutes }\n customers { enabled intervalMinutes }\n priceLists { enabled intervalMinutes }\n dailyCallBudget\n }\n catalogueImportPolicy {\n requireWebshopFlag\n nonStockItems\n unpricedItems\n priceBasis\n pictures\n stockBasis\n }\n deltaLastEnqueuedAt\n fullLastEnqueuedAt\n orderLastEnqueuedAt\n purchaseOrderLastEnqueuedAt\n purchaseOrderReconcileLastEnqueuedAt\n customerLastEnqueuedAt\n priceListLastEnqueuedAt\n\n }\n }\n";
726
+ export declare const SET_EXACT_ONLINE_CREDENTIALS_MUTATION = "\n mutation SetExactOnlineCredentials(\n $clientId: String!\n $clientSecret: String\n $webhookSecret: String\n ) {\n setExactOnlineCredentials(\n clientId: $clientId\n clientSecret: $clientSecret\n webhookSecret: $webhookSecret\n ) {\n \n id\n enabled\n connected\n region\n division\n companyName\n clientId\n hasCustomCredentials\n hasWebhookSecret\n lastConnectedAt\n lastRefreshedAt\n accessTokenExpiresAt\n shippingItemCode\n discountItemCode\n externalLineItemCode\n pushSurcharges\n surchargeItemCode\n negativeSurchargeItemCode\n pushSurchargesWarning\n autoPush { enabled defaultTrigger rules { customerGroupId trigger } }\n customerSync {\n enabled\n webhookEnabled\n pushEnabled\n accountFilter\n overwritePolicy\n fields { name email address }\n }\n paymentTerms {\n enabled\n synchronizationEnabled\n newAccountPaymentConditionCode\n paymentMethodConditions { paymentMethodId conditionCode }\n }\n deliveryTerms {\n enabled\n synchronizationEnabled\n forwardRequestedDeliveryDate\n sendDeliveryAddress\n newAccountShippingMethodId\n newAccountIncotermCode\n newAccountIncotermVersion\n newAccountIncotermAddress\n newAccountShippingLeadDays\n newAccountDeliveryAdvice\n }\n syncSchedule {\n delta { enabled intervalMinutes }\n full { enabled intervalMinutes }\n order { enabled intervalMinutes }\n purchaseOrders { enabled intervalMinutes }\n purchaseOrdersReconcile { enabled intervalMinutes }\n customers { enabled intervalMinutes }\n priceLists { enabled intervalMinutes }\n dailyCallBudget\n }\n catalogueImportPolicy {\n requireWebshopFlag\n nonStockItems\n unpricedItems\n priceBasis\n pictures\n stockBasis\n }\n deltaLastEnqueuedAt\n fullLastEnqueuedAt\n orderLastEnqueuedAt\n purchaseOrderLastEnqueuedAt\n purchaseOrderReconcileLastEnqueuedAt\n customerLastEnqueuedAt\n priceListLastEnqueuedAt\n\n }\n }\n";
727
+ export declare const EXACT_ONLINE_AUTHORIZATION_URL_MUTATION = "\n mutation ExactOnlineAuthorizationUrl($region: String) {\n exactOnlineAuthorizationUrl(region: $region)\n }\n";
728
+ export declare const DISCONNECT_EXACT_ONLINE_MUTATION = "\n mutation DisconnectExactOnline {\n disconnectExactOnline\n }\n";
729
+ export declare const EXACT_ONLINE_SAMPLE_ACCOUNTS_QUERY = "\n query ExactOnlineSampleAccounts($limit: Int) {\n exactOnlineSampleAccounts(limit: $limit) { id code name city country email status }\n }\n";
730
+ export declare const EXACT_ONLINE_SAMPLE_ITEMS_QUERY = "\n query ExactOnlineSampleItems($limit: Int) {\n exactOnlineSampleItems(limit: $limit) { id code description isSalesItem isStockItem }\n }\n";
731
+ export declare const EXACT_ONLINE_CATALOGUE_STRUCTURE_QUERY = "\n query ExactOnlineCatalogueStructure($sample: Int) {\n exactOnlineCatalogueStructure(sample: $sample) {\n sampledCount\n distinctItemGroupCount\n topItemGroups { code description itemCount }\n classFields { field nonEmptyCount distinctCount }\n rows { code description itemGroup }\n }\n }\n";
732
+ export declare const EXACT_ONLINE_CUSTOMER_STRUCTURE_QUERY = "\n query ExactOnlineCustomerStructure($sample: Int) {\n exactOnlineCustomerStructure(sample: $sample) {\n sampledCount\n withEmail\n withoutEmail\n withAddress\n resellerCount\n dimensions {\n sequence\n name\n slotField\n populatedCount\n distinctCount\n values { id code description accountCount }\n }\n priceLists { id code description accountCount }\n rows { code name email city country isReseller classifications priceList }\n }\n }\n";
733
+ export declare const EXACT_ONLINE_PRICING_STRUCTURE_QUERY = "\n query ExactOnlinePricingStructure {\n exactOnlinePricingStructure {\n priceLists { id code description currency }\n priceListItemPriceCount\n priceListItemSamples {\n itemCode\n itemDescription\n quantity\n newPrice\n discount\n entryMethod\n basePrice\n }\n accountsWithDefaultPriceList\n customerPriceCount\n customerPriceDistinctAccounts\n customerPriceDistinctItems\n customerPriceSamples { itemCode accountName price quantity currency }\n sampled\n }\n }\n";
734
+ export declare const EXACT_ONLINE_WEBHOOK_STATUS_QUERY = "\n query ExactOnlineWebhookStatus {\n exactOnlineWebhookStatus {\n supported\n registered\n subscriptions { topic subscriptionId callbackUrl }\n checkedAt\n error\n }\n }\n";
735
+ export declare const SYNC_EXACT_ONLINE_WEBHOOKS_MUTATION = "\n mutation SyncExactOnlineWebhooks {\n syncExactOnlineWebhooks\n }\n";
736
+ export declare const EXACT_ONLINE_SYNC_ESTIMATE_QUERY = "\n query ExactOnlineSyncEstimate($schedule: ExactSyncScheduleInput!) {\n exactOnlineSyncEstimate(schedule: $schedule) {\n delta { \n enabled\n intervalMinutes\n minIntervalMinutes\n maxIntervalMinutes\n callsPerRun\n runsPerDay\n callsPerDay\n }\n full { \n enabled\n intervalMinutes\n minIntervalMinutes\n maxIntervalMinutes\n callsPerRun\n runsPerDay\n callsPerDay\n }\n order { \n enabled\n intervalMinutes\n minIntervalMinutes\n maxIntervalMinutes\n callsPerRun\n runsPerDay\n callsPerDay\n }\n purchaseOrders { \n enabled\n intervalMinutes\n minIntervalMinutes\n maxIntervalMinutes\n callsPerRun\n runsPerDay\n callsPerDay\n }\n purchaseOrdersReconcile { \n enabled\n intervalMinutes\n minIntervalMinutes\n maxIntervalMinutes\n callsPerRun\n runsPerDay\n callsPerDay\n }\n customers { \n enabled\n intervalMinutes\n minIntervalMinutes\n maxIntervalMinutes\n callsPerRun\n runsPerDay\n callsPerDay\n }\n priceLists { \n enabled\n intervalMinutes\n minIntervalMinutes\n maxIntervalMinutes\n callsPerRun\n runsPerDay\n callsPerDay\n }\n total\n dailyCallBudget\n overBudget\n }\n }\n";
737
+ export declare const EXACT_ONLINE_SYNC_LOGS_QUERY = "\n query ExactOnlineSyncLogs($limit: Int, $entity: String) {\n exactOnlineSyncLogs(limit: $limit, entity: $entity) { \n id\n entity\n mode\n status\n createdCount\n updatedCount\n skippedCount\n failedCount\n detachedCount\n error\n durationMs\n createdAt\n catalogueExclusions { inactive notWebshop nonStock unpriced total absent }\n }\n }\n";
738
+ export declare const EXACT_ONLINE_SYNC_HEALTH_QUERY = "\n query ExactOnlineSyncHealth {\n exactOnlineSyncHealth {\n customers { lastRunAt status error lastSuccessAt }\n catalogue { lastRunAt status error lastSuccessAt }\n orders { lastRunAt status error lastSuccessAt }\n }\n }\n";
739
+ export declare const RUN_EXACT_ONLINE_CATALOGUE_SYNC_MUTATION = "\n mutation RunExactOnlineCatalogueSync {\n runExactOnlineCatalogueSync\n }\n";
740
+ export declare const RUN_EXACT_ONLINE_CUSTOMER_SYNC_MUTATION = "\n mutation RunExactOnlineCustomerSync {\n runExactOnlineCustomerSync\n }\n";
741
+ export declare const RUN_EXACT_ONLINE_PRICE_LIST_SYNC_MUTATION = "\n mutation RunExactOnlinePriceListSync {\n runExactOnlinePriceListSync\n }\n";
742
+ export declare const REIMPORT_EXACT_ONLINE_ITEM_PICTURES_MUTATION = "\n mutation ReimportExactOnlineItemPictures {\n reimportExactOnlineItemPictures\n }\n";
743
+ export declare const EXACT_ONLINE_SYNC_CURSORS_QUERY = "\n query ExactOnlineSyncCursors {\n exactOnlineSyncCursors { entity cursor }\n }\n";
744
+ export declare const RESET_EXACT_ONLINE_SYNC_CURSOR_MUTATION = "\n mutation ResetExactOnlineSyncCursor($entity: String!) {\n resetExactOnlineSyncCursor(entity: $entity)\n }\n";
745
+ export declare const EXACT_ONLINE_WAREHOUSE_LINKS_QUERY = "\n query ExactOnlineWarehouseLinks {\n exactOnlineWarehouseLinks { stockLocationId stockLocationName exactWarehouseId }\n }\n";
746
+ export declare const EXACT_ONLINE_SHIPPING_METHODS_QUERY = "\n query ExactOnlineShippingMethods {\n exactOnlineShippingMethods {\n mappings { \n vendureShippingMethodId\n vendureCode\n vendureName\n exactShippingMethodId\n exactManaged\n status\n }\n exact { id code description active amount linked }\n }\n }\n";
747
+ export declare const RUN_EXACT_ONLINE_SHIPPING_METHOD_SYNC_MUTATION = "\n mutation RunExactOnlineShippingMethodSync {\n runExactOnlineShippingMethodSync\n }\n";
748
+ export declare const IMPORT_EXACT_ONLINE_SHIPPING_METHOD_MUTATION = "\n mutation ImportExactOnlineShippingMethod($exactShippingMethodId: String!) {\n importExactOnlineShippingMethod(exactShippingMethodId: $exactShippingMethodId) {\n \n vendureShippingMethodId\n vendureCode\n vendureName\n exactShippingMethodId\n exactManaged\n status\n\n }\n }\n";
749
+ export declare const SET_EXACT_ONLINE_SHIPPING_METHOD_MAPPING_MUTATION = "\n mutation SetExactOnlineShippingMethodMapping(\n $vendureShippingMethodId: ID!\n $exactShippingMethodId: String\n ) {\n setExactOnlineShippingMethodMapping(\n vendureShippingMethodId: $vendureShippingMethodId\n exactShippingMethodId: $exactShippingMethodId\n ) {\n \n vendureShippingMethodId\n vendureCode\n vendureName\n exactShippingMethodId\n exactManaged\n status\n\n }\n }\n";
750
+ export declare const CONVERT_EXACT_ONLINE_SHIPPING_METHOD_TO_MAPPING_MUTATION = "\n mutation ConvertExactOnlineShippingMethodToMapping(\n $exactShippingMethodId: String!\n $vendureShippingMethodId: ID!\n ) {\n convertExactOnlineShippingMethodToMapping(\n exactShippingMethodId: $exactShippingMethodId\n vendureShippingMethodId: $vendureShippingMethodId\n ) {\n \n vendureShippingMethodId\n vendureCode\n vendureName\n exactShippingMethodId\n exactManaged\n status\n\n }\n }\n";
751
+ export declare const RETIRE_EXACT_ONLINE_IMPORTED_SHIPPING_METHOD_MUTATION = "\n mutation RetireExactOnlineImportedShippingMethod($exactShippingMethodId: String!) {\n retireExactOnlineImportedShippingMethod(exactShippingMethodId: $exactShippingMethodId)\n }\n";
752
+ export declare const EXACT_ONLINE_PAYMENT_CONDITIONS_QUERY = "\n query ExactOnlinePaymentConditions {\n exactOnlinePaymentConditions {\n exactId\n code\n description\n summary\n classification\n paymentDays\n paymentEndOfMonths\n paymentMethod\n percentage\n discountPaymentDays\n discountPercentage\n paymentDiscountType\n active\n syncedAt\n }\n }\n";
753
+ export declare const EXACT_ONLINE_PAYMENT_TERMS_DIAGNOSTICS_QUERY = "\n query ExactOnlinePaymentTermsDiagnostics {\n exactOnlinePaymentTermsDiagnostics {\n totalCustomers\n assignedCount\n unassignedCount\n unresolvedCount\n staleCount\n lastSyncedAt\n error\n permissionWarning\n distribution { code description customerCount }\n unresolvedCodes { code customerCount }\n lastReconciliation {\n mode\n status\n createdCount\n updatedCount\n deactivatedCount\n failedCount\n at\n error\n }\n }\n }\n";
754
+ export declare const EXACT_ONLINE_PAYMENT_TERMS_DRY_RUN_QUERY = "\n query ExactOnlinePaymentTermsDryRun {\n exactOnlinePaymentTermsDryRun {\n division\n generatedAt\n complete\n permissionWarning\n catalogRowCount\n catalogCodeCount\n accountCount\n assignedCount\n unassignedCount\n unresolvedCount\n uncheckedCount\n distribution { code description customerCount }\n duplicateConditions { code description summary classification scheduleCount }\n complexConditions { code description summary classification scheduleCount }\n unresolvedCodes { code customerCount }\n assignmentIssues { accountId accountCode conditionCode conditionDescription status }\n resources { resource ok permissionWarning error }\n }\n }\n";
755
+ export declare const EXACT_ONLINE_INCOTERMS_QUERY = "\n query ExactOnlineIncoterms {\n exactOnlineIncoterms {\n exactId\n code\n version\n description\n catalogAvailable\n stale\n lastSyncedAt\n error\n }\n }\n";
756
+ export declare const EXACT_ONLINE_DELIVERY_TERMS_DIAGNOSTICS_QUERY = "\n query ExactOnlineDeliveryTermsDiagnostics {\n exactOnlineDeliveryTermsDiagnostics {\n reconciliationRequired\n accountSyncStatus\n totalCustomers\n assignedCount\n unassignedCount\n unresolvedCount\n staleCount\n mappedMethodCount\n usableShippingMappingCount\n unmappedMethodCount\n inactiveMethodCount\n unavailableMethodCount\n nullAmountCount\n invalidIncotermCount\n lastSyncedAt\n error\n permissionWarning\n shippingMethodDistribution { exactId code description customerCount }\n incotermDistribution { code version description customerCount }\n warnings\n }\n }\n";
757
+ export declare const EXACT_ONLINE_DELIVERY_TERMS_DRY_RUN_QUERY = "\n query ExactOnlineDeliveryTermsDryRun {\n exactOnlineDeliveryTermsDryRun {\n division\n generatedAt\n complete\n permissionWarning\n shippingMethodCount\n activeShippingMethodCount\n mappingCount\n unmappedCatalogMethodCount\n nullAmountCount\n zeroAmountCount\n incotermCount\n accountCount\n assignedShippingMethodCount\n mappedAssignedShippingMethodCount\n unmappedAssignedShippingMethodCount\n unassignedShippingMethodCount\n unresolvedShippingMethodCount\n assignedIncotermCount\n unassignedIncotermCount\n unresolvedIncotermCount\n invalidPolicyCount\n shippingMethodDistribution { exactId customerCount }\n incotermDistribution { code version customerCount }\n assignmentIssues {\n accountId\n accountCode\n shippingMethodId\n incotermCode\n incotermVersion\n status\n message\n }\n resources { resource ok permissionWarning error }\n }\n }\n";
758
+ export declare const EXACT_ONLINE_CUSTOMER_PAYMENT_TERMS_QUERY = "\n query ExactOnlineCustomerPaymentTerms($customerId: ID!) {\n exactOnlineCustomerPaymentTerms(customerId: $customerId) {\n customerId\n source\n managedExternally\n linkedExternally\n status\n stale\n exactAccountId\n exactAccountCode\n conditionCode\n conditionDescription\n summary\n classification\n paymentDays\n paymentEndOfMonths\n paymentMethod\n percentage\n discountPaymentDays\n discountPercentage\n paymentDiscountType\n syncedAt\n lastCheckedAt\n error\n }\n }\n";
759
+ export declare const EXACT_ONLINE_CUSTOMER_DELIVERY_TERMS_QUERY = "\n query ExactOnlineCustomerDeliveryTerms($customerId: ID!) {\n exactOnlineCustomerDeliveryTerms(customerId: $customerId) {\n customerId\n source\n managedExternally\n linkedExternally\n status\n shippingMethodStatus\n policyStatus\n summary\n exactAccountId\n exactAccountCode\n preferredShippingMethodId\n preferredShippingMethodCode\n preferredShippingMethodName\n preferredShippingMethodAvailable\n eligibleShippingMethodIds\n incotermStatus\n incotermCode\n incotermVersion\n incotermAddress\n incotermDescription\n shippingLeadDays\n deliveryAdvice\n stale\n syncedAt\n lastCheckedAt\n error\n }\n }\n";
760
+ export declare const EXACT_ONLINE_CUSTOMER_PRICE_LIST_QUERY = "\n query ExactOnlineCustomerPriceList($customerId: ID!) {\n exactOnlineCustomerPriceList(customerId: $customerId) {\n customerId\n exactAccountId\n exactAccountCode\n exactPriceListId\n groupId\n groupName\n priceListId\n priceListName\n status\n lastReconciledAt\n lastError\n }\n }\n";
761
+ export declare const EXACT_ONLINE_ORDER_STATE_QUERY = "\n query ExactOnlineOrderState($orderId: ID!) {\n exactOnlineOrderState(orderId: $orderId) {\n pushed\n origin\n salesOrderId\n salesOrderNumber\n pushedAt\n hasCustomer\n customerLinked\n unmappedSkus\n warnings\n }\n }\n";
762
+ export declare const EXACT_ONLINE_ORDER_SYNC_STATE_QUERY = "\n query ExactOnlineOrderSyncState($orderId: ID!) {\n exactOnlineOrderSyncState(orderId: $orderId) {\n exactSalesOrderId\n exactOrderNumber\n revision\n lastSyncedAt\n driftDetected\n exactDeletedAt\n unmappedSkus\n }\n }\n";
763
+ export declare const PUSH_ORDER_TO_EXACT_ONLINE_MUTATION = "\n mutation PushOrderToExactOnline($orderId: ID!) {\n pushOrderToExactOnline(orderId: $orderId) {\n success\n alreadyPushed\n salesOrderId\n salesOrderNumber\n error\n errorCode\n warnings\n }\n }\n";
764
+ /**
765
+ * {@link EXACT_ONLINE_ORDER_STATE_QUERY} without `warnings`, for an engine that predates the field
766
+ * (#1925): services deploy separately, and GraphQL refuses the whole document over one unknown
767
+ * field. Drop it once every engine serves `warnings` (orchestrator probe 2026-10-16: production
768
+ * did not yet).
769
+ */
770
+ export declare const EXACT_ONLINE_ORDER_STATE_LEGACY_QUERY = "\n query ExactOnlineOrderState($orderId: ID!) {\n exactOnlineOrderState(orderId: $orderId) {\n pushed\n origin\n salesOrderId\n salesOrderNumber\n pushedAt\n hasCustomer\n customerLinked\n unmappedSkus\n }\n }\n";
771
+ /**
772
+ * {@link PUSH_ORDER_TO_EXACT_ONLINE_MUTATION} without `warnings`, for an engine that predates the
773
+ * field. Safe to send after the current document was refused: an unknown field fails validation,
774
+ * before the push runs, so nothing reached Exact. Drop it with the state read's.
775
+ */
776
+ export declare const PUSH_ORDER_TO_EXACT_ONLINE_LEGACY_MUTATION = "\n mutation PushOrderToExactOnline($orderId: ID!) {\n pushOrderToExactOnline(orderId: $orderId) {\n success\n alreadyPushed\n salesOrderId\n salesOrderNumber\n error\n errorCode\n }\n }\n";
777
+ export declare const REPRICE_EXACT_ONLINE_ORDER_MUTATION = "\n mutation RepriceExactOnlineOrder($orderId: ID!) {\n repriceExactOnlineOrder(orderId: $orderId) {\n success\n changed\n linesRepriced\n error\n }\n }\n";
778
+ export declare const REPRICE_ALL_EXACT_ONLINE_IMPORTED_ORDERS_MUTATION = "\n mutation RepriceAllExactOnlineImportedOrders {\n repriceAllExactOnlineImportedOrders {\n total\n repriced\n skipped\n failed\n }\n }\n";
779
+ export declare const RUN_EXACT_ONLINE_ORDER_SYNC_MUTATION = "\n mutation RunExactOnlineOrderSync {\n runExactOnlineOrderSync\n }\n";
780
+ export declare const RUN_EXACT_ONLINE_ORDER_BACKFILL_MUTATION = "\n mutation RunExactOnlineOrderBackfill {\n runExactOnlineOrderBackfill\n }\n";
781
+ export declare const EXACT_PRODUCT_STATUS_QUERY = "\n query ExactProductStatus($id: ID!) {\n product(id: $id) {\n id\n customFields {\n exactManaged\n exactItemId\n exactItemGroupId\n exactDisabledReason\n }\n }\n }\n";
782
+ /** How long a connection-log export may stream before the call gives up, unless said otherwise. */
783
+ export declare const EXACT_ONLINE_LOG_EXPORT_TIMEOUT_MS = 120000;
784
+ export declare function createExactOnlineModule(transport: Transport): ExactOnlineModule;