import Triglit from 'triglit';
const client = new Triglit({
apiKey: 'My API Key',
});
// Automatically fetches more pages as needed.
for await (const trigger of client.triggers.list()) {
console.log(trigger.id);
}{
"data": [
{
"id": "trg_abc123def456",
"tenantId": "tenant_123",
"workflowVersionId": "wfv_abc123def456",
"name": "User Registration Webhook",
"type": "webhook",
"config": {},
"isActive": true,
"createdAt": "2024-01-15T10:30:00.000Z",
"updatedAt": "2024-01-15T10:30:00.000Z",
"subTenantId": "sub_tenant_456"
}
],
"page": 0,
"lastPage": 2
}Retrieves a paginated list of triggers for the tenant. Accepts both public and secret keys.
import Triglit from 'triglit';
const client = new Triglit({
apiKey: 'My API Key',
});
// Automatically fetches more pages as needed.
for await (const trigger of client.triggers.list()) {
console.log(trigger.id);
}{
"data": [
{
"id": "trg_abc123def456",
"tenantId": "tenant_123",
"workflowVersionId": "wfv_abc123def456",
"name": "User Registration Webhook",
"type": "webhook",
"config": {},
"isActive": true,
"createdAt": "2024-01-15T10:30:00.000Z",
"updatedAt": "2024-01-15T10:30:00.000Z",
"subTenantId": "sub_tenant_456"
}
],
"page": 0,
"lastPage": 2
}Chave de API do tenant (publishable key ou secret key)
Chave de API do tenant (publishable key ou secret key)
Search term to filter triggers
Type of the triggers to return
schedule, webhook Whether the triggers should be active
Number of triggers per page
20
Page number (zero-based)
0
Workflow version identifier
Was this page helpful?