fix: use correct Twenty CRM GraphQL endpoint (/graphql)

Twenty CRM exposes data queries at /graphql, not /api or /api/graphql.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Jeff Emmett 2026-03-04 21:30:06 -08:00
parent 2853e46037
commit ea99a83678
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ function getTokenForSpace(space: string): string {
async function twentyQuery(query: string, variables?: Record<string, unknown>, space?: string) {
const token = space ? getTokenForSpace(space) : TWENTY_DEFAULT_TOKEN;
if (!token) return null;
const res = await fetch(`${TWENTY_API_URL}/api/graphql`, {
const res = await fetch(`${TWENTY_API_URL}/graphql`, {
method: "POST",
headers: {
"Content-Type": "application/json",