# Instagram API

> Instagram returns public profile details, recent posts, and reels as a workflow and API.

Get profile returns public profile details and counts from a username, @name, or profile link. List recent posts returns public posts and reels, newest first, from a username or profile link; max results is optional.

- Page: https://fous.com/tools/instagram
- Handle: `@instagram`
- Category: [Social](https://fous.com/tools/category/social)
- Source website: https://instagram.com
- Last verified: Oct 8, 2026

## Methods

### Get profile

Operation `get_profile`, version 1. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.

Get an Instagram account’s public profile, exact headline counts, bio link, and profile picture from its username or profile link. Business category is not shown on signed-out profiles; Instagram may require login for some profiles.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `username` | string | yes | `"https://www.instagram.com/nasa/"` | Instagram account name, @name, or profile link, such as natgeo. |

**Input schema**

```json
{
  "type": "object",
  "required": [
    "username"
  ],
  "properties": {
    "username": {
      "type": "string",
      "description": "Instagram account name, @name, or profile link, such as natgeo.",
      "examples": [
        "https://www.instagram.com/nasa/",
        "natgeo"
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {
      "username": "https://www.instagram.com/nasa/"
    },
    {
      "username": "natgeo"
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `bio` | string | `"Making the seemingly impossible, possible. ✨"` | Public profile biography. |
| `posts` | integer | `4936` | Number of posts. |
| `username` | string | `"nasa"` | Account username. |
| `followers` | integer | `104329278` | Number of followers. |
| `following` | integer | `89` | Number of followed accounts. |
| `full_name` | string | `"NASA"` | Account display name. |
| `is_private` | boolean | `false` | Whether the account is private. |
| `is_verified` | boolean | `true` | Whether the account is verified. |
| `profile_link` | string | `"https://www.instagram.com/nasa/"` | Instagram profile link. |
| `website_link` | string or null | `"https://www.nasa.gov"` | First website link listed on the profile. |
| `instagram_user_id` | string | `"528817151"` | Instagram account ID. |
| `profile_picture_link` | string or null | `"https://scontent-lga3-2.cdninstagram.com/v/t51.2885-19/29090066_159271188110124_1152068159029641216_n.jpg?stp=dst-jpg_s` | Profile picture link. |

**Example input**

```json
{
  "username": "https://www.instagram.com/nasa/"
}
```

**Example output**

```json
{
  "bio": "Making the seemingly impossible, possible. ✨",
  "posts": 4936,
  "username": "nasa",
  "followers": 104329278,
  "following": 89,
  "full_name": "NASA",
  "is_private": false,
  "is_verified": true,
  "profile_link": "https://www.instagram.com/nasa/",
  "website_link": "https://www.nasa.gov",
  "instagram_user_id": "528817151",
  "profile_picture_link": "https://scontent-lga3-2.cdninstagram.com/v/t51.2885-19/29090066_159271188110124_1152068159029641216_n.jpg?stp=dst-jpg_s150x150_tt6&_nc_cat=1&ccb=7-5&_nc_sid=f7ccc5&efg=eyJ2ZW5jb2RlX3RhZyI6InByb2ZpbGVf…"
}
```

### List recent posts

Operation `list_recent_posts`, version 1. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.

List the latest publicly embeddable posts and reels from an Instagram account, newest first. Instagram may show fewer than requested without login; unavailable view counts are null.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `username` | string | yes | `"natgeo"` | Instagram account name, @name, or profile link, for example natgeo. |
| `max_results` | integer | no | `3` | Most posts to return, for example 12. Instagram may publicly show fewer. |

**Input schema**

```json
{
  "type": "object",
  "required": [
    "username"
  ],
  "properties": {
    "username": {
      "type": "string",
      "description": "Instagram account name, @name, or profile link, for example natgeo.",
      "examples": [
        "natgeo",
        "@instagram",
        "https://www.instagram.com/natgeo/"
      ]
    },
    "max_results": {
      "type": "integer",
      "default": 12,
      "maximum": 50,
      "minimum": 1,
      "description": "Most posts to return, for example 12. Instagram may publicly show fewer.",
      "x-fous-developer": true,
      "examples": [
        3,
        2
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {
      "username": "natgeo"
    },
    {
      "username": "@instagram",
      "max_results": 3
    },
    {
      "username": "https://www.instagram.com/natgeo/",
      "max_results": 2
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `posts` | array |  | Recent public posts and reels, newest first. |
| `posts[].caption` | string or null | `"Take a few seconds to relax in the prairie grass 🌼\n\n#IncredibleAnimalJourneys is now streaming on @disneyplus"` |  |
| `posts[].post_url` | string | `"https://www.instagram.com/reel/Dd1rVy4Ae8b/"` |  |
| `posts[].image_url` | string or null |  |  |
| `posts[].is_pinned` | boolean | `false` |  |
| `posts[].post_type` | string | `"reel"` |  |
| `posts[].posted_at` | string | `"2026-09-28T17:04:13+00:00"` | Date and time posted, ISO 8601 with offset. |
| `posts[].shortcode` | string | `"Dd1rVy4Ae8b"` |  |
| `posts[].like_count` | integer or null | `21387` |  |
| `posts[].view_count` | integer or null | `72855` |  |
| `posts[].comment_count` | integer or null | `119` |  |

**Example input**

```json
{
  "username": "natgeo"
}
```

**Example output**

```json
{
  "posts": [
    {
      "caption": "Take a few seconds to relax in the prairie grass 🌼\n\n#IncredibleAnimalJourneys is now streaming on @disneyplus",
      "post_url": "https://www.instagram.com/reel/Dd1rVy4Ae8b/",
      "image_url": "https://scontent-sea5-1.cdninstagram.com/v/t51.82787-15/825325618_18702123289019133_8306510580496048755_n.jpg?stp=dst-jpg_e15_tt6&_nc_cat=1&ig_cache_key=Mzk5NjI5MDg1ODA5NjkxNDIwMw%3D%3D.3-ccb7-5&ccb=7…",
      "is_pinned": false,
      "post_type": "reel",
      "posted_at": "2026-09-28T17:04:13+00:00",
      "shortcode": "Dd1rVy4Ae8b",
      "like_count": 21387,
      "view_count": 72855,
      "comment_count": 119
    },
    {
      "caption": "National Geographic photographer Jasper Doest joined an annual scientific expedition of the Okavango Delta—learning from local experts’ connections to this living landscape and changing his outlook on…",
      "post_url": "https://www.instagram.com/p/Dd1e6WyCCLZ/",
      "image_url": "https://scontent-sea5-1.cdninstagram.com/v/t51.82787-15/827856154_18702081256019133_8840428697517582330_n.jpg?stp=dst-jpg_e15_tt6&_nc_cat=1&ig_cache_key=Mzk5NjIzNTQzMDk0MDM3OTU4OA%3D%3D.3-ccb7-5&ccb=7…",
      "is_pinned": false,
      "post_type": "carousel",
      "posted_at": "2026-09-28T15:14:59+00:00",
      "shortcode": "Dd1e6WyCCLZ",
      "like_count": 17543,
      "view_count": null,
      "comment_count": 73
    }
  ]
}
```

## Quick start

Replace `YOUR_API_KEY` with a Fous API key. To create one, open Developers at the bottom of Fous Studio, turn on Developer mode, then go to API keys (https://app.fous.com/keys). Change the values in `input` to run the same tool on new data.

```bash
curl 'https://api.fous.com/v1/query' \
  --fail-with-body --silent --show-error --max-time 180 \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "api": "@instagram",
  "visibility": "public",
  "operation": "get_profile",
  "version": 1,
  "input": {
    "username": "https://www.instagram.com/nasa/"
  },
  "response": {
    "format": "json"
  }
}'
```

```python
# Save as fous.py and run with python3 fous.py. No packages needed.
import json
import urllib.error
import urllib.request

api_key = "YOUR_API_KEY"

body = json.loads("{\n  \"api\": \"@instagram\",\n  \"visibility\": \"public\",\n  \"operation\": \"get_profile\",\n  \"version\": 1,\n  \"input\": {\n    \"username\": \"https://www.instagram.com/nasa/\"\n  },\n  \"response\": {\n    \"format\": \"json\"\n  }\n}")
request = urllib.request.Request(
    "https://api.fous.com/v1/query",
    data=json.dumps(body).encode("utf-8"),
    headers={
        "Authorization": f"Bearer {api_key}",
        "Content-Type": "application/json",
    },
    method="POST",
)
try:
    with urllib.request.urlopen(request, timeout=180) as response:
        result = json.load(response)
except urllib.error.HTTPError as error:
    raise RuntimeError(f"HTTP {error.code}: {error.read().decode('utf-8', errors='replace')}") from error
if result.get("success") is False:
    raise RuntimeError(result.get("error", {}).get("message", "Request failed"))
print(json.dumps(result["data"]["output"], indent=2))
```

```typescript
// Save as fous.mts and run with npx tsx fous.mts.
const apiKey = "YOUR_API_KEY";

const response = await fetch("https://api.fous.com/v1/query", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  signal: AbortSignal.timeout(180_000),
  body: JSON.stringify({
  "api": "@instagram",
  "visibility": "public",
  "operation": "get_profile",
  "version": 1,
  "input": {
    "username": "https://www.instagram.com/nasa/"
  },
  "response": {
    "format": "json"
  }
}),
});
type ApiResult = { success: boolean; data?: { output: unknown }; error?: { message: string } };
const result: ApiResult = await response.json();
if (!response.ok || result.success === false) {
  throw new Error(result.error?.message ?? `HTTP ${response.status}`);
}
if (!result.data) throw new Error("Missing API response data");
console.log(result.data.output);
```

## Use from an AI assistant

Connect this tool to Claude Code, Claude Desktop, Cursor, VS Code, Codex and any MCP client as its own MCP server. Each method is a typed tool whose arguments are the method’s input.

- Server URL: `https://api.fous.com/mcp/tools/instagram`
- Authorization: `Authorization: Bearer <Fous API key>`

**Tools**

- `get_profile`: Get profile. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.
- `list_recent_posts`: List recent posts. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.
- `fous_get_run`: the result of a run that was still going, by its `request_id`. Free.

Claude Code:

```bash
claude mcp add --scope user --transport http fous-instagram https://api.fous.com/mcp/tools/instagram --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"
```

To give the assistant every tool, connect `https://api.fous.com/mcp`: it finds one with `fous_search_tools` and runs it with `fous_run_tool`. Setup for other clients: https://fous.com/llms-full.txt.

## Use cases

- Review public account profiles and follower counts.
- Track recent public posts and reels from selected accounts.
- Collect captions, post links, and posting dates.
- Compare likes and comments across recent posts.
- Find public profile bios and listed website links.

## FAQ

### Can I run it with my own inputs?

Yes. Change the inputs in Studio and press Run, or send new inputs from your code, or ask a connected AI assistant.

### Can I call this Instagram tool as an API?

Yes. Send a POST request to /v1/query with your Fous API key and the inputs, and get JSON back.

### How much does it cost?

Each completed run costs 1 credit. Failed runs without a completed receipt are free; completed work can remain charged if delivery is interrupted. With pay as you go, a credit costs 1¢. Monthly plans cost less per credit.

### Do I need a Instagram account?

No. You only need a Fous account.

### How current is the data?

Fous gets the data from instagram.com when you run it. Some results are reused for up to 24 hours, and results that use your account or key are never reused. It was last verified on Oct 8, 2026.

### What is a public account’s follower count?

Get profile returns the account’s follower count when given a username, @name, or profile link.

### What are an account’s latest posts and reels?

List recent posts returns the latest publicly embeddable posts and reels, newest first.

### When was a recent post published?

List recent posts returns each post’s posting date and time when available.

## Related

- [Threads API](https://fous.com/tools/threads.md): Threads provides public profiles and posts, including recent posts, engagement and replies; private or login-only content is excluded, and replies may be limited to 10.
- [Mastodon API](https://fous.com/tools/mastodon.md): Mastodon provides public profiles and recent public posts, including hashtag posts, but excludes private and unlisted posts and may limit visibility to accounts known to mastodon.social or a selected server.
- [Bluesky API](https://fous.com/tools/bluesky.md): Bluesky provides public profile details and latest posts, plus searches of up to 100 matching public posts; search results may lag behind new posts.
- [Social Blade API](https://fous.com/tools/social-blade.md): Social Blade provides public creator totals and grades, YouTube 30-day growth and 14-day history, TikTok 30-day changes and up to 14-day history, and Instagram totals without public daily history or 30-day follower change.
- [TikTok API](https://fous.com/tools/tiktok.md): TikTok returns public profiles and totals, recent pinned-first videos, and public video details and engagement; private content unavailable, and feeds may be incomplete or empty.
- [Pinterest API](https://fous.com/tools/pinterest.md): Pinterest helps people discover and save visual ideas, returning public search results from the first page and visible profile boards, with monthly views only when shown.
- [X API](https://fous.com/tools/x.md): X returns public profile details and public posts with author, media, and engagement; deleted, protected, or unavailable posts cannot be retrieved.
- [Telegram API](https://fous.com/tools/telegram.md): Telegram provides public channel details and the latest posts visible in public previews, with media and view totals that may be rounded or approximate.
- [All Social tools](https://fous.com/tools/category/social)
