Can I take repository from Github GraphQl Api by ID #22184
-
Hi, I want to take details about the repository by using repository ID. Thanks for help. |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 1 reply
-
Hi @hajczek, welcome to the community! Yes, you can absolutely do that, try the query below. Here’s an example using this repository: github.comAndreaGriffiths11/graphql-testa repository with test queries, to test queries. Contribute to AndreaGriffiths11/graphql-test development by creating an account on GitHub. The GitHub API exposes the //api.github.com/repos/AndreaGriffiths11/graphql-test In this case, the Using our GraphQL API Explorer, you can run this query to fetch that repository by its
I hope this helps! |
Beta Was this translation helpful? Give feedback.
-
Thank you so much for this query, is what I want but not exactly. I have the app where I want to search for details about the repository using the repository id, but dynamically declared. It means that I have this ‘id’ in some variable and I want to put this variable inside query, something like that:
with declared variable $id. But when I try to do this in Explorer, I have this message: "Variable $id is used by but not declared" How can I do this, maybe you know? Thanks for help. |
Beta Was this translation helpful? Give feedback.
-
Thanks for help again! I found the solution of my problem :slight_smile: Here is my query, which works well:
Have a nice evening!!! |
Beta Was this translation helpful? Give feedback.
-
Awesome 👏 thanks for coming back to share your solution. |
Beta Was this translation helpful? Give feedback.
Thanks for help again!
I found the solution of my problem :slight_smile:
Here is my query, which works well:
Have a nice evening!!!