Custom Actions

Integration Examples

Common custom action patterns and real-world integration examples

|View as Markdown
1 min read
ℹ️

Custom actions require a Builder plan or higher.

Upgrade to Builder →

ℹ️

Body parameters are sent as top-level JSON keys. When you import a cURL whose body has nested objects or arrays, the importer creates dotted keys such as from.email, and those are sent as flat keys, not nested JSON. For an API that needs a nested body, replace those rows with one AI fills it in parameter of type Object or List (see Nested Body Fields).

Slack Notifications

Send messages to Slack channels via webhook.

Configuration

bash
curl -X POST https://hooks.slack.com/services/{{var.SLACK_WEBHOOK_ID}} \
  -H "Content-Type: application/json" \
  -d '{
    "text": "{{message}}",
    "channel": "{{channel}}",
    "username": "Chipp Bot"
  }'

Parameters

ParameterSourceConfiguration
messageAI fills it inMessage content to send. Type Text, Required
channelAI fills it inTarget channel. Type Text, Required off
SLACK_WEBHOOK_IDApplication variableYour Slack webhook ID, used in the URL

Usage

“Send a message to #general saying the report is ready”

OpenAI Completions

Call OpenAI’s API for advanced processing.

Configuration

bash
curl -X POST https://api.openai.com/v1/responses \
  -H "Authorization: Bearer {{var.OPENAI_API_KEY}}" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-4.1",
    "input": "{{prompt}}",
    "max_output_tokens": {{maxTokens}}
  }'

Parameters

ParameterSourceConfiguration
OPENAI_API_KEYApplication variable (secret)Your OpenAI API key, used in the header
inputAI fills it inText for OpenAI to process. Type Text, Required
max_output_tokensAI fills it inToken limit. Type Whole number, Required off, sample 1000

Set Type to Whole number on max_output_tokens, so the AI sends a number and not the text "1000".

SendGrid Email

Send transactional emails via SendGrid.

Configuration

bash
curl -X POST https://api.sendgrid.com/v3/mail/send \
  -H "Authorization: Bearer {{var.SENDGRID_API_KEY}}" \
  -H "Content-Type: application/json" \
  -d '{
    "personalizations": [{
      "to": [{"email": "{{recipientEmail}}"}],
      "subject": "{{subject}}"
    }],
    "from": {
      "email": "{{var.FROM_EMAIL}}",
      "name": "{{var.FROM_NAME}}"
    },
    "content": [{
      "type": "text/html",
      "value": "{{emailBody}}"
    }]
  }'

Variables

bash
SENDGRID_API_KEY = SG.abc123...
FROM_EMAIL = noreply@example.com
FROM_NAME = Your Company

Google Sheets

Read and write data to Google Sheets.

Read Data

bash
curl -X GET "https://sheets.googleapis.com/v4/spreadsheets/{{var.SHEET_ID}}/values/{{range}}" \
  -H "Authorization: Bearer {{var.GOOGLE_API_KEY}}"

Append Data

bash
curl -X POST "https://sheets.googleapis.com/v4/spreadsheets/{{var.SHEET_ID}}/values/{{range}}:append" \
  -H "Authorization: Bearer {{var.GOOGLE_API_KEY}}" \
  -H "Content-Type: application/json" \
  -d '{
    "values": [[
      "{{system.timestamp}}",
      "{{system.user_id}}",
      "{{data}}"
    ]]
  }'

Webhook with Dependencies

Multi-step workflow using action dependencies.

Step 1: Create User

bash
curl -X POST https://api.example.com/users \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer {{var.API_KEY}}" \
  -d '{
    "name": "{{userName}}",
    "email": "{{userEmail}}"
  }'

Returns: {"data": {"id": "user_123", "email": "john@example.com"}}

Step 2: Send Welcome Email

Use the user ID from Step 1:

bash
curl -X POST https://api.example.com/emails \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer {{var.API_KEY}}" \
  -d '{
    "user_id": "{{userId}}",
    "template": "welcome",
    "send_at": "{{system.timestamp}}"
  }'

Parameter configuration for user_id:

  • Source: Output from another action
  • Action: Create User
  • JSONPath: $.data.id
  • Test value: user_123 (sent by Test Request, which has no earlier action output)

Save “Create User” first: the action list only shows saved actions. If the AI calls “Send Welcome Email” before “Create User” has run in the conversation, the call stops and the AI is told to run “Create User” first.

CRM Integration

Update customer records in your CRM.

Configuration

bash
curl -X PATCH https://api.crm.com/v2/contacts/{{contactId}} \
  -H "Authorization: Bearer {{var.CRM_API_KEY}}" \
  -H "Content-Type: application/json" \
  -d '{
    "properties": {
      "last_contact": "{{system.timestamp}}",
      "last_message": "{{summary}}",
      "status": "{{status}}"
    }
  }'

AI Instructions

For summary parameter:

plaintext
Summarize the key points from the conversation in 1-2 sentences

For status parameter:

plaintext
Determine status: 'interested', 'qualified', 'not-interested', or 'follow-up'

Stripe Payment

Create payment intents via Stripe API.

Configuration

bash
curl -X POST https://api.stripe.com/v1/payment_intents \
  -u "{{var.STRIPE_SECRET_KEY}}:" \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "amount={{amount}}&currency=usd&customer={{customerId}}"

Parameters

ParameterSourceConfiguration
STRIPE_SECRET_KEYApplication variable (secret)Your Stripe secret key
amountAI fills it inAmount in cents. Type Whole number
currencyFixed valueusd
customerAI fills it inStripe customer ID. Type Text

The importer reads a form-encoded -d string as a single data parameter, so add these three body parameters by hand. It also turns -u into a fixed Authorization header that encodes the placeholder text itself, which Chipp cannot resolve. Delete that header and set the Auth tab to Basic Auth with the STRIPE_SECRET_KEY variable as the credential (Stripe uses the key as the username and an empty password). With the Content-Type: application/x-www-form-urlencoded header set, Chipp sends them form-encoded.

Weather API

Fetch weather data for user queries.

Configuration

bash
curl -X GET "https://api.openweathermap.org/data/2.5/weather" \
  -G \
  --data-urlencode "q={{city}}" \
  --data-urlencode "appid={{var.WEATHER_API_KEY}}" \
  --data-urlencode "units=metric"

Usage Examples

“What’s the weather in New York?” “Is it raining in London?”

GitHub Integration

Create issues in GitHub repositories.

Configuration

bash
curl -X POST https://api.github.com/repos/{{var.GITHUB_OWNER}}/{{var.GITHUB_REPO}}/issues \
  -H "Authorization: Bearer {{var.GITHUB_TOKEN}}" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "{{issueTitle}}",
    "body": "{{issueBody}}",
    "labels": {{labels}},
    "assignees": {{assignees}}
  }'

Parameter Configuration

ParameterSourceTypeAI Instructions
titleAI fills it inTextCreate a concise title for the GitHub issue
bodyAI fills it inTextWrite a detailed description of the issue
labelsAI fills it inListRelevant labels, for example [“bug”, “urgent”]. Required off
assigneesAI fills it inListGitHub usernames to assign. Required off

Best Practices

1. Error Handling

Always return clear error messages:

json
{
  "success": false,
  "error": "API key invalid. Please check your credentials."
}

2. Rate Limiting

Respect API rate limits:

  • Add delays between requests
  • Implement exponential backoff
  • Cache responses when possible

3. Security

  • Use HTTPS endpoints only
  • Store credentials as secret variables
  • Never log sensitive data
  • Validate all inputs

4. Performance

  • Paginate large result sets
  • Use field selection to minimize data
  • Implement timeouts (30s max)
  • Cache frequently accessed data

5. Testing

  • Test with various inputs
  • Verify error handling
  • Check edge cases
  • Monitor response times

Next Steps