Learn how to connect with NEAR WebSocket.
Supported WebSocket Methods
The Blockdaemon RPC API supports the following methods:
init
nft_mint
nft_token
nft_transfer
nft_transfer_call
nft_resolve_transfer
nft_is_approved
nft_approve
nft_payout
nft_transfer_payout
nft_revoke
nft_revoke_all
nft_total_supply
nft_tokens
nft_tokens_for_owner
nft_supply_for_owner
nft_metadata
How To Access
Step 1: Connect to the secure WebSocket endpoint:
wss://svc.blockdaemon.com/near/mainnet/native?service_name=ws
Step 2: Send an object specifying the type of events you want to filter for and any additional parameters.
For example, to filter for the nft_mint
event, you can send the following message:
{
"secret": "secret",
"filter": [{
"account_id": "nft.nearapps.near",
"status": "SUCCESS",
"event": {
"standard": "nep171",
"event": "nft_mint"
}
}],
"fetch_past_events": 20
}
Step 3: Upon connection, the server will send event notifications matching your filter criteria. Each event notification will be in the format specified by NEP-297.
👋 Need Help?
Contact us through email or our support page for any issues, bugs, or assistance you may need.