External Integration

API Integration Guide

External systems can use the WEMS Investment News API to read published articles, market assets, candlesticks, and analytics. Every data endpoint except /status requires X-Api-Key.

Base URLhttps://news.sun-bd.com/api/public/v1
Auth HeaderX-Api-Key
ResponseJSON envelope
Versionv1

Quick Start

/status can be called without a key for health checks. Production data endpoints require an issued API key.

curl -sS "https://news.sun-bd.com/api/public/v1/status"
curl -sS "https://news.sun-bd.com/api/public/v1/catalog" \
  -H "X-Api-Key: YOUR_API_KEY"

Standard Response Envelope

Successful and failed responses use the same envelope to simplify error handling, tracing, and retries.

{
  "success": true,
  "data": {},
  "error": null,
  "timestamp": "2026-05-30T12:00:00Z",
  "traceId": null
}

Endpoints

MethodPathPurposeKey
GET/statusHealth and API status checkNo
GET/catalogAvailable endpoints and parameter descriptionsYes
GET/articlesPublished articles with page, page_size, category, and keywordYes
GET/articles/{id}Single article content, summary, tags, and publish metadataYes
GET/market/assetsMarket assets, optionally filtered by categoryYes
GET/market/candlesCandlestick data using asset_id, interval, and daysYes
GET/analytics/overviewArticle, view, share, and push overview metricsYes

Examples

curl -sS "https://news.sun-bd.com/api/public/v1/articles?page=1&page_size=20&category=market" \
  -H "X-Api-Key: YOUR_API_KEY"
curl -sS "https://news.sun-bd.com/api/public/v1/market/assets?category=crypto" \
  -H "X-Api-Key: YOUR_API_KEY"
const response = await fetch("https://news.sun-bd.com/api/public/v1/articles", {
  headers: { "X-Api-Key": process.env.WEMS_NEWS_API_KEY }
})
const body = await response.json()

Error Handling

Member Login API

Member login, logout, token refresh, and permissions are not handled by this project API. Use the centralized member API documentation.

Open Central Member API Guide