Skip to main content

Triggers

Time to learn: 8 minutes
Prerequisites: Automation configured with data source and mappings

Triggers are the "go button" that tells Gdocify to generate documents. They determine when and how your automation runs.

Triggers Quick Reference

ManualClick button in Gdocify
AirtableButton, Script, Email
WebhookHTTP request from apps
APIProgrammatic trigger

What Are Triggers?

Triggers are different ways to start your automation:

  • Manual trigger: Click a button in Gdocify
  • Airtable button: Click a button in your Airtable base
  • Webhook: Call a URL from another app
  • API: Send a request from your own application

Why Use Triggers?

Triggers let you:

  • Control when documents are generated - Run on-demand or automatically
  • Integrate with workflows - Connect to other tools and processes
  • Automate generation - Set up hands-free document creation
  • Scale easily - Generate documents for one record or thousands

Manual Triggers

The simplest way to run your automation.

How It Works

  1. Go to your automation in Gdocify
  2. Click the "Run" or "Generate" button
  3. Select which records to process:
    • All records: Generate for every record
    • Specific records: Choose individual records
  4. Click "Generate Documents"

When to Use

  • Testing: Perfect for testing your automation
  • One-time generation: When you need documents now
  • Small batches: For processing a few records
  • On-demand: When you control when to generate

Airtable Triggers

If you're using Airtable, you can add buttons directly in your base.

Button Trigger

Add a button field in Airtable that generates documents:

  1. In Airtable, add a "Button" field to your table
  2. Configure the button to call the Gdocify webhook URL
  3. When you click the button, it generates a document for that specific record

Perfect for:

  • On-demand generation from Airtable
  • Generating documents for specific records
  • User-friendly interface for non-technical users

Script Trigger

Use Airtable scripts for advanced automation:

  1. Create an Airtable script
  2. Call the Gdocify API endpoint
  3. Generate documents based on script logic

Perfect for:

  • Complex automation logic
  • Conditional generation
  • Advanced workflows

Email Trigger

Generate documents when records are emailed:

  1. Set up email automation in Airtable
  2. Configure to trigger Gdocify webhook
  3. Documents generate automatically when emails are sent

Perfect for:

  • Automated email workflows
  • Triggering from Airtable automations
  • Event-driven generation

Google Sheets Webhook Triggers

Trigger from Google Sheets using webhooks:

  1. Set up a webhook URL in Gdocify
  2. Configure Google Sheets to call the webhook
  3. Use Google Apps Script or automation tools
  4. Documents generate when the webhook is called

Perfect for:

  • Google Workspace workflows
  • Spreadsheet-based automation
  • Integration with Google Apps Script

API Triggers

For developers, trigger via API:

  1. Get your API endpoint and authentication key
  2. Send a POST request with record data
  3. Gdocify processes the request and generates documents

Perfect for:

  • Custom applications
  • Existing API infrastructure
  • Full control over triggering

API Request Example

curl -X POST https://api.gdocify.com/trigger \
-H "Authorization: Bearer your-api-key" \
-H "Content-Type: application/json" \
-d '{
"automationId": "your-automation-id",
"recordId": "record-123"
}'

How Triggers Work

When a trigger is activated:

  1. Trigger received: Gdocify receives the trigger request
  2. Data loaded: Reads data from your data source
  3. Template processed: Applies data to your template
  4. Document generated: Creates the Google Doc and/or PDF
  5. Actions executed: Saves files, sends emails, calls webhooks
  6. Status updated: Records the execution in history

Choosing the Right Trigger

Manual Trigger

Use when:

  • You need full control
  • Testing your automation
  • One-time or occasional generation

Airtable Button

Use when:

  • Your team uses Airtable
  • You want user-friendly triggering
  • Generating for specific records

Webhook

Use when:

  • Integrating with other apps
  • Automating from external systems
  • Building custom workflows

API

Use when:

  • Building custom applications
  • Need programmatic control
  • Integrating with existing APIs

Testing Your Trigger

Before using triggers in production:

  1. Test with one record: Always test with a single record first
  2. Verify the output: Check that documents are generated correctly
  3. Check execution history: Review the execution log
  4. Test at scale: Once confirmed, test with multiple records
  5. Monitor performance: Watch for any issues

Best Practices

Trigger Selection

  • Start simple: Begin with manual triggers
  • Choose appropriately: Use the trigger that fits your workflow
  • Test thoroughly: Always test before scaling
  • Document your setup: Note which trigger you're using

Performance

  • Batch processing: Process multiple records efficiently
  • Rate limits: Be aware of API rate limits
  • Error handling: Handle failures gracefully
  • Monitoring: Track trigger success rates

Common Issues

"Trigger not working"

  • Check that you've copied the URL correctly
  • Verify authentication credentials
  • Ensure the trigger endpoint is accessible
  • Review execution history for errors

"Permission denied"

  • Verify authentication credentials
  • Check API keys or tokens
  • Ensure proper permissions are granted
  • Re-authorize if needed

"No records found"

  • Make sure your data source has records
  • Verify records are accessible
  • Check filters or views aren't excluding all records
  • Test data source connection

Tips

  • Start with manual triggers: Easiest way to test your automation
  • Test before scaling: Always test with one record before running for hundreds
  • Use appropriate triggers: Choose the trigger type that fits your workflow
  • Document your triggers: Note which trigger you're using for future reference
  • Monitor execution: Keep an eye on trigger success rates

Next Steps

Now that you understand triggers:

  1. Learn about Run History to track executions
  2. Explore Email Notifications for delivery
  3. Check out Webhooks for integrations