Edit: Well no, it's only some sites. E. g. https://medium.com
Try using a backend language or just curl and it should be fine.
I found it: The API responds with an HTTP 500 error if you use CSS selectors that don't select anything or are simply invalid.
Probably makes sense to add some Exception handling right there.
Nonetheless, a great idea!
Edit: Just tried it in Node and it works brilliantly. Cool project.
Try using a backend language or just curl and it should be fine.