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

self-hosted

announcements

convex.cloud requests blocked by malwarebytes

I just had a usertest session of my app and the user reported that links to my convex.cloud deployment were blocked by malwarebytes so we couldn't do any testing. Has this happened before? Do we have any idea what could cause this?

Getting the user id

I am following a tutorial where they use
const userId = await auth.getUserId(ctx)
const userId = await auth.getUserId(ctx)
This is apprently deprecated now, so looking at the Convex code nase in my IDE I see I have to use
const userId = await getAuthUserId(ctx);
const userId = await getAuthUserId(ctx);
...

What to put for auth.config.ts domain?

If the url for the jwks.json is https://auth.privy.io/api/v1/apps/<app_id>/jwks.json, what should be the value of domain in auth.config.ts?

debouncing

hey! i have a text input and based on its value i need to query the database? right now as soon as i type something it starts to query and is being super reactive. which is good, but at the same time "isn't it putting too much pressure on db"? and hence increasing the total costs for me? should i implement a debouncing on the client side for that? if yes -- then whats is the best way to do that? because its returning immediately results for previous debounced value -- which is wrong and staying like that for some time until the next debounced value appears...

About receiving useQuery events

I have a question about useQuery. (This is a translation, so the wording may be awkward). I'm developing a chat room. I'll give you an example to help you understand. I've created the following getMessages function to query messages per chat room. export const getMessages = query({...

Convex Auth + Google + Custom Domain

Hey Convex team, I've configured Convex Auth with Google and it works great, except my Convex .site domain is being used even though I have a custom HTTP Actions domain configured in both Convex and Google Auth Platform. The Convex URL shows up in the Google sign-in page, which makes it look untrustworthy to my customer (see screenshot) -- I need this page to display my custom subdomain instead. I tried editing the domain value in my auth.config.ts, but this doesn't help -- it seems process.env.CONVEX_SITE_URL is hardcoded in several places....
No description

Clerk integration call functions infinitely - need help

Using expo@52.0.17, convex@1.17.3 and @clerk/clerk-expo@2.4.2, currently working in a turborepo project with yarn I have configured the clerk integration according to the documentation, my _layout.tsx : ```typescript import { ClerkProvider, useAuth, ClerkLoaded } from "@clerk/clerk-expo"; import { ConvexProviderWithClerk } from "convex/react-clerk";...
No description

convex.json schema?

Hey there, I was wondering if there was a JSON schema available for the convex.json config file by chance. Does this exist? Couldn't find anything on the Convex search.

I currently run a cron job every 20 sec but its using bandwidth a lot how can i reduce the bandwidth

My cron job currently runs every 20 sec. It scrapes data from a site and inserts into the db. The db has 300 rows and 12 columns which is updated every 20 sec. My ideal situation is to be able to run the cron every 10 sec or even lower but seeing that i am doing something clearly wrong how can i optimise this behavior. I liked using convex because of the real time changes that can be seen in the UI when i change the db data after cron job updates it. Any help is appreciated.
No description

.paginate combined with .withIndex is causing an error

let say I have two tables in my scheme that represents a user that lives in a city and posts that are made in a city. All the code below could be better arranged, but this is for the simplicity of the example: ```TS const userTable = defineTable({...

Convex Auth + Tamagui (Monorepo)

Hey, I added convex to my nextjs app so far, but trying to use Auth signIn Im getting http://localhost:3000/api/auth 404 Not found error. What am I doing wrong?
No description

Convex with Vue/Nuxt

Hi everyone! Has anyone here used Convex with Vue.js or Nuxt.js? If so, I’d love to hear about your experiences and best practices! Also, is there any official support for Vue.js coming from Convex, similar to the @convex-dev/react library for React? Or any guidance on how to best leverage Convex’s features in Vue apps, especially for managing real-time updates?...

Telegram Authentication

I'm writing a React app with Convex. I want to support Telegram's super simple Mini App authentication. Here's how it works:...

how do you do a like operator in queries?

Just started using Convex and I'm trying to find out how to do a simple like operator in a query.

How to get `ctx` through indirection?

I'm writing a telegram bot that uses webhooks. I was able to set it up like this: convex/http.ts ```typescript import { httpRouter } from "convex/server";...

Help with search in join table

Hi, I've been looking for an answer for this with no success. I have 3 tables, users, workspaces and members. members is a join table, each member has a userId and a workspaceId. Every workspace has also an ownerId. I want to be able to search (text search withSearchIndex) workspaces where the user is a member of without being the owner. I'm using aggregate for performance reasons and i need pagination. Here is how we would write it in SQL code to be more clear. ```SELECT w.*...

How can we collaborate accross diffrent repos

I am currently developing a project that consists of two parts: Web Admin Panel - Used for managing and overseeing the system. React native App - The main application for end users. The issue I'm facing is related to maintaining a shared codebase for these two platforms. Whenever I work on the react native app, the web admin panel starts throwing errors due to changes I make for the react native features or configurations. Similarly, if I focus on the web admin panel, the Android app encounters compatibility issues....

Connect to multiple projects from the same nextjs app

Is this a matter of having the right imports for types and having multiple convex folders? I’m curious if anyone has tried this. Basically being able to call functions in different projects in different parts of the app. With the firestore sdk for instance you can define as many db objects as you want...

Auth not working properly in Nextjs

hey guys what could be the reason that convex auth is not working properly on my nextjs app? setup everything as on the tutorial but after login, i dont get redirected and even if i manually go to protected route, i still get redirected back to /login page, and isAuthenticated is always loggin false ``` import {...