feat(check): add global speed checker command#30
Merged
Conversation
Adds `openstatus check <URL>` (alias `c`): a top-level, unauthenticated command that runs a one-shot HTTP check from 28 global regions via the public OpenStatus speed checker. Highlights: - Live row-per-region output streaming as NDJSON arrives, followed by a summary footer (fastest/slowest/mean/success-rate + share URL). - --timing adds DNS / Connection / TLS / TTFB / Transfer columns. - --json buffers a single object with full timing nested per region, ready for jq pipelines. - curl-style flags -X / -H / -d (with @file and @- stdin support). - Typed errors for 429 (parsed Retry-After + body reset fallback), 4xx (with VPN/proxy hint when body mentions client IP), 5xx, network errors, and truncated streams. - Region codes mapped to human-readable names (e.g. koyeb_tyo → "Tokyo (Koyeb)") from the upstream skill repo snapshot. Internals: - New internal/check/ package: client.go (NDJSON streaming parser), render.go (table + summary + JSON output), regions.go (display names), types.go (typed errors). - internal/api/client.go gains PlayCheckerURL pinned to www.openstatus.dev (skips a 308 redirect on every call). - Tests use the existing RoundTripper-interceptor pattern from internal/run/run_test.go; fixtures captured from live probes live in internal/check/testdata/. Docs: - README: new check row, dedicated Quick Start example, Global Speed Check section. - Manpage and generated markdown regenerated. - skills/cli/SKILL.md teaches when to reach for check vs. saved monitors. Version bumped to v1.2.0 (new top-level command = semver minor).
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.
Adds
openstatus check <URL>(aliasc): a top-level, unauthenticated command that runs a one-shot HTTP check from 28 global regions via the public OpenStatus speed checker.Highlights:
Internals:
Docs:
Version bumped to v1.2.0 (new top-level command = semver minor).