1) you setup a withdraw permission:
get_prototype_operation withdraw_permission_create_operation
[
25,{
"fee": {
"amount": 0,
"asset_id": "1.3.0"
},
"withdraw_from_account": "1.2.0",
"authorized_account": "1.2.0",
"withdrawal_limit": {
"amount": 0,
"asset_id": "1.3.0"
},
"withdrawal_period_sec": 0,
"periods_until_expiration": 0,
"period_start_time": "1970-01-01T00:00:00"
}
]
All you need to define is
* The account from which to withdraw
* The account that is allowed to withdraw
* The asset and amount limit that is allowed to withdraw
* And the period in which the limit is reset (e.g. 1k$ monthly.)
* as well as the start time
2) The other party can withdraw funds from your account with the
withdraw operation:
get_prototype_operation withdraw_permission_claim_operation
[
27,{
"fee": {
"amount": 0,
"asset_id": "1.3.0"
},
"withdraw_permission": "1.12.0",
"withdraw_from_account": "1.2.0",
"withdraw_to_account": "1.2.0",
"amount_to_withdraw": {
"amount": 0,
"asset_id": "1.3.0"
}
}
]
You need
* The actually object id of that withdrawal permission
* the account to withdraw from (imho redundant)
* the account to withdraw to
* and the amount
The biggest problem here is that the withdraw permissions are not
"searchable" and I don't think they are in the results of
get_full_account yet.
@abit: maybe you can help add them there.
Once you have a withdraw permission object id (and the matching
account), you can create a withdrawal transaction!