Update api.py
Merge pull request #3 from jschwalbe/patch-2

Update api.py