Skip to content
On this page

Restake Code Example

The transaction namespace contains methods used for sending transactions. The unique method to the transaction namespace is:

restake(address): Restake user tokens (Claim reward and auto delegate them).

Restake Code Example

ts
// Import SDK
import { Polygon } from '@everstake/wallet-sdk';

const address = '2f92e...6761b'

// Restake user tokens - return transaction
const restakeResp = await Polygon.restake(address);
console.log(restakeResp); // Raw Transaction