Volcano Alert Banner Service

This service monitors USGS volcano data and displays a banner when watched volcanoes reach configurable alert levels.

Available endpoints:

Configuration options:

You can customize the banner by adding query parameters to the /volcano-banner.iife.js URL:

Example:

${url.origin}/volcano-banner.iife.js?minAlertLevel=YELLOW&customMessage=Stay%20informed&messageDisplay=always

Testing:

Via URL parameters:

Via Console (recommended method):


            testVolcanoBanner('RED');
            testVolcanoBanner('YELLOW');
            testVolcanoBanner('FORCE_GREEN');
            testVolcanoBanner('RED', {
            minAlertLevel: "YELLOW",
            customMessage: "Custom test message",
            messageDisplay: "always"
            });
            window.playwrightTestMode = true;
            testVolcanoBanner('RED');
        

Embed the banner:

<script async src="${url.origin}/volcano-banner.iife.js"></script>

With config:


            <script>
            window.volcanoAlertConfig = {
            minAlertLevel: "YELLOW",
            customMessage: "Stay informed about volcanic activity",
            messageDisplay: "always"
            };
            </script>
            <script async src="${url.origin}/volcano-banner.iife.js"></script>