Skip to Content
Symmio Trading-SDK — the SDK surface for builders on HyperEVM
CoreInstantLayergrantDelegation

grantDelegation

Grant a delegated signer access to one or more selectors until an expiry timestamp.

import { grantDelegation } from "@symmio/trading-core"; const hash = await grantDelegation(config, { account: { addr: account, isPartyB: false }, delegatedSigner: delegate, selectors: ["0x501e891f"], expiryTimestamp: 1_766_000_000n, });

Parameters

accountInstantLayerAccountrequired

Account that grants the delegation. The connected wallet must own this account.

delegatedSignerAddressrequired

Signer that may call the selected Instant Layer functions.

selectorsreadonly Hex[]required

Function selectors (bytes4[]) to grant.

expiryTimestampbigintrequired

Expiry timestamp in seconds.

chainIdnumberoptional

Optional chain override.

simulateBeforeWritebooleanoptional

Dry-run via simulateContract first (defaults to the config’s setting, itself true by default).

Returns

Hash

The submitted transaction hash. Dry-run without sending via simulateGrantDelegation(config, params).

Last updated on