API Kit Reference
getSafeOperationsByAddress

getSafeOperationsByAddress

Returns the list of Safe operations associated to a Safe account.

Usage


_11
import { GetSafeOperationListProps } from '@safe-global/api-kit'
_11
import { apiKit } from './setup.ts'
_11
_11
const config: GetSafeOperationListProps = {
_11
safeAddress: '0x...',
_11
ordering: 'created', // Optional
_11
limit: '10', // Optional
_11
offset: '50' // Optional
_11
}
_11
_11
const safeOperationsResponse = await apiKit.getSafeOperationsByAddress(config)

Returns

Promise<GetSafeOperationListResponse>

The paginated list of Safe operations.

Parameters

config.safeAddress

  • Type: string

The Safe address.


_10
const safeOperationsResponse = await apiKit.getSafeOperationsByAddress({
_10
safeAddress: '0x...'
_10
})

config.ordering (Optional)

  • Type: string
  • Default: -user_operation__nonce

The field used when ordering the results.

Can be one of: -user_operation__nonce, user_operation__nonce, -created, created.


_10
const safeOperationsResponse = await apiKit.getSafeOperationsByAddress(
_10
{
_10
safeAddress: '0x...',
_10
ordering: 'created'
_10
}
_10
)

config.limit (Optional)

  • Type: number

The number of results to return per page.


_10
const safeOperationsResponse = await apiKit.getSafeOperationsByAddress(
_10
{
_10
safeAddress: '0x...',
_10
limit: 10
_10
}
_10
)

config.offset (Optional)

  • Type: number

The initial index from which to return the results.


_10
const safeOperationsResponse = await apiKit.getSafeOperationsByAddress(
_10
{
_10
safeAddress: '0x...',
_10
offset: 50
_10
}
_10
)

Was this page helpful?