Skip to content

Submit an NVWA batch

When to use this

You need Docmation to file a new Dutch NVWA RVDM (Registratie Vervoer Dierlijke Mest) document for the cross-border transport of animal manure into/out of the Netherlands. Each call appends one work item to the tenant's open NVWA batch; the NVWA bot (an internal SOAP cron job, not WebBot) submits the document to the NVWA SOAP interface when the batch runs.

Prerequisites

  • A valid JWT (see Authentication) issued for an API key with Role.ApiKey.
  • The shipment data ready: destination country/region, export date, sender and receiver KvK (Chamber of Commerce) numbers, planned load.
  • (Optional) A webhookUrl for the result callback — see Receive webhooks.

Walkthrough

1. POST the work item

POST /api/NvwaRvdm/AddWorkItemCreate

curl -X POST "https://api.docmation.eu/api/NvwaRvdm/AddWorkItemCreate" \
  -H "Authorization: Bearer <jwt>" \
  -H "Content-Type: application/json" \
  -d @body.json

body.json:

{
  "customerReference": "NVWA-2026-0001",
  "documentReference": null,
  "webhookUrl": "https://example.com/docmation/webhook/{0}"
}

Note — the NvwaRvdmWorkItemCreate request DTO currently only exposes the common BaseWorkItem fields (customerReference, documentReference, webhookUrl). The richer NvwaRvdmCreate payload — productName, destinationCountry, destinationRegion, exportDate, senderChamberOfCommerceNo, senderDomestic, receiverChamberOfCommerceNo, receiverDomestic, requestNo, plannedLoad, certificateLanguage, certificateType — is populated server-side from defaults and tenant configuration. Cross-check the live Swagger UI for the current API contract; this is the most likely place the documentation will lag behind the code.

Response (HTTP 200 OK):

{
  "workBatchId": 34567,
  "workItemId": 89012
}

2. (Optional) Wait for completion

There is no dedicated GetResult on NvwaRvdmController. Use the generic work-item endpoints instead:

curl "https://api.docmation.eu/api/WorkItem/GetById?workItemId=89012" \
  -H "Authorization: Bearer <jwt>"

Or by reference and task type:

curl "https://api.docmation.eu/api/WorkItem/GetByReference?reference=NVWA-2026-0001&taskType=NvwaRvdmCreate" \
  -H "Authorization: Bearer <jwt>"

See Poll work-item status for the response shape.

What to watch for

  • 401 Unauthorized — JWT expired or missing the Role.ApiKey claim. Re-authenticate via /api/Login/Authenticate.
  • No GetResult on this channel — unlike VLM MAD and Traces DOCOM, NvwaRvdmController does not expose a GetResult endpoint. Use /api/WorkItem/GetById or /api/WorkItem/GetByReference plus the webhook callback to track completion.
  • Background processing — the NVWA bot runs as a cron job every 3 minutes (Services/CronJobs/). Until it runs, status stays Queued/Created.
  • Duplicate submissions — like the other submit endpoints, there is no idempotency key. If a submit times out and you have no workItemId, look the work item up by customerReference via /api/WorkItem/GetByReference with taskType=NvwaRvdmCreate before resubmitting.

AI-drafted from NvwaRvdmController.cs. Verify field names against the live Swagger UI before publishing.