Accountancy Practice API - client question

I’m doing an integration that is leveraging the Accountancy Practice API. We’ve managed to create the OAuth connection successfully, bring back the different clients under the accountant and receive the categories (chart of accounts) for the individual clients. However we realised that the response from the client’s endpoint (https://api.freeagent.com/v2/clients), doesn’t include the ‘sales_tax_rates’ property whereas the company ‘https://api.freeagent.com/v2/company’ endpoint for singular businesses does. Is there a reason for the client endpoint not returning the ‘sales_tax_rates’, we have changed the settings so one of the clients is VAT registered but no luck. How am I able to get the ‘sales_tax_rates’ for a client?

Hi Tim,

Thanks for posting your question. The Client’s End-Point is designed to return a list of all the clients associated with the currently authenticated Account Manager. If the Account Manager is senior level, this will return all clients for the accountancy practice. As you have noticed, this end-point doesn’t currently support returning the sales_tax_rates for each client. If you think that it should, please let me know and I can raise this as a feature request with the relevant Engineering Team.

However, you should still be able to access the sales_tax_rates via the standard Company end-point. To access this via an accountancy practice authenticated integration, you should only need to include the following additional field in the HTTP request header:

X-Subdomain: companysubdomain

where the companysubdomain is the subdomain of the company you’re interested in. This should return successfully provided that the authenticated Account Manager has access to this company (i.e. if this company would be returned in their list of Clients). More information on this can be found in the Making API requests on behalf of clients section of our Accountancy Practice API docs.

I hope this helps solve your problem. Please let me know if you have any follow up questions.

Andrew Rodger
Support Engineer