R
Railway2mo ago
_mati

How to get data about all projects using Railway's API?

Hey! So, I'm automating some deployments on Railway, but I'm stuck trying to get all my account's projects. Despite of the lack of documentation, with most of the API calls, I basically replicated what's shown in the Network tab (I only changed the Authorization header and the URL path). But, with the "me" query, I'm unable to get the projects. I tried with the Postman collection you have, uncommenting the "projects" field, adding the fragment and so on, but still no luck. I know there's also a "projects" query in Postman, but I don't know what should do with the "edges" and "pageInfo" fields, since I couldn't find the query in the Network tab. Could I get your help, please?
Solution:
may i ask what is wrong with the dashboard query that the dashboard makes while on the dashboard?
Jump to solution
9 Replies
Percy
Percy2mo ago
Project ID: N/A
_mati
_mati2mo ago
N/A
Solution
Brody
Brody2mo ago
may i ask what is wrong with the dashboard query that the dashboard makes while on the dashboard?
_mati
_mati2mo ago
Also tried with the dashboard query (adapted to use graphql/v2 with my auth token, instead of the internal Railway's API that uses my cookies), but this is the response I'm getting:
{
"errors": [
{
"message": "Problem processing request",
"traceId": "325782497962424061"
}
]
}
{
"errors": [
{
"message": "Problem processing request",
"traceId": "325782497962424061"
}
]
}
I can send the body as well if needed
Brody
Brody2mo ago
fun fact, you can use the internal endpoint with your API token
_mati
_mati2mo ago
lol, problem solved may I ask why does it work with the internal endpoint, but not the "external" one?
Brody
Brody2mo ago
the public endpoint doesn't have a dashboard query, the error responses are just really bad is all, otherwise it would have told you it doesn't exist but the me query should do the same
_mati
_mati2mo ago
got it, so I'll use the internal endpoint - ty!
Brody
Brody2mo ago
sounds good!
Want results from more Discord servers?
Add your server