Gateway
Lender submission intake — submit deals via API, email, or portal.
Gateway gives lenders a white-label API to receive deal submissions from brokers. Brokers integrate once and can submit deals to any Gateway-enabled lender.
Endpoints
| Method | Path | Description |
|---|---|---|
GET | /v1/gateway/{slug}/status | Check if a lender is accepting submissions |
GET | /v1/gateway/{slug}/products | List the lender's financing products |
POST | /v1/gateway/{slug}/submissions | Submit a deal |
GET | /v1/gateway/{slug}/submissions | List submissions in the inbox |
GET | /v1/gateway/{slug}/submissions/{id} | Get submission detail |
PATCH | /v1/gateway/{slug}/submissions/{id} | Respond to a submission |
GET | /v1/gateway/{slug}/stats | Inbox statistics |
SDK Usage
import { LW } from '@lendworks/lwjs'
const lw = new LW({ apiKey: 'lw_live_...' })
// Check if lender is accepting
const status = await lw.gateway.status('quickfund-capital')
// Submit a deal
const deal = await lw.gateway.submissions.create('quickfund-capital', {
businessName: 'Acme Corp',
amountRequested: 150000,
monthlyRevenue: 85000,
industry: 'Technology',
state: 'CA',
creditScore: 720,
brokerName: 'Jane Doe',
brokerEmail: 'jane@broker.com',
})
// List pending submissions
for await (const sub of lw.gateway.submissions.list('quickfund-capital')) {
console.log(sub.businessName, sub.matchScore)
}
// Respond to a submission
await lw.gateway.submissions.respond('quickfund-capital', deal.id, {
action: 'approve',
offerTerms: { amount: 150000, rate: 0.08, termDays: 365 },
})Submission Fields
When creating a submission, the following fields are accepted:
| Field | Type | Required | Description |
|---|---|---|---|
businessName | string | Yes | Legal business name |
amountRequested | number | No | Requested funding amount |
monthlyRevenue | number | No | Monthly gross revenue |
annualRevenue | number | No | Annual gross revenue |
industry | string | No | Business industry |
state | string | No | 2-letter state code |
city | string | No | Business city |
creditScore | number | No | Owner credit score (300-850) |
timeInBusinessMonths | number | No | Months in business |
useOfFunds | string | No | How funds will be used |
productType | string | No | Requested product type |
ein | string | No | Employer Identification Number |
ownerName | string | No | Business owner full name |
brokerName | string | No | Submitting broker name |
brokerEmail | string | No | Broker contact email |
brokerPhone | string | No | Broker phone number |
brokerNotes | string | No | Notes for the lender |
Response Actions
When responding to a submission, use one of these actions:
approve— Accept the deal, optionally include offer termsdecline— Reject the dealcounter— Counter with different termsrequest_docs— Request additional documentation
Authentication
Gateway endpoints require a platform API key with gateway access:
Authorization: Bearer lw_live_a1b2c3d4_...The {slug} path parameter is the lender's directory slug (e.g., quickfund-capital). Find slugs via the TrustMark search endpoint.