Onramp Funds Partner API (1.0.0)

Download OpenAPI specification:

Overview

The Onramp Funds Partner API enables partners to submit referrals for business funding and receive prequalification amounts. This REST API uses JWT authentication and provides a streamlined workflow for processing funding applications.

Who Is This API For?

This API is designed for Onramp partners who want to:

  • Submit seller referrals programmatically
  • Receive instant prequalification amounts
  • Integrate Onramp funding into their platform

Getting Started

Prerequisites

Before using the API, you need:

  1. Partner Account - Register with Onramp Funds as a partner
  2. API Credentials - You'll receive a client_id and client_secret
  3. HTTPS Support - All API calls must be made over HTTPS

Base URL

https://app.onrampfunds.com/

Authentication

The API uses JWT (JSON Web Token) authentication. You must obtain a token before making API calls.

How Authentication Works

  1. Obtain Credentials - Receive your client_id and client_secret from Onramp
  2. Generate Token - Use the /partners/api/tokens endpoint to get a JWT token
  3. Use Token - Include the token in the Authorization header for subsequent requests

Token Generation Example

curl -X POST https://app.onrampfunds.com/partners/api/tokens \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "YOUR_CLIENT_ID",
    "client_secret": "YOUR_CLIENT_SECRET"
  }'

Response:

{
  "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}

Using Your Token

Include the token in the Authorization header for authenticated endpoints:

Authorization: Bearer YOUR_JWT_TOKEN

Important: Store your credentials securely. Never expose them in client-side code or public repositories.


API Workflow

Step-by-Step Guide

Step 1: Generate Authentication Token

Make a POST request to /partners/api/tokens with your credentials.

Step 2: Create a Referral

Submit referral details to /partners/api/referrals with the following information:

  • Seller email and business details
  • Legal entity information
  • Platform sales data (e.g., Shopify, Amazon)
  • Optional: Additional business details for enhanced prequalification

Step 3: Receive Prequalification

The API responds with:

  • Prequalified funding amount
  • Correlation ID for tracking
  • Referral URL for the seller
  • Submitted referral details

Complete Example

# Step 1: Get token
TOKEN=$(curl -X POST https://app.onrampfunds.com/partners/api/tokens \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "YOUR_CLIENT_ID",
    "client_secret": "YOUR_CLIENT_SECRET"
  }' | jq -r '.token')

# Step 2: Create referral (minimal example)
curl -X POST https://app.onrampfunds.com/partners/api/referrals \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $TOKEN" \
  -d '{
    "seller_email": "seller@example.com",
    "business_name": "Example Business Inc",
    "seller_tenure_months": "24",
    "legal_entity": "llc",
    "incorporation_state": "CA",
    "platforms": [{
      "type": "shopify",
      "seller_id": "shop_12345",
      "sales": {
        "90_days": 45000.00,
        "180_days": 85000.00
      }
    }]
  }'

Response:

{
  "business_name": "Example Business Inc",
  "legal_entity": "llc",
  "incorporation_state": "CA",
  "prequalified_amount": 15000.00,
  "referral_url": "https://app.onrampfunds.com/partners/referrals/...",
  "correlation_id": "065a417b-ce17-4c64-b8dd-e35a3128a021"
}

Using the Referral URL

Once you receive the response, you need to direct the seller to the referral_url to complete their funding application. You can do this in two ways:

Option 1: Redirect the User

// Redirect the user immediately after receiving the response
window.location.href = response.referral_url;

Option 2: Provide a Link

<!-- Display a link for the user to click -->
<a href="https://app.onrampfunds.com/partners/referrals/...">
  Continue to complete your funding application
</a>

The referral URL is a unique, personalized link for each seller that:

  • Contains their pre-filled information
  • Shows their prequalified amount
  • Guides them through the funding application process
  • Tracks the referral back to your partner account

Required vs Optional Fields

Minimum Required Fields

To create a referral, you only need to provide:

  • seller_email - The seller's email address

For more accurate prequalification amounts, include:

  • business_name - Business name
  • seller_tenure_months - How long the business has been operating
  • legal_entity - Legal structure (sole_proprietorship, partnership, corporation, llc)
  • incorporation_state - State of incorporation
  • platforms - Sales data from e-commerce platforms

Enhanced Fields

For the most comprehensive prequalification and faster processing, consider including:

  • Business identification (EIN, registered business name, SOS filing number)
  • Operating and mailing addresses
  • Controller information (title, DOB, identification)
  • Industry classification
  • Desired funding amount and planned use of funds

Sales Data Format

The sales field in platform objects accepts flexible time periods:

  • Aggregate periods: 90_days, 180_days
  • Monthly data: Use YYYYMM format (e.g., "202401" for January 2024)

Example:

"sales": {
  "90_days": 45000.00,
  "180_days": 85000.00,
  "202401": 12000.00,
  "202402": 15000.00,
  "202403": 18000.00
}

Error Handling

The API uses standard HTTP status codes and returns detailed error information.

Common HTTP Status Codes

Status Code Meaning Action
200 Success Request processed successfully
201 Created Referral created successfully
400 Bad Request Check request format and data types
401 Unauthorized Verify credentials or token validity
422 Validation Error Review validation errors in response
500 Server Error Contact Onramp support if persists

Error Response Format

{
  "status": 422,
  "error": "validation_error",
  "message": "Validation failed",
  "errors": {
    "seller_email": ["can't be blank"],
    "legal_entity": ["is not included in the list"]
  }
}

Common Issues

401 Unauthorized

  • Token expired or invalid
  • Missing Authorization header
  • Invalid client credentials

422 Validation Error

  • Missing required fields
  • Invalid enum values (e.g., legal_entity, incorporation_state)
  • Improperly formatted data (email, SSN, EIN patterns)

Best Practices

Security

  • Store credentials securely - Use environment variables or secure vaults
  • Use HTTPS only - Never make requests over HTTP
  • Rotate secrets regularly - Contact Onramp to update credentials
  • Validate input - Sanitize data before sending to the API
  • Protect sensitive data - Handle SSNs, EINs, and personal information with care

Token Management

  • Cache tokens - Reuse tokens instead of generating new ones for each request
  • Handle expiration - Implement retry logic with token refresh on 401 errors
  • Monitor usage - Track API calls for debugging and optimization

Data Quality

  • Provide accurate sales data - More data leads to better prequalification
  • Use consistent formats - Follow the specified date and number formats
  • Include all platforms - Submit data for all relevant sales channels
  • Complete business information - More details enable faster processing

Error Recovery

  • Implement retries - Use exponential backoff for transient failures
  • Log errors - Maintain logs for troubleshooting
  • Validate before sending - Client-side validation reduces error rates

Support

For questions, issues, or to request partner credentials:

  • Technical Support - Contact your Onramp partner representative
  • Documentation - Refer to the endpoint details below

API Endpoints

Detailed documentation for each endpoint is provided below.

Generate a JWT token

Authenticates a partner and generates a JWT token using the provided client credentials.

Request Body schema: application/json
required
client_id
required
string

The client ID provided during registration.

client_secret
required
string

The client secret provided during registration.

Responses

Request samples

Content type
application/json
{
  • "client_id": "P6KgcP7wQXkbhufpCYLpiSgC",
  • "client_secret": "$2a$12$BoCljYIBQXQbNebC6d2mf.N4TIHWe5jDM6dPTzzMOLwV9tRFPBPYW"
}

Response samples

Content type
application/json
{
  • "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}

Create a new referral and prequalify them for funding

Submits new referral details to receive a prequalification amount for funding.

Authorizations:
bearerAuth
Request Body schema: application/json
required
seller_email
required
string <email>

The seller's email address.

business_name
string

The name of the business.

contact_first_name
string

The first name of the business's contact.

contact_last_name
string

The last name of the business's contact.

contact_phone_number
string

The phone number of the business's contact.

ecommerce_seller
boolean

Is the business eCommerce?

desired_amount
number

How much cash is the business looking for (if known)?

seller_tenure_months
string

The number of months the seller has been operating.

legal_entity
string
Enum: "sole_proprietorship" "partnership" "corporation" "llc"

The type of legal entity of the business.

incorporation_state
string
Enum: "AK" "AL" "AR" "AS" "AZ" "CA" "CO" "CT" "DC" "DE" "FL" "GA" "GU" "HI" "IA" "ID" "IL" "IN" "KS" "KY" "LA" "MA" "MD" "ME" "MI" "MN" "MO" "MS" "MT" "NC" "ND" "NE" "NH" "NJ" "NM" "NV" "NY" "OH" "OK" "OR" "PA" "PR" "RI" "SC" "SD" "TN" "TX" "UT" "VA" "VI" "VT" "WA" "WI" "WV" "WY"

The state where the business is incorporated. Must be a two character US state code.

planned_use_of_funds
Array of strings
Items Enum: "inventory" "marketing" "other"

What are the planned use of funds?

Array of objects
user_provided_average_monthly_sales
number

What are the average monthly sales for the business?

registered_business_name
string

The official registered business name in the Secretary of State.

ein
string^\d{2}-\d{7}$

The business's Employee Identification Number or Tax ID. Must be in format XX-XXXXXXX.

sos_filing_number
string

The Secretary of State filing number.

industry
string
Enum: "All Other General Merchandise Stores" "All Other Health and Personal Care Stores" "All Other Miscellaneous Store Retailers (except Tobacco Stores)" "All Other Specialty Food Stores" "Automotive Parts and Accessories Stores" "Beer, Wine, and Liquor Stores" "Book Stores" "Children's and Infants' Clothing Stores" "Clothing Accessories Stores" "Clothing Stores" "Cosmetics, Beauty Supplies, and Perfume Stores" "Electronics and Appliance Stores" "Electronics Stores" "Fish and Seafood Markets" "Fruit and Vegetable Markets" "Gift, Novelty, and Souvenir Stores" "Grocery Stores" "Hardware Stores" "Health and Personal Care Stores" "Hobby, Toy, and Game Stores" "Home Furnishings Stores" "Household Appliance Stores" "Jewelry Stores" "Jewelry, Luggage, and Leather Goods Stores" "Lawn and Garden Equipment and Supplies Stores" "Luggage and Leather Goods Stores" "Men's Clothing Stores" "Musical Instrument and Supplies Stores" "Nursery, Garden Center, and Farm Supply Stores" "Office Supplies, Stationery, and Gift Stores" "Optical Goods Stores" "Other Clothing Stores" "Other Miscellaneous Store Retailers" "Outdoor Power Equipment Stores" "Pet and Pet Supplies Stores" "Pharmacies and Drug Stores" "Sewing, Needlework, and Piece Goods Stores" "Shoe Stores" "Specialty Food Stores" "Sporting Goods Stores" "Tobacco Stores" "Used Merchandise Stores" "Women's Clothing Stores"

The industry where the business operates. Must be one of the valid industry values.

operating_street_address
string

The street address where the business operates.

operating_secondary_address
string

The secondary address where the business operates.

operating_city
string

The city where the business operates.

operating_state
string
Enum: "AK" "AL" "AR" "AS" "AZ" "CA" "CO" "CT" "DC" "DE" "FL" "GA" "GU" "HI" "IA" "ID" "IL" "IN" "KS" "KY" "LA" "MA" "MD" "ME" "MI" "MN" "MO" "MS" "MT" "NC" "ND" "NE" "NH" "NJ" "NM" "NV" "NY" "OH" "OK" "OR" "PA" "PR" "RI" "SC" "SD" "TN" "TX" "UT" "VA" "VI" "VT" "WA" "WI" "WV" "WY"

The state where the business operates. Must be a two character US state code.

operating_zip
string

The zip where the business operates.

mailing_street_address
string

The street address where the business receives mail, if different than the operating address.

mailing_secondary_address
string

The secondary address where the business receives mail, if different than the operating address.

mailing_city
string

The city where the business receives mail, if different than the operating address.

mailing_state
string
Enum: "AK" "AL" "AR" "AS" "AZ" "CA" "CO" "CT" "DC" "DE" "FL" "GA" "GU" "HI" "IA" "ID" "IL" "IN" "KS" "KY" "LA" "MA" "MD" "ME" "MI" "MN" "MO" "MS" "MT" "NC" "ND" "NE" "NH" "NJ" "NM" "NV" "NY" "OH" "OK" "OR" "PA" "PR" "RI" "SC" "SD" "TN" "TX" "UT" "VA" "VI" "VT" "WA" "WI" "WV" "WY"

The state where the business receives mail, if different than the operating address. Must be a two character US state code.

mailing_zip
string

The zip where the business receives mail, if different than the operating address.

controller_title
string

The controller's title.

controller_dob
string <date>

The controller's Date of Birth.

controller_ssn
string^\d{3}-\d{2}-\d{4}$

The controller's SSN, if they have one. Must be in format XXX-XX-XXXX.

controller_2_ssn
string^\d{3}-\d{2}-\d{4}$

The second controller's SSN, if they have one. Must be in format XXX-XX-XXXX.

controller_passport_number
string

The controller's Passport Number, if they do not have a SSN.

controller_passport_country
string
Value: "US"

The controller's Passport Country, if they do not have a SSN.

business_dba
string

The businesses DBA, if any.

controller_2_first_name
string

The first name of the second controller.

controller_2_last_name
string

The last name of the second controller.

controller_2_dob
string <date>

The second controller's date of birth.

controller_2_passport_number
string

The second controller's Passport Number, if they do not have a SSN.

controller_2_passport_country
string
Value: "US"

The second controller's Passport Country, if they do not have a SSN.

controller_2_street_address
string

The street address where the second controller resides.

controller_2_city
string

The city where the second controller resides.

controller_2_state
string
Enum: "AK" "AL" "AR" "AS" "AZ" "CA" "CO" "CT" "DC" "DE" "FL" "GA" "GU" "HI" "IA" "ID" "IL" "IN" "KS" "KY" "LA" "MA" "MD" "ME" "MI" "MN" "MO" "MS" "MT" "NC" "ND" "NE" "NH" "NJ" "NM" "NV" "NY" "OH" "OK" "OR" "PA" "PR" "RI" "SC" "SD" "TN" "TX" "UT" "VA" "VI" "VT" "WA" "WI" "WV" "WY"

The state where the second controller resides. Must be a two character US state code.

controller_2_zip
string

The zip where the second controller resides.

Responses

Request samples

Content type
application/json
{
  • "seller_email": "test@example.com",
  • "business_name": "Test Business",
  • "contact_first_name": "John",
  • "contact_last_name": "Doe",
  • "contact_phone_number": "3243243243",
  • "ecommerce_seller": true,
  • "desired_amount": 12500,
  • "seller_tenure_months": "12",
  • "legal_entity": "corporation",
  • "incorporation_state": "CA",
  • "planned_use_of_funds": [
    ],
  • "platforms": [
    ],
  • "user_provided_average_monthly_sales": 12500,
  • "registered_business_name": "Test Business LLC",
  • "ein": "12-3456789",
  • "sos_filing_number": "ABC123",
  • "industry": "Clothing Stores",
  • "operating_street_address": "123 Main St",
  • "operating_secondary_address": "Suite 100",
  • "operating_city": "San Francisco",
  • "operating_state": "CA",
  • "operating_zip": "94105",
  • "mailing_street_address": "456 Market St",
  • "mailing_secondary_address": "Floor 2",
  • "mailing_city": "San Francisco",
  • "mailing_state": "CA",
  • "mailing_zip": "94105",
  • "controller_title": "CEO",
  • "controller_dob": "01/01/1980",
  • "controller_ssn": "123-45-6789",
  • "controller_2_ssn": "987-65-4321",
  • "controller_passport_number": "123456789",
  • "controller_passport_country": "US",
  • "business_dba": "Test Business DBA",
  • "controller_2_first_name": "Jane",
  • "controller_2_last_name": "Smith",
  • "controller_2_dob": "02/02/1982",
  • "controller_2_passport_number": "P987654321",
  • "controller_2_passport_country": "US",
  • "controller_2_street_address": "789 Oak St",
  • "controller_2_city": "San Francisco",
  • "controller_2_state": "CA",
  • "controller_2_zip": "94105"
}

Response samples

Content type
application/json
{
  • "business_name": "Test Business",
  • "contact_first_name": "John",
  • "contact_last_name": "Doe",
  • "contact_phone_number": "3243243243",
  • "ecommerce_seller": true,
  • "desired_amount": 12500,
  • "legal_entity": "string",
  • "incorporation_state": "CA",
  • "planned_use_of_funds": [
    ],
  • "platforms": [
    ],
  • "seller_email": "test@example.com",
  • "seller_tenure_months": 60,
  • "prequalified_amount": 12500,
  • "user_provided_average_monthly_sales": 12500,
  • "controller_passport_country": "US",
  • "correlation_id": "065a417b-ce17-4c64-b8dd-e35a3128a021",
  • "registered_business_name": "Test Business LLC",
  • "ein": "12-3456789",
  • "sos_filing_number": "ABC123",
  • "industry": "Clothing Stores",
  • "operating_street_address": "123 Main St",
  • "operating_secondary_address": "Suite 100",
  • "operating_city": "San Francisco",
  • "operating_state": "CA",
  • "operating_zip": "94105",
  • "mailing_street_address": "456 Market St",
  • "mailing_secondary_address": "Floor 2",
  • "mailing_city": "San Francisco",
  • "mailing_state": "CA",
  • "mailing_zip": "94105",
  • "controller_title": "CEO",
  • "controller_dob": "01/01/1980",
  • "controller_ssn": "123-45-6789",
  • "controller_passport_number": "123456789",
  • "business_dba": "Test Business DBA",
  • "controller_2_first_name": "Jane",
  • "controller_2_last_name": "Smith",
  • "controller_2_dob": "02/02/1982",
  • "controller_2_ssn": "987-65-4321",
  • "controller_2_passport_number": "P987654321",
  • "controller_2_passport_country": "US",
  • "controller_2_street_address": "789 Oak St",
  • "controller_2_city": "San Francisco",
  • "controller_2_state": "CA",
  • "controller_2_zip": "94105"
}