> ## Documentation Index
> Fetch the complete documentation index at: https://docs.olanna.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Instagram

By the end of this, DMs people send to your Instagram will land in Olanna. Your agent will answer them.

Instagram is owned by Meta, the company behind Facebook. So most of this happens on Meta's website, not in Olanna. Here is the whole job:

1. Set up an account with Meta.
2. Copy four things from Meta into a note.
3. Paste those four things into Olanna.
4. Tell Meta to start sending your DMs to Olanna.

Set aside 20 to 30 minutes. Use a computer, not your phone, apart from the first step below.

<Note>
  Meta changes these pages now and then. A button might not be exactly where this guide says. Look for the words, not the place, and you will find it.
</Note>

### **Before you start**

Your Instagram has to be a Business or Creator account. A personal one will not work. If yours is still personal, switch it on your phone:

<Steps>
  <Step title="Open your Instagram profile">
    In the Instagram app on your phone.
  </Step>

  <Step title="Go to Account type and tools">
    Tap the menu, then **Settings and privacy**, then **Account type and tools**.
  </Step>

  <Step title="Switch to Business">
    Tap **Switch to professional account**, choose **Business**, and follow the prompts.
  </Step>
</Steps>

Your Instagram also has to be linked to a Facebook Page. Instagram usually offers this while you switch. If you skipped it, you can link one later under **Settings**, then **Linked accounts**.

You also need a Meta business account. Part 2 covers making one.

### **Part 1: Open a blank note**

You are about to collect four things from Meta. Keep them in one place so you do not lose any.

Open a blank note on your computer. Leave it open in its own window.

Type these four lines into it. Fill each one in as you reach it.

```text theme={null}
Instagram Business Account ID:
Page access token:
App secret:
Verify token:
```

### **Part 2: Set up your Meta business account**

Skip to Part 3 if you already have one. Meta calls it Meta Business Suite, or Business Manager. It is the same thing.

<Steps>
  <Step title="Open Meta's business site">
    Go to business.facebook.com.
  </Step>

  <Step title="Choose Create Account">
    The button is near the top of the page.
  </Step>

  <Step title="Type your name and email">
    Your business name, your own name, and your work email. Then choose **Submit**.
  </Step>

  <Step title="Add your business details">
    Fill in what Meta asks for.
  </Step>

  <Step title="Confirm your email">
    Open the email Meta sends you and click the link in it.
  </Step>
</Steps>

### **Part 3: Create a Meta app**

Meta will ask you to make something called an app. It is not an app anyone downloads. It is a box that holds your connection. Meta will not let Olanna handle your DMs without one. You make it once, then leave it alone.

If you already made one while connecting WhatsApp or Messenger for this business, use that one and skip to Part 4.

<Steps>
  <Step title="Go to Meta's developer site">
    Open developers.facebook.com and log in with the same account as Part 2.
  </Step>

  <Step title="Start a new app">
    Choose **My Apps**, then **Create App**.
  </Step>

  <Step title="Pick Business as the type">
    Meta asks what type of app this is. Choose **Business**.
  </Step>

  <Step title="Name it after your business">
    Something you will recognise in a year, like "Willow Spa Olanna".
  </Step>

  <Step title="Finish creating it">
    Link it to the business account from Part 2, then choose **Create App**.
  </Step>
</Steps>

### **Part 4: Add Instagram and link your Page**

<Steps>
  <Step title="Set up Instagram">
    On your app's dashboard, find **Instagram** in the list of products and choose **Set up**.

    <Frame caption="Instagram is one tile among many.">
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/olanna/images/instagram/01-add-product.png" alt="Meta's add products screen with Instagram in the list" />
    </Frame>
  </Step>

  <Step title="Link your Facebook Page">
    Follow the prompts to link the Page that is connected to your Instagram.
  </Step>

  <Step title="Check it is the right account">
    Meta shows you which Instagram account is tied to that Page. Make sure it is yours.
  </Step>
</Steps>

### **Part 5: Copy your Instagram Business Account ID**

An ID is a number Meta uses to tell one thing from another.

<Steps>
  <Step title="Open the Instagram setup page">
    Still inside your app on developers.facebook.com, choose **Instagram**, then **API setup with Instagram business login**. Meta sometimes calls this **Messenger API for Instagram**.
  </Step>

  <Step title="Find your account in the list">
    Next to it is a long number. That is your Instagram Business Account ID.

    <Frame caption="The ID sits beside your linked account.">
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/olanna/images/instagram/02-business-account-id.png" alt="The Instagram API setup page showing the Business Account ID" />
    </Frame>
  </Step>

  <Step title="Copy it into your note">
    That is one of your four lines done.
  </Step>
</Steps>

<Tip>
  Cannot find it there? Open developers.facebook.com/tools/explorer. Pick your app, choose your Page under "User or Page", and ask for the **instagram\_business\_account** field. The number appears in the result.
</Tip>

### **Part 6: Make your page access token**

An access token is a long password. It is what lets Olanna into your Instagram.

This part has the most steps of anything here. Go slowly.

<Steps>
  <Step title="Open System Users">
    Go to business.facebook.com. Choose **Settings**, then **Users**, then **System Users**.
  </Step>

  <Step title="Add a system user">
    Choose **Add**. Name it "Olanna Integration". Set the role to **Admin**. Choose **Create System User**. Skip this if you made one already.
  </Step>

  <Step title="Give it your Page">
    Choose **Add Assets**. Pick the Facebook Page linked to your Instagram. Give it **Full Control**.
  </Step>

  <Step title="Start a new token">
    Choose **Generate New Token**. Pick the app you made in Part 3.
  </Step>

  <Step title="Tick three permissions">
    You will see a list of permissions with tick boxes. Tick **instagram\_basic**, **instagram\_manage\_messages** and **pages\_messaging**. Leave the rest alone.
  </Step>

  <Step title="Generate it">
    Choose **Generate Token**. A long line of letters and numbers appears.

    <Frame caption="Three permissions ticked, the rest left alone.">
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/olanna/images/instagram/03-generate-token.png" alt="The system user token dialog with the three Instagram permissions ticked" />
    </Frame>
  </Step>

  <Step title="Copy it into your note">
    Do this before you close anything.

    <Warning>
      Meta shows this token once and never again. If you close the window without copying it, you will have to come back and make a new one. That is annoying, not serious.
    </Warning>
  </Step>
</Steps>

### **Part 7: Copy your app secret, then make up a verify token**

**App secret.** This is another password. It proves the app belongs to you.

<Steps>
  <Step title="Open your app">
    Go to developers.facebook.com and open the app you made.
  </Step>

  <Step title="Go to Settings, then Basic">
    Both are in the left menu.
  </Step>

  <Step title="Reveal the app secret">
    Find **App Secret** and choose **Show**. Meta might ask for your password.
  </Step>

  <Step title="Copy it into your note">
    That is three of your four lines done.
  </Step>
</Steps>

**Verify token.** You make this one up yourself. It is not copied from anywhere. Any word or phrase will do, like `willow-ig-2026`.

Write it into your note exactly as you typed it. You will type the same thing in two places later, and they have to match.

Your note should now have all four lines filled in.

### **Part 8: Paste it into Olanna**

<Steps>
  <Step title="Open Channels">
    In Olanna, choose **Channels** in the left menu.
  </Step>

  <Step title="Choose Connect on the Instagram row">
    A form opens with a box for each of your four things.
  </Step>

  <Step title="Copy your note into the boxes">
    Each line of your note goes in the box with the same name.

    <Frame caption="All four values from your note, in Olanna.">
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/olanna/images/instagram/04-olanna-connect-form.png" alt="Olanna's Instagram connect form filled in" />
    </Frame>
  </Step>

  <Step title="Choose Install">
    Olanna checks your token against your Instagram Business Account ID. It tries a few different ways behind the scenes, so you do not need to know which kind of token you made.
  </Step>
</Steps>

If everything matches, Instagram moves into your connected apps. If not, the message tells you which value is wrong. Troubleshooting is at the bottom of this page.

### **Part 9: Tell Meta where to send your DMs**

Meta now trusts Olanna. But it still does not know where to send your DMs. This part gives it the address.

That address is called a webhook URL. It is a long web address. You copy it out of Olanna and paste it into Meta. Nothing will arrive until you do.

<Steps>
  <Step title="Copy your webhook URL from Olanna">
    On the Channels page, open your Instagram row and copy the **Webhook URL**.
  </Step>

  <Step title="Open Configuration in Meta">
    Go to developers.facebook.com, open your app, then **Instagram**, then **Configuration**. On some layouts it sits under **Webhooks**, then **Instagram**.
  </Step>

  <Step title="Edit the webhook section">
    Choose **Edit** next to Webhooks.
  </Step>

  <Step title="Paste in the address">
    Put the Webhook URL into the **Callback URL** box.
  </Step>

  <Step title="Type your verify token">
    In the **Verify Token** box, type the phrase you made up in Part 7. It has to match what is in Olanna exactly. Same capital letters. No spaces at either end.

    <Frame caption="Callback URL from Olanna, verify token from your note.">
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/olanna/images/instagram/05-webhook-config.png" alt="The Instagram Configuration page with Callback URL and Verify Token fields" />
    </Frame>
  </Step>

  <Step title="Verify and save">
    Choose **Verify and Save**.
  </Step>

  <Step title="Switch on messages">
    Still on that page, find **Webhook fields** and switch on **messages**.
  </Step>
</Steps>

### **Part 10: Test it**

<Steps>
  <Step title="Use a different Instagram account">
    A personal test account is fine. It cannot be the account you just connected, because an account cannot DM itself.
  </Step>

  <Step title="Send a DM to your business account">
    Any short message will do.
  </Step>

  <Step title="Check your Olanna inbox">
    It should be there within a few seconds. If nothing arrives after a minute, see Troubleshooting.
  </Step>
</Steps>

You can close your note now. Or keep it somewhere safe, in case you ever need to connect again.

### **Questions**

<AccordionGroup>
  <Accordion title="Do I need a Facebook Page even though I only care about Instagram?">
    Yes. Meta requires every Business or Creator account to be linked to a Facebook Page for this kind of connection, even if you never post to that Page.
  </Accordion>

  <Accordion title="Can I use a personal Instagram account?">
    No. It has to be switched to Business or Creator first. That is in Before you start.
  </Accordion>

  <Accordion title="Can I reuse the Meta app I made for WhatsApp or Messenger?">
    Yes. One Meta app can hold WhatsApp, Messenger and Instagram together. You do not need a separate one for each. You can use separate apps if you would rather.
  </Accordion>

  <Accordion title="Do I need to keep the Meta app after this?">
    Yes. It is what keeps the connection alive. You do not have to open it again, but do not delete it.
  </Accordion>
</AccordionGroup>

### **Troubleshooting**

<AccordionGroup>
  <Accordion title="Access token is not valid on either graph.facebook.com or graph.instagram.com">
    Your page access token does not go with the Instagram Business Account ID you entered, or it has expired. Go back to Part 6 and make it again, checking you pick the right Page. Then update it in Olanna.
  </Accordion>

  <Accordion title="App Secret is incorrect for this app">
    The app secret has to come from the same Meta app your token was made for. Copy it again from Settings, then Basic, on that app.
  </Accordion>

  <Accordion title="Meta shows an error when I choose Verify and Save">
    The verify token you typed into Meta does not match the one saved in Olanna. A space on the end is the usual cause. Also check you finished Part 8 first, because Meta's check needs a live connection to work against.
  </Accordion>

  <Accordion title="DMs are not showing up even though everything says connected">
    Check that messages is switched on under Instagram, then Configuration, then Webhook fields. Also check you are not messaging from the same account you connected.
  </Accordion>

  <Accordion title="I lost my access token or app secret">
    Neither can be looked up once hidden. But you can make a new one from Part 6 or Part 7 and update it in Olanna. You will not lose your account or your messages.
  </Accordion>

  <Accordion title="Still stuck">
    Contact support. Tell us which part you are on, and the exact words of the error. A screenshot is best.
  </Accordion>
</AccordionGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.