Shared GraphQL queries for the Retcon platform
Project description
Retcon Queries
Shared GraphQL queries for the Retcon platform. Published as both npm (@retcon/queries) and PyPI (retcon-queries) packages.
Installation
TypeScript / JavaScript
npm install @retcon/queries
Python
pip install retcon-queries
Or for local development:
pip install -e ../retcon-queries
Usage
TypeScript
import { GET_FEEDS, GET_FEED_BY_URL } from '@retcon/queries';
// Use with any GraphQL client
const result = await client.query({
query: GET_FEEDS,
variables: { limit: 100 }
});
Python
from retcon_queries import GET_FEEDS, GET_FEED_BY_URL
# Use with any GraphQL client (httpx, gql, etc.)
response = await client.post(
graphql_url,
json={"query": GET_FEEDS, "variables": {"limit": 100}}
)
Available Queries
Registry Queries
| Query | Description | Variables |
|---|---|---|
GET_FEEDS |
Get all Feed-Registry entries | cursor, limit |
GET_FEED_BY_URL |
Get feed by canonical URL | feedUrl |
GET_FEEDS_BY_CATEGORY |
Filter feeds by category | category, cursor, limit |
GET_FEEDS_BY_CONTRIBUTOR |
Filter by contributor wallet | contributor, cursor, limit |
CHECK_FEED_EXISTS |
Check if feed URL exists | feedUrl |
Archive Queries
| Query | Description | Variables |
|---|---|---|
GET_ARTICLES |
Get all Article-Archive entries | cursor, limit |
GET_ARTICLES_BY_FEED |
Get articles from a feed | feedUrl, cursor, limit |
GET_ARTICLE_BY_URL |
Get article by URL | articleUrl |
GET_ARTICLE_BY_HASH |
Get article by content hash | contentHash |
Arweave GraphQL Endpoints
- Primary:
https://arweave-search.goldsky.com/graphql(Goldsky - optimized) - Fallback:
https://arweave.net/graphql(Official gateway)
Development
# TypeScript
npm install
npm run build
# Python
pip install -e ".[dev]"
pytest
Package Structure
retcon-queries/
├── package.json # npm package config
├── pyproject.toml # PyPI package config
├── tsconfig.json
├── src/ # TypeScript source
│ ├── index.ts
│ ├── registry.ts
│ └── archive.ts
├── python/ # Python source
│ └── retcon_queries/
│ ├── __init__.py
│ ├── registry.py
│ └── archive.py
└── graphql/ # Raw .graphql files (reference)
├── registry/
└── archive/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
retcon_queries-1.0.0.tar.gz
(3.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file retcon_queries-1.0.0.tar.gz.
File metadata
- Download URL: retcon_queries-1.0.0.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
88e545989acd866f4f8aebee0a5ca526096314c60df83de87d3ec52439ad89e4
|
|
| MD5 |
97e581ddec6d96e3412f877c0ca24410
|
|
| BLAKE2b-256 |
ad6a069a626801599083b19c5ae6f0a78da943bdd4893fd6227d61ac7be3716c
|
File details
Details for the file retcon_queries-1.0.0-py3-none-any.whl.
File metadata
- Download URL: retcon_queries-1.0.0-py3-none-any.whl
- Upload date:
- Size: 3.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
633a67aeeac702a3183f387d33ccb3e43925d0459e018169e44012c8ec81be6e
|
|
| MD5 |
dba0b0adafe3812352b2ae568c36d0ce
|
|
| BLAKE2b-256 |
d3a3faee6702c2eaa6035791290058144df92df50876c48eccb94ee293298b56
|