Request jsonlist instead of superlist

This commit is contained in:
jpk 2019-10-03 10:34:38 +02:00
parent 3bda68b466
commit 60a1dc7bf9
1 changed files with 3 additions and 3 deletions

View File

@ -55,12 +55,12 @@ def serve(recursive, filename):
@cli.command() @cli.command()
@click.argument('host', default='127.0.0.1') @click.argument('host', default='127.0.0.1')
def superlist(host): def jsonlist(host):
"""Fetch superlist from HOST running SupberBeam. """Fetch jsonlist from HOST running SupberBeam.
HOST is the IP of the SuperBeam server. HOST is the IP of the SuperBeam server.
""" """
with requests.get(f'http://{host}:8080/superlist', with requests.get(f'http://{host}:8080/jsonlist',
headers={'User-Agent': 'sbeam'}) as response: headers={'User-Agent': 'sbeam'}) as response:
assert response.status_code == 200 assert response.status_code == 200
return response.text.split('\n') return response.text.split('\n')