MT-23420: document the delete organization sub account endpoint - #56
Draft
oshchyhol wants to merge 1 commit into
Draft
MT-23420: document the delete organization sub account endpoint#56oshchyhol wants to merge 1 commit into
oshchyhol wants to merge 1 commit into
Conversation
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Motivation
MT-23420
Sub-accounts can now be deleted from the organization panel, and the same action is exposed over
the public API.
DELETE /api/organizations/{organization_id}/sub_accounts/{sub_account_id}is notdescribed in the spec yet, so it is missing from the rendered reference.
Changes
deleteOrganizationSubAccount: newdeleteoperation on/api/organizations/{organization_id}/sub_accounts/{sub_account_id}, tagged Organizations,reusing the existing
organization_idandsub_account_idparameterssub-account outside the organization, 404 on an unknown or already deleted sub-account,
429 over the rate limit of 10 requests per minute per organization
deleting the organization's last sub-account also deletes the organization, and that a
repeated call returns 404
RateLimitExceededResponseschema andLIMIT_EXCEEDEDresponse for the 429, which thespec had no shared definition for
How to test
organization_idandsub_account_idpath params, a cURL sample, and 204/401/403/404/429responses
{"errors": "Rate limit exceeded"}DELETE /api/organizations/:organization_id/sub_accounts/:idwitha token holding Sub-accounts Creation & Listing Admin returns 204 and the sub-account is gone
from
GET /api/organizations/:organization_id/sub_accountsCompanion PRs
Caveat: merge after the falcon change ships – the endpoint does not exist in production yet. The
documented last-sub-account behaviour is inherited from the existing deletion flow; if that gets a
guard before release, the description needs updating.