public function update($id, array $data)
{
$data = $this->resolve($data, function (OptionsResolver $resolver) {
$resolver->setDefined('notification_types')->setAllowedTypes('notification_types', 'int')->setAllowedValues('notification_types', [1, -2]);
});
return $this->api->request('PUT', '/players/' . $id, [], json_encode($data));
}