iOS
Introduction
Initialization
[TPApi registerAppID:@"tpsdk"];
[TPApi setSeed:@"xxxx" error:nil];
[TPApi setBlockChain:TPBlockChainTypeEOSMainNet nodeUrl:@"http://eosinfo.mytokenpocket.vip" plugNodeUrl:@"http://eosinfo.mytokenpocket.vip"];Auth
TPAuthObj *auth = [TPAuthObj new];
auth.dappName = @"xxx";
auth.dappIcon = @"https:.../xx.png";
auth.account = "xxxx";
auth.perm = "xxxx";
auth.selectAll = NO;
auth.actions = [linkActions];
[TPApi sendObj:auth resultHandle:^(TPReqType type,NSError *error) {
// ...
}];
/// Response ↓
TPRespObj.data
{
...,
"ref" : "TokenPocket",
"publickey" : "EOS5AvWThdghtNngWP4UcNi9DL6kF7Mnv2ccO",
"sign" : "SIG_K1_JyCJtV9vqwxtyEt68UhUibkg1CmRjxtG6zkZwE...",
"timestamp" : "1554266633",
}PushTransaction
Method
Modify the seed
seedGet the information of authorized account
Check if permission exists
Check if the permission has been linked to the action
actionClear local authorization
Last updated