# Mastodon & Fediverse Influencer & Content Intelligence (`straightforward_hydra/mastodon-fediverse-intelligence`) Actor

Discover influencers, enrich accounts, scrape posts & hashtags on Mastodon, Pleroma, Pixelfed and Firefish. No key.

- **URL**: https://apify.com/straightforward\_hydra/mastodon-fediverse-intelligence.md
- **Developed by:** [Dev D](https://apify.com/straightforward_hydra) (community)
- **Categories:** Social media, Automation, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 items

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Mastodon & Fediverse Influencer & Content Intelligence 🐘

**Discover niche influencers, enrich accounts, scrape posts & engagement, and pull hashtag content from the Fediverse — no API key, no proxy.**

Works on **any Mastodon-compatible instance** — so one actor covers **Mastodon, Pleroma, Pixelfed and Firefish**. Point it at an instance and:

- 🔥 **Discover niche influencers** — give it a **hashtag** (`#art`, `#opensource`, `#photography`) and get the accounts active in that niche, **ranked by followers**, each with an **engagement score**. (Federated — surfaces accounts from across many instances.)
- 👤 **Account enrichment** — handles → full profiles (followers, following, post count, bio).
- 📝 **Posts & engagement** — an account's posts with favourites/reblogs/replies.
- \#️⃣ **Hashtag content** — every recent post under a hashtag.

Perfect for **influencer marketing, community & brand monitoring, audience research, and social analytics** on the open social web.

> Uses the public **Mastodon REST API** — no key, no login, pure JSON. Very low maintenance.

***

### Compatible platforms

| Platform | How |
|---|---|
| **Mastodon** | Native. |
| **Pleroma** | Implements the Mastodon API. |
| **Pixelfed** | Implements the Mastodon API. |
| **Firefish** | Mastodon-compatible endpoints. |

Just set the `instance` (e.g. `mastodon.social`, `pixelfed.social`, `pleroma.envs.net`).

### Modes

- 🔥 **Discover** — hashtag (or name) → ranked accounts.
- 👤 **Accounts** — handles → enriched profiles.
- 📝 **Posts** — handles → posts + engagement.
- \#️⃣ **Hashtag** — hashtag → content stream.

***

### Input

| Field | Description |
|---|---|
| **Instance** | The instance domain to query. |
| **Mode** | discover / accounts / posts / hashtag. |
| **Hashtag** | Topic for discover/hashtag modes. |
| **Query** | Alternative name search (discover). |
| **Handles** | Accounts for accounts/posts modes. |
| **Include engagement** | Sample posts to compute avg favourites/reblogs + score. |
| **Max results** | discover: top accounts; posts/hashtag: max posts. |

#### Example — top #photography accounts, ranked

```json
{
  "instance": "mastodon.social",
  "mode": "discover",
  "hashtag": "photography",
  "includeEngagement": true,
  "maxResults": 100
}
```

#### Example — a Pixelfed account's posts

```json
{
  "instance": "pixelfed.social",
  "mode": "posts",
  "handles": ["dansup"],
  "maxResults": 100
}
```

### Output (discover)

```json
{
  "rank": 1,
  "acct": "LibreOfficeDE@social.tchncs.de",
  "display_name": "LibreOffice",
  "followers_count": 2650,
  "following_count": 12,
  "statuses_count": 1134,
  "bio": "The Document Foundation …",
  "matched": "#opensource",
  "avg_favourites": 9.5,
  "engagement_score": 13.5,
  "sampled_posts": 10,
  "url": "https://social.tchncs.de/@LibreOfficeDE"
}
```

Post text is decoded from HTML to plain text; posts mode adds favourites/reblogs/replies + URL.

### Run it on a schedule

Track a hashtag's leaderboard or a set of accounts over time — pipe to a sheet, database or webhook.

### Notes & limitations

- Uses **public, unauthenticated** endpoints — hashtag timelines, account lookup/statuses and account search. (The instance-wide public firehose is often login-gated; hashtag discovery covers the niche use case.)
- Coverage depends on the instance you query and how much of the Fediverse it federates with.
- Data source: the queried Mastodon-compatible instance.

***

#### Keywords

Mastodon, Fediverse, Pleroma, Pixelfed, Firefish, influencer marketing, social media, influencer discovery, hashtag, engagement, social analytics, audience research, brand monitoring, ActivityPub, decentralized social, Twitter alternative, profile scraper, posts scraper, social intelligence, open social web.

# Actor input Schema

## `instance` (type: `string`):

The Mastodon-compatible instance domain, e.g. "mastodon.social", "pixelfed.social", "pleroma.envs.net", "firefish.social". Works on Mastodon, Pleroma, Pixelfed and Firefish.

## `mode` (type: `string`):

discover = top accounts in a niche; accounts = enrich handles; posts = an account's posts; hashtag = posts under a hashtag.

## `hashtag` (type: `string`):

A hashtag/topic, e.g. "art", "photography", "opensource". In discover mode, accounts posting under it are ranked by followers.

## `query` (type: `string`):

Alternative to hashtag: search accounts by name/handle text.

## `handles` (type: `array`):

Account handles, e.g. \["Gargron", "someone@mastodon.social"]. The @ is optional; use user@instance for remote accounts.

## `includeEngagement` (type: `boolean`):

For discover/accounts: sample recent posts to compute avg favourites/reblogs/replies + an engagement score.

## `engagementSampleSize` (type: `integer`):

How many recent posts to sample for engagement.

## `maxResults` (type: `integer`):

discover: top accounts; posts/hashtag: max posts.

## Actor input object example

```json
{
  "instance": "mastodon.social",
  "mode": "discover",
  "hashtag": "art",
  "includeEngagement": false,
  "engagementSampleSize": 20,
  "maxResults": 100
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "hashtag": "art"
};

// Run the Actor and wait for it to finish
const run = await client.actor("straightforward_hydra/mastodon-fediverse-intelligence").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "hashtag": "art" }

# Run the Actor and wait for it to finish
run = client.actor("straightforward_hydra/mastodon-fediverse-intelligence").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "hashtag": "art"
}' |
apify call straightforward_hydra/mastodon-fediverse-intelligence --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=straightforward_hydra/mastodon-fediverse-intelligence",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/epGUJUI8nYbrZ2eOs/builds/oztwJ7KRIBHba1lhc/openapi.json
