def buy(ctx, resource, **options):
"""Buy API calls with bitcoin.
\b
Usage
-----
Buy a bitcoin-payable resource.
$ 21 buy <resource>
\b
Get state, city, latitude, longitude, and estimated population for a given zip code.
$ 21 buy "https://mkt.21.co/21dotco/zip_code_data/zipdata/collect?zip_code=94109" --maxprice 2750
"""
buy_url = resource
if buy_url is None or buy_url is "":
logger.info(ctx.command.get_help(ctx))
sys.exit()
options['mock_requests'] = ctx.parent.params['mock_requests']
_buy(ctx.obj['config'], ctx.obj['client'], ctx.obj['machine_auth'], buy_url, **options)
评论列表
文章目录