AFRLATLatvia–SADC Trade Intelligence

— API DOCUMENTATION

Trade Data API

Free, public API for Latvia–SADC bilateral trade data and company intelligence. No authentication required. Data sourced from Eurostat COMEXT (DS-045409), updated weekly.

Base URL

https://afrlat.com/api/v1

Rate limits: None currently enforced. Responses are cached for 1 hour (trade) or 24 hours (companies). Be reasonable.

GET/api/v1/trade

Monthly bilateral trade flows between Baltic states and SADC countries. Returns export and import values in EUR, grouped by year and month.

Parameters

ParamTypeRequiredDefaultDescription
reporterstringoptional"LV"Reporter country code. Allowed values: "LV" (Latvia), "LT" (Lithuania), "EE" (Estonia).
partnerstringoptionalSADC partner country code. If omitted, returns aggregate across all SADC countries.
yearintegeroptionalFilter to a specific year. If omitted, returns all available years.
formatstringoptional"json"Response format. "json" returns structured JSON. "csv" returns a downloadable CSV file.

Valid SADC Partner Codes

ZA (South Africa), BW (Botswana), NA (Namibia), LS (Lesotho), SZ (Eswatini), MZ (Mozambique), ZW (Zimbabwe), ZM (Zambia), MW (Malawi), AO (Angola), TZ (Tanzania), CD (DR Congo), MG (Madagascar), MU (Mauritius), KM (Comoros), SC (Seychelles)

Examples

Latvia–South Africa trade in 2024:

curl "https://afrlat.com/api/v1/trade?reporter=LV&partner=ZA&year=2024"

All Latvia–SADC trade as CSV:

curl "https://afrlat.com/api/v1/trade?reporter=LV&format=csv" -o trade.csv

Estonia–Tanzania trade, all years:

curl "https://afrlat.com/api/v1/trade?reporter=EE&partner=TZ"

Response (JSON)

{
  "meta": {
    "source": "Eurostat COMEXT (DS-045409)",
    "updated": "2026-04-04",
    "reporter": "LV",
    "partner": "ZA",
    "year": 2024,
    "url": "https://afrlat.com/api/v1/trade?reporter=LV&partner=ZA&year=2024"
  },
  "data": [
    {
      "year": 2024,
      "month": 1,
      "exportValueEur": 1234567,
      "importValueEur": 234567,
      "totalValueEur": 1469134
    }
  ],
  "total": {
    "records": 12,
    "exportValueEur": 12345678,
    "importValueEur": 2345678,
    "totalValueEur": 14691356
  }
}

Response (CSV)

year,month,exportValueEur,importValueEur,totalValueEur
2024,1,1234567,234567,1469134
2024,2,987654,345678,1333332
GET/api/v1/companies

Directory of Latvian companies with confirmed operations, exports, or partnerships in SADC member states. Each entry includes sector, tier, SADC presence, and sources.

Example

curl "https://afrlat.com/api/v1/companies"

Response

{
  "meta": {
    "source": "AFRLAT Research",
    "updated": "2026-04-04",
    "url": "https://afrlat.com/api/v1/companies"
  },
  "data": [
    {
      "slug": "mikrotik",
      "name": "MikroTik",
      "sector": "Networking Equipment",
      "sectorTag": "Networking",
      "tier": "established",
      "headline": "Distributors Across Africa ...",
      "description": "Latvian networking equipment company ...",
      "sadcCountries": ["ZA", "MZ", "TZ", "ZM", "ZW", "MW", "BW", "NA"],
      "website": "mikrotik.com",
      "sources": [
        { "label": "MikroTik Africa Distributors", "url": "https://..." }
      ]
    }
  ],
  "total": 12
}

Errors

All errors return a JSON object with an error field and the appropriate HTTP status code.

// 400 Bad Request
{ "error": "Reporter must be LV, LT, or EE" }

// 400 Bad Request
{ "error": "Partner must be a SADC country code: ZA, BW, NA, ..." }

// 500 Internal Server Error
{ "error": "Internal server error" }

CORS

All endpoints return Access-Control-Allow-Origin: *. You can call these APIs directly from any browser application.

Attribution

This data is free to use. If you publish analysis or visualizations based on it, a link back to afrlat.com and a mention of the underlying Eurostat COMEXT source is appreciated.

Trade data: Eurostat COMEXT (DS-045409). Company data: AFRLAT Research.