Show examples in:
Delete a environment

Returns

Returns a environment resource object.

Examples

Example Basic example
import { buildClient } from '@datocms/cma-client-node';
async function run() {
const client = buildClient({ apiToken: '<YOUR_API_TOKEN>' });
const environmentId = 'main';
const environment = await client.environments.destroy(environmentId);
console.log(environment);
}
run();