/build/rpc / cosign / cross_chain
cosign.list_cross_chain_offers
cosign.list_cross_chain_offers ( "external_chain" "adapter" force_refresh ) List cross-chain settlement offers from the bulletin board. Filters SpotContract offers whose contract_payload contains schema == "cross_chain_spot_v1". Arguments: 1. external_chain (string, optional) Filter by external chain: btc|ethereum|tron 2. adapter (string, optional) Filter by adapter: btc_scriptless_v1|eth_htlc_v1|tron_htlc_v1 3. force_refresh (boolean, optional) Re-fetch from Nostr relays first (default: false) Result: { (json object) "success" : true|false, (boolean) Whether listing succeeded "count" : n, (numeric) Number of cross-chain offers "offers" : [ (json array) Cross-chain offers { (json object) "offer_id" : "str", (string) Offer UUID "maker_pubkey" : "str", (string) Maker Nostr pubkey "network" : "str", (string) Network "cross_chain_payload" : { (json object) Parsed cross-chain payload "schema" : "str", (string) Schema identifier "funding_order" : "str" (string) Funding order } }, ... ] } Examples: > bitcoin-cli cosign.list_cross_chain_offers > bitcoin-cli cosign.list_cross_chain_offers "btc"
Signature
cosign.list_cross_chain_offers(external_chain?: string, adapter?: string, force_refresh?: boolean) → any Code samples
curl --user "$RPC_USER:$RPC_PASS" \
--data-binary '{"jsonrpc":"1.0","id":"docs","method":"cosign.list_cross_chain_offers","params":["\"<external_chain>\"","\"<adapter>\"",false]}' \
-H 'content-type: text/plain;' \
http://127.0.0.1:8332/ Parameters
| Name | Type | Req. | Description |
|---|---|---|---|
| external_chain | string | — | Filter by external chain: btc|ethereum|tron |
| adapter | string | — | Filter by adapter: btc_scriptless_v1|eth_htlc_v1|tron_htlc_v1 |
| force_refresh | boolean | — | Re-fetch from Nostr relays first (default: false) |
Result
Type: any
{ (json object) "success" : true|false, (boolean) Whether listing succeeded "count" : n, (numeric) Number of cross-chain offers "offers" : [ (json array) Cross-chain offers { (json object) "offer_id" : "str", (string) Offer UUID "maker_pubkey" : "str", (string) Maker Nostr pubkey "network" : "str", (string) Network "cross_chain_payload" : { (json object) Parsed cross-chain payload "schema" : "str", (string) Schema identifier "funding_order" : "str" (string) Funding order } }, ... ] }
Source: services/core-node/bcore/src/rpc/cosign.cpp:2344
C++ symbol: cosign_list_cross_chain_offers