Skip to content

Commit fdf6c4a

Browse files
author
aadamgough
committed
save before deployment fix
1 parent ac94241 commit fdf6c4a

File tree

1 file changed

+9
-0
lines changed
  • apps/sim/app/api/webhooks/trigger/[path]

1 file changed

+9
-0
lines changed

apps/sim/app/api/webhooks/trigger/[path]/route.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,15 @@ export async function POST(
123123
return authError
124124
}
125125

126+
const isGrainVerificationRequest =
127+
foundWebhook.provider === 'grain' && (!body || Object.keys(body).length === 0 || !body.type)
128+
if (isGrainVerificationRequest) {
129+
logger.info(
130+
`[${requestId}] Grain verification request detected - returning 200 for reachability test`
131+
)
132+
return NextResponse.json({ status: 'ok', message: 'Webhook endpoint verified' })
133+
}
134+
126135
let preprocessError: NextResponse | null = null
127136
try {
128137
preprocessError = await checkWebhookPreprocessing(foundWorkflow, foundWebhook, requestId)

0 commit comments

Comments
 (0)