Back to API docs

API Use Cases

Mast turns official half-staff and full-staff signals into structured data for civic websites, public dashboards, newsroom tools, and automation.

Ways to build with Mast

Examples

State-aware status badges

Show visitors whether flags should be at full-staff or half-staff for their selected state, then link back to source details.

Operations dashboards

Monitor federal and state source health with cache freshness, pull status, fetch errors, and active retained events.

Newsroom context tools

Give editors quick structured context when a proclamation, memorial notice, or recurring federal observance affects flags.

Calendar integrations

Build reminders and embeds around known half-staff date ranges, including recurring federal observances such as Memorial Day.

Local alert workflows

Trigger internal notifications when a state changes status, a cache becomes stale, or an official source begins failing.

Open-source widgets

Publish reusable components, browser extensions, or civic-site snippets that consume Mast endpoints with a developer API key.

Typical integration flow

Pattern
  1. Request current status Call /api/v1/status with a country and optional state.
  2. Render the answer Use status.isHalfMast, source fields, and effective dates.
  3. Show data age Use cache.refreshedAt and cache.isStale.
  4. Handle corrections Link users to report an inaccuracy when official data looks wrong.

Projects that use the Mast API can be tagged with the mast-today topic to appear here.

Loading GitHub projects...