generic client api