REST API
REST API
NomaUBL embeds an HTTP server (WebServer) that exposes a REST API consumed by the React frontend. All endpoints are under the path /api/.
Base URL
Common response format
Most endpoints return a JSON object with at minimum a success boolean:
Invoice ID format
Endpoints that target a specific invoice use a compound identifier encoded as {doc}-{dct}-{kco} and passed URL-encoded. Example: document 123456, type RI, company 001 → 123456-RI-001.
Configuration
List all templates
Returns all templates (system + document) loaded from the configuration files.
Response:
Get a specific template
| Parameter | Description |
|---|---|
name |
Template name (URL-encoded) |
Response: the template object with all its properties.
Create a template
Body:
Update a template
Replaces all properties of the named template. System templates (global, e-invoicing, e-directory) can be updated but not renamed or deleted.
Body: same structure as create.
Delete a template
Deletes a document template. System templates cannot be deleted.
Copy a template
Duplicates an existing template under a new name.
Body:
Processing
Run invoice processing
Triggers the invoice processing pipeline (equivalent to the -run CLI mode).
Body:
| Field | Type | Description |
|---|---|---|
template |
string | Document template name |
file |
string | Absolute path to the JDE XML input file |
mode |
string | Processing type: SINGLE, BURST, UBL, BOTH, UBL_VALIDATE |
jobNumber |
string | JDE job number for tracking |
replaceMode |
boolean | true to overwrite an existing invoice record |
Response:
Validate UBL
Validates a UBL XML file (XSD + EN16931 + CIUS-FR) without processing it through the full pipeline.
Body:
| Field | Type | Description |
|---|---|---|
file |
string | Path to the XML file to validate |
sourceType |
xml | ubl |
xml = JDE source (transform first), ubl = already a UBL document |
template |
string | Template to use for XSLT transform (required if sourceType=xml) |
Response: same structure as /api/run with validation errors in the logs.
Poll PA import status
Polls the PA for all invoices in status 9906 (Pending). Updates the Oracle tables based on the PA responses.
Response:
Retrieve PA lifecycle statuses
Fetches the latest lifecycle events from the PA for all active invoices and updates F564231 / F564235.
Response: same structure as /api/import.
Invoices
List invoices
Returns paginated invoices from F564231 / F564230.
Query parameters:
| Parameter | Type | Default | Description |
|---|---|---|---|
page |
integer | 1 |
Page number |
pageSize |
integer | 50 |
Records per page |
search |
string | — | Full-text search (UBL number, customer name) |
status |
string | — | Filter by status code (e.g. 9906, 10) |
ublNumber |
string | — | Filter by UBL invoice number (K74FLEN) |
customer |
string | — | Filter by customer name or number |
sortBy |
string | — | Sort column |
sortDir |
asc | desc |
— | Sort direction |
dateFrom |
string | — | Start date filter (ISO: yyyy-MM-dd) |
dateTo |
string | — | End date filter (ISO: yyyy-MM-dd) |
Response:
Invoice statistics
Returns invoice counts grouped by status, for dashboard charts.
Query parameters:
| Parameter | Type | Description |
|---|---|---|
dateFrom |
string | Start date filter (ISO) |
dateTo |
string | End date filter (ISO) |
Response:
Get invoice lines
Returns the detail lines for an invoice from F564233.
Response:
Get invoice VAT summary
Returns the VAT subtotals from F564234.
Response:
Get invoice lifecycle
Returns all lifecycle events from F564235.
Response:
Get invoice validation errors
Returns validation errors from F564236.
Response:
Resend invoice to PA
Re-submits an invoice to the PA. Used when a send has failed (9904) or to force re-submission.
Response:
Update invoice status
Manually sets the invoice status. Supports two targets:
Update DB status directly:
Send status event to PA:
JDE / BIP Extraction
Extract from JDE BIP
Extracts XML or PDF data stored in JDE BIP (BI Publisher) BLOB fields.
Body:
| Field | Type | Values | Description |
|---|---|---|---|
mode |
string | XML, PDF |
Type of output to extract |
report |
string | — | JDE report name |
version |
string | — | Report version |
language |
string | — | Report language |
jobNumber |
string | — | JDE job number |
outputDir |
string | — | Output directory path |
Extract XML from DB
Extracts UBL XML stored in F564231.TXFT for a specific invoice.
Body:
Download XML from server
Downloads an XML spool file from the JDE server via SFTP (uses the SCP settings from the global template).
Body:
File System
Browse directory
Returns the contents of a local directory.
Query parameters:
| Parameter | Description |
|---|---|
path |
Directory path (URL-encoded). Omit for the configured root. |
Response:
Read file
Returns the text content of a file (used by the XSL Editor and XML Viewer).
Response:
Write file
Writes text content to a file (used by the XSL Editor to save changes).
Body:
Copy file
Copies a file to a new location.
Body:
Upload file
Uploads a file (e.g. JDE XML spool) to the configured input directory for the given template.
Query parameters:
| Parameter | Description |
|---|---|
template |
Document template name (determines the target directory) |
filename |
File name to save as |
Response:
Integration Errors
List integration errors
Returns validation errors from F564236 across all invoices, paginated.
Query parameters:
| Parameter | Type | Default | Description |
|---|---|---|---|
page |
integer | 1 |
Page number |
pageSize |
integer | 50 |
Records per page |
search |
string | — | Search by document number, rule, or message |
level |
string | — | Filter by severity: FATAL, ERROR, WARNING, INFO |
sortBy |
string | — | Sort column |
sortDir |
asc | desc |
— | Sort direction |
Response:
Directory
Check PPF directory
Looks up a company identifier in the PPF (Portail Public de Facturation) directory via the e-directory template credentials.
Body (one of):
Response:
INSEE company search
Searches the French company registry (INSEE Sirene API) for company information.
Body:
Response:
XSL
Install XSL templates
Copies bundled XSL base templates from the JAR to a target directory, for use as a starting point for new stylesheets.
Body:
Response:
SQL Queries
Get saved queries
Returns the list of saved SQL queries used in the web interface (configurable custom queries for reporting/debugging).
Response:
Update saved queries
Saves or updates the set of custom SQL queries.
Body:
Connectors
The connector system allows calling arbitrary external REST APIs configured in a template, without writing code.
List connector endpoints
Returns the API endpoints defined in the connector template.
Response:
Execute a connector endpoint
Calls the specified endpoint with the provided parameter values.
Body:
Response:
Send email
Sends an email notification, optionally attaching a reference to an invoice.
Body:
AI Assistant
AI chat (streaming)
Sends a chat message to the AI assistant. Returns a Server-Sent Events (SSE) stream of tokens for real-time display.
Body:
Response: text/event-stream — each SSE event contains a token chunk: