Get AA state vars
Get state variables of an Autonomous Agent.

Example

1
const params = {
2
address: 'TSDLQPZTSVDNC63G7YROC26CYCCZC4GO',
3
var_prefix: 'proposal_1'
4
};
5
6
client.api.getAaStateVars(params, function(err, result) {
7
if (err) return console.error(err);
8
console.log(result);
9
});
Copied!

Returns

1
{
2
proposal_1: '1',
3
proposal_1_amount: '25000',
4
proposal_1_author: 'CWUD2ZRELMGI7CQIXRRGENRMSV2NFZOT',
5
proposal_1_expiration: '1567288484',
6
proposal_1_url: 'https://bit.ly/2Ka8HGo',
7
proposal_1_vest: '40000',
8
proposal_1_vote_K237YYRMBYWCJBLSZGLJTXLZVVEXLI2Y: '1'
9
}
Copied!

Learn more

Last modified 6mo ago
Copy link