This repository contains a Python Flask application that utilizes the Facebook Graph API to generate access tokens. The access tokens are required to make authenticated requests to the Facebook Graph API and access various features and data on the Facebook platform.
To run this application, you need to have the following installed:
Python (version 3.6 or higher)
Flask (version 2.0.1 or higher)
Requests (version 2.26.0 or higher)
Virtualenv (version 20.14.1 or higher)
You also need to have a Facebook Developer account and an app created on the Facebook Developer platform. You will need the app ID, app secret, and other necessary credentials to authenticate and generate access tokens.
-
Clone this repository to your local machine or download the ZIP file.
-
Create a virtual environment by running the following command in your terminal or command prompt:
virtualenv env
- Activate the virtual environment by running the following command in your terminal or command prompt:
./env/Scripts/Activate
- Install the required dependencies by running the following command in your terminal or command prompt:
pip install -r requirements.txt
- Open the
config.py
file and replace the placeholders with your Facebook app credentials:
app_id = 'YOUR_APP_ID'
app_secret = 'YOUR_APP_SECRET'
Note: If you want to generate "Page Access Token" give your page id in:
page_id = 'YOUR_PAGE_ID'
- Save the changes and run the Flask application by executing the following command:
python app.py
-
Open your web browser and navigate to http://localhost:8888. You should see the access token generator interface.
-
Enter click on the "Access Token" button. Follow the authentication flow, and upon successful authentication, you will receive an access token.
Just Run the following command in your terminal or command prompt and everything will be installed.
python install.py
Contributions to this project are welcome! If you find any issues or want to add new features, feel free to open a pull request or submit an issue.
This project is licensed under the MIT License
. Feel free to modify and use it for your own purposes.
Repository Link: https://github.com/Tonmoy-abc/facebook-manual-login.git