Sorry, no results found for "".
RFC 4122 UUID of workflow expressed in URL-safe base64 format
"uJzC2b6YQg-DW2A5edpQYQ"
The name of the workflow
"Approval by editors required"
The stages of the workflow
[{ id: "waiting_for_review", name: "Waiting for review", initial: true }]
ID of the stage
"waiting_for_review"
Name of the stage
"Waiting for review"
Description of the stage
"Editor has finished writing and is waiting for approval from a supervisor"
Whether this is the initial stage or not
Workflow API key
"approval_by_editors"
Returns a resource object of type workflow
import { buildClient } from "@datocms/cma-client-node";
async function run() { const client = buildClient({ apiToken: process.env.DATOCMS_API_TOKEN });
const workflow = await client.workflows.create({ name: "Approval by editors required", stages: [ { id: "waiting_for_review", name: "Waiting for review", initial: true }, ], api_key: "approval_by_editors", });
// Check the 'Returned output' tab for the result ☝️ console.log(workflow);}
run();
{ id: "uJzC2b6YQg-DW2A5edpQYQ", name: "Approval by editors required", stages: [ { id: "waiting_for_review", name: "Waiting for review", initial: true }, ], api_key: "approval_by_editors",}