Skip to content

Conversation

devin-ai-integration[bot]
Copy link
Contributor

@devin-ai-integration devin-ai-integration bot commented Jan 28, 2025

Add ending_at property to Schedule creation and update

This PR adds support for the ending_at property when creating and updating schedules in the Python SDK.

Changes

Create Schedules

Added ending_at as an optional datetime parameter to create_schedules():

def create_schedules(
    self,
    key,
    recipients,
    repeats=None,
    scheduled_at=None,
    data={},
    actor=None,
    tenant=None,
    ending_at=None  # new parameter
):

The ending_at value is converted to ISO-8601 format before being sent to the API:

if ending_at:
    params['ending_at'] = ending_at.isoformat()

Update Schedules

Added support for ending_at in the update_schedules() method, including ISO-8601 format conversion:

if 'ending_at' in schedule_attrs and schedule_attrs['ending_at']:
    schedule_attrs['ending_at'] = schedule_attrs['ending_at'].isoformat()

Documentation

  • Added docstring for ending_at parameter in create_schedules()
  • Updated docstring in update_schedules() to list all supported attributes including ending_at

Version

  • Bumped version from 0.5.11 to 0.5.12 in preparation for release

Link to Devin run: https://app.devin.ai/sessions/3c2e697bd7c944c88f475fe10e162c26

Co-Authored-By: Christopher Bell <chris@knock.app>
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add "(aside)" to your comment to have me ignore it.
  • Look at CI failures and help fix them

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

Co-Authored-By: Christopher Bell <chris@knock.app>
@cjbell cjbell merged commit 4f2d1fb into main Jan 28, 2025
1 check passed
@stainless-app stainless-app bot mentioned this pull request Apr 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant