PipedreamHQ / PipedreamHQ/pipedream

[BUG] CORS errors when sending requests to `GET /deployed-triggers/{trigger_id}`

Open
#18,816 1 comment 0 reactions 0 assignees View on GitHub
bug tracked internally triaged
Dominant language
JavaScript
Stars
11.7k
Forks
5.8k
Avg merge
3d 10h
Merged PRs (30d)
102

Description

**Describe the bug**

I get CORS errors when sending requests to the [Get deployed trigger](https://pipedream.com/docs/connect/api-reference/get-deployed-trigger) endpoint. I don't get CORS errors for any other endpoints - just this one.

I'm using the Typescript SDK (2.1.0) browser client to make these requests, but the errors also appears if I manually make the request with the browser's Fetch API.

**To Reproduce**
Steps to reproduce the behavior:

1. Create a browser client with `createFrontendClient()`
2. Deploy a trigger with `client.triggers.deploy()`
3. Try to get the trigger with `client.deployedTriggers.retrieve()`

At this point, the request will fail with CORS errors. If I run the browser without CORS protections, it passes and I can see the correct response data.

**Expected behavior**
The request should not fail with CORS errors and should work from the browser.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.