79552190

Date: 2025-04-03 06:58:28
Score: 1
Natty:
Report link

There are two different route types (admin and content-api). API tokens and U&P only work on content-api routes, not admin.

You can create content-api routes from your custom plugin with the following syntax:

const contentAPIRoutes = require('./content-api');

const routes = {
  'content-api': {
    type: 'content-api',
    routes: contentAPIRoutes,
  },
};

module.exports = routes;

Reference:
https://github.com/strapi-community/plugin-healthcheck/blob/b86874915cf2087dd84f4fa922476f7071791e6d/server/src/routes/index.js#L4

Reasons:
  • Probably link only (1):
  • Has code block (-0.5):
  • Self-answer (0.5):
Posted by: Drashti Kheni