Documentation menu

Guide

The Holded token

How to create the Holded API token, which permissions AutoCuadre needs and what to do if one is missing.

The token is the key AutoCuadre uses to get into your Holded account. You create it, you decide which permissions it carries and you can change it without losing anything.

How to create the token

  1. In Holded, go to Settings → Developers → Credentials and press “Add token”.
  2. It must be a token for Holded's new API. An “API Keys v1” one does not work: Holded rejects it.
  3. Tick the permissions in the table below.
  4. Copy the token and paste it into AutoCuadre: in step 1 of the wizard or in “Settings → Connections”, in the “Holded API token” field. Press “Connect Holded”.

AutoCuadre checks it with Holded before saving it. It is stored encrypted.

The “Holded” card in “Connections” before connecting, with each area numbered
The “Holded” card in “Connections” before connecting, with each area numbered
  1. “Holded API token”: this is where you paste the token.
  2. “Connect Holded”.
  3. “Permissions the token needs”: the list of permissions. It is only shown next to the token field.

Permissions it needs

“Connections” shows the list under “Permissions the token needs”, next to the field where you paste the token: before connecting and, with Holded already connected, when you press “Replace the Holded token”. This is what each one is for; the details are in Permissions AutoCuadre asks for:

PermissionWhat AutoCuadre uses it for
account:info.readKnowing which Holded account is connected and showing it to you.
sales:receipts.read and sales:receipts.writeReading and creating sales receipts.
sales:invoices.read and sales:invoices.writeReading and creating invoices and credit notes.
sales:sales-channels.readListing your sales accounts.
sales:sales-channels.writeAdding an income account from “Settings → Documents”.
accounting:chart-of-accounts.readSeeing all your income accounts (groups 70, 75, 76 and 77) and choosing the fees expense account from a list.
accounting:payments.read and accounting:payments.writeRecording the payment of each document and the repayment of each refund.
accounting:banks.readListing your treasury accounts and reading the bank deposits.
accounting:banks.writeMarking the bank deposit as reconciled.
accounting:daily-ledger.read and accounting:daily-ledger.writeCreating the journal entry of each reconciliation in the daily ledger, and deleting it if you undo it.
accounting:taxes.readChecking that each VAT key exists in your account before creating a document.
accounting:purchases.read and accounting:purchases.writeReading your purchase invoices when updating documents.
contacts:contacts.read and contacts:contacts.writeFinding the single contact and creating or reusing the buyer's contact.
inventory:products.read and inventory:products.writeSyncing the catalogue and stock, only if you turn it on.
inventory:warehouses.readListing your warehouses to assign them to Shopify locations.
developers:usage.readShowing you how many Holded calls you have used this month.

When connecting, AutoCuadre checks the read permissions. If any is missing, it does not connect and tells you which one. The write permissions are checked separately.

Checking the write permissions

In “Connections”, inside the Holded card, “Token write permissions” shows the latest check and a button to repeat it: “Check again” (“Check permissions” if none has been done yet). It checks one by one the write permissions for receipts, invoices, contacts, payments, banks, daily ledger, sales accounts and products.

  • It does not create or change anything in Holded. It uses 8 calls from your monthly quota.
  • It runs on its own when you change the token and when you activate AutoCuadre.
  • Before activating it cannot be done: AutoCuadre only reads from Holded.
The “Holded” card in “Connections” with Holded connected and AutoCuadre activated, with each area numbered
The “Holded” card in “Connections” with Holded connected and AutoCuadre activated, with each area numbered
  1. “Token write permissions”: what the latest check found.
  2. “Check again”.
  3. “Holded API calls this month”: the ones you have used and the ones you have left.
  4. “Disconnect Holded”: only for switching to another Holded account.
  5. “Replace the Holded token”: to paste a new token for the same account.

If any is missing, “Connections” tells you which one and what it is for, and in “Home” the “Needs your attention” card warns you that the Holded token is missing permissions, with the “Open Connections” button. Without the banks and daily ledger permissions, AutoCuadre does not start a reconciliation: that way it is not left half done.

Read-only until you activate

Until you complete the last step of the wizard, the connection is read-only: AutoCuadre does not create, change or delete anything in Holded, whatever permissions the token carries.

That is why you can start with a token that only has read permissions and replace it with one with write permissions just before you activate. When you activate, AutoCuadre checks the write permissions.

Changing the token without losing anything

  1. Create the new token in Holded, in the same account.
  2. In AutoCuadre, open “Settings → Connections” and, in the Holded card, press “Replace the Holded token”.
  3. Paste the new token and press “Connect Holded”.

Nothing is deleted: documents, settings and assignments are kept.

If the app says a permission is missing

Depending on where it is missing, you will see it one way or another:

  • When connecting: “The token is valid but is missing permissions”, followed by the list.
  • When reconciling a payout or applying a PayPal journal entry: “The Holded token is missing the … permission”, with the name of the permission. For example accounting:daily-ledger.write, the one that allows writing in the daily ledger.
  • When adding an income account in “Settings → Documents”: the message names sales:sales-channels.write.
  • In the account lists: if you only see a few sales accounts, accounting:chart-of-accounts.read is missing.
  • In the call usage in “Connections”: “We could not read your usage yet”. The “API usage” permission is missing.

The solution is always the same:

  1. Create a token in Holded that includes that permission, or add it to the one you have.
  2. If the token has changed, paste it in “Connections” with “Replace the Holded token”.
  3. Press “Check again” and press the button that failed again. What had already been done is not repeated.

Holded calls

Holded limits the monthly calls according to your plan, and “Connections” shows you how many you have used. Creating an order's document uses between 3 and 5: with 1.500 calls left you get between 300 and 500 more documents. If they run out, AutoCuadre cannot create documents until the 1st of the month or until you upgrade your plan in Holded.