Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Intro
- This wrapper has both asynchronous & synchronous support, this intro will cover the basic of both. Lucily for you the API for asynchronous (awaiting) & synchronous (blocking) is identical.
- Getting started
- Awaiting
- import proxycheck
- client = proxycheck.Awaiting(
- key=""
- )
- ip = client.ip("51.68.191.78")
- if await ip.proxy():
- print("Is proxy")
- risk_score = await ip.risk()
- latitude, longitude = await ip.geological()
- data = await ip.get()
- # A client should always be closed after being used!
- await client.close()
- Blocking
- import proxycheck
- client = proxycheck.Blocking(
- key=""
- )
- ip = client.ip("51.68.191.78")
- if ip.proxy():
- print("Is proxy")
- risk_score = ip.risk()
- latitude, longitude = ip.geological()
- data = ip.get()
Add Comment
Please, Sign In to add comment