/micropython-http-client

MicroPython HTTP Client

Primary LanguagePython

MicroPython HTTP Client

HTTP 1.0 client for MicroPython with a small subset of the API of Requests for Humans. Please note that it does not verify SSL certificates.

import http_client

r = http_client.get('http://httpbin.org/get')
r.raise_for_status()
print(r.status_code)
print(r.text)  # r.content for raw bytes

r = http_client.post('http://httpbin.org/post', json={'hello': 'world'})
print(r.json())