Generate the api client