OkCredit: Ledger, UPI, Billing icon

OkCredit merchant ledger and UPI collection API

OkCredit Technologies Pvt. Ltd. · Business

OkCredit: Ledger, UPI, Billing is the Android digital khata from Bengaluru-based OkCredit Technologies Pvt. Ltd., built for Indian kirana shops, wholesalers and other MSMEs who still keep customer udhaar and supplier payables in a paper bahi. Merchants sign in with a mobile OTP, then run a home due list of customers, per-party credit books with give/take entries and receipt photos, WhatsApp or SMS reminders, UPI collection links and QR, a supplier-credit tab, an account-statement PDF, a shop profile with UPI VPA, and an optional app lock. Books are kept offline-first in a local store, so adding a party or a transaction works without a network and syncs to the cloud once the phone is back online. The UI ships in English plus Indian languages including Hindi, Marathi, Gujarati, Punjabi, Tamil, Telugu, Kannada, Malayalam and Bengali. It sits in the same MSME credit-book niche as Khatabook, Vyapar and myBillBook, aimed at owners who want a phone-sized ledger rather than a desktop Tally setup.

Customer khata rows pin balanceV2 and lastPayment on each party, with give/take lines carrying amountV2, billDate and an optional collectionId when the entry came from a collect. Collection objects add payment_link, amount_requested versus amount_collected, a UPI UTR, and the merchant payment_address used for settlement; supplier credit repeats the pattern with balance, payment and bill_date.

Working-capital underwriters age udhaar from those balances, payments ops reconcile collection UTRs to the active VPA, distributors close supplier payables against the shop's own entries, and accountants archive the statement reportUrl. openData Studio turns that surface into callable open data.

Screenshots

  • OkCredit: Ledger, UPI, Billing screenshot 1
  • OkCredit: Ledger, UPI, Billing screenshot 2
  • OkCredit: Ledger, UPI, Billing screenshot 3
  • OkCredit: Ledger, UPI, Billing screenshot 4
  • OkCredit: Ledger, UPI, Billing screenshot 5
  • OkCredit: Ledger, UPI, Billing screenshot 6
  • OkCredit: Ledger, UPI, Billing screenshot 7
  • OkCredit: Ledger, UPI, Billing screenshot 8

API surface

The endpoints and request/response examples below are reconstructed from the app's interface — illustrative, not a live capture.

  • Request merchant login OTP

    POST /v1/khata-login/otp-send osint

    Starts the merchant OTP login used by the Enter OTP screen. Returns otp_id (and optional otp_key) that later calls attach when verifying the code.

    Auth: Unauthenticated bootstrap. Body carries mode and the merchant mobile; the response otp_id is used on verify and then on POST /v1/khata-login/token-exchange.

    • mode
    • mobile
    • otp_id
    • otp
    • otp_key
    POST /v1/khata-login/otp-send HTTP/1.1
    Content-Type: application/json
    
    {
      "mode": "SMS",
      "mobile": "9876543210"
    }
    {
      "otp_id": "otp_7c11ab",
      "otp": null,
      "otp_key": "ok_9f2a"
    }
  • Authenticate and mint access token

    POST /v1/khata-login/token-exchange osint

    Opens the signed-in merchant session. access_token is the Bearer value attached to every later ledger, payment, payable and reward request.

    Auth: Unauthenticated bootstrap. Body grant_type plus username/password, refresh_token, or assertion; the response access_token is sent as Authorization: Bearer on later ledger, payment, payable and reward calls.

    • grant_type
    • username
    • password
    • refresh_token
    • assertion
    • access_token
    • expires_in
    • new_user
    • mobile
    POST /v1/khata-login/token-exchange HTTP/1.1
    Content-Type: application/json
    
    {
      "grant_type": "password",
      "username": "9876543210",
      "password": "••••••••",
      "refresh_token": null,
      "assertion": null
    }
    {
      "access_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.example",
      "refresh_token": "rt_7c11ab",
      "expires_in": 3600,
      "new_user": false,
      "mobile": "9876543210"
    }
  • Read signed-in merchant profile

    GET /v1/shop/profile osint

    Returns the shop card shown on Profile: merchant id, contact name, mobile, address with lat/long, about text and profile image.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • id
    • name
    • conatctName
    • mobile
    • email
    • address
    • addressLatitude
    • addressLongitude
    • about
    • profileImage
    • createdAt
    GET /v1/shop/profile HTTP/1.1
    Authorization: Bearer <access_token>
    {
      "id": "mrc_9f2a",
      "name": "Ramesh Kirana",
      "conatctName": "Ramesh Patel",
      "mobile": "9876543210",
      "email": "[email protected]",
      "address": "12 MG Road, Pune",
      "addressLatitude": 18.5204,
      "addressLongitude": 73.8567,
      "about": "Daily grocery and provisions",
      "profileImage": "https://files.example.com/receipts/mrc_9f2a.jpg",
      "createdAt": "2024-03-12T08:10:00.000Z"
    }
  • List customer khata parties

    GET /v1/ledger/parties openfinance

    Pages the home customer list: per-party description, paise-scale balanceV2, lastPayment, reminderMode and whether txn alerts are on.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange. Query mobile filters by phone; deleted includes deactivated parties.

    • id
    • userId
    • mobile
    • description
    • balance
    • balanceV2
    • transactionCount
    • lastActivity
    • lastPayment
    • accountUrl
    • reminderMode
    • txnAlertEnabled
    • lang
    • registered
    • status
    GET /v1/ledger/parties?mobile=&deleted=false HTTP/1.1
    Authorization: Bearer <access_token>
    [
      {
        "id": "cust_11ab",
        "userId": "usr_7c11",
        "mobile": "9123456780",
        "description": "Suresh Provision",
        "balance": -2450.0,
        "balanceV2": -245000,
        "transactionCount": 18,
        "lastActivity": "2026-10-18T11:04:00.000Z",
        "lastPayment": "2026-10-12T09:22:00.000Z",
        "accountUrl": "https://khata.example.com/p/cust_11ab",
        "profileImage": null,
        "address": "Lane 4, Camp, Pune",
        "email": null,
        "registered": true,
        "txnAlertEnabled": true,
        "lang": "hi",
        "reminderMode": "whatsapp",
        "status": 1,
        "txnStartTime": 1710230400000,
        "createdAt": "2024-03-12T08:20:00.000Z",
        "updatedAt": "2026-10-18T11:04:00.000Z"
      }
    ]
  • Read one customer khata

    GET /v1/ledger/parties/{party_id} openfinance

    Loads the customer profile and statement header: outstanding balanceV2, lastPayment, reminderMode and the shareable accountUrl.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange. Path party_id is the customer opened on the customer screen.

    • id
    • mobile
    • description
    • balanceV2
    • transactionCount
    • lastPayment
    • accountUrl
    • address
    • reminderMode
    • txnAlertEnabled
    GET /v1/ledger/parties/cust_11ab HTTP/1.1
    Authorization: Bearer <access_token>
    {
      "id": "cust_11ab",
      "userId": "usr_7c11",
      "mobile": "9123456780",
      "description": "Suresh Provision",
      "balance": -2450.0,
      "balanceV2": -245000,
      "transactionCount": 18,
      "lastActivity": "2026-10-18T11:04:00.000Z",
      "lastPayment": "2026-10-12T09:22:00.000Z",
      "accountUrl": "https://khata.example.com/p/cust_11ab",
      "profileImage": null,
      "address": "Lane 4, Camp, Pune",
      "email": null,
      "registered": true,
      "txnAlertEnabled": true,
      "lang": "hi",
      "reminderMode": "whatsapp",
      "status": 1,
      "createdAt": "2024-03-12T08:20:00.000Z",
      "updatedAt": "2026-10-18T11:04:00.000Z"
    }
  • Add a customer party

    POST /v1/ledger/parties opendata

    Creates (or reactivates) a customer on the Add Customer screen from mobile, display name and optional profile image.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • mobile
    • desc
    • reactivate
    • profileImage
    • id
    • description
    • balanceV2
    • registered
    POST /v1/ledger/parties HTTP/1.1
    Authorization: Bearer <access_token>
    Content-Type: application/json
    
    {
      "mobile": "9988776655",
      "desc": "Meena Fancy Store",
      "reactivate": false,
      "profileImage": null
    }
    {
      "id": "cust_22cd",
      "mobile": "9988776655",
      "description": "Meena Fancy Store",
      "balanceV2": 0,
      "transactionCount": 0,
      "registered": false,
      "status": 1,
      "createdAt": "2026-10-20T06:40:00.000Z"
    }
  • List customer ledger transactions

    GET /v1/ledger/entries openfinance

    Returns give/take rows for a customer statement: paise amountV2, type, note, receiptUrl and optional collectionId when the entry came from a UPI collect.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange. Query customer_id plus after/before epoch windows used by statement sync.

    • id
    • customerId
    • amount
    • amountV2
    • type
    • note
    • receiptUrl
    • collectionId
    • billDate
    • createdByCustomer
    • isDeleted
    GET /v1/ledger/entries?customer_id=cust_11ab&after=1727740800000&before=1761004799000 HTTP/1.1
    Authorization: Bearer <access_token>
    [
      {
        "id": "txn_88ef",
        "customerId": "cust_11ab",
        "amount": 500.0,
        "amountV2": 50000,
        "type": 1,
        "note": "Rice 10kg",
        "receiptUrl": "https://files.example.com/receipts/txn_88ef.jpg",
        "collectionId": null,
        "billDate": "2026-10-18T00:00:00.000Z",
        "createdAt": "2026-10-18T11:04:00.000Z",
        "updatedAt": "2026-10-18T11:04:00.000Z",
        "createdByCustomer": false,
        "isDeleted": false,
        "deletedByCustomer": false,
        "isOnboarding": false
      }
    ]
  • Post a give or take entry

    POST /v1/ledger/entries openfinance

    Writes a credit or payment from the Add Transaction screen. requestId is the idempotency key; smsSent records whether a reminder SMS went out.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • customerId
    • requestId
    • type
    • amountV2
    • receiptUrl
    • note
    • timestamp
    • isOnboarding
    • billDate
    • smsSent
    POST /v1/ledger/entries HTTP/1.1
    Authorization: Bearer <access_token>
    Content-Type: application/json
    
    {
      "customerId": "cust_11ab",
      "requestId": "req_3a91",
      "type": 1,
      "amountV2": 50000,
      "receiptUrl": "https://files.example.com/receipts/txn_new.jpg",
      "note": "Rice 10kg",
      "timestamp": "2026-10-18T11:04:00.000Z",
      "isOnboarding": false,
      "billDate": "2026-10-18T00:00:00.000Z",
      "smsSent": true
    }
  • Generate account-statement PDF

    GET /v1/ledger/statements/pdf opendata

    Builds the merchant-wide account statement PDF shared from the Account Statement screen and returns a signed reportUrl.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange. Query after/before bound the statement window.

    • after
    • before
    • reportUrl
    GET /v1/ledger/statements/pdf?after=1727740800000&before=1761004799000 HTTP/1.1
    Authorization: Bearer <access_token>
    {
      "reportUrl": "https://files.example.com/receipts/AccountStatement_mrc_9f2a_2026-10.pdf"
    }
  • List UPI collection requests

    GET /v1/payments/requests openbanking

    Lists collection-history rows: requested vs collected paise, payment_link, UPI UTR and the merchant payout destination.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange. Query customer_id scopes to one party; after is a cursor.

    • id
    • status
    • payment_link
    • amount_requested
    • amount_collected
    • fee
    • customer_id
    • UTR
    • payment_address
    • settlement_category
    GET /v1/payments/requests?customer_id=cust_11ab&after=1727740800000 HTTP/1.1
    Authorization: Bearer <access_token>
    [
      {
        "id": "col_55aa",
        "create_time": "2026-10-12T09:20:00.000Z",
        "update_time": "2026-10-12T09:22:10.000Z",
        "status": 2,
        "payment_link": "https://pay.example.com/c/col_55aa",
        "amount_requested": 245000,
        "amount_collected": 245000,
        "fee": 0,
        "expire_time": "2026-10-19T09:20:00.000Z",
        "customer_id": "cust_11ab",
        "discount": 0,
        "fee_category": 0,
        "settlement_category": 1,
        "merchantName": "Ramesh Kirana",
        "payment": {
          "provider": "upi",
          "id": "pay_91bb",
          "UTR": "AXSK261012091234",
          "reference": "col_55aa",
          "status": 2,
          "amount": 245000,
          "payment_link": "https://pay.example.com/c/col_55aa"
        },
        "payout": {
          "provider": "upi",
          "id": "po_12cc",
          "UTR": "HDFC261012091300",
          "status": 2,
          "amount": 245000,
          "destination": {
            "mobile": "9876543210",
            "name": "Ramesh Patel",
            "payment_address": "ramesh@okaxis",
            "type": "UPI"
          }
        }
      }
    ]
  • Create collection payment links

    POST /v1/payments/requests/batch openbanking

    Mints UPI collection links for one or more due customers from the Collections screen so the merchant can share a payment_link or QR.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • merchant_id
    • customer_id
    • id
    • status
    • payment_link
    • amount_requested
    • merchantName
    POST /v1/payments/requests/batch HTTP/1.1
    Authorization: Bearer <access_token>
    Content-Type: application/json
    
    {
      "merchant_id": "mrc_9f2a",
      "requests": [
        {"customer_id": "cust_11ab"},
        {"customer_id": "cust_22cd"}
      ]
    }
    [
      {
        "id": "col_55aa",
        "status": 1,
        "payment_link": "https://pay.example.com/c/col_55aa",
        "amount_requested": 245000,
        "amount_collected": null,
        "customer_id": "cust_11ab",
        "merchantName": "Ramesh Kirana"
      }
    ]
  • Read merchant UPI collection profile

    POST /v1/payments/profile openbanking

    Returns the active UPI destination (payment_address, type) plus per-customer WhatsApp message_link, payment link_intent and qr_intent used on the Collections UPI screens.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • merchant_id
    • payment_address
    • type
    • customer_id
    • message_link
    • message
    • link_intent
    • qr_intent
    • show_image
    POST /v1/payments/profile HTTP/1.1
    Authorization: Bearer <access_token>
    Content-Type: application/json
    
    {
      "merchant_id": "mrc_9f2a"
    }
    {
      "merchant_id": "mrc_9f2a",
      "destination": {
        "mobile": "9876543210",
        "name": "Ramesh Patel",
        "payment_address": "ramesh@okaxis",
        "type": "UPI"
      },
      "customers": [
        {
          "customer_id": "cust_11ab",
          "profile": {
            "customer_id": "cust_11ab",
            "message_link": "https://chat.example.com/send?to=919123456780",
            "message": "Namaste, aapka 2450 pending hai",
            "link_intent": "https://pay.example.com/c/col_55aa",
            "qr_intent": "upi://pay?pa=ramesh@okaxis&am=2450",
            "show_image": true
          }
        }
      ]
    }
  • Validate a UPI payment address

    POST /v1/payments/address/check openbanking

    Checks a VPA typed on Add/Edit UPI before it is saved as the payout destination. valid plus the registered name are shown on the confirmation sheet.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • payment_address_type
    • payment_address
    • valid
    • name
    POST /v1/payments/address/check HTTP/1.1
    Authorization: Bearer <access_token>
    Content-Type: application/json
    
    {
      "payment_address_type": "UPI",
      "payment_address": "ramesh@okaxis"
    }
    {
      "valid": true,
      "name": "RAMESH PATEL"
    }
  • List supplier credit parties

    GET /v1/payables/vendors openfinance

    Returns supplier-credit parties for the Due Supplier tab: name, mobile, paise balance owed, and txn_alert_enabled.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • id
    • name
    • mobile
    • address
    • balance
    • registered
    • deleted
    • txn_alert_enabled
    • lang
    • create_time
    GET /v1/payables/vendors HTTP/1.1
    Authorization: Bearer <access_token>
    {
      "suppliers": [
        {
          "id": "sup_44ee",
          "registered": true,
          "deleted": false,
          "name": "Patel Distributors",
          "create_time": "2024-06-01T10:00:00.000Z",
          "txn_start_time": 1717200000000,
          "mobile": "9811122233",
          "address": "Market Yard, Pune",
          "profile_image": null,
          "balance": 1800000,
          "txn_alert_enabled": true,
          "lang": "en"
        }
      ]
    }
  • List supplier-credit transactions

    GET /v1/payables/entries openfinance

    Pages supplier give/take rows: payment flag, paise amount, bill_date, receipt_url and whether the supplier created the entry.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange. Query start_time/end_time bound the supplier statement window.

    • id
    • supplier_id
    • collection_id
    • payment
    • amount
    • note
    • receipt_url
    • bill_date
    • created_by_supplier
    • deleted
    GET /v1/payables/entries?start_time=2026-09-01T00:00:00.000Z&end_time=2026-10-20T23:59:59.000Z HTTP/1.1
    Authorization: Bearer <access_token>
    {
      "transactions": [
        {
          "id": "stxn_77aa",
          "supplier_id": "sup_44ee",
          "collection_id": null,
          "payment": true,
          "amount": 500000,
          "note": "Week 41 stock",
          "receipt_url": "https://files.example.com/receipts/stxn_77aa.jpg",
          "bill_date": "2026-10-10T00:00:00.000Z",
          "create_time": "2026-10-10T16:02:00.000Z",
          "created_by_supplier": false,
          "deleted": false,
          "deleted_by_supplier": false,
          "update_time": "2026-10-10T16:02:00.000Z"
        }
      ]
    }
  • List merchant collection rewards

    POST /v1/incentives/search opendata

    Lists collection-campaign rewards shown on the Rewards screen: paise amount, reward_type, status and the UPI payout destination used on claim.

    Auth: Authorization: Bearer <access_token> from POST /v1/khata-login/token-exchange.

    • merchant_id
    • id
    • status
    • amount
    • reward_type
    • create_time
    • payment_address
    POST /v1/incentives/search HTTP/1.1
    Authorization: Bearer <access_token>
    Content-Type: application/json
    
    {
      "merchant_id": "mrc_9f2a"
    }
    {
      "rewards": [
        {
          "id": "rwd_01",
          "create_time": "2026-10-01T08:00:00.000Z",
          "update_time": "2026-10-15T08:00:00.000Z",
          "status": 1,
          "amount": 10000,
          "reward_type": "collection",
          "payout": {
            "destination": {
              "payment_address": "ramesh@okaxis",
              "type": "UPI"
            }
          },
          "events": []
        }
      ]
    }

Data categories

  • merchant profiles
  • customer ledgers
  • transactions
  • UPI collections
  • supplier credit
  • account statements
  • rewards

Where teams use this data

  • MSME udhaar aging for working-capital underwriting

    A lender or B2B BNPL stack pulls each party's balanceV2, lastPayment and transactionCount, then pages amountV2 rows by billDate to build days-past-due buckets without asking the shop to export a spreadsheet.

  • UPI collection reconciliation

    A payments ops bot lists collection requests, matches payment.UTR and amount_collected to the merchant payment_address payout, and flags links that expired before amount_collected landed.

  • Supplier payable close for distributors

    An ERP syncs sc/suppliers balance with sc/transactions payment/amount/bill_date so a distributor can see what the kirana still owes versus what the shop recorded as a payment.

  • Accountant statement drop

    A CA practice fetches reportUrl for the after/before window and archives the account-statement PDF beside the live customer and supplier ledgers.

Frequently asked questions

How does OkCredit authenticate merchants?

The merchant enters a mobile number and the app requests an OTP (mode plus mobile), for example via POST /v1/khata-login/otp-send, then exchanges the verified code for an access_token at POST /v1/khata-login/token-exchange. Later ledger, payment, payable and reward calls send Authorization: Bearer with that token.

Which fields hold a customer's outstanding balance?

The customer list and single-customer reads return balance (legacy float) and balanceV2 (paise-scale long), plus lastPayment, transactionCount and reminderMode for the home due list; for example GET /v1/ledger/parties and GET /v1/ledger/parties/{party_id}.

How are UPI collections represented?

Each collection carries a payment_link, amount_requested, amount_collected, fee and a nested payment.UTR, and can be listed or minted in batches for several due customers. A separate merchant profile read returns the active destination.payment_address (UPI VPA) and per-customer qr_intent / link_intent, for example under /v1/payments.

How is supplier credit modelled next to the customer khata?

Supplier parties and their give/take rows sit alongside the customer ledger, for example GET /v1/payables/vendors and GET /v1/payables/entries, with balance, payment, amount and bill_date, under the same Bearer token as the customer khata and collection calls.

Apps similar to OkCredit: Ledger, UPI, Billing

  • Khatabook — Khatabook is a Bengaluru fintech digital ledger for Indian kirana shops and other MSMEs that records money owed to the merchant in place of a paper accounts book, and Inc42 names it as a direct OkCredit competitor.
  • Vyapar Invoice GST Billing App — Vyapar is GST billing, accounting and inventory software for Indian small businesses, with tax invoices, e-invoicing, e-way bills, stock tracking and payment reminders on phone and desktop.
  • myBillBook Invoice Billing App — myBillBook is GST billing software for Indian small businesses that creates GST and non-GST invoices with HSN/SAC codes, tracks inventory, and sends WhatsApp or SMS payment reminders with UPI links.
  • TallyPrime — TallyPrime is Tally Solutions' business-management software for Indian firms, covering invoicing, books, GST returns and e-invoicing, inventory and connected banking in a desktop-first setup.
  • Zoho Books — Zoho Books is Zoho's GST-compliant cloud accounting product for Indian businesses, covering invoices, e-invoicing, e-way bills, inventory, banking and GST filing from web and mobile apps.
  • Swipe — Swipe is a GST billing, POS and inventory app for Indian SMEs that creates GST and non-GST invoices, shares bills on WhatsApp, collects via UPI or payment links, and files e-invoices and e-way bills.
  • BUSY — BUSY is GST billing and accounting software for Indian MSMEs, with a mobile app that creates parties, quotations, orders and invoices and syncs them with BUSY desktop books.

Topics

  • OkCredit API
  • digital khata
  • customer ledger
  • UPI collection
  • supplier credit
  • balanceV2
  • payment_address
  • MSME udhaar

Need this app's data API integrated?

We deliver scoped integrations for any named app — from USD 500 with source-code handoff, or hosted access billed per call. Tell us the data you need.

  • NDA + SOW on every engagement
  • Delivery in 3–7 days
  • Payment only after acceptance
  • Work scoped to authorized use

Get a quote