Skip to main content

Common Errors

Purpose: Decode the most common mistakes quickly.
Use this when: You hit an SDK error and want the short answer.
Do not use this when: You need a full OAuth2 tutorial.
Backend required: Depends on the error.
Allowed runtimes: Server and public runtimes.
Required credentials: Depends on the error.
Minimal import: Depends on the error.

Error or symptomWhat it meansFix
client_secret is server-onlyYou passed a secret into the public clientUse @quranjs/api/server
This API requires @quranjs/api/serverYou tried to call Content or Search from publicMove the call to the backend
This OAuth2 exchange requires a backendYour client is confidentialExchange the code on the backend
This operation requires a user sessionYou called a user API with no access tokenSign in first or inject a session
401 UnauthorizedToken is missing, expired, or wrong for that APICheck token type, scopes, and environment
QuranReflect create post sends a raw string bodyOlder generated calls used the operation wrapper and { body: "..." } was the HTTP bodyUse the typed helper payload or { body: { post: ... } }; see QuranReflect Posts