private/send_block_proposal
Changed onPosts the caller's signed maker side of a block trade as a block proposal, for a taker to accept with private/accept_block_proposal. The side is signed as the maker side of private/execute_block_trade. The exchange keeps the signature, and no other user can see it. With recipient_wallet, only that wallet can see and accept the proposal. With listed true, the proposal is on the public list that public/get_block_proposals returns, and anyone can accept it. With neither, anyone who has the proposal_id can read and accept the proposal, so share the id only with the intended counterparty. A listed proposal cannot have a recipient_wallet. The proposal can be accepted while the signed side can execute: until 60 seconds before its signature_expiry_sec, or 59 minutes after its nonce time, whichever is first. The response gives that time as expires_at_sec. So the signed signature_expiry_sec sets how long the proposal stays open. A proposal must stay open for at least 60 seconds, or the call fails with invalid_params (-32602). The side must pass the checks that private/verify_block_trade makes for a maker side, except that its nonce time can be up to 59 minutes old. Its total cost must be inside the currency's RFQ price band. A proposal trades with no broker fee. A wallet can have a limited number of open proposals. Returns the proposal with its proposal_id. Its maker and its recipient also receive it on the {wallet}.block_proposals channel. Fails with block_trade_outside_price_band (11123) if the total cost is outside the band, with block_trades_not_available_for_currency (11124) if the currency has no band, with insufficient_funds (11000) if the side does not have enough margin, with block_trade_same_owner (11115) if recipient_wallet is the caller's wallet, with non_unique_nonce (11017) if an open proposal already uses the nonce, and with rate_limit_exceeded (-32000) if the wallet has too many open proposals. Requires the block_trade off-chain scope. A session key that signs the side needs block_trade and an RFQ trade scope for every instrument in the legs.
Request
- Base URLhttps://api.derive.xyz/v3
- AuthAPI key in header X-DeriveWallet and API key in header X-DeriveTimestamp and API key in header X-DeriveSignature
Request body
The caller's maker side of a block trade, signed as for private/execute_block_trade, and who can accept it.
Whether the proposal is on the public list.
Highest total fee this side pays, in USD.
20-byte Ethereum address as a 0x-prefixed lowercase hex string.
20-byte Ethereum address as a 0x-prefixed lowercase hex string.
Response
Success
A block proposal as its maker and its recipient see it.
The block trade, once the proposal executes.
The maker's direction. The taker trades the opposite.
The last second (UTC) at which the proposal can be accepted.
Whether the proposal is on the public list.
20-byte Ethereum address as a 0x-prefixed lowercase hex string.
UUID v4 string
20-byte Ethereum address as a 0x-prefixed lowercase hex string.
Changes
- info
endpoint added
- info