Skip to content

seethedoor/kongadm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

kongadm GitHub license Version

a kong management python client

USEAGE

install kongadm package

  • environment: python 2.7
  • install:
$ pip install git+https://github.com/seethedoor/kongadm.git

configurations

  • use kongadm.set_conf() to do this
  • kongadm_url(required) could be a string of your kongadmin API URL
  • apikey(optional) your api key to access kongadm
  • basicauth(optional) your basicauth infomation as a dict with 'username' and 'password'
  • use_session(optional) Bollean type value, default as 'True'
  • loglevel(optional) devfault as 'ERROR'
>>> import kongadm
>>> kongadm.set_conf(kongadm_url='your kongadmin API url')

kong node status

>>> kongadm.node.info
>>> kongadm.node.status

consumer

  • use kongadm.Consumer('your-username') to create a new consumer
  • use kongadm.Consumer.get('your-username') to get a exist consumer
>>> kongadm.Consumer.list_usernames()
>>> consumer = kongadm.Consumer('your-username')
# set groups property, etc..
>>> consumer.groups = ['group1', 'group2']

group

>>> 

api

Jwtcredential

token auth methods

About

a kong management python client

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages