How can I use a JWT token of an Admin user to make API calls to /API routes?

System Information
  • Strapi Version: v4.9.0
  • Operating System: MacOS
  • Database: Postgres
  • Node Version: v18.15.0

I’m trying to build a multitenant application. Most of the app is done, just updating the data types to support some sort of pseudo multitenant functions. I’ve wanted to be able to use the strapi admin users and the users used internally by the organization to control the user base and access to the app by the different organizations, and have the users of each organization be handled by the User-Permission plugin.

But I’m unable to make calls to the API routes using the admin token, generated by the /admin routes. I’m getting a 401 error from the API endpoints, and the admin functionality I want to be able to abstract it into custom endpoints to be able to add some data validation for the creation and updating of organizations and users, to prevent data from being corrupted while being added and make the process easier for those that would be the platform admins.