Back to all posts
GuidesMay 26, 2026 · 1 min read

The Architecture of Modern Finance: Scaling Operations via Accounting APIs

How high-performance platforms leverage unified ledger infrastructure to achieve forensic precision, eliminate engineering debt, and build programmable financial workflows.

NL
NewLedger team
Editorial
NewLedger App Connect API credentials list showing connected apps and delegated permissions

NewLedger Editorial

If you run a small or mid-size business, “modernizing operations” usually means the same few moves: less re-keying between tools, faster answers from your numbers, and software that talks to each other instead of living in separate tabs.

Accounting API integration is what makes that possible — your accounting system exposes a controlled way for other apps to read (and, where you allow it, draft) financial data. You stay in charge of what connects, what it can do, and when access ends.

On NewLedger, that layer is App Connect. For most accounting API integration work — automations, internal tools, partner sync — you use API credentials (client ID + secret, server-side token exchange). OAuth with a browser consent screen is only for MCP integrations such as ChatGPT, where the AI client redirects you to approve access. This guide covers both, in that order.

Why accounting API integration helps when you modernize ops

Typical SMB goals and how a connected accounting API supports them:

What you're trying to doHow integration helps
Ask questions about cash, AR, or expenses without exporting spreadsheetsMCP clients (e.g. ChatGPT) read live data after you approve OAuth consent — see MCP for accounting
Automate repetitive work (invoice drafts, expense capture, categorization hints)Automations use API credentials and call the API instead of copying numbers by hand
Connect a stack you already use (payments, CRM, industry tools)Partner apps sync through API credentials or your integration layer — not the MCP OAuth flow
Keep control as you add toolsOne place to see what's connected, revoke access, and review activity

The point is not “open the ledger to the internet.” It's replace manual bridges — email attachments, CSV exports, staff pasting totals into chat — with governed connections you can audit and turn off.

App Connect issues scoped, auditable access — never your login password. Two connection styles exist; they are not interchangeable:

Connection styleUse forHow it works
API credentialsAccounting API integration — automations, scripts, partner backends, anything you hostCreate an app in Settings → App Connect, delegate permissions, exchange client_id + client_secret for bearer tokens. No redirect URI, no consent screen.
OAuth (MCP only)ChatGPT and other MCP clients that connect via a company MCP URLBrowser consent in the NewLedger app, PKCE, refresh tokens. Listed under OAuth Connections — not used for ordinary API credential apps.

If you are modernizing ops with integrations and automations, start with API credentials below. OAuth is documented later for MCP only.

Set up accounting API integration (API credentials)

Use API credentials when you control the server, can store a client_secret safely, and do not need an interactive consent screen. This is the default path for SMB accounting API integration.

What you get

  • Scoped permissions — each app only receives permissions you delegate at create time (and your user account must already hold them).
  • Short-lived access tokens — clients request a new token from the token endpoint when one expires.
  • One-time secrets — the client secret is shown only at create or rotate.
  • Lifecycle control — revoke, delete, or restore apps from App Connect; activity is logged.
  • No OAuth redirect — setup is entirely in App Connect settings plus server-side token exchange.

Steps in the workspace

  1. Open Settings → App Connect and use the API Credentials tab to see connected apps, permissions, and last-used dates.
  2. Create App, choose API credentials, name the integration, and pick the permissions it may use.
  3. Copy the client ID and client secret once (the secret is only shown at create or rotate).
  4. Open the app detail anytime to review scope, rotate the secret, or revoke access.

The API Credentials tab lists each connected app, its delegated permissions, and when it was last used.

When you create an app, you name it, set optional expiry, and delegate only the permissions that automation needs.

The detail view is where you audit scope, rotate secrets, or revoke the app.

Token exchange (server-side)

Your integration exchanges the client ID and secret for a short-lived bearer token using the App Connect token API. There is no browser step, no redirect URI, and no PKCE.

Use the NewLedger API documentation for request formats, scopes, and company-scoped token exchange. Store secrets in a vault or secrets manager — never in source control, client-side code, or chat.

MCP integration only: OAuth setup (e.g. ChatGPT)

OAuth authorization code + PKCE is for MCP clients only — not for API credential apps you create under the API Credentials tab. When you add your company MCP URL in ChatGPT (or another supported client), that product drives the OAuth flow below.

For product context and what to ask your AI assistant, see MCP for accounting. This section covers the OAuth mechanics behind MCP.

What you get with MCP OAuth

  • Consent-first access — pick a company, review permissions, confirm with 2FA before any token is issued.
  • Scoped permissions — same permission strings as API credentials, but chosen on the consent screen.
  • PKCE (S256 only) — required for public MCP clients.
  • Refresh tokens — rotate on use; revoke by deleting the connection under OAuth Connections.

End-user flow: connect an MCP client

Use the in-app setup guides; you do not need to call the API yourself to connect ChatGPT.

1. Copy your company MCP URL

In your NewLedger workspace:

  1. Open Settings → App Connect
  2. Click MCP Server
  3. Copy the company-specific MCP endpoint

That URL is unique to the company you have selected. Use it when the external client asks for a server address.

You can also reach per-client instructions from Settings → Integrations (for example the ChatGPT setup page).

2. Start connection in the external app

In ChatGPT (or another supported MCP client), add a connector and paste your MCP URL. The client opens NewLedger's sign-in and consent flow in your browser.

You land on NewLedger's OAuth consent page. The screen shows:

  • Which app is requesting access (name, domain, logo when provided)
  • Which company the connection applies to (you can switch companies if you have access to more than one)
  • The permission list that will become the token scope — you can remove individual permissions before approving

When you continue, NewLedger asks for a verification code (TOTP or another configured confirmation method). Authorization does not complete without it.

This consent screen appears only for MCP OAuth (e.g. ChatGPT). API credential apps are configured entirely under the API Credentials tab.

4. Return to the client

After approval, you are returned to the MCP client. It completes the connection securely on its side, then can call your company's MCP server within the permissions you approved.

5. Manage connections later

Approved OAuth apps appear under Settings → App Connect → OAuth Connections. From there you can:

  • See when the connection was consented
  • Open connection details (scopes, MCP URL, client metadata)
  • Delete the connection — this revokes refresh tokens and blocks active access; the external app must ask for consent again

Idle connections are surfaced in the list so you can audit what still has access.

Register a custom OAuth app (MCP / development)

Some MCP setups need you to register an OAuth client in NewLedger instead of relying on the external product's built-in registration.

  1. Go to Settings → App Connect
  2. Choose Register OAuth App (or create a new app and pick the OAuth connection type)
  3. Fill in:
    • App name — shown on the consent screen
    • Redirect URI — must match exactly what the MCP client shows (HTTPS required)
  4. Save the client ID. Public MCP clients use PKCE and do not receive a long-lived client secret.

ChatGPT tip: Copy the redirect URI from ChatGPT's connector setup. Do not guess or reuse URIs from other products.

Building an MCP client on the NewLedger API

MCP OAuth is implemented on the NewLedger API and completed in the NewLedger web app consent UI. API credential apps do not use that flow.

If you are building or certifying an integration (not just connecting ChatGPT as a user):

  • Follow standard OAuth 2.1 authorization code with PKCE (S256).
  • Use OAuth discovery metadata published by NewLedger for your environment rather than hard-coding URLs.
  • Complete approval only through the signed-in consent screen and 2FA — tokens must not be issued without an explicit user action in the app.
  • Document integration details in your own runbook; use the NewLedger API documentation for supported App Connect and MCP operations.

We do not publish step-by-step token or authorize API recipes in this post. That reduces noise for readers and avoids exposing implementation detail that could be misused. Legitimate integrators should use the official API docs and your NewLedger account team if you need partner access.

MCP OAuth flow at a glance

StepWhoWhat happens
1MCP client (e.g. ChatGPT)Opens NewLedger sign-in and consent using PKCE
2YouReview company and permissions in the app, then confirm with 2FA
3NewLedgerRecords the approved connection with a scoped permission set
4MCP clientCalls your company's MCP server only within that scope

Quick comparison

API credentialsOAuth (MCP only)
Typical useAutomations, ETL, partner APIs, internal toolsChatGPT / MCP URL connection
Setup UIAPI Credentials tabMCP URL + OAuth Connections tab
User consent screenNoYes (in-app OAuth consent)
Redirect URINoYes (must match the MCP client exactly)
PKCENoYes (S256)
How the client gets a tokenServer-side exchange with client secretUser approval, then client completes OAuth

Both issue App Connect bearer tokens under the same permission model. Only MCP uses the OAuth redirect and consent flow.

Security defaults worth knowing

API credentials

  1. Permissions are delegated, not elevated — at create time, from your user's permission set.
  2. One-time secrets — treat the client secret like a password; rotate if exposed.
  3. 2FA for sensitive actions — revoke, delete, and rotate require action confirmation.
  4. Audit trail — token exchange failures and lifecycle events appear in workspace activity.

MCP OAuth (only)

  1. Consent + 2FA before the connection is active.
  2. PKCE (S256) — required for public MCP clients.
  3. HTTPS redirect URIs for registered OAuth clients.
  4. Revoke via OAuth Connections — deleting a connection removes ongoing access; data already drafted in NewLedger stays for you to review.

Troubleshooting (workspace)

API credentials

What you seeWhat to try
Token request failsConfirm client ID and secret, app is active, and the app was not revoked or deleted
Access stops after a dateCheck optional credential expiry on the app
Scope or permission errorsEnsure the permission is delegated on the app and your user role allows it

MCP OAuth only

What you seeWhat to try
Consent does not finishComplete 2FA on the consent screen; do not skip the in-app approval step
ChatGPT cannot connectConfirm the MCP URL is for the correct company; reconnect from Integrations or App Connect
Redirect or registration errorsRedirect URI must match the MCP client exactly (copy from ChatGPT, do not type from memory)
Connection still listed but client failsDelete the OAuth connection and go through consent again

For API error details while building an integration, use the API documentation in the context of your own test company — not production credentials.

Where to go next

Accounting API integration should make operations faster without weakening financial control. Use API credentials for the integrations you run; use OAuth only when an MCP client asks you to connect through a browser.

# accounting # accounting-api # accounting-software # api # integrations # smb # small-business # automation # oauth # oauth2 # app-connect # newledger # mcp # operations
Start the conversation

Choose your next step

Start your 14-day trial for day-to-day accounting, or review pricing, migration, controls, and rollout before changing systems. Either way, the next step should feel clear.

Integration-Ready Delivery
Audit-Ready Controls
Sandbox And Guided Rollout
We use cookies to improve your experience. Manage preferences or accept all.
We use cookies to improve your experience. Manage preferences or accept all.