-1

I have spent a long time searching the API docs and google for a solution and really haven't been able to find a solution that meets my needs. So my question is simple, what would be the most simple way for me to use cron + php to make a facebook post for a page?

Sahil Mittal
  • 20,697
  • 12
  • 65
  • 90
Nathan
  • 409
  • 4
  • 15

1 Answers1

1

Use Simple Feed API of fb with the access_token.

  1. If you are posting as the app, you'll be needing the access_token of the app (which never expires). You can get the token from here: AccessTokens

  2. If you to post on behalf of a user, you'll be needing the access_token of the user. The normal access token expires in 2 hours, and the extended token lasts for 2 months. Use the extended token for the cron job. Ref: How to extend access token validity since offline_access deprecation

Community
  • 1
  • 1
Sahil Mittal
  • 20,697
  • 12
  • 65
  • 90