Skip to main content

Getting Started

Welcome to the Capital Stake API documentation. This comprehensive financial market and mutual funds data API provides real-time and historical data for the Pakistani financial markets.

Overview

The Capital Stake API v3.0.0 provides access to:

Authentication

All API endpoints require Bearer token authentication. Include your API token in the Authorization header:

Authorization: Bearer YOUR_API_TOKEN

Base URLs

The API is available at:

Response Format

All responses follow a consistent JSON format:

{
"status": "ok",
"message": "",
"data": { /* ... */ }
}

Response Fields

FieldTypeDescription
statusstringResponse status: ok for success, error for failures
messagestringDescriptive error message (empty on success)
dataobject/arrayResponse payload containing the requested data
countinteger(Optional) Number of items returned

Pagination

For endpoints that support pagination, the response includes additional fields for navigation:

{
"status": "ok",
"message": "",
"data": [ /* array of items */ ],
"offset": 0,
"count": 100,
"total": 1000
}

Pagination Fields

FieldTypeDescription
offsetintegerCurrent offset
countintegerNumber of items in this response
totalintegerTotal number of items available

Error Handling

The API returns standard HTTP status codes:

StatusMeaning
200Request Successfull
403Unauthorized - Invalid or missing bearer token
404Resource not found
500Server error

Common Error Responses

Unable to fulfill request (200)

{
"status": "error",
"message": "unable to fulfill request"
}

Unauthorized (403)

{
"status": "error",
"message": "unauthorized_request"
}

Invalid Method (403)

{
"status": "error",
"message": "invalid_method"
}

Resource Not Found (404)

{
"status": "error",
"message": "not_found"
}

Rate Limiting

Please contact support for information about rate limits and usage quotas.

Support

For support, visit: https://csapis.com


API Version: 3.0.0
Last Updated: July 2026