hamid1882
hamid18822mo ago

Facing difficulty in setting up Convex on Multiple Projects

I have currenty connected Convex database on my Frontend Nextjs project, Now I have created a new nextjs project for Backend (Admin Dashboard) where we gonna use queries & mutations exhaustively. Can anyone help setup this for us?
5 Replies
Convex Bot
Convex Bot2mo ago
Thanks for posting in <#1088161997662724167>. Reminder: If you have a Convex Pro account, use the Convex Dashboard to file support tickets. - Provide context: What are you trying to achieve, what is the end-user interaction, what are you seeing? (full error message, command output, etc.) - Use search.convex.dev to search Docs, Stack, and Discord all at once. - Additionally, you can post your questions in the Convex Community's <#1228095053885476985> channel to receive a response from AI. - Avoid tagging staff unless specifically instructed. Thank you!
Jordan22
Jordan222mo ago
hi! have you checked out these docs? https://docs.convex.dev/production/multiple-repos
Multiple Repositories | Convex Developer Hub
Use Convex in multiple repositories
hamid1882
hamid1882OP2mo ago
Yes I did, but I need a centralized schema like a global state for handling queries, mutations and other activities in both the repositories without keep updating the backend files every time. also I am getting this error while running this command: npx convex-helpers ts-api-spec
Error retrieving function spec from your Convex deployment. Confirm that you
are running this command from within a Convex project.
Error retrieving function spec from your Convex deployment. Confirm that you
are running this command from within a Convex project.
Jordan22
Jordan222mo ago
has this command previously worked for you? is there any other output that you can provide? can you please explain what you mean by centralized schema? i want to understand what kind of interface you are trying to create
hamid1882
hamid1882OP2mo ago
I am really sorry @Jordan22 , I was on leave so couldn't able to reply to your message. I have actually fixed it by installing this version: convex-helpers": "^0.1.63" also, we've structured our codebase as monorepo using turbo repo so now we could use the same convex database on both web and for the admin dashboard.

Did you find this page helpful?