# Peppol Participant Lookup (`downright_blessing/peppol-participant-lookup`) Actor

Resolve Peppol participant IDs against the official Peppol Directory search API. Returns found/not found, entity names, country, websites, document types and metadata as structured JSON — one Dataset row per lookup.

- **URL**: https://apify.com/downright\_blessing/peppol-participant-lookup.md
- **Developed by:** [Joao Pedro Rosado](https://apify.com/downright_blessing) (community)
- **Categories:** Business, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $5.00 / 1,000 participant lookups

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/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Peppol Participant Lookup

Resolve **Peppol participant IDs** against the official **Peppol Directory** JSON search API. Returns one Dataset row per lookup with found/not found, entity name(s), country, websites, registration date, document-type count and raw match metadata.

No API key. Public Peppol network directory used by e-invoicing and AR/AP automation teams.

**Directory UI:** [directory.peppol.eu](https://directory.peppol.eu/)\
**Endpoint used:** `GET https://directory.peppol.eu/search/1.0/json?participant=…`

***

### What it does

1. Accepts a list of participant IDs (`iso6523-actorid-upis::0192:991825827`, or bare `0192:991825827`).
2. Calls the official Peppol Directory search API for each ID (with optional throttle + retries).
3. Writes one Dataset row per lookup: `found`, entity fields, `docTypes`, `error`.

### Who it's for

- E-invoicing SaaS and ERP connector teams checking supplier reachability
- Fintech / tax-tech onboarding that needs Peppol network presence
- Agents and ETL jobs that need **official** Directory JSON (not scraped HTML)

### Input summary

| Field | Required | Description |
|---|---|---|
| `participants` | yes\* | List of Peppol IDs (scheme::value or ICD:value) |
| `maxItems` | no | Hard Dataset cap (default 50, max 5000) |
| `requestDelayMs` | no | Delay between Directory calls in ms (default 150) |

\*Provide at least one participant. Empty input yields a demo row in local mode.

### Output fields

One Dataset row per participant:

`participant`, `scheme`, `value`, `found`, `entityName`, `entityNames`, `countryCode`, `websites`, `regDate`, `entityCount`, `docTypeCount`, `docTypes`, `totalResultCount`, `entities`, `error`, `sourceUrl`, `directoryUi`, `scrapedAt`.

### Pricing

**Pay-per-event** suggested for the Store:

- **Actor start** (`apify-actor-start`): about **$0.03** / run
- **Dataset item** (`apify-default-dataset-item`): about **$0.005** / lookup

Use `maxItems` as the spend cap.

### Quick start (Apify Console)

```json
{
  "participants": [
    "iso6523-actorid-upis::0192:991825827",
    "iso6523-actorid-upis::0088:5790000435946"
  ],
  "maxItems": 50,
  "requestDelayMs": 150
}
```

#### Local smoke

```bash
npm run local
## or: APIFY_LOCAL=1 node src/main.js
```

Writes `storage/datasets/default/000000001.json` and `storage/key_value_stores/default/OUTPUT.json`.

### Legal / data source

Data comes from the official **Peppol Directory** public search API (`directory.peppol.eu`). This Actor is an independent tool — **not affiliated** with OpenPeppol AISBL. Results reflect Directory state at query time and are **not** a legal opinion on e-invoicing obligations. Respect fair-use request rates.

***

### Português (resumo)

Consulta se um participante **Peppol** está no diretório oficial (alcance e-invoice). Devolve encontrado/não encontrado, nome da entidade, país, sites e tipos de documento. Sem API key. Ideal para SaaS de e-fatura e onboarding AR/AP. **Pay-per-event** sugerido: ~US$0,03 por execução + ~US$0,005 por lookup. Fonte legal = Peppol Directory oficial.

# Actor input Schema

## `participants` (type: `array`):

List of Peppol participant identifiers. Accepts full form (iso6523-actorid-upis::0192:991825827), scheme::value (0192:991825827 with default scheme), or already-prefixed values.

## `maxItems` (type: `integer`):

Hard Dataset row cap (one row per participant lookup).

## `requestDelayMs` (type: `integer`):

Throttle between Directory API calls. Default 150.

## Actor input object example

```json
{
  "participants": [
    "iso6523-actorid-upis::0192:991825827",
    "iso6523-actorid-upis::0088:5790000435946"
  ],
  "maxItems": 50,
  "requestDelayMs": 150
}
```

# Actor output Schema

## `results` (type: `string`):

Default dataset items: found/not found, entities, doc types, metadata.

# 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 = {
    "participants": [
        "iso6523-actorid-upis::0192:991825827",
        "iso6523-actorid-upis::0088:5790000435946"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("downright_blessing/peppol-participant-lookup").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 = { "participants": [
        "iso6523-actorid-upis::0192:991825827",
        "iso6523-actorid-upis::0088:5790000435946",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("downright_blessing/peppol-participant-lookup").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "participants": [
    "iso6523-actorid-upis::0192:991825827",
    "iso6523-actorid-upis::0088:5790000435946"
  ]
}' |
apify call downright_blessing/peppol-participant-lookup --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,downright_blessing/peppol-participant-lookup"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

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