eavz

Actions

Execute operations against third-party services through a unified API.

Actions

An action is a single operation against a third-party service — sending a Slack message, creating a GitHub issue, reading rows from a Google Sheet, or generating text with OpenAI.

Execution Model

Actions can be executed through three interfaces:

  1. REST APIPOST /api/v1/actions/execute
  2. MCP servers — AI agents call tools that map to actions
  3. Playground — test actions interactively from the dashboard

All three use the same underlying execution engine.

Executing an Action

bash
curl -X POST https://api.weavz.io/api/v1/actions/execute \
  -H "Authorization: Bearer wvz_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "integrationName": "slack",
    "actionName": "send_channel_message",
    "workspaceId": "proj_abc123",
    "input": {
      "channel": "#general",
      "text": "Hello from Weavz!"
    },
    "connectionExternalId": "my_slack"
  }'

Response

json
{
  "success": true,
  "output": {
    "ts": "1234567890.123456",
    "channel": "C01234567"
  }
}

Input Schemas

Each action defines an input schema with required and optional properties. Property types include:

TypeDescription
SHORT_TEXTSingle-line string
LONG_TEXTMulti-line text
NUMBERNumeric value
CHECKBOXBoolean
DROPDOWNSelect from available values (resolved from the connected service)
DYNAMICProperties resolved at runtime based on other inputs
ARRAYList of values
OBJECTNested object
JSONRaw JSON input
FILEFile reference

Discovering action inputs

Fetch the integration metadata to see available actions and their input schemas:

bash
curl https://api.weavz.io/api/v1/integrations/slack \
  -H "Authorization: Bearer wvz_your_api_key"

The response includes each action's props array with type, required flag, display name, and description.

Dynamic properties

Some actions have properties that depend on other inputs. For example, selecting a Slack channel might depend on the connected workspace. Use the input value resolution API to fetch dynamic values:

bash
curl -X POST https://api.weavz.io/api/v1/integrations/slack/properties/options \
  -H "Authorization: Bearer wvz_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "propertyName": "channel",
    "connectionExternalId": "my_slack",
    "input": {}
  }'

This returns the available options for dropdown or dynamic properties.

Connection Resolution

When executing an action, Weavz needs a connection to authenticate with the third-party service. You can provide credentials in several ways:

  • Explicit connection — pass connectionExternalId directly
  • External ID — pass externalId to resolve a connection tagged for a specific end-user
  • Workspace context — pass workspaceId to use the workspace's configured connection
  • Workspace integration — let the workspace's integration configuration determine which connection to use
  • Input partials — pass partialIds to apply saved parameter presets with optional enforced values

If the action requires authentication and no connection can be resolved, the API returns a CONNECTION_REQUIRED error.

json
{
  "error": "Connection required for this action",
  "code": "CONNECTION_REQUIRED"
}

Error Handling

Action execution can fail for several reasons:

Error CodeDescription
ACTION_FAILEDThe third-party API returned an error
CONNECTION_REQUIREDNo valid connection found for this action
INTEGRATION_NOT_FOUNDThe specified integration doesn't exist
NOT_FOUNDThe specified action doesn't exist on this integration
QUOTA_EXCEEDEDMonthly action quota exceeded for your plan
RATE_LIMITEDToo many requests — retry after the window resets

ACTION_FAILED details

When a third-party API returns an error, the response includes the original error in the details field:

json
{
  "error": "Action execution failed",
  "code": "ACTION_FAILED",
  "details": {
    "message": "channel_not_found",
    "statusCode": 404
  }
}

Usage Tracking

Each successful action execution is counted toward your organization's monthly usage quota. Usage is tracked per calendar month and resets automatically. Check your current usage from the billing dashboard or via the API.

Next Steps

Try it out in the Playground or learn how to execute actions programmatically.