edgecron/edgecron-php

Official PHP SDK for the EdgeCron webhook scheduling and callback delivery platform.

Maintainers

Package info

github.com/edgecron/edgecron-php

Homepage

pkg:composer/edgecron/edgecron-php

Transparency log

Statistics

Installs: 0

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v1.0.1 2026-07-02 06:36 UTC

This package is auto-updated.

Last update: 2026-07-02 11:40:53 UTC


README

Official PHP SDK for the EdgeCron webhook scheduling and callback delivery platform.

Schedule delayed HTTP requests, deliver webhooks reliably, and automatically retry failed calls — with full execution history so nothing gets lost.

中文文档:README.zh-CN.md

Install

composer require edgecron/edgecron-php

Quick Start

<?php

use EdgeCron\EdgeCron;
use EdgeCron\APIError;

$client = new EdgeCron('ak_xxx', 'sk_xxx');

try {
    $schedule = $client->schedules->create('my-schedule', '*/5 * * * *');
    var_dump($schedule->id);
} catch (APIError $error) {
    var_dump($error->codeValue, $error->getMessage(), $error->requestId);
}

Modules

Client method Description
$client->schedules->* Cron schedule CRUD, pause, resume
$client->tasks->* Task execution instances, cancel
$client->events->* Event publishing and management
$client->endpoints->* Webhook endpoint configuration
$client->deliveries->* Delivery attempt records and retry
$client->retries->* Retry policies and jobs
$client->subscription->* Quota, usage, and resource limits

Configuration

  • base_url — override API base URL
  • timeout — HTTP client timeout in seconds
  • http_client — custom Guzzle Client

Error Handling

Service-side business errors throw APIError.

<?php

use EdgeCron\APIError;

try {
    $client->schedules->get(123);
} catch (APIError $error) {
    var_dump($error->codeValue, $error->getMessage(), $error->requestId);
}

Security Notice

This is a server-side SDK. Do not expose secret in browsers or mobile apps.