How to get environments id?
I'm trying to access this route to get the environment ID, but I'm not having success, could anyone help me?
Solution:Jump to solution
you will need 3 ids for this mutation, environment Id, project Id, and service Id.
all three ids can be easily obtained through the command pallet when you have your desired service open -
cmd / ctrl + k
-> Copy
- and you will see an option to copy the ids.
...11 Replies
Project ID:
67325cec-b292-4cb1-a88d-0ac1c6ac5b96
project ID 67325cec-b292-4cb1-a88d-0ac1c6ac5b96
id be happy to help but can you tell me your usecase first?
I will update the refresh token and access token in the railway env
So I needed to get the env id of the project I have
I'm sorry but I don't exactly know what that means, feels like I'm missing some context
Being objective, I wanted to update information in the variable environment through the API, right?
okay, can you share your usecase for that as well?
My use case is to update, but I didn't build it because I wanted to have access to this information I'm telling you. But what I can share and even show is the integration with the delivery API and I need to update the access token for this API in the railway project's env. And I started testing through insomnia, I didn't manage to create the complete use case because I'm validating if I can get this project ID environment variable for me to update.
okay gotcha, thanks for sharing that.
ill get back to you with instructions on how to update a variable for a given service!
OK
Solution
you will need 3 ids for this mutation, environment Id, project Id, and service Id.
all three ids can be easily obtained through the command pallet when you have your desired service open -
cmd / ctrl + k
-> Copy
- and you will see an option to copy the ids.
here is the graphql mutation -
and here are the variables needed to go along with that -
included is an example variable as to show the syntax needed.
let me know if you have any issues!