Hey andrew,
To extend a plugin’s interface using the ./src/extensions folder in v4 of strapi:
- Create the
./src/extensionsfolder at the root of the app, if the folder does not already exist. - Create a subfolder with the same name as the plugin to be extended, in your case
users-permissions. - Depending on what needs to be extended:
- create a
strapi-server.jsfile to extend a plugin’s back end using the Server API - or create a
strapi-admin.jsfile to extend the admin panel.
Since you are looking for controllers and routes, here is an example of a backend extension:
// path: ./src/extensions/users-permissions/strapi-server.js
module.exports = (plugin) => {
plugin.controllers.user.find = (ctx) => {
console.log('test');
};
return plugin;
};
This guide is from: Plugins extension - Strapi Developer Docs