droplets: support usage-based backup policies#997
Open
theredspoon wants to merge 1 commit intodigitalocean:mainfrom
Open
droplets: support usage-based backup policies#997theredspoon wants to merge 1 commit intodigitalocean:mainfrom
theredspoon wants to merge 1 commit intodigitalocean:mainfrom
Conversation
This was referenced Apr 16, 2026
aa7ab4f to
bcd2404
Compare
Author
|
Small status update from downstream provider usage:
I also tried the documented Happy to adjust the SDK shape if maintainers prefer a different API surface. I kept this PR SDK-only so the provider can update |
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.
Summary
window_length_hoursandretention_period_daystoDropletBackupPolicyRequestweekdayfrom backup-policy action payloads, which allows usage-based policies such asintra_daily_4hContext
DigitalOcean supports newer usage-based Droplet backup policies such as:
{ "plan": "intra_daily_4h", "hour": 0, "window_length_hours": 4, "retention_period_days": 7 }godocan already read these fields throughDropletBackupPolicyConfig, butDropletBackupPolicyRequestand the Droplet action helpers could only sendplan,weekday, andhour.This is needed by the Terraform/OpenTofu provider so it can model usage-based backup policies without out-of-band API calls. Related provider issue: digitalocean/terraform-provider-digitalocean#1525.
Tests