diff --git a/src/app.ts b/src/app.ts index 7e91a01..1f58063 100644 --- a/src/app.ts +++ b/src/app.ts @@ -77,6 +77,7 @@ import { cache } from '@/middleware/cache.ts'; import { csp } from '@/middleware/csp.ts'; import { adminRelaysController } from '@/controllers/api/ditto.ts'; import { storeMiddleware } from '@/middleware/store.ts'; +import { reportsController } from '@/controllers/api/reports.ts'; interface AppEnv extends HonoEnv { Variables: { @@ -192,6 +193,8 @@ app.delete('/api/v1/pleroma/admin/statuses/:id', requireRole('admin'), pleromaAd app.get('/api/v1/admin/ditto/relays', requireRole('admin'), adminRelaysController); app.put('/api/v1/admin/ditto/relays', requireRole('admin'), adminRelaysController); +app.post('/api/v1/reports', requirePubkey, reportsController); + // Not (yet) implemented. app.get('/api/v1/custom_emojis', emptyArrayController); app.get('/api/v1/filters', emptyArrayController); diff --git a/src/controllers/api/reports.ts b/src/controllers/api/reports.ts new file mode 100644 index 0000000..24d8f45 --- /dev/null +++ b/src/controllers/api/reports.ts @@ -0,0 +1,7 @@ +import { type AppController } from '@/app.ts'; + +const reportsController: AppController = (c) => { + return c.json('Reports endpoint'); +}; + +export { reportsController };