how to test api with curl command