GeoNet Node Package Documentation - v1.1.7
    Preparing search index...

    GeoNet Node Package Documentation - v1.1.7

    GeoNet API Wrapper

    Compile TypeScript Discord

    A Node.js API wrapper for GeoNet β€” Aotearoa New Zealand's geological hazard monitoring system.

    Note: This wrapper has been independently developed by Carolina Mitchell and is not officially affiliated with GeoNet or Earth Sciences New Zealand (formerly GNS Science).

    npm install geonet
    # or
    pnpm add geonet
    # or
    yarn add geonet
    • πŸŒ‹ Volcano monitoring and alert levels
    • 🌊 Earthquake data and intensity measurements
    • πŸ“° News feed integration
    • πŸ“‘ Network sensor data access
    • πŸ“Š Strong motion data
    • πŸ—ΊοΈ GeoJSON format support
    • 🧰 Quality-of-life utilities
    • ✨ Full TypeScript support
    • πŸ“ Comprehensive documentation
    import { GeoNet } from "geonet";
    import { MMI } from "geonet/dist/@types/common";

    const geonet = new GeoNet();

    // Get recent earthquakes
    const quakes = await geonet.getQuakes(MMI.Light);

    // Get volcano alert levels
    const alerts = await geonet.getVolcanoAlertLevel();
    const { GeoNet } = require("geonet");

    const geonet = new GeoNet();

    // Get recent earthquakes (MMI = 4 for Light intensity)
    const quakes = await geonet.getQuakes(4);

    // Get volcano alert levels
    const alerts = await geonet.getVolcanoAlertLevel();
    try {
    const quakes = await geonet.getQuakes(MMI.Light);
    } catch (error) {
    console.error("Error fetching quakes: ", (error as Error).message);
    }

    For detailed documentation, visit our documentation site.

    Contributions are welcome! Please read the documentation and get familiar with the project code. For details on our code of conduct, please see our Code of Conduct.

    If you identify a security vulnerability, please read our Security Policy for information on how to report it, and what versions are supported.

    # Install dependencies
    pnpm install

    # Run tests
    pnpm test

    # Build the package
    pnpm build

    # Generate documentation
    pnpm docs

    # Regenerate documentation on file changes
    pnpm docs:watch

    This project is licensed under the GNU Affero General Public License v3.0 (AGPL-3.0); see the LICENCE file for details.