Repository navigation
microvms: add URL add/remove and ingress opt-out - #1174
Merged
SSharma-10 merged 2 commits intoOct 19, 2026
Merged
SSharma-10 merged 2 commits into
SSharma-10 merged 2 commits into
Conversation
Add MicroVMsService.AddURL (POST /v2/microvms/{id}/urls) and RemoveURL (DELETE /v2/microvms/{id}/urls/{url_id}), a MicroVMURLCreateRequest with optional port, MicroVMURL.ID, and MicroVMCreateRequest.Ingress (*bool, defaults true) to opt out of the default URL at create. Matches the microdroplet public API contract.
Co-authored-by: Cursor <cursoragent@cursor.com>
apinonformoso
approved these changes
Oct 19, 2026
SSharma-10
approved these changes
Oct 19, 2026
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.
Why
The public MicroVM API gained ingress-URL management and a create-time ingress opt-out. These godo bindings expose that surface so downstream clients (doctl, terraform-provider-digitalocean) can wire it up.
Internal tracking: MDROP-591.
What changed
microvms.go/microvms_test.go:MicroVMURL.ID— stable per-URL identifier, used to remove a URL.MicroVMCreateRequest.Ingress *bool— omitted (nil) keeps the API default (a default URL is created); set tofalseto create a MicroVM with no default URL.MicroVMURLCreateRequest{ Port int }— optional port for a new URL; defaults to the MicroVM'shttp_portwhen zero.MicroVMsService.AddURL—POST /v2/microvms/{id}/urls, returns the newMicroVMURL.MicroVMsService.RemoveURL—DELETE /v2/microvms/{id}/urls/{url_id}, 204 no body.No version bump or CHANGELOG entry — left for the release PR per CONTRIBUTING.md.
Testing
go build ./...,go vet ./...,gofmt, andgo test .all pass. Added tests: add-with-port, add-with-default-port (nil request), remove, empty-arg guards, and create withingress: false.Made with Cursor