Add skeletal client and api.AddKnownTypes method

Don't change the names of variables in here, it makes merges even harder.