# n8n Community Node

The Sportmonks Football API v3 is available as an open-source community node for [n8n](https://n8n.io/), the workflow automation platform. Built and maintained by [Arthur Rahimov](https://ragmon.nl/), the node lets you use Sportmonks data inside n8n workflows without writing any API integration code.

The package is published on [npm](https://www.npmjs.com/package/n8n-nodes-sportmonks) and the source is available on [GitHub](https://github.com/ragmon/n8n-nodes-sportmonks). It is built and signed on GitHub Actions with a public transparency log.

### What is n8n?

n8n is an open-source, node-based workflow automation platform. It lets you connect services, automate tasks, and build data pipelines using a visual canvas. It supports self-hosting and n8n Cloud, and has over 400 built-in integrations alongside a community node ecosystem of nearly 2,000 packages.

### Resources and operations

The node provides 28 actions across seven resources:

| Resource       | Operations                                                                                                          |
| -------------- | ------------------------------------------------------------------------------------------------------------------- |
| **Livescores** | Get Inplay, Get All Today, Get Latest Updated                                                                       |
| **Fixture**    | Get by ID, Get by Date, Get by Date Range, Get by Date Range for Team, Head to Head, Latest Updated, Search by Name |
| **Team**       | Get by ID, Get by Season, Get by Country, Search by Name                                                            |
| **Player**     | Get by ID, Get by Country, Search by Name                                                                           |
| **League**     | Get All, Get by ID, Get by Country, Get Live, Search by Name                                                        |
| **Standing**   | Get by Season ID, Get Live by League ID                                                                             |
| **Season**     | Get All, Get by ID, Get by Team, Search by Name                                                                     |

### Include selector

Most operations support the Sportmonks include system. The node exposes a full include selector so you can attach related data to any response without making extra API calls:

| Include                     | What it adds                                     |
| --------------------------- | ------------------------------------------------ |
| Participants (Teams)        | Both teams with home/away and winner metadata    |
| Scores                      | Goals per half and current total                 |
| Events (Goals, Cards, Subs) | Goals, cards, substitutions, VAR decisions       |
| Periods (Halves)            | Half timestamps and ticking status               |
| League + Country            | League name, image, and country details combined |
| Round                       | Round name and dates                             |
| Venue                       | Stadium information                              |
| Statistics                  | Match or season statistics                       |
| Lineups                     | Starting XI and bench                            |

### Pagination

Every list operation includes a built-in page parameter. Use it to step through large result sets without any additional workflow configuration.

### Error handling

The node surfaces user-friendly messages for the following error codes:

| Code  | Meaning                             | Hint                                     |
| ----- | ----------------------------------- | ---------------------------------------- |
| `401` | Invalid or missing API token        | Check your credentials                   |
| `403` | Endpoint not available on your plan | Upgrade or check coverage                |
| `429` | Rate limit reached                  | Slow polling or reduce request frequency |
| `500` | Server error                        | Retry or contact Sportmonks support      |

The node supports n8n's **Continue On Fail** mode. When enabled, errors are captured as node output rather than stopping the workflow, which is useful for bulk operations across many fixtures or teams.

### Installation

#### Via the n8n GUI (recommended)

1. Open your n8n instance.
2. Go to **Settings**, then **Community Nodes**, then **Install**.
3. Enter `n8n-nodes-sportmonks` and confirm.
4. Restart n8n when prompted.

#### Via npm (self-hosted CLI or Docker)

```bash
cd ~/.n8n/nodes
npm install n8n-nodes-sportmonks
# then restart n8n
```

#### Via Docker Dockerfile

```dockerfile
FROM n8nio/n8n
USER root
RUN cd /usr/local/lib/node_modules/n8n && npm install n8n-nodes-sportmonks
USER node
```

### Authentication

1. In n8n, go to **Settings**, then **Credentials**, then **New Credential**.
2. Search for **SportMonks API**.
3. Paste your API token from [my.sportmonks.com](https://my.sportmonks.com/api/tokens).
4. Save. The credential is available across all workflows in your instance.

### Plan requirements

| Feature                                      | Minimum plan     |
| -------------------------------------------- | ---------------- |
| Fixtures, Teams, Players, Leagues, Standings | Free             |
| Live scores (in-play)                        | Starter or above |
| Odds, predictions, xG                        | Add-on required  |

See the full [plans and pricing page](https://www.sportmonks.com/football-api/plans-pricing/) for details.

### Example workflows

The repository includes three importable workflow JSON files in the `workflows/` directory. To import: open your n8n instance, go to **Workflows**, select **Import from file**, and load the JSON.

| File                      | Description                                       | Plan required         |
| ------------------------- | ------------------------------------------------- | --------------------- |
| `demo-league-season.json` | Leagues and seasons only — works on the free plan | Free                  |
| `demo-all-features.json`  | All resources with sticky-note explanations       | Paid (for livescores) |
| `livescore-monitor.json`  | Polls in-play scores every 30 seconds             | Paid                  |

### Quick example

The simplest live workflow: **Trigger node, then SportMonks Football node** configured as Livescores, Get Inplay, with the `participants;scores` include. The node outputs one item per live fixture, each containing the raw Sportmonks API response for that match.

### Links

* **npm:** [npmjs.com/package/n8n-nodes-sportmonks](https://www.npmjs.com/package/n8n-nodes-sportmonks)
* **GitHub:** [github.com/ragmon/n8n-nodes-sportmonks](https://github.com/ragmon/n8n-nodes-sportmonks)
* **n8n community node installation guide:** [docs.n8n.io/integrations/community-nodes](https://docs.n8n.io/integrations/community-nodes/installation/)

### Notes

This is a community-maintained node and is not an official Sportmonks product. For issues or feature requests, open an issue on the [GitHub repository](https://github.com/ragmon/n8n-nodes-sportmonks). For questions about the Sportmonks Football API itself, refer to the [Football API documentation](https://docs.sportmonks.com/football) or contact [Sportmonks support](https://www.sportmonks.com/contact-support/).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sportmonks.com/v3/tutorials-and-guides/integrations/n8n-community-node.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
