Back to Home

Documentation

Everything you need to integrate with OpenCredit, understand our algorithms, and build on our platform. Our documentation is open-source and community-maintained.

Last updated: November 2025Edit on GitHub

Quick Start

Get started with OpenCredit in just a few steps. This guide will help you make your first credit score request.

1Install the SDK
npm install @open-credit/sdk
2Initialize the Client
import { OpenCredit } from '@opencredit/sdk';

const client = new OpenCredit({
  apiKey: process.env.OPENCREDIT_API_KEY,
  environment: 'sandbox', // or 'production'
});
3Request a Credit Score
const score = await client.scoring.calculate({
  merchantId: 'merchant_123',
  upiId: 'merchant@upi',
  consentToken: 'consent_token_from_aa',
});

console.log(score);
// { score: 72, category: 'good', factors: [...] }

Note: You'll need API credentials to make requests. Sign up at github.com/open-credit to get started with the sandbox environment.

API Reference

Complete API documentation is available on GitHub. Our API follows REST conventions and returns JSON responses.

REST API

Full REST API documentation with request/response examples.

View API Docs

SDK Reference

JavaScript/TypeScript SDK with full type definitions.

View SDK Docs

Data Models

Understanding the data structures used in OpenCredit.

interface CreditScore {
  score: number;           // 0-100
  category: 'excellent' | 'good' | 'fair' | 'poor';
  calculatedAt: string;    // ISO timestamp
  validUntil: string;      // ISO timestamp
  factors: ScoringFactor[];
  merchantId: string;
  version: string;         // Algorithm version
}

interface ScoringFactor {
  name: string;
  weight: number;          // Percentage weight
  score: number;           // Factor score (0-100)
  description: string;
  improvementTips?: string[];
}

Security

Data Protection

  • AES-256 encryption at rest
  • TLS 1.3 for all data in transit
  • DPDP Act 2023 compliant
  • Data localization in India

Authentication

  • API key authentication
  • OAuth 2.0 for user flows
  • Rate limiting per API key
  • IP allowlisting available

Documentation Coming Soon

We're actively building out our documentation. In the meantime, check out our GitHub repositories or join our Discord community for help.