Repository navigation
feat: show active AMBER Alerts first - #4
Merged
Merged
Conversation
Each load now checks NCMEC's active AMBER Alerts (action=amberAlert, scoped to the configured state). While one is active, the board shows the child from it, flagged "AMBER Alert" with the alert date, and pulls the photo and age from the alert's detail record. With no alerts, or if the check fails, the app falls back to a random open case as before. Records naming an abductor or companion are dropped so only the child is ever shown. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Copilot encountered an error: Your billing is not configured or you have Copilot licenses from multiple standalone organizations or enterprises. To use premium requests, select a billing entity via the GitHub site, under Settings > Copilot > Features.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The board now shows active AMBER Alerts first. Each load asks NCMEC for active alerts (
JSONDataServlet?action=amberAlert&missState=XX, empty for nationwide). If there are any, it shows a child from one at random:action=amberDetail)./poster/AMBER/{amberId}/{personId}.With no active alert (the usual case), or if the check fails, the app behaves exactly as before and shows a random open case.
Why
Until now the app only drew from NCMEC's open-case search. AMBER Alerts cover the most urgent abductions, and NCMEC publishes active ones at missingkids.org/gethelpnow/amber. Children still missing after an AMBER Alert are already in the open-case search under their regular case numbers, so this change only adds the live alerts.
How it's verified
bun test(43 pass),bun run typecheck,bun run lintandbun run buildare clean.missing-children.srly.ioand returns{"alertCount":0,"persons":[]}when nothing is active, as it does today.amberId/caseNumber,fullNameor first/last name,missingFromorcity/state, andalertDate, pluspersonId. The parser accepts every variant, and a record it can't read is skipped, so the worst case is today's behavior.🤖 Generated with Claude Code