Skip to main content
PATCH
/
v1
/
gateway
/
workflows
/
{workflowId}
JavaScript
import Triglit from 'triglit';

const client = new Triglit({
  apiKey: 'My API Key',
});

const workflow = await client.workflows.update('wf_abc123def456');

console.log(workflow.id);
{
  "id": "wf_abc123def456",
  "tenantId": "tenant_123",
  "name": "User Onboarding Workflow",
  "isActive": true,
  "createdAt": "2024-01-15T10:30:00.000Z",
  "updatedAt": "2024-01-15T10:30:00.000Z",
  "subTenantId": "sub_tenant_456",
  "description": "Automated workflow for new user onboarding"
}

Authorizations

X-API-Key
string
header
required

Chave de API do tenant (publishable key ou secret key)

Headers

X-API-Key
string
required

Chave de API do tenant (publishable key ou secret key)

Path Parameters

workflowId
string
required

Workflow identifier

Example:

"wf_abc123def456"

Body

application/json
name
string
Required string length: 1 - 255
description
string
Maximum string length: 1000

Response

Workflow updated successfully

id
string
required

Unique workflow identifier

Example:

"wf_abc123def456"

tenantId
string
required

Tenant identifier

Example:

"tenant_123"

name
string
required

Workflow name

Example:

"User Onboarding Workflow"

isActive
boolean
required

Whether the workflow is active

Example:

true

createdAt
string
required

Creation timestamp

Example:

"2024-01-15T10:30:00.000Z"

updatedAt
string
required

Last update timestamp

Example:

"2024-01-15T10:30:00.000Z"

subTenantId
string

Sub-tenant identifier

Example:

"sub_tenant_456"

description
string

Workflow description

Example:

"Automated workflow for new user onboarding"