2017-06-06 4 views
0

私はピンからAPIのデータを取得できますが、そのデータにはピンに記載されている記事のリンクは含まれていません。私は画像URL、Pinterestのピンのリンク、ビデオの場合はビデオURLのリンクを取得するだけです。 URL以外の記事リンクに関する情報があるセクションがあります。これはPinterestの意図的な省略ですか?バグですか?この最初の例でPinterest APIは記事のリンクメタデータを提供しません

は、以下、この記事へのピンリンク: http://www.bitrebels.com/geek/worlds-tallest-tunnel-slide/

[url] => https://www.pinterest.com/pin/601582462695976350/ 

[link] => https://www.pinterest.com/r/pin/601582462695976350/4880694774085992885/ce2911ec61615ec208fb683a2ba0b5f956f82935841fc5971ffcfbb87413fb6f         

[metadata] => [link] => Array 
(
[locale] => en 
[title] => Tallest Tunnel Slide In The World Is Not For The Faint Hearted 
[site_name] => Bit Rebels 
[description] => The Slide, found at ArcelorMittal Orbit in London, is the world's tallest tunnel slide and it will take you a whopping 40 seconds to reach the bottom! 
[favicon] => https://s-media-cache-ak0.pinimg.com/favicons/89e7e1209b5f9f9c74429abf7724bc4e3fea6b0de84bf72942765648.png?89a711f94fe87f5d1741cbaa8c2b5b94 
) 

とビデオのためには、私はこれを取得:

[attribution] => Array 
(
[title] => Null Stern Hotel (Landversion) â Bericht auf blick.ch 
[url] => http://www.youtube.com/watch?v=ITEg_7-JVv4 
[provider_icon_url] => https://s.pinimg.com/images/api/attrib/[email protected] 
[author_name] => sonderaufgaben2000 
[provider_favicon_url] => https://s.pinimg.com/images/api/attrib/youtube.png 
[author_url] => https://www.youtube.com/user/sonderaufgaben2000 
[provider_name] => youtube 
) 

答えて

0

私は答えを見つけました。

APIによって返されるPinオブジェクトには、使用可能なすべてのフィールドを示す 'fillable'配列が含まれています。

私はその後のリンクを含む 'original_link'フィールドがありますが、PinterestのAPIドキュメントのどこにも記載されていません。

'fillable'配列の13番目と最後の項目です。APIドキュメントのリリース後に追加された可能性があります。

関連する問題