import { Router } from 'express';
import { create, destroy, index, update } from '../controllers/credentialController.js';
import { requireAuth } from '../middleware/auth.js';

export const credentialRoutes = Router();

credentialRoutes.get('/', requireAuth, index);
credentialRoutes.post('/', requireAuth, create);
credentialRoutes.put('/:id', requireAuth, update);
credentialRoutes.delete('/:id', requireAuth, destroy);
