Yes, you can actually do so with one of the customapis listed here: Useful Custom APIs
Specifically here is a command you can copy paste to do what you need:
!commands add !flip $(urlfetch https://api.rtainc.co/twitch/random?format=The%20coin%20landed%20on+[0]&choices=heads,tails)
running it will return:
The coin landed on [Result]