peppol_get_service_endpoint
Retrieve the AS4 endpoint for a Peppol participant's document type by resolving the SMP hostname via DNS and fetching service metadata. Handles redirects, indicating when a follow-up is required, to enable e-invoice routing.
Instructions
Fetch the AS4 endpoint for a Peppol participant's document type.
Resolves the SMP hostname via DNS, then fetches service metadata for
document_type_id. If the SMP returns a redirect, the result's
redirect_url is set and endpoint_url is None; callers must not
follow more than one redirect hop (SMP 1.4.0 §3.2).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| identifier | Yes | Peppol participant ID or adaptable national identifier. | |
| environment | No | "production" or "test". | production |
| document_type_id | No | Peppol document type identifier URN (default: BIS Billing 3.0 invoice). | urn:oasis:names:specification:ubl:schema:xsd:Invoice-2::Invoice##urn:cen.eu:en16931:2017#compliant#urn:fdc:peppol.eu:2017:poacc:billing:3.0::2.1 |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||