@ton3/liteclient
Version:
TON Blockchain LiteClient
16 lines (13 loc) • 432 B
text/typescript
import { crc32 } from '../../utils';
import { StreamWriter } from '../../tl/stream';
export interface AccountId {
workchain: number;
id: Uint8Array;
}
export const accountId = {
tag: crc32('liteServer.accountId workchain:int id:int256 = liteServer.AccountId'),
write: (bufferWriter: StreamWriter, account: AccountId) => {
bufferWriter.writeInt32LE(account.workchain);
bufferWriter.writeBuffer(account.id);
},
};