指定したユーザーのプロフィールバナーとして使用できるサイズバリエーションのマップを取得します。
このユーザーにプロフィールバナーがアップロードされていない場合、HTTP 404を返します。
プロフィール画像とプロフィールバナーで説明されているように、
user オブジェクトから取得できるprofile_banner_urlの文字列を手動で変更するやり方の代替手段として、このメソッドを使用することができます。
プロフィールバナーデータの各種サイズURLに使用できるのは PNG 形式です。
GET users/
|
https://api.twitter.com/1.1/users/profile_banner.json
Resource URL
|
Resource Information
Response formats
JSON
Requires authentication?
Yes (user context only)
Rate limited?
Yes
Requests / 15-min window (user auth)
180
|
このメソッドを実行する場合、user_id か screen_nameのどちらかは常に設定してください。
結果を取得するユーザーのID。ユーザーIDとスクリーンネームが同じ場合に、どちらを指定しているのか明確にするために使います。
サンプル値: 12345
結果を取得るユーザーのスクリーンネーム。スクリーンネームとユーザーIDが同じ場合に、どちらを指定しているのか明確にするために使います。
サンプル値: noradio
ParametersAlways specify either an
user_id
optional
The ID of the user for whom to return results. Helpful for disambiguating when a valid user ID is also a valid screen name. Example Values:
screen_name
optional
The screen name of the user for whom to return results. Helpful for disambiguating when a valid screen name is also a user ID. Example Values: |
ログインして登録アプリケーションの一覧を参照してください。
OAuth Signature GeneratorSign in to see a list of your registered applications. |
GET
https://api.twitter.com/1.1/users/profile_banner.json?screen_name=twitterapi
Example RequestGET
|
{
"sizes": {
"ipad": {
"h": 313,
"w": 626,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/ipad"
},
"ipad_retina": {
"h": 626,
"w": 1252,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/ipad_retina"
},
"web": {
"h": 260,
"w": 520,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/web"
},
"web_retina": {
"h": 520,
"w": 1040,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/web_retina"
},
"mobile": {
"h": 160,
"w": 320,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/mobile"
},
"mobile_retina": {
"h": 320,
"w": 640,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/mobile_retina"
},
"300x100": {
"h": 100,
"w": 300,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/300x100"
},
"600x200": {
"h": 200,
"w": 600,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/600x200"
},
"1500x500": {
"h": 500,
"w": 1500,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/1500x500"
}
}
}
Example Result
{
"sizes": {
"ipad": {
"h": 313,
"w": 626,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/ipad"
},
"ipad_retina": {
"h": 626,
"w": 1252,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/ipad_retina"
},
"web": {
"h": 260,
"w": 520,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/web"
},
"web_retina": {
"h": 520,
"w": 1040,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/web_retina"
},
"mobile": {
"h": 160,
"w": 320,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/mobile"
},
"mobile_retina": {
"h": 320,
"w": 640,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/mobile_retina"
},
"300x100": {
"h": 100,
"w": 300,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/300x100"
},
"600x200": {
"h": 200,
"w": 600,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/600x200"
},
"1500x500": {
"h": 500,
"w": 1500,
"url": "https://pbs.twimg.com/profile_banners/6253282/1347394302/1500x500"
}
}
}
|