P5010 - Can't figure it out
Hello - I'm trying to implement Accelerate but I'm getting a P5010 and cannot figure out what it is. I enlisted chatGPT's help before coming here and still no luck š
I've checked the DATABASE_URL 8000 times, including generating like 4 URLs just to see (didn't know with the AWS outage yesterday). I am using a Heroku postgres DB but I don't think that matters yet because I think the issue lies in the connection between the interface and Prisma because Prisma isn't logging anything.
If you're able to pull requests, I have a request ID (992162f33b9f05a1) - I can generate more if need be.
This is the error I get when trying to invoke a call from my local machine:
Environment variables loaded from .env
Prisma schema loaded from prisma/schema.prisma
ā Generated Prisma Client (v6.17.1, engine=none) to ./node_modules/@prisma/client in 111ms
Start by importing your Prisma Client (See: https://pris.ly/d/importing-client)
Tip: Need your database queries to be 1000x faster? Accelerate offers you that and more: https://pris.ly/tip-2-accelerate
terminal % node scripts/test-prisma.mjs "auth0|68e82bcb4a872d06060c3f7f"
[TestPrisma] Using DATABASE_URL: prisma://accelerate.prisma-data.net/
[TestPrisma] Accelerate enabled: true
[TestPrisma] Looking for account {
provider: 'auth0',
providerAccountId: 'auth0|[userid]'
}
prisma:error
Invalid prisma.account.findUnique() invocation:
Cannot fetch data from service:
Unable to connect to the Accelerate API. This may be due to a network or DNS issue. Please check your connection and the Accelerate connection string. For details, visit https://www.prisma.io/docs/accelerate/troubleshoot.
[TestPrisma] Query failed: PrismaClientKnownRequestError:
Invalid prisma.account.findUnique() invocation:
Cannot fetch data from service:
Unable to connect to the Accelerate API. This may be due to a network or DNS issue. Please check your connection and the Accelerate connection string. For details, visit https://www.prisma.io/docs/accelerate/troubleshoot.
at ei.handleRequestError (/Users/[user]/Desktop/[project]/node_modules/@prisma/client/runtime/library.js:121:7268)
at ei.handleAndLogRequestError (/Users/[user]/Desktop/[project]/node_modules/@prisma/client/runtime/library.js:121:6593)
at ei.request (/Users/[user]/Desktop/[project]/node_modules/@prisma/client/runtime/library.js:121:6300)
at async a (/Users/[user]/Desktop/[project]/node_modules/@prisma/client/runtime/library.js:130:9551)
at async main (file:///Users/[user]/Desktop/[project]/scripts/test-prisma.mjs:30:21) {
code: 'P5010',
meta: { modelName: 'Account' },
clientVersion: '6.17.1'
}2 Replies
You selected the carefully hand-crafted route. A dev artisan will respond soon. Meanwhile, the
#ask-ai channel awaits if you're curious!Oh yeah, I've also been exploring connection issue. Here are those details:
CONNECTED(00000005)
depth=2 C=US, O=Internet Security Research Group, CN=ISRG Root X1
verify return:1
depth=1 C=US, O=Let's Encrypt, CN=E8
verify return:1
depth=0 CN=prisma-data.net
verify return:1
---
Certificate chain
0 s:CN=prisma-data.net
i:C=US, O=Let's Encrypt, CN=E8
a:PKEY: EC, (prime256v1); sigalg: ecdsa-with-SHA384
v:NotBefore: Sep 19 01:57:03 2025 GMT; NotAfter: Dec 18 01:57:02 2025 GMT
1 s:C=US, O=Let's Encrypt, CN=E8
i:C=US, O=Internet Security Research Group, CN=ISRG Root X1
a:PKEY: EC, (secp384r1); sigalg: sha256WithRSAEncryption
v:NotBefore: Mar 13 00:00:00 2024 GMT; NotAfter: Mar 12 23:59:59 2027 GMT
---
Server certificate
-----BEGIN CERTIFICATE-----
GUID
-----END CERTIFICATE-----
subject=CN=prisma-data.net
issuer=C=US, O=Let's Encrypt, CN=E8
---
No client certificate CA names sent
Peer signing digest: SHA256
Peer signature type: ecdsa_secp256r1_sha256
Negotiated TLS1.3 group: X25519MLKEM768
---
SSL handshake has read 3456 bytes and written 1637 bytes
Verification: OK
---
New, TLSv1.3, Cipher is TLS_AES_256_GCM_SHA384
Protocol: TLSv1.3
Server public key is 256 bit
This TLS version forbids renegotiation.
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 0 (ok)
This is a standard curl with no api key:
'* Host accelerate.prisma-data.net:443 was resolved.
* IPv6: 2606:4700::6812:18e0, 2606:4700::6812:19e0
* IPv4: 104.18.25.224, 104.18.24.224
* Trying 104.18.25.224:443...
* Connected to accelerate.prisma-data.net (104.18.25.224) port 443
* ALPN: curl offers h2,http/1.1
* (304) (OUT), TLS handshake, Client hello (1):
* CAfile: /etc/ssl/cert.pem
* CApath: none
* (304) (IN), TLS handshake, Server hello (2):
* (304) (IN), TLS handshake, Unknown (8):
* (304) (IN), TLS handshake, Certificate (11):
* (304) (IN), TLS handshake, CERT verify (15):
* (304) (IN), TLS handshake, Finished (20):
* (304) (OUT), TLS handshake, Finished (20):
* SSL connection using TLSv1.3 / AEAD-CHACHA20-POLY1305-SHA256 / [blank] / UNDEF
* ALPN: server accepted h2
* Server certificate:
* subject: CN=prisma-data.net
* start date: Sep 19 01:57:03 2025 GMT
* expire date: Dec 18 01:57:02 2025 GMT
* subjectAltName: host "accelerate.prisma-data.net" matched cert's "accelerate.prisma-data.net"
* issuer: C=US; O=Let's Encrypt; CN=E8
* SSL certificate verify ok.
* using HTTP/2
* [HTTP/2] [1] OPENED stream for https://accelerate.prisma-data.net/
* [HTTP/2] [1] [:method: GET]
* [HTTP/2] [1] [:scheme: https]
* [HTTP/2] [1] [:authority: accelerate.prisma-data.net]
* [HTTP/2] [1] [:path: /]
* [HTTP/2] [1] [user-agent: curl/8.7.1]
* [HTTP/2] [1] [accept: /]
GET / HTTP/2 Host: accelerate.prisma-data.net User-Agent: curl/8.7.1 Accept: /* Request completely sent off < HTTP/2 400 < date: Tue, 21 Oct 2025 20:20:08 GMT < content-type: application/json < content-length: 105 < cf-ray: 9923742e9c240f96-ORD < prisma-error-code: P6002 < prisma-request-id: 9923742e9c240f96 < server: cloudflare < * Connection #0 to host accelerate.prisma-data.net left intact {"code":"P6002","message":"The provided API Key is invalid. Reason: No Authorization header is present."}' So - connecting just fine locally except when invoking the prisma.account.findUnique() lmao... I can't... I literally disabled and re-enabled accelerate and now it works... IT Crowd wins again