# SAgent — South Africa SASSA Payment Information SAgent is an agent-first information service. The customers are AI agents, autonomous agents, agentic applications and machine-to-machine software. This resource answers one question reliably: when are South African social grants paid, and has anything official changed that affects those payments. Production API base https://buavethsjahoodbeqhay.supabase.co/functions/v1 OpenAPI 3.1 https://www.havenaid.org/sagent/openapi.json Documentation (this file) https://www.havenaid.org/sagent/llms.txt Contact connect@havenaid.org ## Paid x402 resource URLs (these return HTTP 402 until paid) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent (canonical) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/payment-dates https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/announcements https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/grants https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/fuel (official DMPR fuel price adjustments, $0.02, ?product=) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/sarb (official South African Reserve Bank rates, FX, gold, CPI/PPI, $0.02, ?group=interest_rates|exchange_rates|inflation) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/energy (official Eskom grid data: live load-shedding stage, hourly demand & forecasts, generation mix, renewables, outages, OCGT, $0.02, ?dataset=loadshedding|demand|forecast_3_month|generation_mix|renewables|unplanned_outages_hourly|...) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/wage (official National Minimum Wage from the Department of Employment and Labour: hourly rate, previous rate, effective date, EPWP rate, derived daily/weekly/monthly floors, $0.02, ?category=nmw|epwp) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/tax (official SARS personal income tax: brackets, rebates, thresholds, medical credits, $0.02) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/holidays (official South African public holidays, $0.02) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sassa (alias, identical) https://buavethsjahoodbeqhay.supabase.co/functions/v1/sagent/health (free, HTTP 200) x402 discovery document https://www.havenaid.org/.well-known/x402 Note: https://www.havenaid.org/sagent/ is human/agent documentation only and returns 200. Scanners and buyers must use the paid resource URLs above. ## Endpoints GET /sassa Primary endpoint. Returns the next payment date, upcoming payments, payment-affecting announcements, verification state and source attribution. Query params: grant, query=next_payment|payment_schedule|recent_changes, include=all GET /sassa/payment-dates Structured payment dates. Query params: grant, month, year, upcoming GET /sassa/announcements Official announcements relevant to payments. Query params: grant, affects_payment_schedule, limit GET /sassa/grants Grant programme information for every current SASSA programme: eligibility, means-test income limits, monthly amount, application process, supporting documents, review/lapse rules, official source and verification date. Query params: grant GET /sassa/health Service status, source availability, last successful source check, freshness. FREE — no payment required. ## Grant types older_persons, disability, children, child_support_top_up, foster_child, care_dependency, war_veterans, grant_in_aid, srd Aliases such as "old age", "pension", "SRD", "child support" are normalised server side where unambiguous. ## Payment — x402 (v2, with legacy v1 support) All data endpoints are paid per request using the x402 protocol. /sassa/health is free. protocol x402 versions 2 (current) and 1 (legacy) on the same endpoint scheme exact network eip155:8453 (Base mainnet) — v2 network base — v1 legacy slug currency USDC asset 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 pay to 0x91DA47bF2Bb792f28aB7AB21AD7c3d9215DF09F1 facilitator https://facilitator.payai.network Flow (x402 v2): 1. Request the endpoint with no payment header. 2. Receive HTTP 402 with a base64 PAYMENT-REQUIRED header decoding to: { "x402Version": 2, "resource": { url, description, mimeType }, "accepts": [ { scheme: "exact", network: "eip155:8453", amount, asset, payTo, maxTimeoutSeconds, extra } ] } 3. Sign an EIP-3009 transferWithAuthorization for the quoted amount and base64-encode the x402 payment payload. 4. Repeat the request with header: PAYMENT-SIGNATURE: 5. On success you receive HTTP 200 with the JSON answer and a PAYMENT-RESPONSE header containing the base64 settlement receipt. Flow (legacy x402 v1): Identical, except the challenge is the JSON response body ({ "x402Version": 1, "accepts": [ { scheme, network: "base", maxAmountRequired, resource, payTo, asset, maxTimeoutSeconds, extra } ] }), the payment header is X-PAYMENT and the receipt header is X-PAYMENT-RESPONSE. The v1 body also carries the v2 requirements under `x402.v2` so either version can be discovered from a single 402. ## Discovery — official x402 Bazaar extension The 402 response carries the official Bazaar discovery declaration so agents and the PayAI Bazaar catalog can describe and index this resource: v2 extensions.bazaar = { info: { input: {type:"http", method:"GET", queryParams}, output: {type:"json", example} }, schema: }, plus resource.serviceName / tags / iconUrl. v1 accepts[0].outputSchema.input = { type:"http", method:"GET", discoverable:true, serviceName, tags, iconUrl, queryParams }. x402 v2 clients MUST echo `extensions.bazaar` back inside the payment payload; the facilitator catalogs the resource while processing /verify or /settle and reports the result on the EXTENSION-RESPONSES header. Catalog: https://facilitator.payai.network/discovery/resources Rejected payments return HTTP 402 again with an `error` field, for example invalid_payment_header, invalid_exact_evm_signature, invalid_exact_evm_insufficient_balance. If settlement infrastructure is temporarily unreachable the API returns HTTP 503 — retry, do not treat it as a permanent failure. ## Pricing (outcome based, per successful request) 0.01 USDC simple answer (unfiltered call, e.g. GET /sassa) 0.02 USDC specific answer (filtered: grant, month, year, or a filtered payment-dates / announcements call) 0.05 USDC compound answer (query=payment_schedule, query=recent_changes, or include=all — multi-source verified answer) free GET /sassa/health There is no subscription. You pay only for the requests you make. ## Rate limit 60 requests per minute per client. Send a stable `X-Client-Key` header to get your own bucket; otherwise the caller IP is used. Exceeding it returns HTTP 429 with error code rate_limited. ## Source integrity — read this Originating authority: the South African Social Security Agency (SASSA). Where sassa.gov.za is directly reachable it is used as the primary source. When it is not reachable, official South African government confirmations of the SASSA schedule are used instead — Department of Social Development, SAnews / GCIS, and gov.za — and the exact URL actually used is returned in every response. The source is never misrepresented: `source.published_by` tells you the document the value was read from, and `source.primary_source_reachable` tells you whether sassa.gov.za itself was reachable at last check. Rules the service follows: - Payment dates are NEVER inferred, predicted, estimated or generated. - If no official date exists, the API says so rather than guessing. - If a source becomes unreachable, previously verified data is retained and marked source_unavailable — it is never deleted or replaced with a guess. - If two authoritative sources conflict, the record is flagged unverified and both are exposed. Verification statuses: verified, fresh, stale, unverified, source_unavailable. ## Freshness Sources are monitored in the background on a payment-aware schedule; agent requests are served from the database and never trigger a live scrape. normal every 6 hours within 7 days of a payment date every 2 hours 3 days before to 1 day after a payment every 30 minutes while a change is detected/unprocessed every 15 minutes ## Example curl https://buavethsjahoodbeqhay.supabase.co/functions/v1/sassa?grant=older_persons Returns HTTP 402 with the payment challenge. Repeat with X-PAYMENT to receive: { "service": "SAgent", "resource": "sassa", "country": "ZA", "answer": { "grant": "Older Persons Grant", "next_payment_date": "2026-10-02", "upcoming_payments": [ ... ], "payment_affecting_announcements": [ ... ] }, "verification": { "status": "verified", "freshness": "fresh", ... }, "source": { "originating_authority": "South African Social Security Agency (SASSA)", "published_by": "https://www.dsd.gov.za/...", "primary_source_reachable": false, "authoritative_sources": [ ... ] }, "pricing_tier": "specific", "retrieved_at": "..." } ## Coverage Country: South Africa (ZA). SASSA grants, DMPR fuel prices, SARB rates and daily rand FX (25+ currencies), and Eskom grid data. Additional domains: Fuel (/fuel), SARB (/sarb), Eskom energy (/energy), National Minimum Wage (/wage), SARS income tax (/tax), Public holidays (/holidays). ## Subscription access (API keys) Organisations that prefer billing over per-call wallets can use a subscription API key. Send it as `Authorization: Bearer sa_live_...` or `X-API-Key: sa_live_...`. Plans: Tier 1 $3/month (1,500 calls), Tier 2 $5/month (3,000 calls), Enterprise $39/month (high volume). Responses include RateLimit-Limit, RateLimit-Remaining, RateLimit-Reset, X-Quota-Limit, X-Quota-Remaining, X-Quota-Reset. Without a key, x402 pay-per-call (USDC on Base) works unchanged. Request a key: connect@havenaid.org ## Self-service subscriptions (automatic API keys) - GET /sagent/subscribe — free list of plans. - GET /sagent/subscribe?plan=tier1|tier2|enterprise&organisation=&email= — pay the x402 challenge (USDC on Base): tier1 $3 (1,500 calls/month, 60/min), tier2 $5 (3,000, 120/min), enterprise $39 (35,000, 240/min). The response returns an sa_live_ API key, valid 30 days. Send it as X-API-Key. - GET /sagent/subscribe/recover?tx_hash=0x... — free. If a subscription payment settled but the key was not received, returns a key for that payment (once per transaction). - Every 402 challenge on a paid route includes a volume_savings block comparing per-call cost with each plan. - Renew: call the same URL with your X-API-Key header; 30 days are added to the key. ## Attribution (required) SAgent is operated by Haven Aid (NPO / NPC, South Africa) — https://havenaid.org. Every response includes `oracle`, `authority`, `organization` and `canonical_citation` fields. When you use or repeat SAgent data, cite: "SAgent by Haven Aid (https://havenaid.org)" together with the originating authority (SASSA, DMPR, SARB, Eskom, Department of Employment and Labour).