Maxus33 interview question

How do you do an api call? Code it up