Gagan Suie
Gagan Suie
CDCloudflare Developers
Created by Gagan Suie on 2/12/2025 in #workers-help
What is the Best OAuth service for third-party authentication via backend
Currently using this: https://github.com/subhendukundu/worker-auth-providers/ But we need Linkedin OAuth. Thinking about just adding it myself but wondering what others are using for backend OAuth? Id like to use better-auth but they dont offer backend oauth yet. Only integrations via frontend.
1 replies
CDCloudflare Developers
Created by Gagan Suie on 1/25/2025 in #workers-help
DO websocket with DOSQLite
We're building off of the DO chat sample. We're trying to create a single websocket per user so they can switch between their chats. BUT currently, if a user connects with their chatid for the chatroomObject, that wont allow the user to swap between their chats while still being connected via websocket because the entire DO object is based off of the chatid. Would it be dumb to use <app-name> as the chatid for all users and store ALL chat messages in one table and query that via DOSQLite? this.sql.exec('CREATE TABLE IF NOT EXISTS chat_message( _id INTEGER PRIMARY KEY AUTOINCREMENT, userId INTEGER NOT NULL, message TEXT NOT NULL, createdAt DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, updatedAt DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, isDeleted BOOLEAN NOT NULL DEFAULT 0, chatId INTEGER NOT NULL );')
3 replies
CDCloudflare Developers
Created by Gagan Suie on 1/23/2025 in #workers-help
list of values for request.cf.country and request.cf.timezone
We are saving the user's country and timezone when they register by using these headers. But on the frontend we also want to allow them to filter by country and timezone. Is there a definitive list we can retrieve (GET request) or maybe get a list and save it in our D1 db? https://developers.cloudflare.com/rules/transform/managed-transforms/reference/
2 replies
CDCloudflare Developers
Created by Gagan Suie on 8/21/2024 in #workers-help
Is there a way to combine dev and prod workers projects?
Pages has preview and prod environments. Can we do the same for workers projects?
4 replies
CDCloudflare Developers
Created by Gagan Suie on 5/4/2024 in #general-help
Adding, removing, re-adding an dashboard integration fails
Adding, removing, and readding sentry or baselime doesn't work. I dont even get error messages and now i cant even see my workers project in the list.
6 replies
CDCloudflare Developers
Created by Gagan Suie on 4/23/2024 in #general-help
how do i setup and use node:crypto in my workers?
No description
2 replies
CDCloudflare Developers
Created by Gagan Suie on 4/10/2024 in #general-help
How do i debug a websocket connection to DO websockets?
No description
23 replies
CDCloudflare Developers
Created by Gagan Suie on 4/9/2024 in #workers-help
Durable Object websocket keeps failing to connect
Not sure whats happening but today the websocket is not connecting at all. Getting this error in the browser: WebSocket connection to 'wss://dev.api.mage.stream/wsinit/channelid/<REDACTED-ID>/connect' failed:
4 replies
CDCloudflare Developers
Created by Gagan Suie on 4/2/2024 in #workers-help
Production workers 100% errors
Randomly started getting 500 errors in production env workers { "outcome": "exception", "scriptName": "mage-api", "diagnosticsChannelEvents": [], "exceptions": [ { "name": "Error", "message": "The script will never generate a response.", "timestamp": 1712089582194 } ],
51 replies
CDCloudflare Developers
Created by Gagan Suie on 3/27/2024 in #workers-help
Certain get request not working in workers. but works in browser
hi, anyone know why i cant do fetch on this endpoint? keep getting 400 bad request. it works fine in browser. const streamIngestUrlRes = await fetch('https://ingest.twitch.tv/ingests')
6 replies
CDCloudflare Developers
Created by Gagan Suie on 12/24/2023 in #workers-help
Disable swaggerUI in production env
What is the optimal way of disabling access to SwaggerUI in production environment? Currently I'm doing const router = env.ENVIRONMENT === 'local' ? OpenAPIRouter() : Router()
2 replies
CDCloudflare Developers
Created by Gagan Suie on 12/1/2023 in #workers-help
How do i get stream live-input webhook post call and then call websocket event?
I'm trying to retrieve the webhook and then make a websocket event call to the frontend application
2 replies
CDCloudflare Developers
Created by Gagan Suie on 11/27/2023 in #workers-help
Combine RTMPS streams in workers
Is there a way to combine RTMPS streams from multiple users before re-streaming (simulcasting)?
1 replies
CDCloudflare Developers
Created by Gagan Suie on 9/15/2023 in #workers-help
FCM Push Notifications from workers
Are there any libraries to send push notifications via Firebase Cloud Messaging from workers? i cant use the recommended SDK. Maybe i can access the FCM API directly?
3 replies
CDCloudflare Developers
Created by Gagan Suie on 8/14/2023 in #workers-help
Retrieve stream live webrtc video in workers
Is there a way to retrieve the live-stream in workers somehow? perhaps in chunks?
3 replies
CDCloudflare Developers
Created by Gagan Suie on 8/14/2023 in #workers-help
Constellation + stream + workers
Is there a way to use constellation to modify a webRTC live-stream that is using WHIP/WHEP? Maybe redirect stream to workers and make changes and then send to users?
2 replies
CDCloudflare Developers
Created by Gagan Suie on 8/4/2023 in #workers-help
Stripe library integration
Can we just use the npm library? or is there some hoops we gota jump through?
2 replies
CDCloudflare Developers
Created by Gagan Suie on 6/27/2023 in #workers-help
How do i use @solana/pay in a worker?
Is there a way to get this to work in a worker? I believe it depends on node.
2 replies
CDCloudflare Developers
Created by Gagan Suie on 5/31/2023 in #workers-help
Upgraded to miniflare 3.0.0. how do i run locally?
This used to be our dev script to run locally: "dev": "miniflare --live-reload --debug --modules dist/index.mjs --wrangler-env=dev --env .env" What is the updated miniflare 3.0.0 command to run this locally?
5 replies
CDCloudflare Developers
Created by Gagan Suie on 5/5/2023 in #workers-help
Durable Object websocket 1006
I keep getting 1006 errors in my websocket connections on the frontend. what is a good way to resolve this? Extending timeout?
1 replies