Facebook Graph API Call - Feed is not working [closed] - facebook-graph-api

Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 8 years ago.
Improve this question
I am trying to make a graph api call to post status update to a fan pages.
I am using http post here
my base url: https://graph.facebook.com/{page_id}/feed
message=hi&access_token={access_token}
I am however getting an error
{"error":{"message":"An unexpected error has occurred. Please retry your request later.","type":"OAuthException","code":2}}
Could you tell me if I am missing anything?
Things I checked:
Access token is valid
Page exisits

You need the extended permission manage_pages for your app (or through graph explorer) to be able to publish to the page feed. Once you have a new access_token with that permission, this should work:
curl \
-F "message=hi" \
"https://graph.facebook.com/<page_id>/feed"
Or whatever method you prefer.
Edit: You may also need the page access token, as described in the Publish page API

There was a genuine bug at Fb's end.

Related

Amazon CloudFront distribution is configured to block access from your country [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 1 year ago.
Improve this question
I keep getting this when I try to visit a website that I have previously visited many times before.
403 ERROR
The request could not be satisfied.
The Amazon CloudFront distribution is configured to block access from your country. We can't connect to the server for this app or website at this time. There might be too much traffic or a configuration error. Try again later, or contact the app or website owner.
If you provide content to customers through CloudFront, you can find steps to troubleshoot and help prevent this error by reviewing the CloudFront documentation.
Generated by cloudfront (CloudFront)
Request ID: db4AJqwG88H12zSDESOE7SIS8twSWZGScHR005VdWdEQ4RF8fx_ITA==
This might mean that the website is blocked on your country, your IP is blocked, or the website it's wrongly configured.
You can try contacting the site owner. 😉

Serverless | How to set Lambda authorizer to None (public API) [closed]

Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 1 year ago.
Improve this question
Please consider the following code (serverless.yml):
functions:
exportCvToPdf:
handler: handler.exportCvToPdf
timeout: 20
events:
- http:
path: export
method: post
Deploying to AWS returns a link to the API endpoint.
CURL'ing the endpoint returns:
{"message":"Missing Authentication Token"}
How can I make a public endpoint using Serverless Framework?
I have tried the following:
functions:
exportCvToPdf:
handler: handler.exportCvToPdf
timeout: 20
events:
- http:
path: export
method: post
authorizer: none # None NONE "none" "NONE" "None" has also been tried
The above returns an error at deploy:
Function none doesn't exist in this Service
You should be able to just omit authorizer and your endpoint will be publicly accessible right after deployment. Ensure that you're calling proper URL with proper path and method. Could you share how are you calling the deployed endpoint?

AWS + Cloudflare | https getting redirected to http [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 1 year ago.
Improve this question
I have just moved a MERN Stack app to AWS and I'm currently facing some problems with the certificates.
Current Scenario:
My website (example.com) has Cloudflare as the DNS Management.
I have added Cloudflare's Full SSL (end-to-end) encryption and a page rule for always redirect to https.
On the AWS Side, I have an Application Load Balancer (ALB) which is having a listener for HTTPS:443 using the certificate provided by AWS CA for example.com.
Problem:
When making a call to example.com, it redirects me to https://example.com and renders the static page which is fine.
When I change the page to https://example.com/articles the website goes berserk and changes it to http://example.com/articles and the certificate sign shows insecure now! Although, I do get my articles response from the server. Moreover, this is only happening in chrome and not firefox!
I would be more than happy to share any details/images required to support my query.
Thanks in advance!
Please share your page rules here. Your page rules are getting problem for you.
You can use the Always Use HTTPS function provided without wasting your page rules.

How set cookies on mongoose server? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
How can I set cookies with c++ on a mongoose web server?
I found something here https://www.cesanta.com/developer/mongoose#_mg_http_parse_header But i'm not sure if is what I'm looking.
You should send a Set-Cookie HTTP header to the client. There multiple ways of doing that with mongoose, for example using mg_send_head() , https://www.cesanta.com/developer/mongoose#_mg_send_head :
mg_send_head(conn, 200, content_len, "Set-Cookie: token=1234; Expires=Wed, 09 Jun 2021 10:18:14 GMT");
Set-Cookie header format is described in https://www.rfc-editor.org/rfc/rfc6265. Wikipedia also has a good article on it, https://en.wikipedia.org/wiki/HTTP_cookie

Server blacklisted from Facebook?

Yesterday we installed a new plugin on our site to allow our posts to be posted to our Facebook page automatically. Well early morning Monday's and some testing code was left in that made the call a couple of thousand times in about an hour. Over 24 hours later, Facebook still returns:
{"error":{"message":"(#1) An error occured while creating the share","type":"OAuthException","code":1}}
The post is going to {page_id}/feed and using the extended access_token, which doesn't expire for pages.
I know this is related to the IP of the server, as I can perform a post via curl on our other servers without and problems (just copy and pasting over the curl arguments). So I was wondering if anyone has experienced this before and if there is a policy to get your server removed from the blacklist, or is it just a wait it out type thing?
TIA!