How add meta fields to a user with the wp-api?
I have managed to do this with hooking into rest_insert_user. I send an array like this: var data = { first_name: user.first_name, last_name: user.last_name, name: user.display_name, email: user.email, description: user.description, meta: { ‘wpcf-phone’: user.phone, ‘wpcf-institution’: user.institution, ‘wpcf-birthday’: Math.round(new Date(user.birthday).getTime()/1000) } }; And treat only the meta data through the hook as this: function aa_user_update($user, $request, … Read more