Create custom endpoint for Users in strapi v4

Thank you all. Great thread.
I created a custom endpoint for users but don’t know how to access “Entity Service API”.
How can I access strapi? and update the user like so:

const entry = await strapi.entityService.findOne('api::user.user', 1, {
  populate: { someRelation: true },
});
2 Likes