<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>bouzuya</author_name>
  <author_url>https://blog.hatena.ne.jp/bouzuya/</author_url>
  <blog_title>bouzuya.hatenablog.com</blog_title>
  <blog_url>https://bouzuya.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>Retrofit で一部のメソッドだけに Authorization ヘッダーとトークンをつけるには……。以下のソースコードは Kotlin でコンパイルも通していない雰囲気だけのもの。 バージョンは↓。 Retrofit 2.6.x OkHttp 4.0.x ↓にある方法のひとつを紹介する。 https://stackoverflow.com/questions/41078866/retrofit-authorization-bearer-token まず単純な方法はメソッドの引数に @Headder(&quot;Authorization&quot;) token という引数を追加すること。 interfac…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fbouzuya.hatenablog.com%2Fentry%2F2019%2F08%2F29%2F230549&quot; title=&quot;Retrofit + OkHttp で Authorization ヘッダーを設定する - bouzuya.hatenablog.com&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2019-08-29 23:05:49</published>
  <title>Retrofit + OkHttp で Authorization ヘッダーを設定する</title>
  <type>rich</type>
  <url>https://bouzuya.hatenablog.com/entry/2019/08/29/230549</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
