ZuloOne
English
Sign in
Menu

🔌 M.E.Doc at a customer

Updated

← The Ukrainian localization

How to connect a live M.E.Doc on a project, and why this is not Fatoora. Where to click in ZuloOne — the ЄРПН invoice. Why MakeDoc is not Cleared — for the developer.

What's not there yet#

There is no cloud sandbox for M.E.Doc. The FAQ has one address: a service on the accountant's machine, Swagger at http://localhost:63777/Swagger/index.html. There is no sandbox.medoc.ua in the operator's delivery — waiting for it the way KSA waits for gw-fatoora is pointless.

A licence that is "just M.E.Doc, we file to ДПС from this PC" is not enough. The REST API needs a networked M.E.Doc (client–server) and the licence Інтеграція з обліковими системами. Without those, Swagger will not open and the connection card will go nowhere.

Diia and the ДПС cabinet are not on this page — Diia.

What the customer must have#

  1. A networked M.E.Doc with REST. Check on the accountant's PC: the browser opens http://localhost:63777/Swagger/index.html (if the port is different, that is the port that goes on the card).
  2. An M.E.Doc user the REST logs in as (userLogin + password). That is not a КЕП and not a Bearer token.
  3. A КЕП already in M.E.Doc. ZuloOne neither sees it nor stores it. ToGov will sign with whatever is on the PC.
  4. A ZuloOne agent on that same PC. A server in the cloud or in docker will not see the accountant's 127.0.0.1: that is SSRF. Administration → Agents → download the installer → the service is online, its tag matches the TaxAuthorityConnection card.

The card in ZuloOne#

Tax → Settings → Authority connections (TaxAuthorityConnection), on the ПДВ-payer legal entity.

Field What to put Empty
Legal entity the one that issues invoices the envelope is created, it never joins the queue
Base URL http://127.0.0.1:63777 will not save / nowhere to dial
Agent tag the agent's tag on this PC, e.g. medoc the host refuses the loopback
Credential reference the M.E.Doc user name, e.g. buch the host will not log in
Environment a test / prod label, it does not change the URL the resolver simply passes no environment

The password lives only on the server: Integration__Credentials__buch. It goes neither on the card nor into git. A bank token does not go here — PrivatBank.

In Ukraine → Settings → Ukraine settings: the e-invoice tick, the ПН form code (J1201010 / F1201010), the RK form code. An empty form code means no envelopes.

How to prove it arrived without pushing to ДПС#

MakeDoc puts the document in the M.E.Doc journal. Only ToGov sends it to ДПС. ToGov is enqueued by the PullUaTaxInvoiceReceipts job when it takes a successful MakeDoc. The "Ask the operator" button does not call ToGov.

Example. An invoice for 1 200 ₴, ПДВ 200 ₴, a buyer with a real EDRPOU, the legal entity with a filled-in card.

  1. Disable the PullUaTaxInvoiceReceipts job (or do not let it tick).
  2. Post that invoice. Invented MakeDoc JSON will not land: the cells are the same as a live ПН (FIRM_NAME, TAB1_A13).
  3. Administrator → Outbound queue, channel erpn-send — Succeeded.
  4. On the TaxDocument envelope, ExternalId is a CardCode (a number like 3446267).
  5. In M.E.Doc on the accountant's PC, a draft with that CardCode is visible.

That is the boundary "our part is done". XML and the КЕП from here are M.E.Doc's job. The VAT book already has 200 ₴ (the first event). There is still no tax invoice in ЄРПН — and there will not be one until you turn the job back on.

When you turn the job on, that same envelope goes to ToGov, M.E.Doc signs it with the КЕП on the PC and sends it to ДПС. Do not leave the job enabled for a smoke check.

What breaks if you wait for a sandbox#

Until there is an agent and REST on the PC, the queue will be Failed / SSRF, not "we are waiting for a URL from M.E.Doc". You cannot paste a cloud host: there is none. The package tests (UkraineTaxInvoiceTest) do not cover a live exchange — that is in the test's header, not a gap.

Same topic for other readers: User

Where next#

Was this page helpful?