GraphQL API Quickstart
Use Aviator's GraphQL API to access pull request data.
1. Create a user access token
# IMPORTANT!
# Replace this value with the token you just created.
AV_API_TOKEN="av_uat_abcdefghijklmnopqrstuvwxyz"2. Make a simple GraphQL request
import os
import requests
query = """
{
viewer {
fullName
}
}
"""
av_api_token = os.environ["AV_API_TOKEN"]
res = requests.post(
"https://api.aviator.co/graphql",
json={"query": query},
headers={"Authorization": "Bearer "+av_api_token},
)
res.raise_for_status()
print(res.json())3. Fetch data about a pull request
Learn more
Last updated
Was this helpful?
