5 months ago
Hi,
I am trying to get an Account Token to work but whether I user curl or an HTTP call I am getting Not Authorized errors.
curl --request POST \
--url https://backboard.railway.com/graphql/v2 \
--header 'Authorization: Bearer ****' \
--header 'Content-Type: application/json' \
--data '{"query":"query { me { name email } }"}'
{"errors":[{"message":"Not Authorized","locations":[{"line":1,"column":9}],"path":["me"],"extensions":{"code":"INTERNAL_SERVER_ERROR"},"traceId":"6717193895679864282"}],"data":null}
Are there any further steps to troubleshoot this?
Thanks.
2 Replies
5 months ago
Hey there! We've found the following might help you get unblocked faster:
🧵 Can't use Railway Public API with Project Token (projectToken null / Not Authorized)
🧵 API Token "Not Authorized" Error for Public API and MCP Automation
🧵 Is it possible to use the Railway Public API to Trigger a "Run Now" cron job?
If you find the answer from one of these, please let us know by solving the thread!
5 months ago
Hey,
It looks like you are trying to run that query with a workspace-scoped token. For security reasons, a workspace token does not have the permissions to request data about the user.
Please try the same query with a token that is not scoped to any workspaces.
Best,
Brody
Status changed to Awaiting User Response Railway • 5 months ago
4 months ago
This thread has been marked as solved automatically due to a lack of recent activity. Please re-open this thread or create a new one if you require further assistance. Thank you!
Status changed to Solved Railway • 4 months ago