Skip to main content

Incremental Bank Transaction Sync: Change Feed, Cursors and Page Tokens

The Didit change feed returns a full snapshot with reset true on the first read, pages with a page token while more pages remain, and continues incrementally from the next cursor on later reads.

Incremental Bank Transaction Sync: Change Feed, Cursors and Page Tokens

Contents

In this guide

Jump to the part you need.

This guide is for engineers who already have a Didit bank connection and need to keep a local copy of its transactions current without re-reading everything each time. It covers the change feed at GET /v3/bank/connections/{id}/transactions/sync/, the durable cursor, the page_token and the reset flag. Reads never bill. The caveat: ongoing access with real banks is not open to live applications yet, so you prove the whole flow in sandbox with the Didit Test Bank.

Last updated: November 26, 2026. Prices checked against the live Didit price feed on November 26, 2026.

The change feed in one table

Every read of the Didit transactions change feed, and what you do with the answer
What you are doingRequestWhat comes back
Loading your first copyGET /v3/bank/connections/{id}/transactions/sync/?limit=500 with no cursorEvery current transaction as added, with reset: true. Clear the old copy once, then apply every page of the replacement snapshot.
Finishing one passThe same call with page_tokenThe next page while has_more is true. The last page carries the next_cursor.
Staying currentThe same call with cursorOnly what changed since that cursor: added, modified, removed.
Asking for a sync nowPOST /v3/bank/connections/{id}/refresh/If the refresh stays within the connection's budgets and stores changes, bank.data.updated follows.

Start free in the sandbox at https://business.didit.me/ with no sales call. For developers, connect Didit to an AI assistant via https://didit.me/developers/mcp/.

Cover of the guide on using Didit from an AI assistant through the MCP server
The Didit MCP setup guide shows how to connect an AI assistant to Didit.

What the feed returns, and where it differs from a date range

The feed returns transaction changes for one connection. It is not a list of transactions between two dates. For the full product, see the Bank Data API overview; if you do not have a connection yet, the bank data quickstart takes you from a sandbox key to your first transactions. Every price is on https://didit.me/pricing/. Each response carries three arrays: added, modified and removed. Apply added and modified as upserts keyed by the transaction id, and apply removed as a delete by id, ignoring any id you do not hold. When a pending transaction is booked, it leaves in removed with reason pending_booked, and the booked one arrives in added.

The date-range read is a different endpoint, GET /v3/bank/accounts/{account_id}/transactions/, documented on the transactions reference. It continues with page_token too, but it has no durable cursor and no reset. Use the date range when you want a window such as a tax year. Use the change feed when you want to stay current. The cursor is the saved position for the next pass on this connection. If the feed returns reset: true, replace your local copy.

Prerequisites before your first read

What the change feed needs on your side
ItemWhat it must be
PlanAny Didit plan. The sandbox is free and unlimited on every plan, and nothing is charged in sandbox.
ClientServer side only. The API key never reaches a browser or an app; the docs state this on the quickstart.
API keyFull access, or a key whose scopes name Bank data: Read for the reads, Write for refresh, renew, revoke and delete.
ConnectionThe feed reads stored transactions once the first sync makes them available. Active ongoing access is what keeps recurring bank syncs running. Stored one-time data stays readable through the same endpoints until consent.retain_until.
StorageOne row per connection holding the connection id, the change feed cursor and the consent end.
Webhook destinationNeeded for event-driven reads. Subscribe it to bank.data.updated, with HMAC verification as described on the webhooks page.

Seven steps to an incremental sync

You can test ongoing access in sandbox with the Didit Test Bank. Live applications can make one-time reads of real banks in supported countries. Ongoing access to real banks is not yet open to live applications, so the walkthrough below runs in a sandbox application.

Step 1: create an API key with the Bank data scope

In the Business Console, open your sandbox application and go to API keys. Create a named key. Full access works. For a key with custom access, add Bank data: Read for the reads, Write for the calls that create, change or delete something. Copy the key and export it:

export DIDIT_API_KEY="your-sandbox-key"

Step 2: create a link with ongoing access

A link is one run of the screens where a person connects a bank. Create an ongoing one for the Test Bank:

curl -X POST https://verification.didit.me/v3/bank/links/ \
  -H "x-api-key: $DIDIT_API_KEY" \
  -H "content-type: application/json" \
  -d '{
    "access": "ongoing",
    "country": "ESP",
    "data": ["accounts", "balances", "transactions"],
    "history_days": 90,
    "vendor_data": "client-7731"
  }'

The response carries the link id, the hosted url and a connection_id that is null until the person finishes. Keep the link id with your user. Every write accepts an Idempotency-Key.

Step 3: complete Bank Link and wait for the first sync

Open the url, pick Didit Test Bank, sign in with one of the test customers listed on the sandbox page, and choose the accounts to share. bank.link.completed arrives with the link_id and the connection_id, then bank.connection.created when the first sync has stored the accounts. At that point sync.initial_status is succeeded or partial, and bank.connection.history_complete follows when the backfill ends. Each account reports what the bank really delivered in history_coverage. Consent, renewal and the statuses of a connection are covered in connections, consent and renewal, and a renewal keeps the connection id and every account id.

Step 4: read the first snapshot with no cursor

An empty cursor returns every current transaction as added with reset: true. It is a true snapshot: every transaction the connection had when the read started, each exactly once, in its current state, even if a sync runs while you page.

curl "https://verification.didit.me/v3/bank/connections/$CONNECTION_ID/transactions/sync/?limit=500" \
  -H "x-api-key: $DIDIT_API_KEY"

Because reset is true, clear the old copy once, then apply every page of the replacement snapshot. Do not append.

Step 5: page with page_token, then store next_cursor

The first page of a snapshot can carry has_more: true with a next_page_token and no next_cursor, because the snapshot spans several pages. Keep reading with page_token while has_more is true, and store the next_cursor of the last page only.

cursor, page_token = stored_cursor or "", None
while True:
    params = {"limit": 500, "page_token": page_token} if page_token else {"cursor": cursor, "limit": 500}
    page = get(f"/v3/bank/connections/{connection_id}/transactions/sync/", params)
    if page["reset"] and not page_token:
        wipe_local_copy(connection_id)       # replace, never append
    apply(page["added"], page["modified"], page["removed"])
    if not page["has_more"]:
        store_cursor(connection_id, page["next_cursor"])
        break
    page_token = page["next_page_token"]
  • limit defaults to 100 and its maximum is 500, so a limit of 500 lets each request return up to 500 items and cuts the number of requests for a large snapshot.
  • While has_more is true, continue with next_page_token. The feed returns the new next_cursor on the final page. Keep any previously saved cursor until you have applied that page.
  • next_page_token is temporary. Use the page token to finish the current pass, and never store it between runs.
  • If paging fails midway, restart from the cursor you stored, not from the page you were on.

Step 6: stay current on bank.data.updated

We automatically sync each active ongoing connection one to four times a day, depending on the bank, shown as sync.frequency_per_day. When a sync stores changes, bank.data.updated arrives with the connection_id, the account_ids and the counts. That is your signal to read the change feed. Each new pass starts with the last saved cursor:

curl "https://verification.didit.me/v3/bank/connections/$CONNECTION_ID/transactions/sync/?cursor=$STORED_CURSOR&limit=500" \
  -H "x-api-key: $DIDIT_API_KEY"

Continue either a snapshot or a change batch with page_token set to the preceding next_page_token while has_more is true, and save the final next_cursor after applying the final page. When bank.data.updated arrives, start one pass from the saved cursor. Follow next_page_token while has_more is true, then apply the final page and save its next_cursor. Changes made while you were paging the first snapshot arrive in this read from next_cursor: a transaction you already received comes again as modified, and a new one as added.

Step 7: force a sync, then stop cleanly

To fetch sooner than the automatic schedule, call POST /v3/bank/connections/{id}/refresh/, documented on the refresh reference. The call is bounded by sync.live_syncs_left_today and sync.budgets, so read your remaining allowance before you ask. If the refresh stays within those budgets and stores changes, bank.data.updated fires; read from the stored cursor to see any transaction changes. GET /v3/bank/connections/{id}/sync-runs/ lists what actually ran, and GET /v3/bank/connections/{id}/sync-runs/{sync_id}/ shows one run.

When a client leaves, stop access with POST /v3/bank/connections/{id}/revoke/. Revocation stops future bank syncs, and stored data remains readable until consent.retain_until. Deleting the connection with DELETE /v3/bank/connections/{id}/ removes the stored data.

Field and event mapping

Each field and event in the sync flow, and the action it triggers in your system
Field or eventWhere it appearsWhat you do
addedSync responseInsert or upsert by transaction id. Includes pending transactions.
modifiedSync responseUpsert by id with the current state. One you already hold is updated, one you do not hold yet is added.
removedSync response, each item carries a reasonDelete by id. Ignore an id you do not have.
resetSync responseTrue with no page_token sent means replace your copy of this connection before applying the page.
has_moreSync responseTrue means read the next page with next_page_token.
next_page_tokenSync response, only while has_moreSend as page_token on the same request. Do not store it.
next_cursorLast page of a pass, where has_more is falseStore it per connection. Each new pass starts by sending it as cursor on the first request.
bank.data.updatedWebhookStart one change feed pass from the stored cursor.
bank.connection.createdWebhookAccounts, balances and recent transactions become readable.
bank.connection.consent_expiringWebhook, 14, 7 and 1 day before the endAsk for a renewal before the consent ends, so the connection id and account ids survive.
bank.connection.revokedWebhookAccess ended. Revocation stops future bank syncs and stored data remains readable until consent.retain_until. Deleting the connection removes the stored data.
transaction idEvery transactionYour key within one connection. Pair it with the connection id and never merge ids across connections.
account_refAccountUse account_ref to recognize a bank account across connections. Key accounts by their id. Use the documented transaction reconciliation guidance when a new connection returns overlapping history.
identity_qualityTransactionWith derived, a bank correction can appear as one removed and one added.

Why the first page has has_more but no next_cursor

The two tokens answer different questions. cursor is the saved position for the next pass on this connection. If the feed returns reset: true, replace your local copy. page_token is a bookmark inside one pass: use it to finish the current pass, and it has no meaning afterwards.

If each page contains 500 transactions, 20,000 ÷ 500 = 40 requests. Follow has_more to determine when the pass is complete. At $0.00 per change-feed read, 40 × $0.00 = $0.00 in feed-read charges. Page one therefore has has_more: true and a next_page_token, and there is no next_cursor to store yet, because the snapshot is not finished. While has_more is true, continue with next_page_token. The feed returns the new next_cursor on the final page. Keep any previously saved cursor until you have applied that page.

A two-page snapshot followed by the next incremental pass, traced with the fields the feed returns:

  1. First request: GET /v3/bank/connections/{id}/transactions/sync/?limit=500. The response has reset: true, has_more: true and a next_page_token, with no next_cursor. Apply the page.
  2. Continuation: the same path with page_token set to that next_page_token. The response has has_more: false and a next_cursor. Apply the page, then store the next_cursor.
  3. Next pass, after bank.data.updated: the same path with cursor set to the stored value. The response carries only the changes since that cursor, and a new next_cursor to store the same way.

If a bank sync lands while you are paging the initial snapshot, the running snapshot keeps the original view it started with. The next pass from next_cursor picks up the changes that landed meanwhile, as modified and added.

Read the whole flow on the transactions change feed reference and on accounts, balances and transactions.

Where a transaction id changes, and where it does not

An account has an id that never changes while the connection exists, and it stays the same after every renewal of that connection. A transaction has an id that is stable within its connection, across reads, syncs and renewals. That is what makes the upsert-by-id model safe for a daily feed.

A new connection of the same bank account gets new ids for the account and for its transactions. So key your rows on connection id plus transaction id, and use account_ref to recognize the bank account when a person connects again, because several accounts of one connection can share the same account_ref while their id stays unique. When a bank corrects a transaction and identity_quality is derived, that correction can appear as one removed and one added instead of a modified.

Errors and fixes

Every error carries code, message, request_id, field, next_action and retry_after. Branch on code, as described on the API errors page.

Common failures in the sync flow and what fixes each one
What you seeWhat it meansFix
401The key is wrong, malformed, revoked or expiredCheck DIDIT_API_KEY or create a new key
403The key has no access to this resource or action, the request came from outside the key's IP list, or the balance cannot cover the callRead code in the body. A GET needs Bank data Read, a write needs Bank data Write, and the key's IP restrictions must allow your address
400 country_not_availableThe country is not served, or no bank is offered thereDrop the country field or pick a covered country
404The connection id does not existCheck the id you stored against GET /v3/bank/connections/
409 one_time_connectionYou refreshed or renewed a one time connectionCreate a new link to read the bank again
409 renewal_not_neededMore than 30 days of consent remainWait, or renew inside the window
409 renewal_window_expiredThe window after consent.renewable_until has passedCreate a new link and reconcile with account_ref
429Too many requestsWait the seconds in retry_after, then retry

Test it in sandbox with the Didit Test Bank

Sandbox is free on every plan and nothing is charged there. Use the Test Bank’s long-history and pending-transaction scenarios to test snapshot pagination and how your copy handles pending transactions.

Expected success. After bank.connection.created, check that the selected accounts and recent transactions are readable. After bank.connection.history_complete, inspect history_coverage for the dates the bank actually delivered.

Error cases worth staging. Renew a connection in sandbox and confirm the account ids and transaction ids do not change. Call refresh on a one time connection and confirm you get 409 one_time_connection instead of a silent no op. Request a country that is not served and confirm you get 400 country_not_available.

Disconnect. Revoke the connection: future bank syncs stop and stored data remains readable until consent.retain_until. Delete the connection to remove the stored data. The full lifecycle is on connections, consent and renewal.

Cost of both ends

Didit side. Reads never bill, so if each page contains 500 transactions, paging a 20,000 transaction snapshot takes 20,000 ÷ 500 = 40 requests and costs nothing beyond what the connection already costs. Follow has_more to determine when the pass is complete. The billable events are the completed read of a one time link and, for ongoing access, an active connection per month. The published numbers live on the bank verification pricing page and on https://didit.me/pricing/. Sandbox is free and unlimited.

Your side. One change feed pass per bank.data.updated event, plus the paging reads of the first snapshot. If each page contains 500 transactions, a snapshot of 20,000 transactions takes 20,000 ÷ 500 = 40 requests. Follow has_more to determine when the pass is complete. If 250 connections each sync four times in a day, that is 250 × 4 = 1,000 scheduled sync runs. The number of feed requests depends on which runs store changes and how many pages each pass returns.

Worked example. If each page contains 500 transactions, 20,000 ÷ 500 = 40 requests. Follow has_more to determine when the pass is complete. At $0.00 per change-feed read, 40 × $0.00 = $0.00 in feed-read charges. Sandbox testing is free. The published billing unit for ongoing access is an active connection per month, so multiply the per connection price on https://didit.me/pricing/ by the number of connections you keep active, and add the completed read of any one time link at the price on the same page.

How Didit billing works with credits, auto recharge and volume discounts
Billing is per completed check from prepaid credit. Reads in the sync flow are not a billed event.

Sources

Next step: create a sandbox application, connect the Didit Test Bank and run the seven steps above against it. Start at https://business.didit.me/, no sales call needed, and keep the change feed reference open beside you.

Try it

Try this in the sandbox

Run the check this guide describes, free.

ID Verification

The product this post is about, taken from its topic. Run it free in the sandbox.

$0.15 per checkStart free

Author

Alberto Rosas

Co-founder and CEO

Alberto Rosas

Alberto Rosas

Co-founder and CEO

About Didit

Questions

Frequently asked questions

How do I incrementally sync bank transactions with the Didit API?

Call GET /v3/bank/connections/{id}/transactions/sync/ once with no cursor to load the full snapshot, continue with page_token set to the preceding next_page_token while has_more is true, and store the next_cursor from the page where has_more is false. Each new pass starts with the last saved cursor and returns only the added, modified and removed items since then. Reads never bill.

What does reset: true mean in the transactions sync response?

reset: true means the response is a full snapshot, not an increment, so you replace your local copy of that connection instead of appending to it. It appears on a first read with no cursor. Clear the old copy once, then apply every page of the replacement snapshot.

Why does my first page have has_more true but no next_cursor?

Because the snapshot is not finished. The page_token is a bookmark inside one pass, while the cursor is the saved position for the next pass on this connection. The feed returns the new next_cursor on the final page, and you keep any previously saved cursor until you have applied that page.

What is the difference between cursor and page_token?

The cursor is the saved position for the next pass on this connection. If the feed returns reset: true, replace your local copy. The page_token is temporary: it only walks you through the pages of the pass you are making now, so use it to finish that pass and never store it between runs.

When exactly should I store next_cursor?

Only after a response where has_more is false, using the next_cursor on that page, and only after you have applied that final page. If paging fails midway, restart from the cursor you already stored, not from the page where you stopped, so no page is skipped.

How do I recover if paging fails halfway through?

Restart from the last stored cursor, or omit the cursor if none has been saved yet. When the feed returns reset: true, replace the local copy before you apply the pages that follow. Upsert added and modified by id. For each item in removed, delete the matching transaction by id if it exists in your local copy.

Does a transaction id change after a person reconnects their bank?

Within one connection, transaction ids are stable across reads, syncs and renewals, and the account id never changes while that connection exists. A new connection of the same bank account gets new ids, so key rows on connection id plus transaction id, and use account_ref to recognize the same bank account across connections. Use the documented transaction reconciliation guidance when a new connection returns overlapping history.

Which webhook tells me there are new bank transactions?

bank.data.updated fires when a sync stores changes, and it carries the connection_id, the account_ids and the counts. Start one change feed pass from the stored cursor after each event and follow next_page_token while has_more is true. Reads never bill, but the data only changes when a sync runs.

How do I force a bank sync instead of waiting for the schedule?

Call POST /v3/bank/connections/{id}/refresh/. The connection reports sync.live_syncs_left_today and sync.budgets, so read your remaining allowance before asking. If the refresh stays within those budgets and stores changes, bank.data.updated fires and you read from the stored cursor.

Does reading the change feed cost anything?

No. Reads never bill, on any plan, and sandbox is free and unlimited. What is billable is the completed read of a one time link, or an active connection per month for ongoing access, priced on the published bank verification price list.

Can I use ongoing bank access with real banks in production today?

Live applications can make one-time reads of real banks in supported countries. Ongoing access is currently available in sandbox with the Didit Test Bank. Access to real banks will open country by country. Check the coverage page and the institutions endpoint before you promise a feed to a client.

How many transactions fit in one page?

A limit of 500 lets each request return up to 500 items, which cuts the number of requests for a large snapshot. If each page contains 500 transactions, 20,000 ÷ 500 = 40 requests. Follow has_more to determine when the pass is complete, and only the last page gives you a next_cursor.

Compliance built in

Audited, certified and attested.

We hold the certifications and build each country's rules into your flows, so you can launch anywhere without worrying. Security and Compliance center

  • Regulation encoded into your flows

    Tell us what you do and where. Didit lists the rules that apply to you, with sources, and builds the checks each country needs into one workflow.

  • Ready for AMLR

    Every requirement of the new EU anti-money laundering rules, from checking customers to human review, is already covered by a Didit check.

  • Tested in Spain's Treasury sandbox

    Spain's Treasury published its supervised sandbox report on Didit's NFC plus active liveness onboarding; SEPBLAC took part and valued the added measures positively.

  • Audited, not self-declared

    iBeta Level 1 and Level 2. Liveness tested under ISO/IEC 30107-3.

Compliance assistant

Your obligations · 3 regions

EU · AMLRCustomer due diligence, human reviewCovered
Illinois, Texas, ColoradoExplicit biometric consentCovered
Germany · Youth protectionVerified adults only (JMStV)Covered
Workflow checked. Every obligation is met
  • SOC 2 Type 2
  • ISO 27001
  • iBeta Level 1 and Level 2
  • EU regulator attestation
  • FSM youth protection
  • GDPR
  • EBA remote onboarding
  • MiCA compatible
  • FIDO Alliance member
  • AMLREU AML Regulation ready

Integration · Didit MCP

Run Didit from your own AI agent

Connect Didit to Claude, Cursor, VS Code or ChatGPT and just ask in plain words. Your agent can do anything you can do in the console, with the same permissions you have.

Add to ClaudeChatGPT
Didit Academy · Lesson 04 · Use Didit with MCP
  • Build workflowsDescribe the checks you need. The agent creates and publishes the flow.
  • Run investigationsAsk why a session was declined, review cases, search people and companies.
  • Change rulesCreate payment rules, test them on past data and switch them on.
  • Pull reportsAsk for numbers, exports or the audit log.

Verify your first user today.

Start free

Free sandbox. Credit applies to work-email sign-ups.