---
title: "PHP SDK v2.7.0-BETA3 Schedules"
description: "PHP SDK v2.7.0-BETA3 Schedules"
canonical: "https://temporal.io/changelog/php-sdk-v2-7-0-beta3-schedules.md"
source: "https://temporal.io/changelog/php-sdk-v2-7-0-beta3-schedules"
date: "2023-11-30"
product_areas:
  - "PHP SDK"
---

# PHP SDK v2.7.0-BETA3 Schedules

## What's Changed

- Expose Schedule API by [@roxblnfk](https://github.com/roxblnfk) in [#372](https://github.com/temporalio/sdk-php/pull/372), [#373](https://github.com/temporalio/sdk-php/pull/373)

## Schedule API

[Concept](https://docs.temporal.io/workflows#schedule)
[Temporal Schedules: Reliable, Scalable, and More Flexible than Cron Jobs](https://temporal.io/blog/temporal-schedules-reliable-scalable-and-more-flexible-than-cron-jobs.md) (blog post)

### Example

use Temporal\\Client\\Schedule;

// Create a Schedule Client

$client = \\Temporal\\Client\\ScheduleClient::create(
    \\Temporal\\Client\\GRPC\\ServiceClient::create('localhost:7233'),
);

// Create a Schedule

$handle = $client-\>createSchedule(
    Schedule\\Schedule::new()-\>withAction(
        Schedule\\Action\\StartWorkflowAction::new('testWorkflow')
            -\>withTaskQueue('testTaskQueue')
            -\>withRetryPolicy(\\Temporal\\Common\\RetryOptions::new()\>withMaximumAttempts(3))
            -\>withHeader(\['foo' =\> 'bar'\])
            -\>withWorkflowExecutionTimeout('40m')
    )-\>withSpec(
        Schedule\\Spec\\ScheduleSpec::new()
            -\>withCronStringList('0 \* \* \* \*') // Every hour

),
    scheduleId: 'testSchedule',
);

// Describe the Schedule

$description = $handle-\>describe();

// Update the Schedule$handle-\>update(
    $description-\>schedule-\>withSpec(
        Schedule\\Spec\\ScheduleSpec::new()
            -\>withCronStringList('0 12 \* \* 5', '0 12 \* \* 1')
    ),
    conflictToken: $description-\>conflictToken, // To avoid race condition);

// Pause the Schedule

$handle-\>pause();

// Trigger the Action to be taken immediately

$handle-\>trigger(Schedule\\Policy\\ScheduleOverlapPolicy::CancelOther);

// Delete the Schedule$handle-\>delete();

**Full Changelog**: [v2.7.0-BETA2...v2.7.0-BETA3](https://github.com/temporalio/sdk-php/compare/v2.7.0-BETA2...v2.7.0-BETA3)

- [Release notes](https://github.com/temporalio/sdk-php/releases/tag/v2.7.0-BETA3)
