Last updated 3 months ago
OK
Rule ID
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/new-item-reply', { method: 'GET', headers: { "Authorization": "Bearer jwt" }, }); const data = await response.json();
{ "projectId": "123e4567-e89b-12d3-a456-426614174000" }
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/rules/{automationRuleId}', { method: 'DELETE', headers: { "Authorization": "Bearer jwt" }, }); const data = await response.json();
{ "code": "text", "message": "text" }
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/categories', { method: 'GET', headers: { "Authorization": "Bearer jwt" }, }); const data = await response.json();
{ "results": [ { "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "orderPosition": 0, "createdAt": "2024-12-21T12:02:39.808Z", "updatedAt": "2024-12-21T12:02:39.808Z" } ] }
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/categories/{categoryId}', { method: 'DELETE', headers: { "Authorization": "Bearer jwt" }, }); const data = await response.json();
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/new-item-reply', { method: 'PUT', headers: { "Authorization": "Bearer jwt", "Content-Type": "application/json" }, body: JSON.stringify({ "projectId": "123e4567-e89b-12d3-a456-426614174000" }), }); const data = await response.json();
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/categories', { method: 'POST', headers: { "Authorization": "Bearer jwt", "Content-Type": "application/json" }, body: JSON.stringify({ "name": "text" }), }); const data = await response.json();
{ "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "orderPosition": 0, "createdAt": "2024-12-21T12:02:39.808Z", "updatedAt": "2024-12-21T12:02:39.808Z" }
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/rules', { method: 'GET', headers: { "Authorization": "Bearer jwt" }, }); const data = await response.json();
{ "results": [ { "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "description": "text", "categoryId": "123e4567-e89b-12d3-a456-426614174000", "trigger": "feedItemCreated", "orderPosition": 0, "enabled": false, "conditions": { "all": [ { "name": "text" } ] }, "actions": [ { "name": "text" } ], "createdAt": "2024-12-21T12:02:39.808Z", "updatedAt": "2024-12-21T12:02:39.808Z" } ] }
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/rules/reorder', { method: 'PATCH', headers: { "Authorization": "Bearer jwt", "Content-Type": "application/json" }, body: JSON.stringify({ "trigger": "feedItemCreated", "rules": [ { "ruleId": "123e4567-e89b-12d3-a456-426614174000", "newOrderPosition": 0 } ] }), }); const data = await response.json();
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/categories/reorder', { method: 'PATCH', headers: { "Authorization": "Bearer jwt", "Content-Type": "application/json" }, body: JSON.stringify({ "categories": [ { "categoryId": "123e4567-e89b-12d3-a456-426614174000", "newOrderPosition": 0 } ] }), }); const data = await response.json();
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/categories/{categoryId}', { method: 'PATCH', headers: { "Authorization": "Bearer jwt", "Content-Type": "application/json" }, body: JSON.stringify({ "name": "text" }), }); const data = await response.json();
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/rules/{automationRuleId}', { method: 'GET', headers: { "Authorization": "Bearer jwt" }, }); const data = await response.json();
{ "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "description": "text", "categoryId": "123e4567-e89b-12d3-a456-426614174000", "trigger": "feedItemCreated", "orderPosition": 0, "enabled": false, "conditions": { "all": [ { "name": "text" } ] }, "actions": [ { "name": "text" } ], "createdAt": "2024-12-21T12:02:39.808Z", "updatedAt": "2024-12-21T12:02:39.808Z" }
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/rules', { method: 'POST', headers: { "Authorization": "Bearer jwt", "Content-Type": "application/json" }, body: JSON.stringify({ "name": "text", "categoryId": "123e4567-e89b-12d3-a456-426614174000", "trigger": "feedItemCreated", "conditions": {}, "actions": [ { "name": "text" } ] }), }); const data = await response.json();
const response = await fetch('/workspaces/{workspaceId}/inbox/automation/rules/{automationRuleId}', { method: 'PATCH', headers: { "Authorization": "Bearer jwt", "Content-Type": "application/json" }, body: JSON.stringify({}), }); const data = await response.json();