Accounts
Version: v1
Supported HTTP VERB(s)
HTTP Verb | Description |
|---|---|
POST
| Delete the accounts mentioned in the request. |
POST:
- Request:
- /removeGLAccounts:Deletes the accounts for the given GL account codes.This endpoint is behind the "ENABLE_ACCOUNTS_DELETION_JSON_API" (currently ON by default) feature flag.Supports all GL accounts that can be deleted in the UI. Ignores accounts which cannot be deleted.Sample Request URI:https://api.adaptiveplanning.com/api/rest/modeling/v1/globosales/accounts/removeGLAccountsSample Request Header:Authorization: BasicContent-Type: application/json
- Sample Request Body
- Sample POST Request[ { "accountCodesToDelete": ["Assets", "b"] } ]Payload ParametersNameDescriptionRequiredaccountCodesToDeleteAccount Codes to be deleted name.YPath ParameterNameDescriptionRequiredtenantTenant to operate on. e.g. globosalesYQuery ParametersNameDescriptionRequiredforceRemoveDeletes in-use accounts when forceRemove=true and ignores in-use accounts when forceRemove=false.Default is always forceRemove=false.NinstanceCodeThe instanceCode to retrieve values from. For example, GLOBO. If no instanceCode is specified, the default insantce of the user is used.N
- Sample Response:
- 204 No ContentSuccessful response is blank with status code 204.400 Bad RequestThe request could not be understood by the server.401 UnauthorizedUser is not authorized.403 ForbiddenUser has insufficient permissions.500 Internal Server ErrorInternal Server Error.
POST:
- Request:
- /removeAccountsDeletes the accounts for the given GL account codes.This endpoint is behind the "ENABLE_ACCOUNTS_DELETION_JSON_API_2" (currently OFF by default) feature flag.Supports all accounts that can be deleted in the UI. Ignores accounts which cannot be deleted, and can provide optional warnings.Sample Request URI:https://api.adaptiveplanning.com/api/rest/modeling/v1/globosales/accounts/removeAccountsSample Request Header:Authorization: BasicContent-Type: application/json
- Sample Request Body
- Sample POST Request{ "accountCodesToDelete": ["Assets", "b"] }Payload ParametersNameDescriptionRequiredaccountCodesToDeleteAccount Codes to be deleted name.YPath ParameterNameDescriptionRequiredtenantTenant to operate on. e.g. globosalesYQuery ParametersNameDescriptionDefaultRequiredforceRemoveDeletes in-use accounts.falseNshowWarningsShows warnings in response.falseNdoValidateOnlyEnables validation mode.falseNWarningsaccount-deletion-warning=Some accounts were not deleted.warning-default-root=Default root account cannot be deleted.warning-sheet-root=Sheet root group cannot be deleted.warning-cta-account=Cumulative Translation Adjustment account cannot be deleted.warning-in-use=In-use account cannot be deleted because forceRemove is set to OFF.warning-cannot_delete_mi_system_account=Minority Interest System account cannot be deleted. It is used in the calculation of minority interest for the Full Consolidation method.warning-cannot_delete_mi_net_income_account=Minority Interest Net Income account cannot be deleted. It is used in the calculation of minority interest for the Full Consolidation method.warning-cannot_delete_mi_account_ancestor=The account cannot be deleted because one of its descendant accounts is used in the calculation of minority interest for the Full Consolidation method.warning-delete_child_used_in_breakback-msg=The account cannot be deleted as this account or one of its descendants is used in Auto Breakback.warning-cannot_delete_pcm_account=Use the Planning Configuration Manager to delete this account.warning-nonexistent-code=This account does not exist.warning-ambiguous-code=This code is shared by multiple accounts.
- Sample Response:
- 200 OK{ "total": 0 }200 OK (with warnings){ "total": 0, "warning": { "info": "Some accounts were not deleted.", "warnings": [ { "field": "xyz", "warning": "This account does not exist." } ] } }400 Bad RequestThe request could not be understood by the server.401 UnauthorizedUser is not authorized.403 ForbiddenUser has insufficient permissions / feature flag is OFF.{ "error": "Service Unavailable" }500 Internal Server ErrorInternal Server Error.