def get_402_info(self, url):
"""Get channel payment information about the resource."""
response = requests.get(url)
price = response.headers.get(ChannelRequests.HTTP_BITCOIN_PRICE)
channel_url = response.headers.get(ChannelRequests.HTTP_BITCOIN_PAYMENT_CHANNEL_SERVER)
return {ChannelRequests.HTTP_BITCOIN_PRICE: price,
ChannelRequests.HTTP_BITCOIN_PAYMENT_CHANNEL_SERVER: channel_url}
评论列表
文章目录