ngrok HTTP API client library
Project description
ngrok API client library for Python
This library wraps the ngrok HTTP API to make it easier to consume in Python.
Installation
This library is published on PyPi
pip install ngrok-api
Documentation
A quickstart guide and a full API reference are included in the ngrok python API documentation
Quickstart
Please consult the documentation for additional examples.
import ngrok
# construct the api client
ng = ngrok.Client("<API KEY>")
# list all online tunnels
for t in ng.tunnels():
print(t)
# create an ip policy the allows traffic from some subnets
policy = ng.ip_policies.create(action="allow")
for cidr in ["24.0.0.0/8", "12.0.0.0/8"]:
ng.ip_policy_rules.create(cidr=cidr, ip_policy_id=policy.id)
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
ngrok-api-0.1.3.tar.gz
(29.4 kB
view hashes)
Built Distribution
ngrok_api-0.1.3-py3-none-any.whl
(30.1 kB
view hashes)
Close
Hashes for ngrok_api-0.1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 13b6c06a9d85dc8c48ca88f2b39a1683293f9aa8ebaffd67ebeb7e362ba54346 |
|
MD5 | 0eaeae3761c7dfaa53cc9df20966d0c4 |
|
BLAKE2b-256 | 9cb790c245d65013663f13d7cd270d3e32d2cc550edf5595413db9e7e2f124a2 |