FreshBooks

Search


API Calls

Resources

Expenses

Staff have access to the API calls listed below. They will only see expenses for clients they have access to, or those not assigned to any client. Expenses that are not associated with a client are represented by client_id as 0.

expense.create

Create a new expense specifically for a client, and optionally one of their projects, or keep it generalized for a number of clients. If successful, returns the expense_id of the newly created item.

  • staff_id is a required field only for admin users. It is ignored for staff using the API.

Request

<?xml version="1.0" encoding="utf-8"?>

  

    0          
    5    

    10     
    10       
    29.95          
    FreshBooks     
    2008-11-01         

    Software package.     
    1                   

                  
            
              
                  
            
              

  

Response

<?xml version="1.0" encoding="utf-8"?>

  433
	

expense.update

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

Request

<?xml version="1.0" encoding="utf-8"?>

  

    433     

    

  

Response

<?xml version="1.0" encoding="utf-8"?>
	

expense.get

Return the complete expense details associated with the given expense_id.

Request

<?xml version="1.0" encoding="utf-8"?>


  433

Response

<?xml version="1.0"?>

  

  433
  0
  5
  10
  10
  29.95
  2008-11-01
  Software package.
  FreshBooks
  1 

  
  
  
  
  
  

  

expense.delete

Delete an existing expense.

Request

<?xml version="1.0" encoding="utf-8"?>

  433

Response

<?xml version="1.0" encoding="utf-8"?>
	

expense.list

Returns a list of expense summaries. You can filter by client_id, category_id, project_id optionally.

Request

<?xml version="1.0" encoding="utf-8"?>


  3     # Filter by client (Optional)


Response

<?xml version="1.0" encoding="utf-8"?>

  

    

      430
      1
      5
      10
      10
      29.95
      2008-11-01
      Hardware.
      FreshBooks
      1 
      
	  
	  
	  
	  
	  
	
    
    

      433
      2
      5
      10
      10
      29.95
      2008-11-01
      Software package.
      1
      
	  
	  
	  
	  
	  
	
    
    ...