Skip to main content

Update stream status

POSThttps://api.moralis-streams.com/streams/evm/:id/status

Updates the status of specific evm stream.

PATH PARAMS
idstringrequired
The id of the stream to update
BODY PARAM
statusstringrequired

The stream status: [active] The Stream is healthy and processing blocks [paused] The Stream is paused and is not processing blocks [error] The Stream has encountered an error and is not processing blocks

Responses
API KEY
import Moralis from "moralis";

try {
await Moralis.start({
apiKey: 'YOUR_API_KEY',
// ...and any other configuration
});

const id = "id-1";
const status = "paused";

const { result } = await Moralis.Streams.updateStatus({
id,
status,
});

console.log(result);
} catch (e) {
console.error(e);
}
Response Example
{
"triggers": {
"inputs": [
""
]
}
}