記事を読む対象者 ・初めて外部APIを使う方 ・spring−boot初学者 を想定して書いています。 目的 各企業がマイクロサービスを作って、外部APIとして提供していることは多いかと思います。 その中で、外部APIを自分のサービスに取り込む時に、クライアントライブラリの使い方、Json形式のデータからJavaオブジェクトへのマッピング等の基本となる使い方を学んでおくことで、今後の業務に役立てたいと思っています。 成果物 GitHub Search APIを叩いて、リポジトリを言語別に検索し、リポジトリ名とユーザー名、リポジトリの概要を取得、表示する内容になっています。 環境 FW:spring-boot 2.2.5 テンプレートエンジン:thymeleaf 3.0.4 HTTPクライアントライブラリ:okhttp3 4.4.1 JsonからJavaオブジェクトの相互変換ライブラリ:gs