誰でも正しい方向に向けることができますか、またはUnirestなしでAPIキーを使用してMashapeにリクエストを行う方法をデモンストレーションできますか?Mashape APIをVolleyまたはHttpURLConnectionで使用する
単にHttpURLConnectionクラスやOkHttpやVolleyのようなAndroid RESTライブラリを使用してJSONリクエストをMashape APIに作成したいと思っていますが、リクエストを構造化する方法や、Mashapeを使用せずにUnirestライブラリ。
HttpResponse<JsonNode> response = Unirest.get("https://wordsapiv1.p.mashape.com/words/incredible/definitions")
.header("X-Mashape-Key", "**********apikey************")
.header("Accept", "application/json")
.asJson();
イム痛みを設定するために、大きなCommonsWare自身が述べられているのでUnirestは、Androidのために避けるべきであるようにそれはそうなのでUnirestを避けるためにしよう:
は、これは、彼らがUnirest要求を作成することをお勧めする方法ですDoes anyone have an example of an android studio project that import Unirest via gradle?
私は実際には同じAPIを使用しようとすると、この問題の初心者と同じ状況にいます: Trying to fetch JSON with Android using Unirest