Giter VIP home page Giter VIP logo

facebook-marketing-api-example's Introduction

facebook-marketing-api-example

##Requirements: Webserver running PHP 5.x, e.g. Apache/XAMPP/MAMP; Composer

I was completely surprised that the documentation on the QuickStart didn't have any functional code examples.

So I created this repo to help other developers.

Check out the repo into a SSL'ed hosted domain directory. This will need to be a public facing IP, most likely. I never got far on my localhost.

Run composer install command to grab dependencies as per your environment setup.

Enter values for app_id, app_secret, URL, page_id in the conf.json file.

Make sure you have manage_pages permissions, and the URL is entered in your App if you want to grab leadgen_forms.

Point your browser at getAccessToken.php, authenticate, enjoy.

I didn't test this code yet, so feel free to point out any mistakes. Slapped it together pretty quickly from my actual work project.

Thanks!

Robert Baindourov

facebook-marketing-api-example's People

Contributors

robert-baindourov avatar rbaindourov avatar

Stargazers

 avatar Marianna Pessolano avatar Anton Shelyganov avatar Luan Haddad avatar Alexandre Pardo avatar

Watchers

James Cloos avatar Ysidro Almonte avatar

facebook-marketing-api-example's Issues

I would like to know if you can guide me with the following problems

Hello I would like to list the potential customers of a Facebook Lead Ads Lead form, and I think you have a great code but I would like to see if you can guide me.

when trying to try getAccessToken.php

I get the following:

Login not secure blocked: You can not get an access token or log in to this app from an insecure page. Try re-loading the page as https: //

Question 1 is it mandatory to use SSL?

Question 2 about the config

   "app_id": "ID of an APP related to my Business Manager?",
   "URL": "The URL of my domain?",
   "page_id": "Id of the page that has the forms to obtain the clients?"

Question 3 is there a way to get access to potential customers without requesting a section initiation? . It happens that I want to make a code that runs every day automatically and get potential customers.

Thank you in advance for your help.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.