dotbit
Version:
A complete .bit SDK and utilities in TypeScript
30 lines • 889 B
JavaScript
import { Networking } from '../tools/Networking';
export class SubAccountAPI {
constructor(baseUri) {
this.baseUri = baseUri;
this.net = new Networking(baseUri);
}
initSubAccount(account, keyInfo) {
return this.net.post('sub/account/init', {
account,
type: 'blockchain',
key_info: keyInfo,
});
}
sendTransaction(tx) {
return this.net.post('transaction/send', tx);
}
subAccountList(params) {
return this.net.post('sub/account/list', params);
}
checkSubAccounts(params) {
return this.net.post('sub/account/check', params);
}
createSubAccounts(params) {
return this.net.post('sub/account/create', params);
}
editSubAccount(params) {
return this.net.post('sub/account/edit', params);
}
}
//# sourceMappingURL=SubAccountAPI.js.map