LendKey Payments API

Payment and remittance processing

Operations 1

POST /v1/createPayment Create Payment #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/lendkey-payments-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

lendkey-payments-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Treasury Management API (via Kong Gateway) Payments API
  version: v1
  description: "# Treasury Management API - Kong Gateway Documentation\n\n## Overview\n\nThe Treasury Management API provides endpoints for managing loan inventory, disbursements, payments, and treasury operations.\nThis API is accessed through Kong Gateway, which handles authentication via OAuth2.\n\n## Authentication\n\nAll requests to this API require OAuth2 authentication through Kong Gateway.\n\n### Step 1: Get OAuth2 Token\n\nBefore calling any endpoint, you must obtain an access token:\n\n**QA Environment:**\n```bash\ncurl -X POST https://api.lkeyqa.com/TreasuryMgmtQa/oauth2/token \\\n  -d \"grant_type=client_credentials\" \\\n  -d \"client_id=YOUR_CLIENT_ID\" \\\n  -d \"client_secret=YOUR_CLIENT_SECRET\"\n```\n\n**DEV Environment:**\n```bash\ncurl -X POST https://api.lkeyqa.com/TreasuryMgmtDev/oauth2/token \\\n  -d \"grant_type=client_credentials\" \\\n  -d \"client_id=YOUR_CLIENT_ID\" \\\n  -d \"client_secret=YOUR_CLIENT_SECRET\"\n```\n\n**Staging Environment:**\n```bash\ncurl -X POST https://api.lkeystaging.com/TreasuryMgmt/oauth2/token \\\n  -d \"grant_type=client_credentials\" \\\n  -d \"client_id=YOUR_CLIENT_ID\" \\\n  -d \"client_secret=YOUR_CLIENT_SECRET\"\n```\n\n**Production Environment:**\n```bash\ncurl -X POST https://api.lendkey.com/TreasuryMgmt/oauth2/token \\\n  -d \"grant_type=client_credentials\" \\\n  -d \"client_id=YOUR_CLIENT_ID\" \\\n  -d \"client_secret=YOUR_CLIENT_SECRET\"\n```\n\n**Response:**\n```json\n{\n  \"access_token\": \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...\",\n  \"token_type\": \"bearer\",\n  \"expires_in\": 7200\n}\n```\n\n### Step 2: Use Token in API Calls\n\nInclude the access token in the `Authorization` header:\n```\nAuthorization: Bearer YOUR_ACCESS_TOKEN\n```\n\n**Token Lifetime:** 2 hours (7200 seconds)\n\n## Base URLs (Kong Gateway)\n\n| Environment | Kong Base URL | Backend OutSystems URL |\n|------------|---------------|------------------------|\n| **DEV** | `https://api.lkeyqa.com/TreasuryMgmtDev` | `https://lendkey-dev.outsystemsenterprise.com` |\n| **QA** | `https://api.lkeyqa.com/TreasuryMgmtQa` | `https://os.lkeyqa.com` |\n| **Staging** | `https://api.lkeystaging.com/TreasuryMgmt` | `https://os.lkeystaging.com` |\n| **Production** | `https://api.lendkey.com/TreasuryMgmt` | `https://os.lendkey.com` |\n\n**Note:** Route names are case-insensitive (`/TreasuryMgmt`, `/treasurymgmt`, `/TREASURYMGMT` all work)\n\n## How Kong Routes Requests\n\nWhen you call Kong:\n```\nhttps://api.lkeyqa.com/TreasuryMgmtQa/v1/createLoan\n```\n\nKong:\n1. Validates your OAuth2 token\n2. Strips the `/TreasuryMgmtQa` prefix\n3. Adds OutSystems authentication headers (X-Auth-Key, X-Auth-AppId)\n4. Forwards to: `https://os.lkeyqa.com/TreasuryManagement_API/rest/v1/createLoan`\n\nYou never need to manage OutSystems credentials directly!\n\n## Getting Started\n\n1. **Get Credentials:** Contact your Kong admin or use the Kong Developer Portal\n2. **Get Token:** Use the OAuth2 token endpoint for your environment\n3. **Call API:** Use the token in the Authorization header\n4. **Refresh:** Get a new token every 2 hours\n"
  contact:
    name: LendKey Platform Team
    url: https://lendkey.com
servers:
- url: https://api.lendkey.com/TreasuryMgmt
  description: Production Environment
security:
- oauth2: []
tags:
- name: Payments
  description: Payment and remittance processing
paths:
  /v1/createPayment:
    post:
      summary: Create Payment
      description: 'Inserts payment/remittance data for loan obligations.


        Use this endpoint to record payments made against loans, including:

        - Interest payments

        - Principal payments

        - Late fees

        - Other charges


        **Kong Route:** `/v1/createPayment`

        **Backend:** `/TreasuryManagement_API/rest/v1/createPayment`

        '
      tags:
      - Payments
      operationId: createPayment
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreatePaymentRequest'
            examples:
              principalPayment:
                summary: Principal payment
                value:
                  subledgerCategory: Payment
                  isSubledgerReversal: false
                  subledgerItemCode: PRINCIPAL
                  paymentId: PMT-2025-001
                  payorEntityType: Borrower
                  amount: 1000.0
                  loanExternalId: LOAN-12345
                  purpose: Monthly principal payment
              interestPayment:
                summary: Interest payment
                value:
                  subledgerCategory: Payment
                  isSubledgerReversal: false
                  subledgerItemCode: INTEREST
                  paymentId: PMT-2025-002
                  payorEntityType: Borrower
                  amount: 150.0
                  loanExternalId: LOAN-12345
                  purpose: Monthly interest payment
              lateFeePayment:
                summary: Late fee payment
                value:
                  subledgerCategory: Payment
                  isSubledgerReversal: false
                  subledgerItemCode: Late Fee
                  paymentId: PMT-2025-003
                  payorEntityType: Borrower
                  amount: 25.0
                  loanExternalId: LOAN-12345
                  purpose: Late payment fee
      responses:
        '200':
          description: Payment successfully created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreatePaymentResponse'
        '207':
          description: Multi-status (partial success)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreatePaymentResponse'
        '400':
          description: Bad request (validation errors)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized (invalid or expired token)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    CreatePaymentResponse:
      type: object
      properties:
        isSuccess:
          type: boolean
          description: Overall success indicator
          example: true
        statusCode:
          type: integer
          description: HTTP status code (200, 207, 400, 500)
          example: 200
        responseDetails:
          type: array
          items:
            type: object
            properties:
              paymentId:
                type: string
                description: Payment identifier
                example: PMT-2025-001
              errors:
                type: array
                description: Array of error messages (if any)
                items:
                  type: string
    CreatePaymentRequest:
      type: object
      required:
      - subledgerCategory
      - isSubledgerReversal
      - subledgerItemCode
      - paymentId
      - payorEntityType
      - amount
      - loanExternalId
      properties:
        subledgerCategory:
          type: string
          enum:
          - Payment
          description: Subledger category (must be "Payment")
          example: Payment
        isSubledgerReversal:
          type: boolean
          description: Whether this is a reversal transaction
          example: false
        subledgerItemCode:
          type: string
          enum:
          - INTEREST
          - PRINCIPAL
          - Late Fee
          - NSF Fee
          - Other
          description: Type of payment
          example: PRINCIPAL
        paymentId:
          type: string
          description: Unique payment identifier
          example: PMT-2025-001
        payorEntityType:
          type: string
          description: Type of entity making payment (e.g., Borrower)
          example: Borrower
        amount:
          type: number
          format: double
          description: Payment amount
          example: 1000.0
        loanExternalId:
          type: string
          description: External loan identifier
          example: LOAN-12345
        purpose:
          type: string
          description: Optional payment purpose/description
          example: Monthly principal payment
    ErrorResponse:
      type: object
      properties:
        isSuccess:
          type: boolean
          description: Success indicator (always false for errors)
          example: false
        statusCode:
          type: integer
          description: HTTP status code
          example: 400
        error:
          type: string
          description: Error message
          example: Invalid request
        errors:
          type: array
          description: Detailed error messages
          items:
            type: string
          example:
          - Field 'loanUUID' is required
          - Field 'amount' must be greater than 0
  securitySchemes:
    oauth2:
      type: oauth2
      description: OAuth2 client credentials flow via Kong Gateway
      flows:
        clientCredentials:
          tokenUrl: /oauth2/token
          scopes: {}