Контур.Диадок

Catch the Diadoc documents that are waiting for your signature

Connect Kontur.Diadoc to the AI agent: inbound and outbound documents, counterparties, signing statuses. The agent shows what awaits a signature and what stalled.

How the agent works with Диадок

The agent works with the Diadoc public API at diadoc-api.kontur.ru within the boundaries of a single organisation box. It reads inbound, outbound and internal documents together with their attachments and document flow statuses, the counterparties and the event feed of the box. Out of that come registers for reconciliation against your accounting system, lists of documents with no response and a digest of what arrived overnight and needs signing today.

In EDI a document status is the state of a two-sided movement, not the fact of a closed deal. Something you sent can sit unsigned and unrejected for weeks, and an inbound document can wait for your answer without reminding you of itself anywhere in the interface. So the agent looks not at the fact of sending but at the age of the wait: it singles out documents sitting for more than a day and names the counterparty, type and arrival date beside each one.

Signing is a decision of its own, and the agent does not make it for you. The sending method never creates a signature: it arrives from outside. When the qualified certificate sits on a token, a person signs, and the agent takes the document exactly up to that point — drafting it, assembling the package, checking completeness and attachments. When the organisation has Diadoc's cloud signature or Gosklyuch enabled, the agent can send files off to be signed and wait for the result, but it starts that on your command, not on its own. Accepting a two-sided document means sending your recipient title, and the agent prepares that in full too. Rejection and annulment are put to you with the whole picture and sent once signed.

The agent sees exactly what the issued token permits and does not try to reach past that boundary. The box cannot be switched on the fly, so one organisation means one connection, and the agent lists your legal entities and their boxes from the GetMyOrganizations response. New material it takes from the event feed of the box rather than by walking day after day, and it remembers the last event it read, so a second digest in one morning does not recount everything. If there are no documents for the period, it says so directly instead of showing an empty register.

Integration scenarios

Documents awaiting a signature

The agent shows inbound documents with no response yet and singles out the ones sitting for more than a day, with counterparty, type and arrival date.

What has stalled on the other side

The agent gathers the documents for a counterparty over a period and names the ones the other party has neither signed nor rejected.

An EDI register for reconciliation

The agent consolidates inbound and outbound documents by type, date and counterparty and prepares a register ready to reconcile against your accounting system.

Morning document flow digest

The agent sends you on schedule how many documents arrived overnight and what needs signing today, so nothing is left hanging.

A package ready to send

The agent prepares the draft and assembles the package for sending — checking completeness, attachments and counterparty details — and stops where your signature is needed.

Rejections and annulments

The agent reads the box event feed and collects the documents a counterparty has rejected or asked to annul, with the reason and the date; on your decision it drafts the annulment proposal or the signature refusal and sends it once signed.

Диадок examples

Диадок
Frozen chats — click a question
Что за ночь прилетело в Диадок?

23 входящих за ночь, 6 из них ждут ответа дольше суток.

Самое старое — УПД от «Северторга» от 14 июля, лежит четвёртый день. Собрал их в один список с контрагентом, типом и датой поступления — подписывать вам, я только подсвечиваю.

How to connect

Before you connect

  • The organisation already works in Diadoc and has a box
  • One connection per organisation: the box is fixed when you connect
  • A qualified certificate for the signer: a token, Diadoc's cloud or Gosklyuch
  1. 1

    Submit the form at diadoc.ru/integrations/api

    Submit the form at diadoc.ru/integrations/api. A Kontur manager opens the Integrator Portal and issues your client_id — keys are not self-service.

  2. 2

    In Integrator Portal issue a client_secret

    In the Integrator Portal issue a client_secret for your client_id. The pair is only used to obtain a token — the API itself does not accept it.

  3. 3

    Get an access_token via OpenID Connect

    Exchange client_id and client_secret for a token with the scope “openid profile email offline_access Diadoc.PublicAPI”: without it the API refuses.

  4. 4

    Copy the box ID from the address bar

    Open the Incoming documents section and copy the 32 characters between https://diadoc.kontur.ru/ and /Folder/Inbox in the address bar.

FAQ

With two values: an access token and a box identifier. The token is obtained via OpenID Connect with the Diadoc.PublicAPI scope, and the box identifier is the 32 characters from the address bar of the Inbound documents section. Kontur issues the keys through a manager on request.

Inbound, outbound and internal documents of the connected box, their attachments and document flow statuses, counterparties and the event feed — within the rights of the issued token.

The sending method itself never creates a signature: it arrives ready-made. With a certificate on a token, a person signs and the agent prepares the draft and the package. With Diadoc's cloud signature or Gosklyuch enabled, the agent can send the files off to be signed and wait for the result — but only on your command.

The box is fixed at connection time, so one organisation means one connection. The agent will list your legal entities and their box identifiers from the GetMyOrganizations response.

Related integrations

Connection
API key
Documentation
Диадок

Connect Диадок

Connecting takes a couple of minutes, and your data stays in your own systems.

Connect