How to initialize a Token Account on Solana

Ask System Account to create an empty account owned by Token Program:

User Account asks SYSTEM Program to create a empty USDT Account that owned by Token Program
Create Empty Token Account

const tempTokenAccount = new Account();
const createTempTokenAccountIx = SystemProgram.createAccount({
programId: TOKEN_PROGRAM_ID,
space: AccountLayout.span,
lamports: await connection.getMinimumBalanceForRentExemption(AccountLayout.span, ‘singleGossip’),
fromPubkey: initializerAccount.publicKey,
newAccountPubkey: tempTokenAccount.publicKey
});

After creating an empty account, you might want to initialize it as a Token Account. spl-token library provides createInitAccountInstruction that lets you create a Transaction Instruction.

static createInitAccountInstruction(
programId: PublicKey,
mint: PublicKey,
account: PublicKey,
owner: PublicKey,
): TransactionInstruction;

User Account asks TOKEN Program to initialize the Empty USDT Account, so it belongs to the User
Initialize USDT Token Account