Convex Community

CC

Convex Community

Join the Convex Discord! Explore Convex, the fullstack TypeScript platform for developers and startup founders.

Join

support-community

show-and-tell

general

open-source

announcements

Connection to database never establishes

Hi, I'm having issues connecting to my convex backend. It seems the websocket connection never succeeds. This was working fine yesterday. Can anyone tell what's happening? I've attached screenshots of the console. I'm following the otp auth flow with resend from the docs. I can add additional context if needed. Any assistance is much appreciated. Thanks!...
No description

Convex Auth with nuxt/js

Does anyone have any experience or knowledge how to install convex with database auth in nuxt.js? I have read through the docs and tried to come up with something myself but no succes so far.

auth/core and convex-dev/auth seem to have diverged in typing

I used to run convex-auth demo fine on "@auth/core": "^0.34.1", "@convex-dev/auth": "^0.0.61", Now I've tried again and under "@auth/core": "^0.37.0",...
No description

User Profile creation on signup

Hi, Currently when I signup, I am taking a bunch of information from the user, and some of the data is for user profile, and when i signup, i want to create user profile with the data and connect it to the user with id, is that possible?

React Native Quickstart Error

I'm following the docs to set up react-native with convex but running into this error: ``` ✘ [ERROR] Could not resolve "convex/server" ...

How to use Buffer in httpRouter?

Some npm packages I need rely on Buffer and I am already using "use node" for convexAuth ConvexCredentials that is working fine. But then I get the following error: ``` InvalidModules: Hit an error while pushing: Loading the pushed modules encountered the following...

TeamNotFound

I recently updated the team and project name in convex and now when I try to deploy, it's telling me the old slug name is not found. How can I get it to know that the team/slug was changed? Error fetching POST https://provision.convex.dev/api/deployment/authorize_preview 404 Not Found: TeamNotFound: No team found with slug: old-team-name: https://provision.convex.dev/api/deployment/authorize_preview...

What’s the best way to connect Convex DB to external services?

Hey everyone, new fan here! 🍻 I’m trying to dive into Convex and figure out how to integrate it with our current workflow. Using Convex on the client side is pretty straightforward, but I’m struggling to understand how to connect to the database from external services, like a task engine running on Cloudflare Workers. Do we need to expose our queries or mutations using httpAction and build another layer for type safety?...

Convex + Nextjs using preloadQuery inside layout.tsx

Hi, I am trying to understand if doing a preloadQuery inside a layout.tsx and share it amongst my "use client" pages through a "react context" has any advantages over using useQuery on each page (assuming the data hasn't changed). Or if it's an anti-pattern cause layout.tsx is loaded once and will not cause re-renders?...

Tracking time of an API call

I'd like to track the execution time of an API call made in an action, and save the duration into a field. This call could take anywhere from a couple seconds to well over a minute. I'm already creating a record at the start of the action right before calling the API, so my first thought was to just get a new Date instance (or using Date.now()), and then compare the value against the record's creation time. However, then I read this about dates in Convex functions: https://docs.convex.dev/functions/runtimes#using-randomness-and-time-in-queries-and-mutations Is there another way to pull this off and accurately track when I receive the response from the API call?...

How to query data without authentication

Hello guys, I want to get data from some tables without authentication. Can i do that and if possible, how? Thanks!

Buffer not defined

Hi guys, I'm developing a mobile app with a Convex backend and have written functions using the bitcoinjs-lib library. When pushing these functions, I encounter a 'Buffer undefined' error. I've tried adding import ``` { Buffer } from "buffer"; ...
No description

Latest version of @convex-dev/auth is with some type errors using Resend as a magic link provider

I can't use react-email either; it seems like the react config parameter to load a react template isn't working.

Supposed to return ids in random order but mostly does one image

I'm trying to pull down 5 document entries in my "levels" table and it seems to only ever return the ids in the same order most of the time. Every once and a while and sometimes when I have to refresh the npx convex dev server, will it then pull a different image. Is my code wrong? ```tsx import { v } from "convex/values"; ...

API Functions Returning from Server but showing undefined in client

I'm having an issue now where my backend and my front end are not syncing with my api functions. The client is saying the ids are undefined even tho the server is saying they are being returned. Code: https://gist.github.com/DylanDevelops/c200090842b559c1837591662b1c8154...
No description

How to find a table entry from _id

I want to query the my table and find the table document that has the _id i pass in. How do I do this?

Document ID length

It looks from the source code like document IDs must be between 31 and 37 characters—is that correct? What are the odds that this ever changes?

Include relations data

Hi, what is the best way to get the related data in convex, like in prisma if i have a user table and a cars table i can get the user with the related cars using include. what is the best why to achive this in convex?

npx dev --run <func> no longer works

Using latest, 1.16.3. It looks like npx dev --run <func> no longer runs the provided function.

Svelte + Clerk | Any example of how to get it working?

Hey, i want to integrate clerk with convex, can anyone share an example of this integration or maybe what steps should i follow and i will it give a try (I'm using lucia but i would like to migrate) https://github.com/lucia-auth/lucia/discussions/1707 (will be deprecated) ...