@engramx/idl 0.16.0-rc.5 → 0.16.0-rc.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/market.did CHANGED
@@ -81,6 +81,7 @@ type SessionCounts =
81
81
  closing: nat;
82
82
  expired: nat;
83
83
  open: nat;
84
+ refundOwed: opt nat;
84
85
  total: nat;
85
86
  };
86
87
  type SessionConfig =
@@ -171,88 +172,93 @@ type RevenueSummary =
171
172
  type Result_9 =
172
173
  variant {
173
174
  Err: Error;
174
- Ok: Page_7;
175
+ Ok: Page_5;
175
176
  };
176
177
  type Result_8 =
177
178
  variant {
178
179
  Err: Error;
179
- Ok: Page_5;
180
+ Ok: Page_4;
180
181
  };
181
182
  type Result_7 =
182
183
  variant {
183
184
  Err: Error;
184
- Ok: Page_4;
185
+ Ok: Page_2;
185
186
  };
186
187
  type Result_6 =
187
188
  variant {
188
189
  Err: Error;
189
- Ok: Page_2;
190
+ Ok: Page_1;
190
191
  };
191
192
  type Result_5 =
192
193
  variant {
193
194
  Err: Error;
194
- Ok: Page_1;
195
+ Ok: SessionState;
195
196
  };
196
197
  type Result_4 =
197
198
  variant {
198
199
  Err: Error;
199
- Ok: SessionState;
200
+ Ok: PaymentQuote;
200
201
  };
201
202
  type Result_3 =
202
203
  variant {
203
204
  Err: Error;
204
- Ok: PaymentQuote;
205
+ Ok: EscrowRecovery;
205
206
  };
206
207
  type Result_2 =
207
208
  variant {
208
209
  Err: Error;
209
210
  Ok: text;
210
211
  };
211
- type Result_18 =
212
+ type Result_19 =
212
213
  variant {
213
214
  Err: Error;
214
215
  Ok: X402Endpoint;
215
216
  };
216
- type Result_17 =
217
+ type Result_18 =
217
218
  variant {
218
219
  Err: Error;
219
220
  Ok: ServiceRequestResponse;
220
221
  };
221
- type Result_16 =
222
+ type Result_17 =
222
223
  variant {
223
224
  Err: Error;
224
225
  Ok: ContentResponse;
225
226
  };
226
- type Result_15 =
227
+ type Result_16 =
227
228
  variant {
228
229
  Err: Error;
229
230
  Ok: opt text;
230
231
  };
231
- type Result_14 =
232
+ type Result_15 =
232
233
  variant {
233
234
  Err: Error;
234
235
  Ok: Job;
235
236
  };
236
- type Result_13 =
237
+ type Result_14 =
237
238
  variant {
238
239
  Err: Error;
239
240
  Ok: blob;
240
241
  };
241
- type Result_12 =
242
+ type Result_13 =
242
243
  variant {
243
244
  Err: Error;
244
245
  Ok: JobStatus;
245
246
  };
246
- type Result_11 =
247
+ type Result_12 =
247
248
  variant {
248
249
  Err: Error;
249
250
  Ok: RevenueSummary;
250
251
  };
251
- type Result_10 =
252
+ type Result_11 =
252
253
  variant {
253
254
  Err: Error;
254
255
  Ok: SellerStatus;
255
256
  };
257
+ type Result_10 =
258
+ variant {
259
+ Err: Error;
260
+ Ok: Page_7;
261
+ };
256
262
  type Result_1 =
257
263
  variant {
258
264
  Err: Error;
@@ -466,6 +472,11 @@ type GenesisNote =
466
472
  predecessorSize: opt nat;
467
473
  version: text;
468
474
  };
475
+ type EscrowRecovery =
476
+ record {
477
+ amount: TokenAmount;
478
+ blockIndex: nat;
479
+ };
469
480
  type Error =
470
481
  variant {
471
482
  Conflict: text;
@@ -616,6 +627,9 @@ service : {
616
627
  /// is RATIFIED as the 0.16.0 contract (the owner's ruling of 2026-10-02, the pre-cut
617
628
  /// recommendation); giving the library one arm per kind of refusal is post-cut dependency work,
618
629
  /// not a change made mid-cut.
630
+ /// ⟨2026-10-07, beside the count above⟩ Twelve: the admin's `retrySellerPayment` (the owner's
631
+ /// decision of that day) passes the library's settle refusal through as `#Conflict` too — state
632
+ /// behind this canister's own gate, like the other six.
619
633
  ///
620
634
  /// It also refuses while TRADE IS FROZEN, and that one is a true `#Conflict` — the refusal says
621
635
  /// so explicitly ("Not a permission problem and not a missing job"), and `isTradeFrozen()` is the
@@ -649,7 +663,7 @@ service : {
649
663
  /// Born disabled deliberately: a listing that went live at creation would be sellable before its
650
664
  /// price was set, and `price` starts at 0 with `suggestedPrice` as the fallback.
651
665
  createEndpoint: (name: text, description: text, contentId: text,
652
- suggestedPriceE6: nat) -> (Result_18);
666
+ suggestedPriceE6: nat) -> (Result_19);
653
667
  /// Submit a paid service request. Returns a job id, or the price.
654
668
  ///
655
669
  /// ⟨0.16.0⟩ TWO GATES FROM THE ENGRAM DO NOT TRAVEL, and both for the same reason: they were the
@@ -664,7 +678,7 @@ service : {
664
678
  ///
665
679
  /// What DOES gate here is the market's freeze, and the service's own existence and pricing mode.
666
680
  createJob: (serviceId: text, params: blob, paymentSig:
667
- opt PaymentSignature) -> (Result_17);
681
+ opt PaymentSignature) -> (Result_18);
668
682
  /// Delete content.
669
683
  ///
670
684
  /// ⚠ THE QUOTA IS NOT REFUNDED, and this is the honest part of the design rather than a
@@ -753,7 +767,7 @@ service : {
753
767
  /// before the nonce lock or any ledger call, and the refusal reaches the buyer as #Refused with
754
768
  /// ic402's text naming both principals. Pay as the principal that approved the allowance.
755
769
  getContent: (contentId: text, paymentSig: opt PaymentSignature) ->
756
- (Result_16);
770
+ (Result_17);
757
771
  /// ⟨0.16.0⟩ THE `getChunk` FIX, and it is the sharpest single case in the corpus.
758
772
  ///
759
773
  /// The engram's version was:
@@ -778,13 +792,13 @@ service : {
778
792
  /// list they scan holds authorization helpers only — so a refusal fabricated behind a payment
779
793
  /// check was out of scope by construction rather than by ruling. L11 adds payment gates to that
780
794
  /// list; this method is why.
781
- getContentChunk: (grant: AccessGrant, index: nat) -> (Result_13) query;
795
+ getContentChunk: (grant: AccessGrant, index: nat) -> (Result_14) query;
782
796
  /// A seller's payout address — THEIRS, or the admin's to read.
783
797
  ///
784
798
  /// The engram made this owner-only and TRAPPED at everyone else. Here the answer is a refusal a
785
799
  /// caller can read, and `#Ok(null)` genuinely means "this seller has set no payout address" —
786
800
  /// distinguishable from "you may not ask", which is the whole point of the envelope.
787
- getEvmSellerPayout: (seller: principal) -> (Result_15) query;
801
+ getEvmSellerPayout: (seller: principal) -> (Result_16) query;
788
802
  /// PUBLIC: what this canister's chains continue, or that they continue nothing. A fresh chain
789
803
  /// beside a published predecessor head is auditable; a fresh chain with no statement is
790
804
  /// indistinguishable from a wipe.
@@ -797,7 +811,7 @@ service : {
797
811
  /// collapsed "unknown jobId" and "not authorized", and the product rendered the wrong conclusion
798
812
  /// from it — the marketplace UI printed "Job not found (or not yet visible)" at a caller who was
799
813
  /// merely unauthorized. Job existence is not the secret: `getJobCounts()` is ungated.
800
- getJob: (jobId: text) -> (Result_14) query;
814
+ getJob: (jobId: text) -> (Result_15) query;
801
815
  /// PUBLIC: aggregate counts that identify nobody — and already public on the engram, which is
802
816
  /// what made `listJobs`' existence-leak justification false.
803
817
  getJobCounts: () -> (JobCounts) query;
@@ -810,7 +824,7 @@ service : {
810
824
  ///
811
825
  /// Three outcomes, three answers now. And `Payer` (above) removes the root cause rather than
812
826
  /// only labelling it.
813
- getJobResult: (jobId: text) -> (Result_13) query;
827
+ getJobResult: (jobId: text) -> (Result_14) query;
814
828
  /// Terminal money settlement — the seller gets paid. Honours the freeze exactly like every
815
829
  /// other settle path; a settlement that ignored the freeze would make the freeze a suggestion.
816
830
  /// PUBLIC: a job's state, and nothing else about it.
@@ -825,7 +839,7 @@ service : {
825
839
  ///
826
840
  /// The engram returned `?EngramJobStatus`, conflating "no such job" with a null-ish answer. Here
827
841
  /// a missing job is `#NotFound`, which is a fact rather than an absence a caller has to interpret.
828
- getJobStatus: (jobId: text) -> (Result_12) query;
842
+ getJobStatus: (jobId: text) -> (Result_13) query;
829
843
  /// PUBLIC: the market's spend limits, with the caller rosters REDACTED.
830
844
  ///
831
845
  /// The limits themselves are already public — they are advertised inside every 402 challenge, so
@@ -848,7 +862,7 @@ service : {
848
862
  /// Anonymous is refused rather than answered with zeroes. A zero here is a real business fact —
849
863
  /// "you have sold nothing" — and returning it to a caller who simply has no identity is the
850
864
  /// fabricated-empty defect wearing a number instead of a list.
851
- getRevenueSummary: () -> (Result_11) query;
865
+ getRevenueSummary: () -> (Result_12) query;
852
866
  /// PUBLIC: what a buyer can learn about a seller, and the whole of it.
853
867
  ///
854
868
  /// The ENGRAM ID is the point of this read. This market runs no reputation system and issues no
@@ -859,7 +873,7 @@ service : {
859
873
  ///
860
874
  /// `verified` is about ownership at a moment in time and nothing else. It is not an endorsement,
861
875
  /// and the field name is the strongest claim it makes.
862
- getSellerStatus: (seller: principal) -> (Result_10) query;
876
+ getSellerStatus: (seller: principal) -> (Result_11) query;
863
877
  /// PUBLIC: aggregate session counts. Identifies nobody, and the same reasoning as getJobCounts —
864
878
  /// which is also what made `listJobs`' old "no existence leak" defence false.
865
879
  getSessionCounts: () -> (SessionCounts) query;
@@ -938,17 +952,17 @@ service : {
938
952
  isTradeFrozen: () -> (bool) query;
939
953
  /// `total` is the head counter, not the row count: this is a bounded ring, so a page that
940
954
  /// reported only what it returned would make a trimmed log look complete.
941
- listAuditEntries: (start: nat, limit: nat) -> (Result_8) query;
955
+ listAuditEntries: (start: nat, limit: nat) -> (Result_9) query;
942
956
  /// Admin AND the enrolled viewers themselves — L8's roster rule. A viewer who cannot see the
943
957
  /// roster cannot tell whether their own enrolment survived a rotation.
944
- listAuditViewers: () -> (Result_9) query;
958
+ listAuditViewers: () -> (Result_10) query;
945
959
  /// PUBLIC: the catalogue is the storefront. A shop that refuses to say what it sells to
946
960
  /// anyone who has not already bought is not a shop.
947
961
  listContent: (start: nat, limit: nat) -> (Page_6) query;
948
962
  /// L11 names this canister's reason for having a denial log at all: the commerce surface is where
949
963
  /// the fabricated-empty class was born, and a refusal that leaves no trace cannot be counted,
950
964
  /// alerted on, or disproved.
951
- listDenialEntries: (start: nat, limit: nat) -> (Result_8) query;
965
+ listDenialEntries: (start: nat, limit: nat) -> (Result_9) query;
952
966
  /// Purchase history for one endpoint: its creator sees every row, a buyer sees their own.
953
967
  ///
954
968
  /// ⟨0.16.0⟩ Two defects close here at once, and they are the same defect wearing two hats.
@@ -962,7 +976,7 @@ service : {
962
976
  /// few sales. `withheld` now counts them, so "no purchases here" and "not yours to see" are
963
977
  /// different answers — without naming whose they were.
964
978
  listEndpointPurchases: (endpointId: text, start: nat, limit: nat) ->
965
- (Result_7) query;
979
+ (Result_8) query;
966
980
  /// PUBLIC: the shelves, like the catalogue. `#Deleted` listings are excluded from an
967
981
  /// unfiltered read and COUNTED in `withheld` — a shop with three deleted listings and a shop with
968
982
  /// none look different, which is the honest answer, without publishing what was withdrawn.
@@ -990,7 +1004,7 @@ service : {
990
1004
  /// Now: `#Refused` when the caller may not ask, `#NotFound` when the service does not exist —
991
1005
  /// two facts that were one empty list.
992
1006
  listJobs: (serviceId: text, statusFilter: opt JobStatus, start: nat, limit:
993
- nat) -> (Result_6) query;
1007
+ nat) -> (Result_7) query;
994
1008
  /// The parked withdrawals belonging to this caller, so an unresolved payout is discoverable
995
1009
  /// rather than something a seller has to already know the id of.
996
1010
  ///
@@ -1005,7 +1019,7 @@ service : {
1005
1019
  /// not see, so nothing is ever hidden from them — unlike `listEndpointPurchases`, where a
1006
1020
  /// non-owner's view withholds other buyers' rows. Stated because a reader comparing the two
1007
1021
  /// should know the zero is a fact about this surface, not an unimplemented field.
1008
- listMyPendingWithdrawals: (start: nat, limit: nat) -> (Result_5) query;
1022
+ listMyPendingWithdrawals: (start: nat, limit: nat) -> (Result_6) query;
1009
1023
  /// ⟨0.16.0⟩ `listAllServices` FOLDS in as `includeDisabled`.
1010
1024
  ///
1011
1025
  /// The engram had two methods because the visibility rule differed: everyone saw enabled
@@ -1055,7 +1069,7 @@ service : {
1055
1069
  /// ⟨2026-09-30, ic402 2.17.0⟩ That future spend path calls `gate.consumeVoucherFrom(msg.caller, …)`,
1056
1070
  /// not the bare `consumeVoucher`: the signed fallback is off on this canister, so the bare call
1057
1071
  /// refuses every voucher, and only the session key calling as itself may spend a session.
1058
- openSession: (config: SessionConfig, sig: PaymentSignature) -> (Result_4);
1072
+ openSession: (config: SessionConfig, sig: PaymentSignature) -> (Result_5);
1059
1073
  /// RENAMED from `requestSession` (census tier-3 #21): it is a pure dry run — a quote for a session
1060
1074
  /// the caller has not opened and is not committed to. `request` read as an action with an effect.
1061
1075
  ///
@@ -1117,7 +1131,7 @@ service : {
1117
1131
  /// This matters most on the ckUSDC rail, which is where customer payments settle: ICP has no
1118
1132
  /// on-chain nonce, so `settle` ALWAYS requires the server one. A conformant EVM x402 client
1119
1133
  /// sends no server nonce at all and is unaffected.
1120
- quotePayment: (amountE6: nat) -> (Result_3) query;
1134
+ quotePayment: (amountE6: nat) -> (Result_4) query;
1121
1135
  /// Admin recovery: re-drive a job stuck mid-settlement — a broadcast EVM transfer whose outcome
1122
1136
  /// this canister never learned. Reads the chain and finishes what the settle started.
1123
1137
  ///
@@ -1196,7 +1210,15 @@ service : {
1196
1210
  /// refused or rejected: that close already ends the session `closed`, with the remainder still in
1197
1211
  /// its escrow, so it needs no force. Recover it within 24 hours of that close, asking at most the
1198
1212
  /// escrow's ledger balance less one fee.
1199
- recoverEscrow: (sessionId: text, amount: TokenAmount) -> (Result);
1213
+ ///
1214
+ /// ⟨2026-10-07, the owner's decision of that day⟩ WHAT IT ANSWERS: what came back. `amount` is what
1215
+ /// was transferred to the session's payer, in the token named (the amount asked, capped at the
1216
+ /// session's unconsumed deposit; the transfer's fee comes out of the escrow on top), and
1217
+ /// `blockIndex` is that ledger's block of the transfer. Until this date it answered a bare `nat`
1218
+ /// that was the block index alone, which read as the amount. If the session's record is removed
1219
+ /// before the amount can be read back — a session closed in the same moment as the recovery and
1220
+ /// cleaned up during its transfer — it answers `#Other` naming the block, never a guessed amount.
1221
+ recoverEscrow: (sessionId: text, amount: TokenAmount) -> (Result_3);
1200
1222
  /// Register as a seller by naming the engram you own.
1201
1223
  ///
1202
1224
  /// The registry is asked, not trusted from the caller's word: `verifyEngramActiveOwner` confirms
@@ -1284,6 +1306,36 @@ service : {
1284
1306
  /// contract as ratified on 2026-10-02; giving the library one arm per kind of refusal is post-cut
1285
1307
  /// dependency work.
1286
1308
  resolveJob: (jobId: text, terminal: JobStatus) -> (Result_1);
1309
+ /// Admin recovery: retry the payment to the seller of a job left `#Verified` by a failed payment.
1310
+ /// NOTHING ELSE. It never refunds the buyer, and it refuses every job that does not read
1311
+ /// `#Verified`, with nothing moved.
1312
+ ///
1313
+ /// ⟨2026-10-07, the owner's decision of that day⟩ A job whose work passed verification and whose
1314
+ /// payment to the seller then failed rests in `#Verified`, and only `resolveDispute` moves it — the
1315
+ /// service's SELLER's, by the ruling of 2026-08-17, which stands unchanged. A seller who never acts
1316
+ /// left it there, with no way for anyone else to move it. This is the admin's way: unstick, not
1317
+ /// decide. The job's outcome was decided by its verification; the payment goes where that sent it,
1318
+ /// and the admin names neither a recipient nor an amount. Refunding the buyer, and anything about a
1319
+ /// job not yet verified (`#Submitted`, `#Disputed`), stay the seller's.
1320
+ ///
1321
+ /// It runs the library's own settle, the one a buyer's confirmation runs: the job reads `#Settling`
1322
+ /// while it pays (so two retries cannot both pay), ends `#Settled`, and a payment the ledger refuses
1323
+ /// leaves it `#Verified` to retry again. For a job priced "up to" an amount, that settle also returns
1324
+ /// to the buyer what the seller did not claim, as every settle does. Past the admin check, the
1325
+ /// freeze and the cycles floor (each of which refuses before anything is read), every outcome is a
1326
+ /// chained record entry naming the admin.
1327
+ ///
1328
+ /// A NEW METHOD, NOT A WIDER `resolveJob`, ON PURPOSE. `resolveJob` is the one place the admin line
1329
+ /// bends — a STATE assertion, moving no money, for a job stuck in `#Settling`. Widening it to move
1330
+ /// money on a `#Verified` job would give one argument (`#Settled`) two meanings depending on a state
1331
+ /// the admin read a moment earlier: if the job moved to `#Settling` in between (a settle in flight),
1332
+ /// "pay the seller" would become "declare the seller paid". One method per meaning keeps the
1333
+ /// deciding one narrow and named.
1334
+ ///
1335
+ /// `#Conflict` covers the state refusals: a job that does not read `#Verified`, and the library's
1336
+ /// own (a job that moved on before the retry ran, or a payment that failed). `#NotFound` is a job id
1337
+ /// this market does not have.
1338
+ retrySellerPayment: (jobId: text) -> (Result_1);
1287
1339
  setAdmin: (newAdmin: principal) -> (Result_1);
1288
1340
  /// Override the policy for ONE payer — the market's per-buyer risk control.
1289
1341
  setCallerPolicy: (caller: principal, policy: SpendingPolicy) -> (Result_1);
@@ -79,6 +79,10 @@ export type Error =
79
79
  | { Other: string }
80
80
  | { Unavailable: string }
81
81
  | { Conflict: string };
82
+ export interface EscrowRecovery {
83
+ blockIndex: bigint;
84
+ amount: TokenAmount;
85
+ }
82
86
  export interface GenesisNote {
83
87
  predecessorSize: [] | [bigint];
84
88
  predecessorHeadHash: [] | [Uint8Array | number[]];
@@ -242,23 +246,24 @@ export interface QuotedRequirement {
242
246
  }
243
247
  export type Result = { Ok: bigint } | { Err: Error };
244
248
  export type Result_1 = { Ok: null } | { Err: Error };
245
- export type Result_10 = { Ok: SellerStatus } | { Err: Error };
246
- export type Result_11 = { Ok: RevenueSummary } | { Err: Error };
247
- export type Result_12 = { Ok: JobStatus } | { Err: Error };
248
- export type Result_13 = { Ok: Uint8Array | number[] } | { Err: Error };
249
- export type Result_14 = { Ok: Job } | { Err: Error };
250
- export type Result_15 = { Ok: [] | [string] } | { Err: Error };
251
- export type Result_16 = { Ok: ContentResponse } | { Err: Error };
252
- export type Result_17 = { Ok: ServiceRequestResponse } | { Err: Error };
253
- export type Result_18 = { Ok: X402Endpoint } | { Err: Error };
249
+ export type Result_10 = { Ok: Page_7 } | { Err: Error };
250
+ export type Result_11 = { Ok: SellerStatus } | { Err: Error };
251
+ export type Result_12 = { Ok: RevenueSummary } | { Err: Error };
252
+ export type Result_13 = { Ok: JobStatus } | { Err: Error };
253
+ export type Result_14 = { Ok: Uint8Array | number[] } | { Err: Error };
254
+ export type Result_15 = { Ok: Job } | { Err: Error };
255
+ export type Result_16 = { Ok: [] | [string] } | { Err: Error };
256
+ export type Result_17 = { Ok: ContentResponse } | { Err: Error };
257
+ export type Result_18 = { Ok: ServiceRequestResponse } | { Err: Error };
258
+ export type Result_19 = { Ok: X402Endpoint } | { Err: Error };
254
259
  export type Result_2 = { Ok: string } | { Err: Error };
255
- export type Result_3 = { Ok: PaymentQuote } | { Err: Error };
256
- export type Result_4 = { Ok: SessionState } | { Err: Error };
257
- export type Result_5 = { Ok: Page_1 } | { Err: Error };
258
- export type Result_6 = { Ok: Page_2 } | { Err: Error };
259
- export type Result_7 = { Ok: Page_4 } | { Err: Error };
260
- export type Result_8 = { Ok: Page_5 } | { Err: Error };
261
- export type Result_9 = { Ok: Page_7 } | { Err: Error };
260
+ export type Result_3 = { Ok: EscrowRecovery } | { Err: Error };
261
+ export type Result_4 = { Ok: PaymentQuote } | { Err: Error };
262
+ export type Result_5 = { Ok: SessionState } | { Err: Error };
263
+ export type Result_6 = { Ok: Page_1 } | { Err: Error };
264
+ export type Result_7 = { Ok: Page_2 } | { Err: Error };
265
+ export type Result_8 = { Ok: Page_4 } | { Err: Error };
266
+ export type Result_9 = { Ok: Page_5 } | { Err: Error };
262
267
  export interface RevenueSummary {
263
268
  serviceJobsSettled: bigint;
264
269
  owedToYou: bigint;
@@ -324,6 +329,7 @@ export interface SessionCounts {
324
329
  total: bigint;
325
330
  expired: bigint;
326
331
  open: bigint;
332
+ refundOwed: [] | [bigint];
327
333
  closing: bigint;
328
334
  }
329
335
  export interface SessionIntent {
@@ -438,6 +444,9 @@ export interface _SERVICE {
438
444
  * / is RATIFIED as the 0.16.0 contract (the owner's ruling of 2026-10-02, the pre-cut
439
445
  * / recommendation); giving the library one arm per kind of refusal is post-cut dependency work,
440
446
  * / not a change made mid-cut.
447
+ * / ⟨2026-10-07, beside the count above⟩ Twelve: the admin's `retrySellerPayment` (the owner's
448
+ * / decision of that day) passes the library's settle refusal through as `#Conflict` too — state
449
+ * / behind this canister's own gate, like the other six.
441
450
  * /
442
451
  * / It also refuses while TRADE IS FROZEN, and that one is a true `#Conflict` — the refusal says
443
452
  * / so explicitly ("Not a permission problem and not a missing job"), and `isTradeFrozen()` is the
@@ -475,7 +484,7 @@ export interface _SERVICE {
475
484
  * / Born disabled deliberately: a listing that went live at creation would be sellable before its
476
485
  * / price was set, and `price` starts at 0 with `suggestedPrice` as the fallback.
477
486
  */
478
- createEndpoint: ActorMethod<[string, string, string, bigint], Result_18>;
487
+ createEndpoint: ActorMethod<[string, string, string, bigint], Result_19>;
479
488
  /**
480
489
  * / Submit a paid service request. Returns a job id, or the price.
481
490
  * /
@@ -491,7 +500,7 @@ export interface _SERVICE {
491
500
  * /
492
501
  * / What DOES gate here is the market's freeze, and the service's own existence and pricing mode.
493
502
  */
494
- createJob: ActorMethod<[string, Uint8Array | number[], [] | [PaymentSignature]], Result_17>;
503
+ createJob: ActorMethod<[string, Uint8Array | number[], [] | [PaymentSignature]], Result_18>;
495
504
  /**
496
505
  * / Delete content.
497
506
  * /
@@ -600,7 +609,7 @@ export interface _SERVICE {
600
609
  * / before the nonce lock or any ledger call, and the refusal reaches the buyer as #Refused with
601
610
  * / ic402's text naming both principals. Pay as the principal that approved the allowance.
602
611
  */
603
- getContent: ActorMethod<[string, [] | [PaymentSignature]], Result_16>;
612
+ getContent: ActorMethod<[string, [] | [PaymentSignature]], Result_17>;
604
613
  /**
605
614
  * / ⟨0.16.0⟩ THE `getChunk` FIX, and it is the sharpest single case in the corpus.
606
615
  * /
@@ -627,7 +636,7 @@ export interface _SERVICE {
627
636
  * / check was out of scope by construction rather than by ruling. L11 adds payment gates to that
628
637
  * / list; this method is why.
629
638
  */
630
- getContentChunk: ActorMethod<[AccessGrant, bigint], Result_13>;
639
+ getContentChunk: ActorMethod<[AccessGrant, bigint], Result_14>;
631
640
  /**
632
641
  * / A seller's payout address — THEIRS, or the admin's to read.
633
642
  * /
@@ -635,7 +644,7 @@ export interface _SERVICE {
635
644
  * / caller can read, and `#Ok(null)` genuinely means "this seller has set no payout address" —
636
645
  * / distinguishable from "you may not ask", which is the whole point of the envelope.
637
646
  */
638
- getEvmSellerPayout: ActorMethod<[Principal], Result_15>;
647
+ getEvmSellerPayout: ActorMethod<[Principal], Result_16>;
639
648
  /**
640
649
  * / PUBLIC: what this canister's chains continue, or that they continue nothing. A fresh chain
641
650
  * / beside a published predecessor head is auditable; a fresh chain with no statement is
@@ -652,7 +661,7 @@ export interface _SERVICE {
652
661
  * / from it — the marketplace UI printed "Job not found (or not yet visible)" at a caller who was
653
662
  * / merely unauthorized. Job existence is not the secret: `getJobCounts()` is ungated.
654
663
  */
655
- getJob: ActorMethod<[string], Result_14>;
664
+ getJob: ActorMethod<[string], Result_15>;
656
665
  /**
657
666
  * / PUBLIC: aggregate counts that identify nobody — and already public on the engram, which is
658
667
  * / what made `listJobs`' existence-leak justification false.
@@ -669,7 +678,7 @@ export interface _SERVICE {
669
678
  * / Three outcomes, three answers now. And `Payer` (above) removes the root cause rather than
670
679
  * / only labelling it.
671
680
  */
672
- getJobResult: ActorMethod<[string], Result_13>;
681
+ getJobResult: ActorMethod<[string], Result_14>;
673
682
  /**
674
683
  * / Terminal money settlement — the seller gets paid. Honours the freeze exactly like every
675
684
  * / other settle path; a settlement that ignored the freeze would make the freeze a suggestion.
@@ -686,7 +695,7 @@ export interface _SERVICE {
686
695
  * / The engram returned `?EngramJobStatus`, conflating "no such job" with a null-ish answer. Here
687
696
  * / a missing job is `#NotFound`, which is a fact rather than an absence a caller has to interpret.
688
697
  */
689
- getJobStatus: ActorMethod<[string], Result_12>;
698
+ getJobStatus: ActorMethod<[string], Result_13>;
690
699
  /**
691
700
  * / PUBLIC: the market's spend limits, with the caller rosters REDACTED.
692
701
  * /
@@ -713,7 +722,7 @@ export interface _SERVICE {
713
722
  * / "you have sold nothing" — and returning it to a caller who simply has no identity is the
714
723
  * / fabricated-empty defect wearing a number instead of a list.
715
724
  */
716
- getRevenueSummary: ActorMethod<[], Result_11>;
725
+ getRevenueSummary: ActorMethod<[], Result_12>;
717
726
  /**
718
727
  * / PUBLIC: what a buyer can learn about a seller, and the whole of it.
719
728
  * /
@@ -726,7 +735,7 @@ export interface _SERVICE {
726
735
  * / `verified` is about ownership at a moment in time and nothing else. It is not an endorsement,
727
736
  * / and the field name is the strongest claim it makes.
728
737
  */
729
- getSellerStatus: ActorMethod<[Principal], Result_10>;
738
+ getSellerStatus: ActorMethod<[Principal], Result_11>;
730
739
  /**
731
740
  * / PUBLIC: aggregate session counts. Identifies nobody, and the same reasoning as getJobCounts —
732
741
  * / which is also what made `listJobs`' old "no existence leak" defence false.
@@ -814,12 +823,12 @@ export interface _SERVICE {
814
823
  * / `total` is the head counter, not the row count: this is a bounded ring, so a page that
815
824
  * / reported only what it returned would make a trimmed log look complete.
816
825
  */
817
- listAuditEntries: ActorMethod<[bigint, bigint], Result_8>;
826
+ listAuditEntries: ActorMethod<[bigint, bigint], Result_9>;
818
827
  /**
819
828
  * / Admin AND the enrolled viewers themselves — L8's roster rule. A viewer who cannot see the
820
829
  * / roster cannot tell whether their own enrolment survived a rotation.
821
830
  */
822
- listAuditViewers: ActorMethod<[], Result_9>;
831
+ listAuditViewers: ActorMethod<[], Result_10>;
823
832
  /**
824
833
  * / PUBLIC: the catalogue is the storefront. A shop that refuses to say what it sells to
825
834
  * / anyone who has not already bought is not a shop.
@@ -830,7 +839,7 @@ export interface _SERVICE {
830
839
  * / the fabricated-empty class was born, and a refusal that leaves no trace cannot be counted,
831
840
  * / alerted on, or disproved.
832
841
  */
833
- listDenialEntries: ActorMethod<[bigint, bigint], Result_8>;
842
+ listDenialEntries: ActorMethod<[bigint, bigint], Result_9>;
834
843
  /**
835
844
  * / Purchase history for one endpoint: its creator sees every row, a buyer sees their own.
836
845
  * /
@@ -845,7 +854,7 @@ export interface _SERVICE {
845
854
  * / few sales. `withheld` now counts them, so "no purchases here" and "not yours to see" are
846
855
  * / different answers — without naming whose they were.
847
856
  */
848
- listEndpointPurchases: ActorMethod<[string, bigint, bigint], Result_7>;
857
+ listEndpointPurchases: ActorMethod<[string, bigint, bigint], Result_8>;
849
858
  /**
850
859
  * / PUBLIC: the shelves, like the catalogue. `#Deleted` listings are excluded from an
851
860
  * / unfiltered read and COUNTED in `withheld` — a shop with three deleted listings and a shop with
@@ -875,7 +884,7 @@ export interface _SERVICE {
875
884
  * / Now: `#Refused` when the caller may not ask, `#NotFound` when the service does not exist —
876
885
  * / two facts that were one empty list.
877
886
  */
878
- listJobs: ActorMethod<[string, [] | [JobStatus], bigint, bigint], Result_6>;
887
+ listJobs: ActorMethod<[string, [] | [JobStatus], bigint, bigint], Result_7>;
879
888
  /**
880
889
  * / The parked withdrawals belonging to this caller, so an unresolved payout is discoverable
881
890
  * / rather than something a seller has to already know the id of.
@@ -892,7 +901,7 @@ export interface _SERVICE {
892
901
  * / non-owner's view withholds other buyers' rows. Stated because a reader comparing the two
893
902
  * / should know the zero is a fact about this surface, not an unimplemented field.
894
903
  */
895
- listMyPendingWithdrawals: ActorMethod<[bigint, bigint], Result_5>;
904
+ listMyPendingWithdrawals: ActorMethod<[bigint, bigint], Result_6>;
896
905
  /**
897
906
  * / ⟨0.16.0⟩ `listAllServices` FOLDS in as `includeDisabled`.
898
907
  * /
@@ -945,7 +954,7 @@ export interface _SERVICE {
945
954
  * / not the bare `consumeVoucher`: the signed fallback is off on this canister, so the bare call
946
955
  * / refuses every voucher, and only the session key calling as itself may spend a session.
947
956
  */
948
- openSession: ActorMethod<[SessionConfig, PaymentSignature], Result_4>;
957
+ openSession: ActorMethod<[SessionConfig, PaymentSignature], Result_5>;
949
958
  /**
950
959
  * / RENAMED from `requestSession` (census tier-3 #21): it is a pure dry run — a quote for a session
951
960
  * / the caller has not opened and is not committed to. `request` read as an action with an effect.
@@ -1011,7 +1020,7 @@ export interface _SERVICE {
1011
1020
  * / on-chain nonce, so `settle` ALWAYS requires the server one. A conformant EVM x402 client
1012
1021
  * / sends no server nonce at all and is unaffected.
1013
1022
  */
1014
- quotePayment: ActorMethod<[bigint], Result_3>;
1023
+ quotePayment: ActorMethod<[bigint], Result_4>;
1015
1024
  /**
1016
1025
  * / Admin recovery: re-drive a job stuck mid-settlement — a broadcast EVM transfer whose outcome
1017
1026
  * / this canister never learned. Reads the chain and finishes what the settle started.
@@ -1097,8 +1106,16 @@ export interface _SERVICE {
1097
1106
  * / refused or rejected: that close already ends the session `closed`, with the remainder still in
1098
1107
  * / its escrow, so it needs no force. Recover it within 24 hours of that close, asking at most the
1099
1108
  * / escrow's ledger balance less one fee.
1109
+ * /
1110
+ * / ⟨2026-10-07, the owner's decision of that day⟩ WHAT IT ANSWERS: what came back. `amount` is what
1111
+ * / was transferred to the session's payer, in the token named (the amount asked, capped at the
1112
+ * / session's unconsumed deposit; the transfer's fee comes out of the escrow on top), and
1113
+ * / `blockIndex` is that ledger's block of the transfer. Until this date it answered a bare `nat`
1114
+ * / that was the block index alone, which read as the amount. If the session's record is removed
1115
+ * / before the amount can be read back — a session closed in the same moment as the recovery and
1116
+ * / cleaned up during its transfer — it answers `#Other` naming the block, never a guessed amount.
1100
1117
  */
1101
- recoverEscrow: ActorMethod<[string, TokenAmount], Result>;
1118
+ recoverEscrow: ActorMethod<[string, TokenAmount], Result_3>;
1102
1119
  /**
1103
1120
  * / Register as a seller by naming the engram you own.
1104
1121
  * /
@@ -1207,6 +1224,38 @@ export interface _SERVICE {
1207
1224
  * / dependency work.
1208
1225
  */
1209
1226
  resolveJob: ActorMethod<[string, JobStatus], Result_1>;
1227
+ /**
1228
+ * / Admin recovery: retry the payment to the seller of a job left `#Verified` by a failed payment.
1229
+ * / NOTHING ELSE. It never refunds the buyer, and it refuses every job that does not read
1230
+ * / `#Verified`, with nothing moved.
1231
+ * /
1232
+ * / ⟨2026-10-07, the owner's decision of that day⟩ A job whose work passed verification and whose
1233
+ * / payment to the seller then failed rests in `#Verified`, and only `resolveDispute` moves it — the
1234
+ * / service's SELLER's, by the ruling of 2026-08-17, which stands unchanged. A seller who never acts
1235
+ * / left it there, with no way for anyone else to move it. This is the admin's way: unstick, not
1236
+ * / decide. The job's outcome was decided by its verification; the payment goes where that sent it,
1237
+ * / and the admin names neither a recipient nor an amount. Refunding the buyer, and anything about a
1238
+ * / job not yet verified (`#Submitted`, `#Disputed`), stay the seller's.
1239
+ * /
1240
+ * / It runs the library's own settle, the one a buyer's confirmation runs: the job reads `#Settling`
1241
+ * / while it pays (so two retries cannot both pay), ends `#Settled`, and a payment the ledger refuses
1242
+ * / leaves it `#Verified` to retry again. For a job priced "up to" an amount, that settle also returns
1243
+ * / to the buyer what the seller did not claim, as every settle does. Past the admin check, the
1244
+ * / freeze and the cycles floor (each of which refuses before anything is read), every outcome is a
1245
+ * / chained record entry naming the admin.
1246
+ * /
1247
+ * / A NEW METHOD, NOT A WIDER `resolveJob`, ON PURPOSE. `resolveJob` is the one place the admin line
1248
+ * / bends — a STATE assertion, moving no money, for a job stuck in `#Settling`. Widening it to move
1249
+ * / money on a `#Verified` job would give one argument (`#Settled`) two meanings depending on a state
1250
+ * / the admin read a moment earlier: if the job moved to `#Settling` in between (a settle in flight),
1251
+ * / "pay the seller" would become "declare the seller paid". One method per meaning keeps the
1252
+ * / deciding one narrow and named.
1253
+ * /
1254
+ * / `#Conflict` covers the state refusals: a job that does not read `#Verified`, and the library's
1255
+ * / own (a job that moved on before the retry ran, or a payment that failed). `#NotFound` is a job id
1256
+ * / this market does not have.
1257
+ */
1258
+ retrySellerPayment: ActorMethod<[string], Result_1>;
1210
1259
  setAdmin: ActorMethod<[Principal], Result_1>;
1211
1260
  /**
1212
1261
  * / Override the policy for ONE payer — the market's per-buyer risk control.