Skip to content

Commit 6705c0a

Browse files
authored
Merge pull request #9 from codebar-ag/feature-updated
Update Readme
2 parents f005c2d + 142d1d0 commit 6705c0a

File tree

1 file changed

+21
-12
lines changed

1 file changed

+21
-12
lines changed

README.md

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ This package is only designed to login with a single user account to display ins
1616
* [Navigation](#navigation)
1717
* [🛠 Requirements](#-requirements)
1818
* [Installation](#installation)
19+
* [Creating a new Instagram App](#creating-a-new-instagram-app)
20+
* [Overriding the default routes](#overriding-the-default-routes)
1921
* [Usage](#usage)
2022
* [Authentication](#authentication)
2123
* [Getting the connector](#getting-the-connector)
@@ -89,6 +91,25 @@ INSTAGRAM_CLIENT_ID=your-client-id
8991
INSTAGRAM_CLIENT_SECRET=your-client-secret
9092
```
9193

94+
## Creating a new Instagram App
95+
96+
To create a new Instagram App, you need to register your app on the [Facebook Developer Portal https://developers.facebook.com/apps/](https://developers.facebook.com/apps/)
97+
98+
When asked for a use case select `Other`
99+
When asked for an app type select `Business`
100+
101+
Once the app is created you need to add Instagram as a product to your app, you can do this by clicking on the `Add Product` button and selecting Instagram on the left side of the app dashboard.
102+
103+
Then goto `API setup with Instagram Login`, goto `Step 3.` and click `Business login settings`.
104+
105+
You will need to set the redirect uri to: `http://your-app-url.com/instagram/callback`
106+
107+
You should also set the Deauthorize callback URL to: `http://your-app-url.com/instagram/deauthorize`
108+
109+
You should also set the Deletion callback URL to: `http://your-app-url.com/instagram/delete`
110+
111+
> NOTE: The links above need to be publicly accessible so you can use tools like NGROK or Expose to expose your local development environment to the internet. When using the tools, ensure you set your `APP_URL` in your `.env` file to the url provided by the tool.
112+
92113
## Overriding the default routes
93114

94115
If you want to override the default routes, you can do so by creating a `instagram.php` file in your routes directory and adding the following code:
@@ -111,7 +132,6 @@ Then you should register the routes in your `bootstrap\app.php`:
111132
```php
112133
->withRouting(
113134
web: __DIR__ . '/../routes/web.php',
114-
// api: __DIR__ . '/../routes/api.php',
115135
then: function () {
116136
Route::middleware('web')->group(base_path('routes/instagram.php'));
117137
},
@@ -127,17 +147,6 @@ $this->routes(function () {
127147
});
128148
```
129149

130-
You can get your client id and client secret by registering your app on the [Instagram Developer Portal](https://developers.facebook.com/docs/instagram-platform/instagram-api-with-instagram-login)
131-
132-
When configuring your app on the Instagram Developer Portal, you will need to set the redirect uri to: `http://your-app-url.com/instagram/callback`
133-
134-
You should also set the Deauthorize callback URL to: `http://your-app-url.com/instagram/deauthorize`
135-
136-
You should also set the Deletion callback URL to: `http://your-app-url.com/instagram/delete`
137-
138-
The links above need to be publicly accessible. You can use tools like [Expose](https://expose.dev/) or [ngrok](https://ngrok.com/) to expose your local development environment to the internet.
139-
When using the tools above, ensure you set your `APP_URL` in your `.env` file to the url provided by the tool.
140-
141150
## Usage
142151

143152
### Authentication

0 commit comments

Comments
 (0)