문제 설명
Facebook 오류 #100: 사진 URL이 제공된 경우 링크를 제공해야 합니다. (Facebook Error #100 : A link must be provided if a picture URL is given)
저는 몇 달 전에 2개의 Facebook 페이지에 자동으로 게시하는 페이지를 개발했습니다. 메시지만 게시할 수 있지만 링크 및/또는 사진을 추가할 수도 있습니다. 모든 것이 매력처럼 작동했고 내 최신 게시물은 11월 25일에 성공적이었습니다. 오늘은 사진만으로 뉴스를 게시하려고 하는데 다음과 같은 오류 100# 메시지를 받았습니다. "사진 URL이 다음과 같으면 링크를 제공해야 합니다. 주어진".
이 주제에 대한 설명이나 도움을 찾을 수 없습니다. Facebook이 사진 게시에 관한 규칙을 변경하는 것 같습니다.
기본적으로 여기에 오류 덤프가 있습니다.
6FacebookApiException Object
(
[result:protected] => Array
(
[error] => Array
(
[message] => (#100) A link must be provided if a picture URL is given.
[type] => OAuthException
[code] => 100
[fbtrace_id] => xxxxxxxxxxxx
)
)
[message:protected] => (#100) A link must be provided if a picture URL is given.
[string:Exception:private] =>
[code:protected] => 0
[file:protected] => /mypathtofacebook/base_facebook.php
[line:protected] => 1042
[trace:Exception:private] => Array
(
[0] => Array
(
[file] => /mypathtofacebook/base_facebook.php
[line] => 747
[function] => throwAPIException
[class] => BaseFacebook
[type] => ‑>
[args] => Array
(
[0] => Array
(
[error] => Array
(
[message] => (#100) A link must be provided if a picture URL is given.
[type] => OAuthException
[code] => 100
[fbtrace_id] => xxxxxxxxxxxxxxxxx
)
)
)
)
[1] => Array
(
[function] => _graph
[class] => BaseFacebook
[type] => ‑>
[args] => Array
(
[0] => /mypageid/feed
[1] => post
[2] => Array
(
[access_token] => myaccesstoken
[from] => myAPPid
[message] => blabla
[picture] => http://www......................jpg
[to] => mypageid
변경된 유일한 것은 내 FB 비밀번호를 변경해야 한다는 것입니다. 그래서 내 access_token이 더 이상 유효하지 않고 새 토큰을 생성했습니다. 동일한 프로세스를 사용하여 이 새로운 access_token을 얻었고 페이지에 게시할 수 있습니다. 하지만 다시 한 번, 글과 링크만 있고 더 이상 사진은 없습니다.
또 다른 정보: 11월 25일에 게시한 것과 동일한 사진을 다시 게시하려고 하는데 오류가 있습니다. 따라서 사진 URL이나 이미지 자체에 오류가 있는 것은 아닙니다.
미리 감사합니다
참조 솔루션
방법 1:
https://developers.facebook.com/docs/graph‑api/reference/v2.5/page/feed#publish
Posting a picture requires a link ‑ the picture is actually the "preview image associated with the link". You can also post to the /page‑id/photos
endpoint if you want to post a picture without a link.
방법 2:
I solved the problem for myself ‑ do not choose the entry from the menu; instead type {{product.url}} yourself.
방법 3:
This is not your fault, Facebook changed something regarding to the posts. This happened to me as well .. I was in the same situation as you were .. had a working script for months, and all of a sudden publishing posts without links didn't work anymore. I could not find any other solution than to post the picture with a link ...
SOLUTION: Until now, if no link was specified, Facebook would of used the actual image src as the link, so what you can do is add that specific link in your posting tool if no actual link is specified
방법 4:
I know this is old but in addition to the endpoint mentioned by the accepted answer /page‑id/photos
you need to set the source
with the fileToUpload method: https://developers.facebook.com/docs/php/FacebookFile/5.0.0
(by Pierrot、andyrandy、user18863987、Scobee、Uriahs Victor)