Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Ohdear Php Sdk Laravel Package

ohdearapp/ohdear-php-sdk

Official PHP SDK for the Oh Dear monitoring API. Built on Saloon v4, it provides typed DTOs and convenient methods to manage monitors and more. Supports API token auth, configurable timeouts, and clear exceptions for validation and API errors.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Monitoring Infrastructure as Code (IaC): Enable programmatic creation, management, and deletion of uptime monitors (HTTP, ping, TCP) directly from PHP applications (e.g., CI/CD pipelines, deployment scripts, or internal tools). Aligns with DevOps practices for infrastructure automation.

  • Status Page Integration: Build dynamic status pages for internal/external stakeholders by programmatically syncing monitor health with real-time updates. Supports incident management workflows (e.g., auto-generating maintenance windows or posting updates during outages).

  • Observability Platform Expansion: Integrate Oh Dear’s monitoring data into existing dashboards (e.g., Grafana, custom PHP apps) for unified visibility. Useful for teams already using Oh Dear but needing deeper programmatic access to metrics (e.g., certificate health, uptime trends).

  • Cost Optimization: Replace manual monitor setup with automated, conditional creation (e.g., spin up monitors for staging environments during deployments, then delete them post-deployment). Reduces unnecessary monitoring costs.

  • Custom Alerting Logic: Implement bespoke alerting rules beyond Oh Dear’s native thresholds (e.g., trigger Slack notifications only for specific monitor types or during business hours). Example: Use the SDK to fetch CheckSummary and route alerts via PHP services.

  • Compliance/Validation Workflows: Automate checks for compliance-critical items (e.g., SSL certificate validity, broken links) in pre-deployment hooks. Example: Fail a GitHub Actions workflow if certificateHealth()->isHealthy() returns false.

  • Roadmap:

    • Phase 1: Pilot for internal tooling (e.g., auto-monitor new deployments).
    • Phase 2: Expand to customer-facing status pages with dynamic updates.
    • Phase 3: Integrate with existing observability stacks (e.g., push metrics to Prometheus).

When to Consider This Package

  • Avoid if:

    • You only need basic monitoring without programmatic control (use Oh Dear’s web UI/API directly).
    • Your team lacks PHP expertise or prefers non-PHP languages (e.g., Python, JavaScript). Consider Oh Dear’s native API or other SDKs (e.g., Node.js).
    • You require real-time streaming of monitor data (this SDK is request-based; explore webhooks instead).
    • Your use case involves high-frequency polling (e.g., sub-second checks). The SDK’s default 10-second timeout may not suit low-latency needs.
  • Consider if:

    • You’re building PHP-native tools (e.g., Laravel apps, CLI scripts) to interact with Oh Dear.
    • You need fine-grained control over monitors, checks, or status pages (e.g., dynamic maintenance windows, custom alerting).
    • Your team already uses Saloon (the underlying HTTP client) and wants consistency.
    • You’re evaluating build vs. buy: This SDK reduces dev time vs. rolling your own API wrapper.

How to Pitch It (Stakeholders)

For Executives:

"This SDK lets us automate and extend Oh Dear’s monitoring capabilities directly from our PHP stack—reducing manual work, improving reliability, and enabling smarter incident responses. For example:

  • Auto-create monitors for new deployments, cutting setup time by 80%.
  • Sync real-time status updates to our customer portal without manual intervention.
  • Integrate certificate/uptime checks into our CI pipeline to block non-compliant deployments. It’s a low-risk way to leverage Oh Dear’s infrastructure while future-proofing our observability stack."

For Engineers:

"The Oh Dear PHP SDK provides a clean, Saloon-powered interface to manage monitors, status pages, and checks programmatically. Key benefits:

  • Batteries-included: Handles auth, retries, and validation errors out of the box.
  • Type-safe DTOs: Strongly typed responses (e.g., CheckSummary, CertificateHealth) reduce runtime bugs.
  • Flexible: Supports everything from one-off CLI scripts to long-running services (e.g., polling metrics for dashboards).
  • Well-documented: Clear examples for common tasks (e.g., creating monitors, managing maintenance windows). Use it to:
  • Replace ad-hoc API calls with maintainable PHP code.
  • Build internal tools faster (e.g., a ‘monitor cleanup’ script).
  • Extend Oh Dear’s functionality without workarounds."

For DevOps/SRE:

"This SDK bridges Oh Dear’s monitoring with our existing workflows. Highlights:

  • Automate monitor lifecycle: Create/delete monitors via scripts (e.g., during deployments).
  • Incident management: Programmatically update status pages or snooze alerts during maintenance.
  • Data portability: Fetch raw metrics (e.g., HTTP timing breakdowns) for custom dashboards. Example: ‘Before’: Manually add monitors to Oh Dear; ‘After’: Monitors auto-provisioned from Terraform/Kubernetes events."
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
codraw/framework-extra-bundle
codraw/messenger
codraw/security
codraw/mailer
codraw/contracts
codraw/profiling
codraw/dependency-injection
codraw/tester
codraw/core
nexmo/api-specification
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony