Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Feat/jotform #2616

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
Shubhamxshah wants to merge 11 commits into simstudioai:staging
base: staging
Choose a base branch
Loading
from Shubhamxshah:feat/jotform
Open

Conversation

@Shubhamxshah
Copy link

@Shubhamxshah Shubhamxshah commented Dec 28, 2025
edited
Loading

Added https://jotform.com as a tool and trigger/block integration. This enables workflows to:

  • Trigger on form submissions via webhook (multipart/form-data)
  • Retrieve form submissions using the Jotform API
  • Get form details and metadata
  • List all forms in the account

Key implementation details:

  • Uses API Key authentication (Jotform doesn't support OAuth)
  • Added multipart/form-data parsing to webhook processor to handle Jotform's webhook format
  • Webhook trigger exposes form data at webhook.data.payload with dynamic field IDs (e.g., q2_q2_fullname0, q3_q3_email1)
  • Supports both block mode (API tools) and trigger mode (webhooks)

Type of Change

  • New feature

Testing

How has this been tested?

  • ✅ Tested webhook trigger end-to-end with live Jotform submissions via ngrok tunnel
  • ✅ Verified multipart/form-data parsing correctly extracts form field values
  • ✅ Confirmed webhook registration and deployment workflow
  • ✅ Tested form data access in subsequent blocks (e.g., Gmail integration)
  • ✅ Verified all three Jotform tools are registered and accessible in UI

What should reviewers focus on?

  • Webhook processor changes (lib/webhooks/processor.ts:79-102) - added multipart/form-data parsing
  • Trigger output structure (triggers/jotform/webhook.ts) - using nested paths like webhook.data.payload.* to match webhook data structure
  • API Key authentication - verify no OAuth credentials are referenced
  • Form field access pattern - dynamic field IDs require accessing via webhook.data.payload.q{N}_{name}{index} format

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing (webhook integration tested manually, unit tests TBD)
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the ./CONTRIBUTING.md#contributor-license-agreement-cla

Screenshots/Videos
1.
image

image
image

greptile-apps[bot] reacted with thumbs up emoji
icecrasher321 and others added 11 commits December 18, 2025 16:23
...dioai#2481)
The realtime service network policy was missing the custom egress rules section
that allows configuration of additional egress rules via values.yaml. This caused
the realtime pods to be unable to connect to external databases (e.g., PostgreSQL
on port 5432) when using external database configurations.
The app network policy already had this section, but the realtime network policy
was missing it, creating an inconsistency and preventing the realtime service
from accessing external databases configured via networkPolicy.egress values.
This fix adds the same custom egress rules template section to the realtime
network policy, matching the app network policy behavior and allowing users to
configure database connectivity via values.yaml.
Copy link

vercel bot commented Dec 28, 2025

@Shubhamxshah is attempting to deploy a commit to the Sim Team on Vercel.

A member of the Team first needs to authorize it.

Copy link
Contributor

greptile-apps bot commented Dec 28, 2025

Greptile Summary

Added comprehensive Jotform integration supporting both webhook triggers and API-based operations.

Key Changes:

  • Webhook Support: Added multipart/form-data parsing to webhook processor (processor.ts:79-102) to handle Jotform's webhook format, with fallback for both rawRequest field and direct form field extraction
  • Three API Tools: Implemented submissions, get_form, and list_forms tools for retrieving form data via Jotform API
  • API Key Authentication: All tools correctly use visibility: 'user-only' for API key parameters, following custom instruction 2851870a (user-provided credentials should use user-only, not hidden)
  • Webhook Trigger: Created webhook trigger with proper output structure using webhook.data.payload.* for accessing form fields with dynamic IDs (e.g., q3_q3_email1)
  • Registry Integration: Properly registered in blocks, tools, and triggers registries with Jotform brand icon

Technical Implementation:

  • Tools use GET requests with API key in query string following Jotform's API conventions
  • Webhook processor enhancement is backward-compatible, only activating for multipart/form-data content type
  • Block configuration supports both trigger mode (webhooks) and block mode (API operations) with conditional field visibility
  • Network policy change (adding custom egress rules support) is unrelated to Jotform but included in same commit

Testing Confirmed:
Per PR description, end-to-end webhook testing was completed with live Jotform submissions via ngrok tunnel, and all three API tools are verified accessible in UI.

Confidence Score: 5/5

  • This PR is safe to merge with minimal risk
  • Implementation follows established patterns consistently across the codebase, uses proper authentication visibility (user-only for API keys per custom instructions), includes comprehensive error handling in webhook processor, and has been thoroughly tested end-to-end per PR description. The multipart/form-data parsing is backward-compatible and only activates for the specific content type.
  • No files require special attention

Important Files Changed

Filename Overview
apps/sim/lib/webhooks/processor.ts Added multipart/form-data parsing support for Jotform webhooks, handles both rawRequest field and direct form field extraction with proper error handling
apps/sim/triggers/jotform/webhook.ts New webhook trigger configuration for Jotform with proper setup instructions and webhook.data.payload output structure
apps/sim/tools/jotform/submissions.ts Implements form submissions retrieval via Jotform API with pagination, filtering, and proper API key authentication using user-only visibility
apps/sim/blocks/blocks/jotform.ts Complete block configuration supporting three operations (submissions, get form, list forms) and webhook trigger integration

Sequence Diagram

sequenceDiagram
 participant User as User (Jotform)
 participant Jotform as Jotform Service
 participant Webhook as Webhook Endpoint
 participant Processor as Webhook Processor
 participant Parser as multipart/form-data Parser
 participant DB as Database
 participant Queue as Task Queue
 participant Executor as Workflow Executor
 
 User->>Jotform: Submit form
 Jotform->>Webhook: POST /api/webhooks/{path}<br/>(multipart/form-data)
 Webhook->>Processor: parseWebhookBody()
 Processor->>Parser: Parse Content-Type: multipart/form-data
 
 alt Has rawRequest field
 Parser->>Parser: JSON.parse(rawRequest)
 else Direct form fields
 Parser->>Parser: Convert FormData to object
 end
 
 Parser-->>Processor: Return parsed body
 Processor->>DB: Find webhook by path
 DB-->>Processor: Return webhook + workflow config
 Processor->>Processor: checkWebhookPreprocessing()<br/>(rate limits, deployment)
 Processor->>Queue: Queue webhook execution
 Queue-->>Webhook: Return 200 OK
 Queue->>Executor: Execute workflow with webhook.data.payload
 Executor->>Executor: Access form fields<br/>(e.g., webhook.data.payload.q3_email1)
Loading

Copy link
Contributor

greptile-apps bot commented Dec 28, 2025

Greptile found no issues!

From now on, if a review finishes and we haven't found any issues, we will not post anything, but you can confirm that we reviewed your changes in the status check section.

This feature can be toggled off in your Code Review Settings by deselecting "Create a status check for each PR".

Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /