Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/juanbindez/ohmslawapi

ohms API
https://github.com/juanbindez/ohmslawapi

api ohms-law

Last synced: about 1 month ago
JSON representation

ohms API

Awesome Lists containing this project

README

        

# ohmslaw API

```python
import requests

SOURCE = 12
COMPONENT_VOLTS = 5.0

url = f'127.0.0.1:5000/api/v1/f_resistor?source={SOURCE}&component_voltage={COMPONENT_VOLTS}'
response = requests.get(url)

if response.status_code == 200:
data = response.json()
print(data)
else:
print(f'Error: {response.status_code}')

```