@@ -285,6 +285,8 @@ export interface ExchangeTrade {
285285 receive ?: CryptoId | undefined ; // litecoin
286286
287287 receiveStringAmount ?: string | undefined ; // "0.01"
288+ /** User`s crypto address where tx should be refunded */
289+ refundAddress ?: string ;
288290 fromAddress ?: string | undefined ; // user's address from which the tx is sent - used in DEX
289291 receiveAddress ?: string | undefined ; // user's address for receive tx
290292 rate ?: number | undefined ; // 100
@@ -337,6 +339,11 @@ export interface ExchangeTrade {
337339 tradeForm ?: FormResponse ;
338340}
339341
342+ export interface ExchangeTradeSigned extends ExchangeTrade {
343+ /** SLIP24: Nonce for payment request signature */
344+ tradeSignature : string ;
345+ }
346+
340347export interface ExtendedExchangeTrade extends ExchangeTrade {
341348 requestTradeErrorType ?: "QUOTE_TIMEOUT" | "UNKNOWN" | undefined ;
342349 newQuote ?: ExchangeTrade | undefined ; // A renewed quote, in case of a timeout
@@ -536,6 +543,11 @@ export interface SellFiatTrade {
536543 partnerData2 ?: string | undefined ; // arbitrary data specific for the partner
537544}
538545
546+ export interface SellFiatTradeSigned extends SellFiatTrade {
547+ /** SLIP24: Signature of the trade */
548+ tradeSignature : string ;
549+ }
550+
539551export interface SellVoucherTradeQuoteRequest {
540552 cryptoCurrency ?: CryptoId | undefined ; // bitcoin
541553 language ?: string | undefined ; // en
@@ -589,3 +601,29 @@ export interface WatchSellTradeResponse {
589601 destinationPaymentExtraId ?: string | undefined ; // Extra ID for payments to exchange for networks that require it (destinationTag)
590602 cryptoStringAmount ?: string ; // Crypto amount to send in case of change on provider's side (Banxa)
591603}
604+
605+ export interface PaymentRequestOutput {
606+ address : string ;
607+ amount : string ;
608+ }
609+
610+ export interface CreateTradeSignatureRequestSell {
611+ type : "sell" ;
612+ /** ID of the trade - `paymentId` for sell */
613+ id : string ;
614+ nonce : string ;
615+ outputs : PaymentRequestOutput [ ] ;
616+ memoText : string ;
617+ }
618+
619+ export interface CreateTradeSignatureRequestExchange {
620+ type : "exchange" ;
621+ /** ID of the trade - `orderId` for exchange */
622+ id : string ;
623+ nonce : string ;
624+ outputs : PaymentRequestOutput [ ] ;
625+ }
626+
627+ export type CreateTradeSignatureRequest =
628+ | CreateTradeSignatureRequestSell
629+ | CreateTradeSignatureRequestExchange ;
0 commit comments