{"repo":"octokit/graphql-action","free":true,"listed":false,"github":"https://github.com/octokit/graphql-action","clone":"git clone https://github.com/octokit/graphql-action.git","description":"A GitHub Action to send queries to GitHub's GraphQL API","language":"JavaScript","stars":138,"topics":["octokit-js","tooling","graphql","hacktoberfest"],"license":"MIT","category":"api-integrations-sdks","readme_excerpt":"Octokit Request Action A GitHub Action to send queries to GitHub's GraphQL API Usage Minimal example You can also use the variables parameter to pass variables. To access deep values of outputs.data , use fromJSON() . Debugging To see additional debug logs, create a secret with the name: ACTIONS STEP DEBUG and value true . How it works octokit/graphql-action is using @octokit/graphql internally with the addition that requests are automatically authenticated using the GITHUB TOKEN environment variable. It is required to prevent rate limiting, as all anonymous requests from the same origin count against the same low rate. The actions sets data output to the response data. Note that it is a string, you should use fromJSON() to access any value of the response. The action also sets headers (again, to a JSON string) and status . Preview Media Types New features of graphql require the use of an Accept header with a preview media-type. This is supported with a mediaType property, e.g. Troubleshooting Input variables It's important to remark input variables are converted to lowercase at runtime. This happens with GitHub Actions by design[^1]. Example In the following example, the variable itemId is casted to itemid so, when trying to use it in the query , the execution will fail because of a missing variable: itemId The recommendation[^1] is to use variables in lowercase to avoid this kind of problems: [^1]: https://docs.github.com/en/actions/creating-actions/metadata-syntax-for-gith","default_branch":null,"files":null,"tree":[],"storefront":"/r/octokit","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/octokit/graphql-action/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}