Webflow sync, pageviews & more.
NEW

Have any of you ever programmatically set up Webflow pilots after sending a form submission to a custom endpoint? If so, do you have any pointers to save me research time? Thank you!

TL;DR
  • Route Webflow form submissions to a custom backend that parses and validates the data.
  • Use the Webflow CMS API with proper authentication and field slugs to create new CMS items, handling rate limits, publishing options, and errors.

You're asking about creating Webflow CMS items (“pilots”) programmatically after a form submission triggers a custom endpoint. This is definitely possible using Webflow’s CMS API.

1. Use Webflow Forms to Trigger the Endpoint

  • Set your Form Action to a backend endpoint you control (e.g., a serverless function, webhook URL, or API gateway).
  • In Webflow, form submissions won't natively support custom headers, so you'll need to handle simple POST data (form-url-encoded).
  • Use hidden fields to pass additional data (e.g., page slug, user ID).

2. Build the API Handler (Node.js Example)

  • Your endpoint should parse the submission, validate it, and use the Webflow CMS API to create a new item.
  • Webflow's CMS API requires:
  • Site ID and Collection ID
  • API Token (created in Webflow Project Settings > Integrations)
  • Format: JSON with field slugs matching your CMS collection

3. Authenticate Correctly

  • Send requests to Webflow CMS API at:
  • https://api.webflow.com/collections/:collection_id/items
  • Add headers:
  • Authorization: Bearer YOUR_API_TOKEN
  • Content-Type: application/json
  • accept-version: 1.0.0

4. Match CMS Field Slugs

  • When submitting CMS data, use the field slugs, not their display names.
  • Use the Webflow API reference to fetch your collection schema if unsure.

Example CMS item data:

{  "fields": {    "name": "New Pilot",    "slug": "new-pilot",    "published": true,    "custom-field": "XYZ"  }}

5. Handle Rate Limits and Errors

  • Webflow has API rate limits (60 requests/minute per site).
  • Include error handling in your backend to account for validation errors, auth issues, or rate limiting.

6. Consider CMS Publishing Needs

  • If you want the item to appear live immediately, set "live": true and "published": true.
  • Without live, the item will be staged but not published.

7. Useful Tools

  • Postman or Insomnia for testing API request formats.
  • Use https://webflow.com/api/reference for up-to-date endpoint documentation.

Summary

To programmatically create Webflow CMS items from a form:

  • Route the Webflow form to a custom backend
  • Parse and validate the submission
  • Use the Webflow CMS API to create the item using your collection and API token
  • Match field slugs and handle authentication, errors, and publish logic

This approach automates content creation within your Webflow project based on form input.

Rate this answer

Other Webflow Questions