DeviZones
Account Desk 6 min read

ZRA Smart Invoice Error 902: "This Device Is Installed"

DZ

Devi Zones

ZRA Smart Invoice Error 902: "This Device Is Installed"

You initialise a device and ZRA answers:

{ "resultCd": "902", "resultMsg": "This device is installed" }

It reads like a failure. Most of the time it is not — and the times it is, it is more serious than it looks, because of one rule about how ZRA issues device keys.

What 902 actually means

Your serial is already initialised on ZRA. That is the whole message. ZRA is telling you the registration you are asking for has already happened.

The rule that makes 902 matter: the device key is issued once

When a device initialises successfully for the first time, ZRA's response carries a cmcKey — the device communication key. It is the credential your VSDC authenticates with from then on.

ZRA issues it at first initialisation and does not re-issue it. Initialise the same serial again and you get 902 — and no key.

That splits 902 into two completely different situations.

If you already hold the key: 902 is a confirmation

You initialised this device before, you stored the cmcKey and sdcId, everything works. You press Verify again — to check connectivity, or out of habit — and get 902.

Nothing is wrong. ZRA is confirming the device is registered. Your software should treat it as success.

That is how we handle it. If we already hold the branch's sdcId, a 902 returns OK and just refreshes the last-verified timestamp:

if (r.resultCd === '902') {
  if (branch.sdcId) {
    // Already initialised and we hold its key — a no-op, not a failure.
    return { ok: true, ... };
  }
  // No key on our side: this is the bad case.
}

If your software shows a red error here, it is misreporting. The device is fine.

If you do not hold the key: you are locked out of that serial

This is the real problem, and for that serial it is permanent.

You get 902 but have no cmcKey stored. ZRA will not issue one — as far as it is concerned the device is installed. You now have a registered device you cannot authenticate as.

How people end up here:

  • The serial was initialised somewhere else first — an earlier setup, a different VSDC, a vendor running a trial, an IT person testing. The key went to that installation.
  • The database was rebuilt, or restored from a backup taken before initialisation, and the key was lost with it.
  • The VSDC moved and the local key store did not come along.

Re-initialising will not help. It will return 902 forever. There is no "resend the key" call in the API.

The fix: use a fresh device serial

A device serial is a unique identifier you assign. It is not a hardware serial and it does not have to look like anything in particular. Register a new device with a serial that has never been initialised, initialise that, and ZRA issues a fresh key.

In Account Desk the setup auto-generates one (an AD-… value) precisely so this is a one-click recovery instead of a support conversation.

The old serial stays registered on ZRA and is simply abandoned. That is normal, and it is fine.

One rule to carry away: once a device is initialised, never change its serial. The serial is the identity the key belongs to. Change it and you have orphaned your own key.

The 902 → 899 chain

Here is what makes 902 worth understanding rather than dismissing.

A 902 with no key does not fail once and stop. It poisons everything downstream. Because you never captured a cmcKey, every subsequent authenticated call — reading branches, fetching notices, loading item classification codes — fails with resultCd 899, "An error regarding the Client occurred."

And 899 tells you nothing about the cause. So people debug the read call, which is not broken, instead of the initialisation, which is.

If you are seeing 899 everywhere, go and look at your init. That is covered in ZRA VSDC error 899.

Quick reference

| Situation | What 902 means | What to do | |---|---|---| | You hold the sdcId and device key | Device already registered — a confirmation | Nothing. Treat it as success. | | You have no device key | You are locked out of this serial | Use a fresh serial and initialise again | | You just changed the serial on a working device | You have orphaned the key | Put the original serial back |

Related

If initialisation returns 901 "It is not a valid device" instead, the cause is different — an identity or environment mismatch. See ZRA Smart Invoice error 901.


If you are setting up ZRA Smart Invoice and would rather not spend a week on device errors, Account Desk connects to Smart Invoice (VSDC) directly — a sale is fiscalised as you bill it, and the ZRA receipt number, SDC ID and QR code print on the invoice. Talk to our team about your Smart Invoice setup, or book a demo.

Frequently asked questions

What does resultCd 902 mean on ZRA Smart Invoice? +

902 is “This device is installed” — the device serial you sent is already initialised on ZRA. If you already hold that device's key and SDC ID, it is a confirmation rather than an error and can be treated as success.

I get 902 but I have no device key. How do I recover? +

You cannot recover the key for that serial. ZRA issues the cmcKey once, at first successful initialisation, and does not re-issue it — so re-initialising returns 902 forever. Register a new device using a fresh serial that has never been initialised, and initialise that instead. The old serial is simply abandoned.

Can I change the device serial after initialisation? +

No. The serial is the identity the device key belongs to. Changing it on a working device orphans the key and leaves you unable to authenticate. If you have already changed it, put the original serial back.

Why does every ZRA call return 899 after a 902? +

Because no device key was ever issued. Authenticated calls such as selectBranches, selectNotices and selectItemsClass need the cmcKey, so without one they all fail with 899. The 899 is the symptom; the 902 at initialisation is the cause.