run402 3.1.0 → 3.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/functions.mjs +6 -6
- package/lib/transfer.mjs +66 -73
- package/package.json +1 -1
- package/sdk/dist/namespaces/deploy.d.ts.map +1 -1
- package/sdk/dist/namespaces/deploy.js +4 -0
- package/sdk/dist/namespaces/deploy.js.map +1 -1
- package/sdk/dist/namespaces/deploy.types.d.ts +13 -0
- package/sdk/dist/namespaces/deploy.types.d.ts.map +1 -1
- package/sdk/dist/namespaces/deploy.types.js.map +1 -1
- package/sdk/dist/namespaces/functions.d.ts +28 -15
- package/sdk/dist/namespaces/functions.d.ts.map +1 -1
- package/sdk/dist/namespaces/functions.js +64 -28
- package/sdk/dist/namespaces/functions.js.map +1 -1
- package/sdk/dist/namespaces/transfers.d.ts +164 -128
- package/sdk/dist/namespaces/transfers.d.ts.map +1 -1
- package/sdk/dist/namespaces/transfers.js +115 -89
- package/sdk/dist/namespaces/transfers.js.map +1 -1
|
@@ -1,36 +1,43 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* `transfers` namespace —
|
|
2
|
+
* `transfers` namespace — the unified project-transfer noun (v1.93+).
|
|
3
3
|
*
|
|
4
|
-
* Exposed as `r.admin.transfers.*`.
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* persistent `secrets_rotation_advised` advisory.
|
|
4
|
+
* Exposed as `r.admin.transfers.*`. Project transfer is ONE capability,
|
|
5
|
+
* body-discriminated by recipient kind: a wallet recipient (`toWallet`, SIWX
|
|
6
|
+
* bilateral signing) or an email recipient (`toEmail`, the recipient claims
|
|
7
|
+
* into an org). Both ride the same `/transfers` surface — there is no separate
|
|
8
|
+
* `/handoffs` noun (the gateway removed it in `unify-project-transfer-surface`).
|
|
10
9
|
*
|
|
11
10
|
* Gateway endpoints:
|
|
12
|
-
* POST /projects/v1/:project_id/transfers —
|
|
13
|
-
* GET /agent/v1/transfers/incoming —
|
|
14
|
-
* GET /agent/v1/transfers/outgoing —
|
|
15
|
-
* GET /agent/v1/transfers/:transfer_id — preview (
|
|
16
|
-
* POST /agent/v1/transfers/:transfer_id/accept —
|
|
17
|
-
* POST /agent/v1/transfers/:transfer_id/
|
|
11
|
+
* POST /projects/v1/:project_id/transfers — initiate; body { to_wallet } XOR { to_email }
|
|
12
|
+
* GET /agent/v1/transfers/incoming — inbox (both kinds, unioned)
|
|
13
|
+
* GET /agent/v1/transfers/outgoing — outbox (both kinds, unioned)
|
|
14
|
+
* GET /agent/v1/transfers/:transfer_id — preview (kind-agnostic)
|
|
15
|
+
* POST /agent/v1/transfers/:transfer_id/accept — WALLET completion (recipient SIWX-signs)
|
|
16
|
+
* POST /agent/v1/transfers/:transfer_id/claim — EMAIL completion (recipient claims into an org)
|
|
17
|
+
* POST /agent/v1/transfers/:transfer_id/cancel — cancel (kind-agnostic)
|
|
18
18
|
*
|
|
19
19
|
* Owner-side mutations against a project with a pending transfer return
|
|
20
20
|
* 409 `PROJECT_HAS_PENDING_TRANSFER`. The SDK kernel surfaces that as
|
|
21
|
-
* {@link TransferFreezeError} so agents can guide the user to cancel.
|
|
21
|
+
* {@link TransferFreezeError} so agents can guide the user to cancel. Calling
|
|
22
|
+
* the wrong completion for a row's kind (e.g. `accept` on an email row) returns
|
|
23
|
+
* 409 `WRONG_COMPLETION_FOR_TRANSFER_KIND`; the thrown error exposes
|
|
24
|
+
* `nextActions` pointing at the sibling completion on the SAME `transfer_id`.
|
|
22
25
|
*/
|
|
23
26
|
import type { Client } from "../kernel.js";
|
|
24
27
|
/** Phase 1A only supports the `migrate` policy — B's wallet must already be on a organization, and the project moves into it. */
|
|
25
28
|
export type TransferBillingPolicy = "migrate";
|
|
26
29
|
export type TransferStatus = "pending" | "accepted" | "cancelled" | "expired";
|
|
27
30
|
export type TransferCancelledBy = "from_wallet" | "to_wallet" | "system";
|
|
28
|
-
/**
|
|
29
|
-
export
|
|
30
|
-
|
|
31
|
+
/** Which kind of recipient a transfer row is addressed to. */
|
|
32
|
+
export type RecipientKind = "wallet" | "email";
|
|
33
|
+
/** Initiate a transfer addressed to a wallet (two-party SIWX completion via `accept`). */
|
|
34
|
+
export interface InitiateWalletTransferInput {
|
|
35
|
+
/** Project id to transfer. Caller must currently own/admin it (gateway re-checks against fresh DB, not cache). */
|
|
31
36
|
projectId: string;
|
|
32
37
|
/** Recipient wallet (any case — gateway lowercases). Must differ from the current owner. */
|
|
33
38
|
toWallet: string;
|
|
39
|
+
/** Mutually exclusive with {@link InitiateWalletTransferInput.toWallet}; not allowed on the wallet path. */
|
|
40
|
+
toEmail?: never;
|
|
34
41
|
/**
|
|
35
42
|
* Billing policy. Defaults to `"migrate"`. Phase 1A only supports
|
|
36
43
|
* `"migrate"`; future phases may add `"inherit"` as a separate spec.
|
|
@@ -40,7 +47,38 @@ export interface InitiateTransferInput {
|
|
|
40
47
|
message?: string;
|
|
41
48
|
/** Optional KySigned record id (Phase 1A: informational only, stored verbatim, not verified). */
|
|
42
49
|
kysignedRecordId?: string;
|
|
50
|
+
/** Retention is an email-only opt-in; not allowed on the wallet path. */
|
|
51
|
+
retainCollaborator?: never;
|
|
43
52
|
}
|
|
53
|
+
/** Initiate a transfer addressed to an email (the recipient claims into an org via `claim`). */
|
|
54
|
+
export interface InitiateEmailTransferInput {
|
|
55
|
+
/** Project id to transfer. Caller must currently own/admin it. */
|
|
56
|
+
projectId: string;
|
|
57
|
+
/** Recipient email; claimed at the recipient's first verified login. */
|
|
58
|
+
toEmail: string;
|
|
59
|
+
/** Mutually exclusive with {@link InitiateEmailTransferInput.toEmail}; not allowed on the email path. */
|
|
60
|
+
toWallet?: never;
|
|
61
|
+
/** Optional note shown to the recipient (HTML-escaped server-side). */
|
|
62
|
+
message?: string;
|
|
63
|
+
/**
|
|
64
|
+
* Opt in (v1.91) to retaining a `developer` membership in the recipient's org
|
|
65
|
+
* after the transfer completes. Only `role: "developer"` is accepted, and the
|
|
66
|
+
* subject is always the initiating owner (you can only retain yourself). The
|
|
67
|
+
* recipient must explicitly accept it at claim time (see
|
|
68
|
+
* {@link ClaimTransferInput.acceptRetainedCollaborator}); omitting this is a
|
|
69
|
+
* full severance, the default.
|
|
70
|
+
*/
|
|
71
|
+
retainCollaborator?: {
|
|
72
|
+
role: "developer";
|
|
73
|
+
} | null;
|
|
74
|
+
/** Billing policy is wallet-path only; not allowed on the email path. */
|
|
75
|
+
billingPolicy?: never;
|
|
76
|
+
/** KySigned record id is wallet-path only; not allowed on the email path. */
|
|
77
|
+
kysignedRecordId?: never;
|
|
78
|
+
}
|
|
79
|
+
/** Inputs to `r.admin.transfers.initiate(...)` — wallet XOR email. */
|
|
80
|
+
export type InitiateTransferInput = InitiateWalletTransferInput | InitiateEmailTransferInput;
|
|
81
|
+
/** Result of a wallet-addressed `initiate`. */
|
|
44
82
|
export interface InitiateTransferResult {
|
|
45
83
|
transfer_id: string;
|
|
46
84
|
expires_at: string;
|
|
@@ -55,12 +93,23 @@ export interface InitiateTransferResult {
|
|
|
55
93
|
lease_refundable: false;
|
|
56
94
|
terms_sha256: string;
|
|
57
95
|
}
|
|
96
|
+
/** Result of an email-addressed `initiate`. The recipient completes via `claim`. */
|
|
97
|
+
export interface InitiateEmailTransferResult {
|
|
98
|
+
status: "ok";
|
|
99
|
+
transfer_id: string;
|
|
100
|
+
to_email: string;
|
|
101
|
+
expires_at: string;
|
|
102
|
+
}
|
|
58
103
|
export interface AcceptTransferResult {
|
|
59
104
|
project_id: string;
|
|
60
105
|
from_wallet: string;
|
|
61
106
|
to_wallet: string;
|
|
62
107
|
new_organization_id: string | null;
|
|
63
108
|
completed_at: string;
|
|
109
|
+
/** New owner's project anon key (stateless JWT) — #428. The SDK persists it on accept. */
|
|
110
|
+
anon_key: string;
|
|
111
|
+
/** New owner's project service key (stateless JWT) — #428. Full project access; persisted on accept. */
|
|
112
|
+
service_key: string;
|
|
64
113
|
secrets_rotation_advised: true;
|
|
65
114
|
/** Names of secrets that carried over with the project. Values are never returned. */
|
|
66
115
|
secret_names_inherited: string[];
|
|
@@ -75,20 +124,34 @@ export interface CancelTransferResult {
|
|
|
75
124
|
cancellation_reason: string | null;
|
|
76
125
|
cancelled_at: string;
|
|
77
126
|
}
|
|
78
|
-
/**
|
|
127
|
+
/**
|
|
128
|
+
* Summary row used in `/agent/v1/transfers/incoming` and `/outgoing`. The list
|
|
129
|
+
* is kind-agnostic: `recipient_kind` discriminates wallet vs email rows. Wallet
|
|
130
|
+
* rows carry `from_wallet`/`to_wallet`; email rows carry `to_email` +
|
|
131
|
+
* `from_organization_id`.
|
|
132
|
+
*/
|
|
79
133
|
export interface TransferSummary {
|
|
80
134
|
transfer_id: string;
|
|
81
135
|
project_id: string;
|
|
82
136
|
project_name_snapshot: string | null;
|
|
83
|
-
|
|
84
|
-
to_wallet: string;
|
|
137
|
+
recipient_kind: RecipientKind;
|
|
85
138
|
billing_policy: TransferBillingPolicy;
|
|
86
139
|
message: string | null;
|
|
87
|
-
initiated_at: string;
|
|
88
140
|
expires_at: string;
|
|
89
|
-
kysigned_record_id: string | null;
|
|
90
141
|
/** API path for the full preview document. */
|
|
91
142
|
preview_path: string;
|
|
143
|
+
/** Wallet rows only. */
|
|
144
|
+
from_wallet?: string;
|
|
145
|
+
/** Wallet rows only; `null`/absent for email rows. */
|
|
146
|
+
to_wallet?: string | null;
|
|
147
|
+
/** Wallet rows only. */
|
|
148
|
+
initiated_at?: string;
|
|
149
|
+
/** Wallet rows only. */
|
|
150
|
+
kysigned_record_id?: string | null;
|
|
151
|
+
/** Email rows only. */
|
|
152
|
+
to_email?: string;
|
|
153
|
+
/** Email rows only. */
|
|
154
|
+
from_organization_id?: string | null;
|
|
92
155
|
}
|
|
93
156
|
export interface ListTransfersOptions {
|
|
94
157
|
/** Page size; defaults to 50 on the gateway. */
|
|
@@ -133,15 +196,37 @@ export interface BillingImplications {
|
|
|
133
196
|
functions_count: number;
|
|
134
197
|
custom_domains_count: number;
|
|
135
198
|
}
|
|
199
|
+
/**
|
|
200
|
+
* The sender-retained-membership offer block on an email transfer preview
|
|
201
|
+
* (v1.91), or `null` when the sender requested no retention. `accept_field`
|
|
202
|
+
* names the claim body field the recipient sets to accept
|
|
203
|
+
* (`"accept_retained_collaborator"`).
|
|
204
|
+
*/
|
|
205
|
+
export interface RetainCollaboratorPreview {
|
|
206
|
+
principal_id: string;
|
|
207
|
+
role: "developer";
|
|
208
|
+
sender_label: string;
|
|
209
|
+
scope: string;
|
|
210
|
+
note?: string;
|
|
211
|
+
accept_field: string;
|
|
212
|
+
[key: string]: unknown;
|
|
213
|
+
}
|
|
214
|
+
/**
|
|
215
|
+
* Kind-agnostic preview document. Wallet-identity fields are `null` on email
|
|
216
|
+
* rows; `to_email` and `retain_collaborator` are populated on email rows.
|
|
217
|
+
*/
|
|
136
218
|
export interface ProjectTransferPreview {
|
|
137
219
|
transfer_id: string;
|
|
138
220
|
project_id: string;
|
|
139
221
|
project_name_snapshot: string | null;
|
|
140
222
|
status: TransferStatus;
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
223
|
+
recipient_kind: RecipientKind;
|
|
224
|
+
from_wallet: string | null;
|
|
225
|
+
from_wallet_display: string | null;
|
|
226
|
+
to_wallet: string | null;
|
|
227
|
+
to_wallet_display: string | null;
|
|
228
|
+
/** Email rows only. */
|
|
229
|
+
to_email?: string;
|
|
145
230
|
billing_policy: TransferBillingPolicy;
|
|
146
231
|
message: string | null;
|
|
147
232
|
initiated_at: string;
|
|
@@ -158,140 +243,91 @@ export interface ProjectTransferPreview {
|
|
|
158
243
|
signers: SignerPreview[];
|
|
159
244
|
github_repo_note: string;
|
|
160
245
|
billing_implications: BillingImplications;
|
|
161
|
-
|
|
162
|
-
/** Inputs to {@link Transfers.initiateHandoff}. */
|
|
163
|
-
export interface InitiateHandoffInput {
|
|
164
|
-
/** Project id to hand off. Caller must currently own it. */
|
|
165
|
-
projectId: string;
|
|
166
|
-
/** Recipient email; claimed at the recipient's first login. */
|
|
167
|
-
toEmail: string;
|
|
168
|
-
/** Optional note shown to the recipient (HTML-escaped server-side). */
|
|
169
|
-
message?: string;
|
|
170
|
-
/**
|
|
171
|
-
* Opt in (v1.91) to retaining a `developer` membership in the recipient's org
|
|
172
|
-
* after the handoff completes. Only `role: "developer"` is accepted, and the
|
|
173
|
-
* subject is always the initiating owner (you can only retain yourself). The
|
|
174
|
-
* recipient must explicitly accept it at claim time (see
|
|
175
|
-
* {@link ClaimHandoffInput.acceptRetainedCollaborator}); omitting this is a
|
|
176
|
-
* full severance, the default. Gateway rejects a bad role with
|
|
177
|
-
* `INVALID_RETAIN_ROLE` and a missing actor with `RETAIN_SUBJECT_REQUIRED`.
|
|
178
|
-
*/
|
|
179
|
-
retainCollaborator?: {
|
|
180
|
-
role: "developer";
|
|
181
|
-
} | null;
|
|
182
|
-
}
|
|
183
|
-
/** Result of {@link Transfers.initiateHandoff}. Forward-compatible (gateway owns the exact shape). */
|
|
184
|
-
export interface HandoffResult {
|
|
185
|
-
transfer_id: string;
|
|
186
|
-
expires_at?: string;
|
|
187
|
-
[key: string]: unknown;
|
|
188
|
-
}
|
|
189
|
-
/** Summary row from `GET /agent/v1/handoffs/incoming`. Forward-compatible. */
|
|
190
|
-
export interface HandoffSummary {
|
|
191
|
-
transfer_id: string;
|
|
192
|
-
project_id: string;
|
|
193
|
-
to_email?: string;
|
|
194
|
-
[key: string]: unknown;
|
|
195
|
-
}
|
|
196
|
-
/**
|
|
197
|
-
* The sender-retained-membership offer block on a handoff preview (v1.91), or
|
|
198
|
-
* `null` when the sender requested no retention. `accept_field` names the claim
|
|
199
|
-
* body field the recipient sets to accept (`"accept_retained_collaborator"`).
|
|
200
|
-
*/
|
|
201
|
-
export interface RetainCollaboratorPreview {
|
|
202
|
-
principal_id: string;
|
|
203
|
-
role: "developer";
|
|
204
|
-
sender_label: string;
|
|
205
|
-
scope: string;
|
|
206
|
-
note?: string;
|
|
207
|
-
accept_field: string;
|
|
208
|
-
[key: string]: unknown;
|
|
209
|
-
}
|
|
210
|
-
/** Preview from `GET /agent/v1/handoffs/:transfer_id`. Forward-compatible. */
|
|
211
|
-
export interface ProjectHandoffPreview {
|
|
212
|
-
transfer_id: string;
|
|
213
|
-
project_id: string;
|
|
214
|
-
status?: TransferStatus | string;
|
|
215
|
-
/** v1.91 sender-retained-membership offer, or `null` when none was requested. */
|
|
246
|
+
/** v1.91 sender-retained-membership offer (email rows), or `null` when none was requested. */
|
|
216
247
|
retain_collaborator?: RetainCollaboratorPreview | null;
|
|
217
|
-
[key: string]: unknown;
|
|
218
248
|
}
|
|
219
|
-
/** Inputs to {@link Transfers.
|
|
220
|
-
export interface
|
|
249
|
+
/** Inputs to {@link Transfers.claim}. */
|
|
250
|
+
export interface ClaimTransferInput {
|
|
221
251
|
/** Org (organization) to claim into. Omit to claim into a brand-new org. */
|
|
222
252
|
organizationId?: string;
|
|
223
253
|
/**
|
|
224
254
|
* Accept the sender's v1.91 retained-`developer`-membership offer (see the
|
|
225
|
-
*
|
|
255
|
+
* preview's `retain_collaborator` block). Only an explicit `true`
|
|
226
256
|
* materializes the membership in the new org; omitting it (the default) is a
|
|
227
257
|
* full severance.
|
|
228
258
|
*/
|
|
229
259
|
acceptRetainedCollaborator?: boolean;
|
|
230
260
|
}
|
|
231
|
-
/**
|
|
232
|
-
|
|
261
|
+
/**
|
|
262
|
+
* Result of {@link Transfers.claim}. Symmetric with wallet {@link Transfers.accept}:
|
|
263
|
+
* the email completion returns the new owner's project keys
|
|
264
|
+
* (`project-transfer-claim-credentials`), and `claim` persists them to the
|
|
265
|
+
* keystore so the claimant can operate the project immediately.
|
|
266
|
+
*/
|
|
267
|
+
export interface ClaimTransferResult {
|
|
268
|
+
status: "accepted";
|
|
233
269
|
project_id: string;
|
|
234
|
-
|
|
270
|
+
to_organization_id: string;
|
|
271
|
+
created_new_org: boolean;
|
|
235
272
|
/**
|
|
236
273
|
* The sender's principal id retained as a `developer` of the new org (v1.91),
|
|
237
274
|
* or `null` when no membership was retained (declined, not offered, or no-op).
|
|
238
275
|
*/
|
|
239
|
-
retained_collaborator_principal_id
|
|
240
|
-
|
|
276
|
+
retained_collaborator_principal_id: string | null;
|
|
277
|
+
/** New owner's project anon key (stateless `project_id`-derived JWT). `claim` persists it. */
|
|
278
|
+
anon_key: string;
|
|
279
|
+
/** New owner's project service key (stateless `project_id`-derived JWT). Full project access; persisted on claim. */
|
|
280
|
+
service_key: string;
|
|
241
281
|
}
|
|
242
282
|
export declare class Transfers {
|
|
243
283
|
private readonly client;
|
|
244
284
|
constructor(client: Client);
|
|
245
285
|
/**
|
|
246
|
-
* Initiate a
|
|
247
|
-
* `
|
|
248
|
-
*
|
|
249
|
-
*
|
|
286
|
+
* Initiate a project transfer — addressed to a wallet (`toWallet`) OR an email
|
|
287
|
+
* (`toEmail`), exactly one. Caller must currently own/admin `projectId`
|
|
288
|
+
* (gateway re-reads owner from DB, not cache). Creates a `pending` row with a
|
|
289
|
+
* 72h expiry and freezes owner-side mutations on the project until the
|
|
290
|
+
* transfer is accepted (wallet), claimed (email), cancelled, or expires.
|
|
250
291
|
*/
|
|
251
|
-
initiate(input:
|
|
292
|
+
initiate(input: InitiateWalletTransferInput): Promise<InitiateTransferResult>;
|
|
293
|
+
initiate(input: InitiateEmailTransferInput): Promise<InitiateEmailTransferResult>;
|
|
252
294
|
/**
|
|
253
|
-
* Fetch the preview document for a pending or terminal transfer
|
|
254
|
-
* caller must be
|
|
255
|
-
*
|
|
256
|
-
* domains, functions, CI bindings
|
|
257
|
-
* the billing implications
|
|
295
|
+
* Fetch the preview document for a pending or terminal transfer of either
|
|
296
|
+
* kind. The caller must be a party to it (wallet signer, addressed-email
|
|
297
|
+
* principal, or offering-org member); other callers receive 403. Preview
|
|
298
|
+
* lists secret NAMES (not values), custom domains, functions, CI bindings
|
|
299
|
+
* that will be revoked at completion, the billing implications, and — on
|
|
300
|
+
* email rows — the `retain_collaborator` offer.
|
|
258
301
|
*/
|
|
259
302
|
preview(transferId: string): Promise<ProjectTransferPreview>;
|
|
260
303
|
/**
|
|
261
|
-
* Accept an incoming transfer. The caller's wallet must equal the
|
|
262
|
-
* transfer's `to_wallet`. The accept transaction atomically flips
|
|
263
|
-
*
|
|
264
|
-
*
|
|
265
|
-
* `secrets_rotation_advised` advisory on the project.
|
|
304
|
+
* Accept an incoming WALLET transfer. The caller's wallet must equal the
|
|
305
|
+
* transfer's `to_wallet`. The accept transaction atomically flips ownership,
|
|
306
|
+
* revokes A's CI bindings on the project, enqueues notifications to both
|
|
307
|
+
* parties, and stamps the persistent `secrets_rotation_advised` advisory.
|
|
266
308
|
*/
|
|
267
309
|
accept(transferId: string): Promise<AcceptTransferResult>;
|
|
268
310
|
/**
|
|
269
|
-
*
|
|
270
|
-
*
|
|
271
|
-
*
|
|
311
|
+
* Claim an incoming EMAIL transfer into an org. Omit `organizationId` to claim
|
|
312
|
+
* into a brand-new org. The claim atomically flips ownership (the email analog
|
|
313
|
+
* of {@link Transfers.accept}) and returns the new owner's project keys, which
|
|
314
|
+
* `claim` persists to the keystore — symmetric with `accept` (#428 /
|
|
315
|
+
* `project-transfer-claim-credentials`) — so the claimant can operate the
|
|
316
|
+
* project immediately. Note the claim auth model is principal-based (a
|
|
317
|
+
* control-plane session or a verified-email SIWX match), so — unlike `accept`
|
|
318
|
+
* — a wallet is not assumed to be present.
|
|
319
|
+
*/
|
|
320
|
+
claim(transferId: string, opts?: ClaimTransferInput): Promise<ClaimTransferResult>;
|
|
321
|
+
/**
|
|
322
|
+
* Cancel a pending transfer of either kind. The caller must be authorized for
|
|
323
|
+
* the row's kind (a wallet signer, or an owner/admin of the offering org /
|
|
324
|
+
* the addressed-email principal). Already-processed transfers return 409
|
|
325
|
+
* `TRANSFER_ALREADY_PROCESSED`.
|
|
272
326
|
*/
|
|
273
327
|
cancel(transferId: string, reason?: string): Promise<CancelTransferResult>;
|
|
274
|
-
/** Pending transfers OFFERED TO the
|
|
328
|
+
/** Pending transfers OFFERED TO the caller — both wallet- and email-addressed. */
|
|
275
329
|
listIncoming(opts?: ListTransfersOptions): Promise<TransferSummary[]>;
|
|
276
|
-
/** Pending transfers INITIATED BY the
|
|
330
|
+
/** Pending transfers INITIATED BY the caller — both wallet- and email-addressed. */
|
|
277
331
|
listOutgoing(opts?: ListTransfersOptions): Promise<TransferSummary[]>;
|
|
278
|
-
/**
|
|
279
|
-
* Initiate an email→org handoff of `projectId` to `toEmail`. Like a wallet
|
|
280
|
-
* transfer, freezes owner-side mutations until the recipient claims, the
|
|
281
|
-
* sender cancels, or it expires.
|
|
282
|
-
*/
|
|
283
|
-
initiateHandoff(input: InitiateHandoffInput): Promise<HandoffResult>;
|
|
284
|
-
/** Pending handoffs addressed to the authenticated principal's email. */
|
|
285
|
-
listIncomingHandoffs(): Promise<HandoffSummary[]>;
|
|
286
|
-
/** Preview a handoff (sender, or the addressed recipient). */
|
|
287
|
-
previewHandoff(transferId: string): Promise<ProjectHandoffPreview>;
|
|
288
|
-
/**
|
|
289
|
-
* Claim an incoming handoff into an org. Omit `organizationId` to claim
|
|
290
|
-
* into a brand-new org. The claim atomically flips ownership (the handoff
|
|
291
|
-
* analog of {@link Transfers.accept}).
|
|
292
|
-
*/
|
|
293
|
-
claimHandoff(transferId: string, input?: ClaimHandoffInput): Promise<ClaimHandoffResult>;
|
|
294
|
-
/** Cancel a pending handoff (sender or recipient). */
|
|
295
|
-
cancelHandoff(transferId: string): Promise<CancelTransferResult>;
|
|
296
332
|
}
|
|
297
333
|
//# sourceMappingURL=transfers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transfers.d.ts","sourceRoot":"","sources":["../../src/namespaces/transfers.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"transfers.d.ts","sourceRoot":"","sources":["../../src/namespaces/transfers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cA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