forked from jonny/DNSocial
posting to DNS
dnsocial | ||
.gitignore | ||
LICENSE | ||
poetry.lock | ||
pyproject.toml | ||
README.md |
DNSocial
DNSocial is a truly decentralized social media protocol that works by posting directly to DNS.
The protocol:
- Any domain or subdomain is a feed. Say
posts.example.com
- Posts for that feed are TXT records for sequential subdomains starting from 1. eg.
1.posts.example.com
,2.posts.example.com
- To subscribe to a feed, continuously poll for the next integer subdomain until a TXT record is received.
Usage
Get an API key and store it in plain text in a JSON file like
{
"key": "KEY",
"secret": "SECRET"
}
post using the dns_post
function:
dns_post -d posts.example.com -p "I am posting!"
Subscribe using the dns_subscribe
function:
dns_subscribe -d posts.example.com
API documentation
dns_post
usage: dns_post [-h] [-c CREDS] -d DOMAIN -p POST
Post to DNSocial
options:
-h, --help show this help message and exit
-c CREDS, --creds CREDS
Location of creds.json file (default is working directory)
-d DOMAIN, --domain DOMAIN
Domain to post to
-p POST, --post POST Your post!
dns_subscribe
usage: subscribe [-h] -d DOMAIN [-i INTERVAL]
Subscribe to a feed on DNS social
options:
-h, --help show this help message and exit
-d DOMAIN, --domain DOMAIN
Domain to post to
-i INTERVAL, --interval INTERVAL
Seconds between polling
Limitations
Yeah it only works with the GoDaddy API, you think i am going to make an arbitrary DNS updating library for a shitpost ya right be my guest.