# AI Manager Instagram DM Connector

> Instagram Direct Messages connector for [AI Manager](https://aimanager-app.pages.dev).

This package allows AI Manager to receive and reply to Instagram Direct Messages. Agents handle Instagram conversations from the unified dashboard alongside Telegram, WhatsApp, Messenger, and web widget channels.

## License & Attribution

**MIT License** — see [LICENSE](./LICENSE).

This software is derived from:
- [`@tiledesk/tiledesk-messenger-connector`](https://www.npmjs.com/package/@tiledesk/tiledesk-messenger-connector) (MIT) — base blueprint
- [`@tiledesk/tiledesk-telegram-connector`](https://github.com/Tiledesk/tiledesk-telegram-connector) (MIT) — architecture reference

All original Tiledesk packages are MIT licensed. This package retains the MIT license and copyright notice as required.

## Status

**Under development.** The repo is seeded from the Messenger connector with all references renamed. Remaining work per the [implementation plan](./docs/proposal.md):

1. Replace basic config form with Instagram OAuth flow
2. Adapt FacebookClient.js for Instagram Graph API
3. Wire up webhook handlers for Instagram DM payloads
4. Add Dashboard UI constants and badges
5. Register as AI Manager server pubmodule

See the full plan in [`docs/proposal.md`](./docs/proposal.md).

## Documentation

| Document | Description |
|----------|-------------|
| [`docs/proposal.md`](./docs/proposal.md) | Instagram connector implementation proposal |
| [`docs/design.md`](./docs/design.md) | Technical design decisions |
| [`docs/specs/`](./docs/specs/) | Requirements and scenarios |
| [`docs/tasks.md`](./docs/tasks.md) | Implementation tasks |
| [`docs/adding-new-channel-guide.md`](./docs/adding-new-channel-guide.md) | Universal guide for adding any channel to AI Manager |
| [`docs/connector-research-proposal.md`](./docs/connector-research-proposal.md) | Research findings on existing connectors |

## Quick Start

```bash
npm install
npm start
```

## Related

- [AI Manager](https://aimanager-app.pages.dev)
- [Tiledesk Telegram Connector](https://github.com/Tiledesk/tiledesk-telegram-connector) (MIT)
