|
190 | 190 | }, |
191 | 191 | "/api/{coin}/wallet/{walletId}/consolidate": { |
192 | 192 | "post": { |
| 193 | + "summary": "Build, sign, and send a consolidation transaction for an account-based asset all in 1 call.", |
| 194 | + "description": "For account-based assets, consolidating the balances in the receive addresses to the base address maximizes the spendable balance of a wallet.", |
193 | 195 | "parameters": [ |
194 | 196 | { |
195 | 197 | "name": "walletId", |
|
214 | 216 | "schema": { |
215 | 217 | "type": "object", |
216 | 218 | "properties": { |
217 | | - "pubkey": { |
218 | | - "type": "string" |
219 | | - }, |
220 | 219 | "source": { |
221 | 220 | "type": "string", |
222 | 221 | "enum": [ |
223 | 222 | "user", |
224 | 223 | "backup" |
225 | | - ] |
| 224 | + ], |
| 225 | + "description": "The key to use for signing the transaction" |
| 226 | + }, |
| 227 | + "pubkey": { |
| 228 | + "type": "string", |
| 229 | + "description": "Public key of the key used for signing multisig transactions" |
226 | 230 | }, |
227 | 231 | "consolidateAddresses": { |
228 | 232 | "type": "array", |
229 | 233 | "items": { |
230 | | - "type": "string" |
| 234 | + "type": "string", |
| 235 | + "description": "Optional: restrict the consolidation to the specified receive addresses. If not provided, will consolidate the funds from all receive addresses up to 500 addresses." |
231 | 236 | } |
232 | 237 | }, |
| 238 | + "commonKeychain": { |
| 239 | + "type": "string", |
| 240 | + "description": "For TSS wallets, this is the common keychain of the wallet" |
| 241 | + }, |
233 | 242 | "apiVersion": { |
234 | 243 | "type": "string", |
235 | 244 | "enum": [ |
236 | 245 | "full", |
237 | 246 | "lite" |
238 | | - ] |
239 | | - }, |
240 | | - "commonKeychain": { |
241 | | - "type": "string" |
| 247 | + ], |
| 248 | + "description": "The Trasaction Request API version to use for MPC EdDSA Hot Wallets. Defaults based on the wallet type and asset curve." |
242 | 249 | } |
243 | 250 | }, |
244 | 251 | "required": [ |
|
322 | 329 | }, |
323 | 330 | "/api/{coin}/wallet/{walletId}/consolidateunspents": { |
324 | 331 | "post": { |
| 332 | + "summary": "Build and send a transaction to consolidate unspents in a wallet.", |
| 333 | + "description": "Consolidating unspents is only for UTXO-based assets.", |
325 | 334 | "parameters": [ |
326 | 335 | { |
327 | 336 | "name": "walletId", |
|
347 | 356 | "type": "object", |
348 | 357 | "properties": { |
349 | 358 | "pubkey": { |
350 | | - "type": "string" |
| 359 | + "type": "string", |
| 360 | + "description": "Public key of the key used for signing multisig transactions" |
351 | 361 | }, |
352 | 362 | "source": { |
353 | 363 | "type": "string", |
354 | 364 | "enum": [ |
355 | 365 | "user", |
356 | 366 | "backup" |
357 | | - ] |
| 367 | + ], |
| 368 | + "description": "The key to use for signing the transaction" |
358 | 369 | }, |
359 | 370 | "feeRate": { |
360 | | - "type": "number" |
| 371 | + "type": "number", |
| 372 | + "description": "Custom fee rate (in base units) per kilobyte" |
361 | 373 | }, |
362 | 374 | "maxFeeRate": { |
363 | | - "type": "number" |
| 375 | + "type": "number", |
| 376 | + "description": "Maximum fee rate (in base units) per kilobyte" |
364 | 377 | }, |
365 | 378 | "maxFeePercentage": { |
366 | | - "type": "number" |
| 379 | + "type": "number", |
| 380 | + "description": "Maximum fee percentage" |
367 | 381 | }, |
368 | 382 | "feeTxConfirmTarget": { |
369 | | - "type": "number" |
| 383 | + "type": "number", |
| 384 | + "description": "Fee transaction confirmation target" |
370 | 385 | }, |
371 | 386 | "bulk": { |
372 | | - "type": "boolean" |
| 387 | + "type": "boolean", |
| 388 | + "description": "Enable bulk processing" |
373 | 389 | }, |
374 | 390 | "minValue": { |
375 | 391 | "oneOf": [ |
|
379 | 395 | { |
380 | 396 | "type": "number" |
381 | 397 | } |
382 | | - ] |
| 398 | + ], |
| 399 | + "description": "Minimum value for unspents" |
383 | 400 | }, |
384 | 401 | "maxValue": { |
385 | 402 | "oneOf": [ |
|
389 | 406 | { |
390 | 407 | "type": "number" |
391 | 408 | } |
392 | | - ] |
| 409 | + ], |
| 410 | + "description": "Maximum value for unspents" |
393 | 411 | }, |
394 | 412 | "minHeight": { |
395 | | - "type": "number" |
| 413 | + "type": "number", |
| 414 | + "description": "Minimum block height" |
396 | 415 | }, |
397 | 416 | "minConfirms": { |
398 | | - "type": "number" |
| 417 | + "type": "number", |
| 418 | + "description": "Minimum confirmations required" |
399 | 419 | }, |
400 | 420 | "enforceMinConfirmsForChange": { |
401 | | - "type": "boolean" |
| 421 | + "type": "boolean", |
| 422 | + "description": "Enforce minimum confirmations for change outputs" |
402 | 423 | }, |
403 | 424 | "limit": { |
404 | | - "type": "number" |
| 425 | + "type": "number", |
| 426 | + "description": "Limit the number of unspents to process" |
405 | 427 | }, |
406 | 428 | "numUnspentsToMake": { |
407 | | - "type": "number" |
| 429 | + "type": "number", |
| 430 | + "description": "Number of unspents to make" |
408 | 431 | }, |
409 | 432 | "targetAddress": { |
410 | | - "type": "string" |
| 433 | + "type": "string", |
| 434 | + "description": "Target address for consolidation" |
411 | 435 | }, |
412 | 436 | "txFormat": { |
413 | 437 | "type": "string", |
414 | 438 | "enum": [ |
415 | 439 | "legacy", |
416 | 440 | "psbt", |
417 | 441 | "psbt-lite" |
418 | | - ] |
| 442 | + ], |
| 443 | + "description": "Transaction format" |
419 | 444 | } |
420 | 445 | }, |
421 | 446 | "required": [ |
|
556 | 581 | "enabletoken", |
557 | 582 | "transfertoken", |
558 | 583 | "trustline" |
559 | | - ] |
| 584 | + ], |
| 585 | + "description": "Required for transactions from MPC wallets." |
560 | 586 | }, |
561 | 587 | "recipients": { |
562 | 588 | "type": "array", |
|
726 | 752 | } |
727 | 753 | }, |
728 | 754 | "required": [ |
729 | | - "source", |
730 | | - "type", |
731 | | - "recipients" |
| 755 | + "source" |
732 | 756 | ] |
733 | 757 | } |
734 | 758 | } |
|
808 | 832 | }, |
809 | 833 | "/api/{coin}/wallet/{walletId}/txrequest/{txRequestId}/signAndSend": { |
810 | 834 | "post": { |
| 835 | + "summary": "Sign a TxRequest and Broadcast it (MPC wallets only)", |
| 836 | + "description": "This is usually needed after resolving a pending approval for a MPC wallet", |
811 | 837 | "parameters": [ |
812 | 838 | { |
813 | 839 | "name": "walletId", |
|
845 | 871 | "enum": [ |
846 | 872 | "user", |
847 | 873 | "backup" |
848 | | - ] |
| 874 | + ], |
| 875 | + "description": "The key to use for signing the transaction" |
849 | 876 | }, |
850 | 877 | "commonKeychain": { |
851 | | - "type": "string" |
| 878 | + "type": "string", |
| 879 | + "description": "Common keychain of the wallet during wallet creation" |
852 | 880 | } |
853 | 881 | }, |
854 | 882 | "required": [ |
855 | | - "source" |
| 883 | + "source", |
| 884 | + "commonKeychain" |
856 | 885 | ] |
857 | 886 | } |
858 | 887 | } |
|
0 commit comments