Skip to content
Datevbridge

Référence de l'API

Deux appels suffisent. Synchronisez, puis exportez.

Chaque requête est authentifiée via une clé d'API Bearer. Tous les montants sont des chaînes décimales et toutes les dates sont au format calendrier ISO.

Authentification

Générez vos clés depuis le tableau de bord. Une clé n'est affichée qu'une seule fois et n'est stockée que sous forme d'empreinte SHA-256 : une clé perdue doit donc être remplacée plutôt que récupérée.

Authorization: Bearer dv_live_XXXXXXXXXXXXXXXXXXXXXXXX

Points de terminaison

  • POST/api/v1/sync

    Import Stripe balance transactions for a period.

    Body: { from, to } as ISO dates; `to` is exclusive so months tile without overlapping. Idempotent — re-running imports only what is new.

  • POST/api/v1/exports

    Build a DATEV Buchungsstapel from imported transactions.

    Body: { from, to, bezeichnung?, vatTreatment? }. Returns the export plus the clearing balance and any transactions we could not map.

  • GET/api/v1/exports

    List previous exports, newest first.

    Cursor paginated with ?limit= (max 100) and ?cursor=.

  • GET/api/v1/exports/{id}

    One export's metadata.

    Scoped to your organisation; an id you do not own returns 404, not 403.

  • GET/api/v1/exports/{id}/file

    Download the EXTF file.

    text/csv; charset=windows-1252. The charset matters: reading it as UTF-8 corrupts every umlaut before DATEV sees it.

# Import March, then export it
curl -X POST https://datevbridge.altixcode.com/api/v1/sync \
  -H "Authorization: Bearer dv_live_..." \
  -H "Content-Type: application/json" \
  -d '{"from":"2026-03-01","to":"2026-04-01"}'

curl -X POST https://datevbridge.altixcode.com/api/v1/exports \
  -H "Authorization: Bearer dv_live_..." \
  -H "Content-Type: application/json" \
  -d '{"from":"2026-03-01","to":"2026-04-01","bezeichnung":"Stripe 03/2026"}'

Ce que devient chaque transaction

Chaque transaction Stripe génère une ou deux écritures, toutes imputées sur le compte d'attente. C'est ce qui permet de vérifier l'exactitude des calculs.

StripeDébit → Crédit (Soll → Haben)Justification
ChargeClearing → RevenueThe gross amount, with the VAT key. Never the net Stripe transfers.
FeeFees → ClearingIts own booking, so the input tax on it is recoverable.
RefundClearing → RevenueMarked Generalumkehr, so turnover is reduced rather than inflated on both sides.
ChargebackDisputes → ClearingA separate account from fees, so lost revenue stays distinguishable from cost of payment.
PayoutBank → ClearingDrains the clearing account. After it, the balance is what Stripe still holds.

Plan comptable par défaut

Valeurs par défaut, sans valeur légale. Chaque compte peut être modifié dans les Paramètres, et le schéma d'imputation doit être validé par votre Steuerberater avant toute utilisation.

RôleSKR03SKR04
bank12001800
stripeClearing13601460
revenueStandard84004400
revenueReduced83004300
revenueIntraCommunity81254125
revenueExport81204120
revenueReverseCharge83374337
paymentFees49706855
disputes24006930
roundingDifference48206969
receivables14001200

Comprendre le solde de compensation

Chaque export indique le solde de clôture du compte d'attente. Un montant non nul n'est pas forcément une anomalie — des fonds en transit d'une période à l'autre apparaissent ici —, mais il doit correspondre au solde Stripe à la fin de la période. Dans le cas contraire, une transaction est manquante.

{
  "export": { "id": "…", "bookingCount": 42, "clearingBalance": "5.00" },
  "clearingBalance": "5.00",
  "skipped": [
    { "id": "txn_x", "reason": "Unmapped Stripe transaction type \"topup\"" }
  ]
}

Tout élément classé dans « ignoré » a été délibérément exclu des écritures. Nous ne tentons pas de deviner le compte à utiliser pour un type de transaction non mappé : une approximation plausible masquerait l'opération, et c'est précisément ainsi qu'un grand livre se fausse en silence.

Erreurs

StatutCodeSignification
400invalid_payloadThe body failed validation. `details.issues` names each field.
401missing_api_key / invalid_api_keyNo bearer token, or one we do not recognise.
402quota_exceededThe monthly transaction limit is reached.
409missing_datev_settingsBeraternummer, Mandantennummer or Wirtschaftsjahresbeginn is not set.
422sync_failedStripe rejected the key, or it lacks read access to balance transactions.
422no_transactionsNothing is imported for that period. Run a sync first.
422reconciliation_failedA transaction violated an invariant; the message names it.