Categories

Staff have access to the get, list and create API calls listed below if the Expenses tab is enabled for staff. Staff cannot delete or update Categories.

The Categories API provides access to the Expense Categories in the application. They relate to the category_id field as used in the Expenses API.

category.create

Create a new category. If successful, returns the category_id of the newly created item.

Request



  
    Gasoline  
  

Response



  00000000012

category.update

Update an existing expense category with the given category_id. Any category fields left out of the request will remain unchanged.

Request



  
    00000000012  
    Gasoline  
  

Response


category.get

Return the complete category details associated with the given category_id.

Request



  00000000012

Response



  
  00000000012
  Gasoline
  

category.delete

Delete an existing expense category.

Request



  00000000012

Response


category.list

Returns a list of expense categories.

Note: This method uses pagination.

Request



Response



  
    
      00000000001
      Food
      00000000001
    
    
      00000000002
      Parking
      00000000001
    
  

A hierarchy of categories and subcategories can be requested using an empty parent_id element.

Request



  

Response



  
    
      00000000001
      Fees
      
      
        
          4
          Bank Fees
          00000000001
        
        
          3
          Business Insurance
          00000000001