
Security News
Deno 2.4 Brings Back deno bundle, Improves Dependency Management and Observability
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
A Python asynchronous/IO GraphQL client based on aiohttp.
In addition to standard HTTP POST queries
and mutations
this client fully supports
the GraphQL multipart form requests spec for file uploads
and the graphql-ws subprotocol for WebSocket based subscriptions
.
pip install aiogqlc
Check the documentation for detailed and more advanced usage examples.
import asyncio
import aiohttp
from aiogqlc import GraphQLClient
ENDPOINT = "https://swapi-graphql.netlify.app/.netlify/functions/index"
document = """
query {
allFilms {
films {
title
}
}
}
"""
async def main():
async with aiohttp.ClientSession() as session:
client = GraphQLClient(ENDPOINT, session=session)
response = await client.execute(document)
print(await response.json())
if __name__ == "__main__":
asyncio.run(main())
import aiohttp
from aiogqlc import GraphQLClient
document = """
mutation ($userId: ID!) {
deleteUser (id: $userId) {
id
}
}
"""
variables = {
"userId": "42",
}
async def main():
async with aiohttp.ClientSession() as session:
client = GraphQLClient("https://example.com/graphql/", session=session)
response = await client.execute(document, variables=variables)
print(await response.json())
import aiohttp
from aiogqlc import GraphQLClient
document = """
mutation($file: Upload!) {
uploadFile(file: $file) {
size
}
}
"""
variables = {
"file": open("test.txt", "rb")
}
async def foo():
async with aiohttp.ClientSession() as session:
client = GraphQLClient("https://example.com/graphql/", session=session)
response = await client.execute(document, variables=variables)
print(await response.json())
import aiohttp
from aiogqlc import GraphQLClient
document = """
subscription($postId: ID!) {
likeAdded(postId: $postId)
}
"""
variables = {
"postId": "42"
}
async def main():
async with aiohttp.ClientSession() as session:
client = GraphQLClient("https://example.com/graphql/", session=session)
async with client.connect() as connection:
async for payload in connection.subscribe(document, variables=variables):
print(payload)
Read the documentation to learn more about queries, mutations, subscriptions, file uploads and even authentication.
FAQs
aiohttp based GraphQL client
We found that aiogqlc demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.