Skip to main content

Mastra.getStorage()

The .getStorage() method is used to retrieve the storage instance that has been configured in the Mastra instance.

Usage example

mastra.getStorage();

Parameters

This method does not accept any parameters.

Returns

storage:

MastraStorage | undefined
The configured storage instance, or undefined if no storage has been configured.

On this page