Get Message Data
- Java
- Nodejs
- Python
- Rust
- Wasm
Once a message is broadcast, you can use the
GetMessageBuilder
helper class that you can instantiate using
the Client.getMessage()
function to retrieve it from
the network. The GetMessageBuilder
provides helper functions related to the message, such as
Client.getMessage().data(str)
and
Client.getMessage().metadata(str)
:
loading...
Output example:
Message meta data:
{
"messageId":"e52b631bc7500366b90c6e11eb7fd6abaa7527f9bb5b4b512b0b9112bb9e7be8",
"parentMessageIds": [
"26d72339ed262c1ec29d6c91de6be26d067b3327191f5e47606df53cc40e334e",
"6289ea0aecf3830e5e8d9925959bb6e804e324bb6db23c5701f7a538d12831f6",
"fdbf2d02603235fdff99f0ceb57705ead95041d62de386387f2922e5d9f6c502",
"ffa26139ca7f9d4849e118ff369fb3a387c8fefd8d15232b8353d4acf334324c"
],
"isSolid":true,
"shouldPromote":false,
"shouldReattach":false
}
Message data:
{
"message": {
"networkId":"14379272398717627559",
"parentMessageIds": [
"27782707e4cbf84ca26b3db881bbf39b6429f9ee736a0cbe5a1c177d7a52b05d",
"61cdf92c64a3304bbbabaf9fbfb0ea7ef9624e1eedea68efbe08595ccdf853e1",
"a222d13e3ee51b56b0b0e38140a5f7f813b6d9e29b752d7e1e2424099455080d",
"ab6bca20091b58dcbb0906438a7e47bfb11621c4a37b8d118b565f7f138a40d6"
],
"payload": {
"type":2,
"index":"484f524e4554205370616d6d6572",
"data":"42696e61727920697320746865206675747572652e0a436f756e743a2031333936393530390a54696d657374616d703a20323032312d30352d33315431353a33363a30392b30323a30300a54697073656c656374696f6e3a203337c2b573"
},
"nonce":"246736"
},
"messageId":"30d87fa9917602e5685638e37802bde11b260bd2379f6c850704d7babd365b44"
}
Client.getMessage().metadata()
provides information on how the given message fits to network structures, such asledger_inclusion_state
, etc.Client.getMessage().data()
provides all the data that relates to the given message and its payload(s).
Once a message is broadcast, you can use the
MessageFinder
helper class that you can instantiate using the
Client.getMessage()
function to retrieve it from the
network. The MessageFinder
provides helper functions related to the message, such as Client.getMessage().data(id: str)
and Client.getMessage().metadata(str)
:
loading...
Output example:
Message meta data:
{
"messageId":"e52b631bc7500366b90c6e11eb7fd6abaa7527f9bb5b4b512b0b9112bb9e7be8",
"parentMessageIds": [
"26d72339ed262c1ec29d6c91de6be26d067b3327191f5e47606df53cc40e334e",
"6289ea0aecf3830e5e8d9925959bb6e804e324bb6db23c5701f7a538d12831f6",
"fdbf2d02603235fdff99f0ceb57705ead95041d62de386387f2922e5d9f6c502",
"ffa26139ca7f9d4849e118ff369fb3a387c8fefd8d15232b8353d4acf334324c"
],
"isSolid":true,
"shouldPromote":false,
"shouldReattach":false
}
Message data:
{
"message": {
"networkId":"14379272398717627559",
"parentMessageIds": [
"27782707e4cbf84ca26b3db881bbf39b6429f9ee736a0cbe5a1c177d7a52b05d",
"61cdf92c64a3304bbbabaf9fbfb0ea7ef9624e1eedea68efbe08595ccdf853e1",
"a222d13e3ee51b56b0b0e38140a5f7f813b6d9e29b752d7e1e2424099455080d",
"ab6bca20091b58dcbb0906438a7e47bfb11621c4a37b8d118b565f7f138a40d6"
],
"payload": {
"type":2,
"index":"484f524e4554205370616d6d6572",
"data":"42696e61727920697320746865206675747572652e0a436f756e743a2031333936393530390a54696d657374616d703a20323032312d30352d33315431353a33363a30392b30323a30300a54697073656c656374696f6e3a203337c2b573"
},
"nonce":"246736"
},
"messageId":"30d87fa9917602e5685638e37802bde11b260bd2379f6c850704d7babd365b44"
}
Client.getMessage().metadata()
provides information on how the given message fits to network structures, such asledger_inclusion_state
, etc.Client.getMessage().data()
provides all the data that relates to the given message and its payload(s).
Once a message is broadcast, you can use the
Client.get_message_data(message_id: str)
and
Client.get_message_metadata()
functions used to get all the information about the message from the Tangle.
loading...
Output example:
Message meta data:
{
"message_id":"e2daa4c6b012b615becd6c12189b2c9e701ba0d53b31a15425b21af5105fc086",
"parent_message_ids":[
"0e2705ce50fec88f896663d4b7d562e74cbcfdd951ac482b1f03cfa5f27396d7",
"0f5a0b2041766127c3f3bff2dd653b450b72e364765fcc805a40423c59ed01f9",
"20635b30aee437575d7e6abdf6629eec80543bee30848b0abdda2200fc11a977",
"da97cd6cfcbb854b8fd3f064c8459c5c9eae80dbd5ef594a3e1a26dcb8fc078c"
],
"is_solid":true,
"referenced_by_milestone_index":284866,
"milestone_index":"None",
"ledger_inclusion_state":{
"state":"NoTransaction"
},
"conflict_reason":"None",
"should_promote":"None",
"should_reattach":"None"
}
Message data:
{
"message_id":"e2daa4c6b012b615becd6c12189b2c9e701ba0d53b31a15425b21af5105fc086",
"network_id":7712883261355838377,
"parents":[
"0e2705ce50fec88f896663d4b7d562e74cbcfdd951ac482b1f03cfa5f27396d7",
"0f5a0b2041766127c3f3bff2dd653b450b72e364765fcc805a40423c59ed01f9",
"20635b30aee437575d7e6abdf6629eec80543bee30848b0abdda2200fc11a977",
"da97cd6cfcbb854b8fd3f064c8459c5c9eae80dbd5ef594a3e1a26dcb8fc078c"
],
"payload":"None",
"nonce":2305843009213869242
}
Client.get_message_metadata
provides information on how the given message fits to network structures such asledger_inclusion_state
.Client.get_message_data
provides all the data that relates to the message and its payload(s)
Once a message is broadcast, you can use the
GetMessageBuilder
helper class
that you can instantiate using the
Client.get_message()
function to retrieve it from the network. The GetMessageBuilder
provides helper functions related to the message, such
as
Client.get_message().data(message_id: &MessageId)
and
Client.get_message().metadata(message_id: &MessageId)
:
loading...
Output example:
Message meta data:
{
"messageId":"e52b631bc7500366b90c6e11eb7fd6abaa7527f9bb5b4b512b0b9112bb9e7be8",
"parentMessageIds": [
"26d72339ed262c1ec29d6c91de6be26d067b3327191f5e47606df53cc40e334e",
"6289ea0aecf3830e5e8d9925959bb6e804e324bb6db23c5701f7a538d12831f6",
"fdbf2d02603235fdff99f0ceb57705ead95041d62de386387f2922e5d9f6c502",
"ffa26139ca7f9d4849e118ff369fb3a387c8fefd8d15232b8353d4acf334324c"
],
"isSolid":true,
"shouldPromote":false,
"shouldReattach":false
}
Message data:
{
"message": {
"networkId":"14379272398717627559",
"parentMessageIds": [
"27782707e4cbf84ca26b3db881bbf39b6429f9ee736a0cbe5a1c177d7a52b05d",
"61cdf92c64a3304bbbabaf9fbfb0ea7ef9624e1eedea68efbe08595ccdf853e1",
"a222d13e3ee51b56b0b0e38140a5f7f813b6d9e29b752d7e1e2424099455080d",
"ab6bca20091b58dcbb0906438a7e47bfb11621c4a37b8d118b565f7f138a40d6"
],
"payload": {
"type":2,
"index":"484f524e4554205370616d6d6572",
"data":"42696e61727920697320746865206675747572652e0a436f756e743a2031333936393530390a54696d657374616d703a20323032312d30352d33315431353a33363a30392b30323a30300a54697073656c656374696f6e3a203337c2b573"
},
"nonce":"246736"
},
"messageId":"30d87fa9917602e5685638e37802bde11b260bd2379f6c850704d7babd365b44"
}
Client.getMessage().metadata()
provides information on how the given message fits to network structures, such asledger_inclusion_state
, etc.Client.getMessage().data()
provides all the data that relates to the given message and its payload(s).
Once a message is broadcast, you can use the
MessageGetter
helper class that you can instantiate using the
Client.getMessage()
function to retrieve
it from the network. The MessageGetter
provides helper functions related to the message, such as
Client.getMessage().data(message_id: String)
and
Client.getMessage().metadata(message_id: String)
:
loading...
Output example:
Message meta data:
{
"messageId":"e52b631bc7500366b90c6e11eb7fd6abaa7527f9bb5b4b512b0b9112bb9e7be8",
"parentMessageIds": [
"26d72339ed262c1ec29d6c91de6be26d067b3327191f5e47606df53cc40e334e",
"6289ea0aecf3830e5e8d9925959bb6e804e324bb6db23c5701f7a538d12831f6",
"fdbf2d02603235fdff99f0ceb57705ead95041d62de386387f2922e5d9f6c502",
"ffa26139ca7f9d4849e118ff369fb3a387c8fefd8d15232b8353d4acf334324c"
],
"isSolid":true,
"shouldPromote":false,
"shouldReattach":false
}
Message data:
{
"message": {
"networkId":"14379272398717627559",
"parentMessageIds": [
"27782707e4cbf84ca26b3db881bbf39b6429f9ee736a0cbe5a1c177d7a52b05d",
"61cdf92c64a3304bbbabaf9fbfb0ea7ef9624e1eedea68efbe08595ccdf853e1",
"a222d13e3ee51b56b0b0e38140a5f7f813b6d9e29b752d7e1e2424099455080d",
"ab6bca20091b58dcbb0906438a7e47bfb11621c4a37b8d118b565f7f138a40d6"
],
"payload": {
"type":2,
"index":"484f524e4554205370616d6d6572",
"data":"42696e61727920697320746865206675747572652e0a436f756e743a2031333936393530390a54696d657374616d703a20323032312d30352d33315431353a33363a30392b30323a30300a54697073656c656374696f6e3a203337c2b573"
},
"nonce":"246736"
},
"messageId":"30d87fa9917602e5685638e37802bde11b260bd2379f6c850704d7babd365b44"
}
Client.getMessage().metadata()
provides information on how the given message fits to network structures, such asledger_inclusion_state
, etc.Client.getMessage().data()
provides all the data that relates to the given message and its payload(s).