Skip to content

joshkunz/nfsn.py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

nfsn.py

nfsn.py is an ultra simple NFSN API helper built on requests. nfsn.py is a requests custom authentication helper that implements the NFSN request signing protocol. Using it is really simple, just put nfsn.py in the same directory as your other python files.

Here's a small example:

import requests
from nfsn import NFSNAuth

# You can set the details globally
NFSNAuth.login = "your NFSN login"
NFSNAuth.api_key = "your NFSN api key"

session = requests.session(auth=NFSNAuth())

# or you can supply the details as constructor arguments
session = requests.session(auth=NFSNAuth("your NFSN login", "your NFSN api key"))

# Then just use requests as normal
session.post("https://api.nearlyfreespeech.net/dns/example.com/listRRs")

About

A requests authentication wrapper for the NFSN API

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages