Skip to content

Quotes API ​

Retrieve sales quotes and proposals created in Cashfin.

Quotes are price proposals sent to customers before an invoice is raised. The Quotes API gives you read access to all quotes in your account — useful for syncing quote data to external CRM or ERP systems, building approval dashboards, or generating reports.

Read-Only

The Quotes API is currently read-only. Quotes can be created and managed from the Cashfin dashboard.

Use Cases

  • CRM Sync: Pull quote data into your external CRM for a unified sales view
  • Reporting: Aggregate quote conversion rates and pipeline value
  • Approval Workflows: Monitor quote status changes via polling or webhooks

Endpoints ​

MethodEndpointDescription
GET/business/quote/listList all quotes
GET/business/quote/details/:idGet quote details

List Quotes ​

Retrieve a paginated list of quotes.

http
GET /business/quote/list

Query Parameters ​

ParameterTypeDefaultDescription
pageinteger1Page number
limitinteger10Results per page (max: 100)
searchstring-Search by title, quote number, or description
statusstring-Filter by status: draft, sent, accepted, rejected, expired, invoiced

Example Request ​

bash
curl -X GET "https://api.cashfin.africa/business/quote/list?page=1&limit=10&status=sent" \
  -H "Authorization: cs_your_client_secret"
javascript
const response = await fetch(
  "https://api.cashfin.africa/business/quote/list?page=1&limit=10&status=sent",
  {
    headers: { Authorization: "cs_your_client_secret" },
  }
);
const data = await response.json();
php
<?php
$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL            => "https://api.cashfin.africa/business/quote/list?page=1&limit=10",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTPHEADER     => ["Authorization: cs_your_client_secret"],
]);

$result = json_decode(curl_exec($curl), true);
python
import requests

response = requests.get(
    'https://api.cashfin.africa/business/quote/list',
    headers={'Authorization': 'cs_your_client_secret'},
    params={'page': 1, 'limit': 10, 'status': 'sent'}
)

Success Response ​

json
{
  "success": true,
  "data": [
    {
      "_id": "507f1f77bcf86cd799439040",
      "quoteno": "QUO-2024-001",
      "title": "Website Redesign Proposal",
      "amount": 150000.0,
      "balance": 150000.0,
      "status": "sent",
      "quotedate": "2024-01-10T00:00:00.000Z",
      "expirydate": "2024-02-10T00:00:00.000Z",
      "customer_name": "Acme Corp",
      "customer_email": "[email protected]",
      "createdat": "2024-01-10T08:00:00.000Z"
    }
  ],
  "pagination": {
    "total": 25,
    "page": 1,
    "limit": 10,
    "pages": 3
  }
}

Get Quote Details ​

Retrieve full details of a specific quote, including line items and customer information.

http
GET /business/quote/details/:id

Path Parameters ​

ParameterTypeRequiredDescription
idstringYesQuote ID (MongoDB ObjectID)

Example Request ​

bash
curl -X GET "https://api.cashfin.africa/business/quote/details/507f1f77bcf86cd799439040" \
  -H "Authorization: cs_your_client_secret"
javascript
const quoteId = "507f1f77bcf86cd799439040";

const response = await fetch(
  `https://api.cashfin.africa/business/quote/details/${quoteId}`,
  {
    headers: { Authorization: "cs_your_client_secret" },
  }
);
const data = await response.json();
python
import requests

quote_id = '507f1f77bcf86cd799439040'

response = requests.get(
    f'https://api.cashfin.africa/business/quote/details/{quote_id}',
    headers={'Authorization': 'cs_your_client_secret'}
)

Success Response ​

json
{
  "success": true,
  "data": {
    "_id": "507f1f77bcf86cd799439040",
    "quoteno": "QUO-2024-001",
    "title": "Website Redesign Proposal",
    "amount": 150000.0,
    "balance": 150000.0,
    "tax": 16,
    "taxamount": 20689.66,
    "discount": 0,
    "status": "sent",
    "description": "Full redesign including UX audit and development",
    "quotedate": "2024-01-10T00:00:00.000Z",
    "expirydate": "2024-02-10T00:00:00.000Z",
    "items": [
      {
        "itemid": "507f1f77bcf86cd799439011",
        "name": "UX Audit",
        "quantity": 1,
        "rate": 50000.0
      },
      {
        "itemid": "507f1f77bcf86cd799439012",
        "name": "Frontend Development",
        "quantity": 1,
        "rate": 100000.0
      }
    ],
    "customer": {
      "_id": "507f1f77bcf86cd799439030",
      "name": "Acme Corp",
      "email": "[email protected]",
      "phone": "+254700000002"
    },
    "createdat": "2024-01-10T08:00:00.000Z",
    "updatedat": "2024-01-10T08:00:00.000Z"
  }
}

Quote Statuses ​

StatusDescription
draftCreated but not yet sent
sentSent to customer, awaiting response
acceptedCustomer has accepted the quote
rejectedCustomer has rejected the quote
expiredQuote passed its expiry date
invoicedConverted to an invoice

Error Responses ​

Quote Not Found ​

json
{
  "success": false,
  "error": "Quote not found"
}

Invalid Quote ID ​

json
{
  "success": false,
  "error": "Invalid quote ID format"
}

Cashfin Business API Documentation