jamp

v0.2.1
io.github.JDWilliums/jamp Checked 1 day ago Published 4 months ago

Agent-run site monitoring: install JAMP, read errors, uptime, vitals and traffic, resolve fixes.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

jamp_create_site

Create a new site on JAMP and get its install snippet. Use this to set JAMP up on a project: create the site, paste the returned <script> tags into the <head> of the root layout, deploy, then confirm with jamp_verify_install. Requires a token with write access.

ParameterTypeDescription
domain *stringThe site's bare domain, e.g. example.com (no protocol)
namestringDisplay name, defaults to the domain

jamp_verify_install

Check whether a site's JAMP snippet is sending data. Call after installing the snippet and deploying: `installed: true` means analytics events have arrived and the setup works. Also reports the error-tracking and vitals pillars separately.

ParameterTypeDescription
site *stringSite id from jamp_create_site or jamp_list_sites

jamp_setup_sourcemaps

Get the site's source-map upload key and the exact upload contract, so you can wire readable stack traces into the build. Add the upload step to CI and put the same release value in the snippet's data-release attribute. Fetching the key never rotates it. Requires a token with write access.

ParameterTypeDescription
site *stringSite id

jamp_enable_uptime

Turn on uptime monitoring for a site (checks every few minutes, alerts on downtime). Monitors the https homepage unless you pass a URL. Requires a token with write access; plans cap how many sites can have monitoring.

ParameterTypeDescription
site *stringSite id
urlstringOptional specific URL to monitor, defaults to the homepage

jamp_install_doctor

Diagnose a snippet install that isn't sending data: fetches the site's served HTML and checks each tag (present, right website id, defer, script reachable), with a fix for anything wrong. Use when jamp_verify_install stays not-installed after deploying. Only sees server-rendered HTML, so tag-manager installs won't show here.

ParameterTypeDescription
site *stringSite id

jamp_resolve_error

Mark an error as fixed after you've shipped a fix. If the error occurs again later it will show as "regressed" in jamp_list_errors, so this is a real resolution, not a mute. Requires a token with write access.

ParameterTypeDescription
fingerprint *stringError fingerprint from jamp_list_errors
site *stringSite id

jamp_list_sites

List the websites this JAMP token can read. Returns each site id (needed by the other tools), name, domain and current uptime status.

jamp_list_errors

List grouped JavaScript errors for a site, busiest first. Use jamp_get_error with a fingerprint for the full stack trace and the release it appeared in.

ParameterTypeDescription
site *stringSite id from jamp_list_sites
limitintegerMax groups, default 25
windowstringTime window, default 7d

jamp_get_error

Full detail for one error group: latest scrubbed stack trace, the release/commit it last appeared in, the file:line, and breakdowns by page, browser and release. This is how you go from a fingerprint to the exact code to fix.

ParameterTypeDescription
fingerprint *stringError fingerprint from jamp_list_errors
site *stringSite id
windowstring

jamp_uptime

Current uptime status for a site: up/down, uptime percentage, average response time and recent incidents.

ParameterTypeDescription
site *stringSite id
windowstring

jamp_vitals

p75 Core Web Vitals (LCP, CLS, INP, FCP, TTFB) for a site from real users over the window.

ParameterTypeDescription
site *stringSite id
windowstring

jamp_traffic

Traffic summary for a site: pageviews, unique visitors, and top pages, sources and countries over the window.

ParameterTypeDescription
site *stringSite id
windowstring

jamp_page_audit

PageSpeed audit for a site's pages. Without a path: a per-page scoreboard (scores, vitals, top opportunity titles, issue counts), worst pages first. With a path: the full diagnosis for that one page, including the LCP element, prioritised opportunities with estimated savings and the exact offending resources, and the failing accessibility/SEO checks with their elements. Scan the scoreboard, then drill into the page you want to fix.

ParameterTypeDescription
site *stringSite id
pathstringOptional page path, e.g. /pricing

jamp_site_audit

Latest site-audit crawl for a site: broken links (internal and external, with the pages they were found on), on-page SEO problems grouped by kind with the affected pages, and the cookies and third-party trackers the site serves. This is the to-do list to fix dead links, SEO gaps and privacy leaks across the whole site.

ParameterTypeDescription
site *stringSite id

jamp_run_audit

Run a FRESH PageSpeed audit for one page right now (not the stored scan): performance + accessibility + SEO + best-practices scores, Core Web Vitals, Total Blocking Time, the LCP element and prioritised opportunities. Audits mobile by default; pass strategy "desktop" to check desktop. Use this to re-check a page after you change it. Requires a plan with Web Vitals.

ParameterTypeDescription
path *stringPage path to audit, e.g. /pricing
site *stringSite id
strategystringDefault mobile