younifyd
Menu

Delete Account

Deletes a chart of accounts

DELETE/Accounts/{AccountID}

Use it in a workflow

  1. Add a step and choose the Xero connector.
  2. Pick the Delete Account action (under Xero).
  3. Fill in the fields below, then reference the result from later steps as {{deleteAccount.response.data}}.

Request

Path parameters

AccountIDstring (uuid)required

Unique identifier for Account object

Headers

xero-tenant-idstringrequired

Xero identifier for Tenant

Response

Returns 200 with an object. Read it in later steps with {{deleteAccount.response.data.<field>}}.

Accountsarray<object>
Codestring

Customer defined alpha numeric account code e.g 200 or SALES (max length = 10)

Namestring

Name of account (max length = 150)

AccountIDstring (uuid)

The Xero identifier for an account – specified as a string following the endpoint name e.g. /297c2dc5-cc47-4afd-8ec8-74990b8761e9

Typestring

See Account Types

One ofBANKCURRENTCURRLIABDEPRECIATNDIRECTCOSTSEQUITYEXPENSEFIXEDINVENTORYLIABILITYNONCURRENTOTHERINCOMEOVERHEADSPREPAYMENTREVENUESALESTERMLIABPAYG

BankAccountNumberstring

For bank accounts only (Account Type BANK)

Statusstring

Accounts with a status of ACTIVE can be updated to ARCHIVED. See Account Status Codes

One ofACTIVEARCHIVEDDELETED

Descriptionstring

Description of the Account. Valid for all types of accounts except bank accounts (max length = 4000)

BankAccountTypestring

For bank accounts only. See Bank Account types

One ofBANKCREDITCARDPAYPALNONE

CurrencyCodestring

3 letter alpha code for the currency – see list of currency codes

One ofAEDAFNALLAMDANGAOAARSAUDAWGAZNBAMBBDBDTBGNBHDBIFBMDBNDBOBBRLBSDBTNBWPBYNBYRBZDCADCDFCHFCLFCLPCNYCOPCRCCUCCUPCVECZKDJFDKK

TaxTypestring

The tax type from taxRates

EnablePaymentsToAccountboolean

Boolean – describes whether account can have payments applied to it

ShowInExpenseClaimsboolean

Boolean – describes whether account code is available for use with expense claims

Classstring

See Account Class Types

One ofASSETEQUITYEXPENSELIABILITYREVENUE

SystemAccountstring

If this is a system account then this element is returned. See System Account types. Note that non-system accounts may have this element set as either “” or null.

One ofDEBTORSCREDITORSBANKCURRENCYGAINGSTGSTONIMPORTSHISTORICALREALISEDCURRENCYGAINRETAINEDEARNINGSROUNDINGTRACKINGTRANSFERSUNPAIDEXPCLMUNREALISEDCURRENCYGAINWAGEPAYABLESCISASSETSCISASSETCISLABOURCISLABOUREXPENSECISLABOURINCOMECISLIABILITYCISMATERIALS

ReportingCodestring

Shown if set

ReportingCodeNamestring

Shown if set

HasAttachmentsboolean

boolean to indicate if an account has an attachment (read only)

Default "false"

UpdatedDateUTCstring

Last modified date UTC format

AddToWatchlistboolean

Boolean – describes whether the account is shown in the watchlist widget on the dashboard

ValidationErrorsarray<object>1 fields

Displays array of validation error messages from the API

json
{
  "Accounts": [
    {
      "Code": 4400,
      "Name": "Food Sales",
      "AccountID": "00000000-0000-0000-0000-000000000000",
      "Type": "BANK",
      "BankAccountNumber": "string",
      "Status": "ACTIVE",
      "Description": "string",
      "BankAccountType": "BANK",
      "CurrencyCode": "AED",
      "TaxType": "string",
      "EnablePaymentsToAccount": false,
      "ShowInExpenseClaims": false
    }
  ]
}

Need more? See the Xero guide for connection setup and behaviour shared by every action.