Add API endpoints for content and update MCP resources to use them

Co-authored-by: ArthurDanjou <29738535+ArthurDanjou@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2025-11-30 14:44:52 +00:00
parent 377cab77ed
commit f6ab805ef3
18 changed files with 109 additions and 80 deletions

View File

@@ -0,0 +1,15 @@
export default defineEventHandler(async (event) => {
const result = await queryCollection(event, 'education')
.where('extension', '=', 'md')
.all()
return result
.sort((a, b) => new Date(b.startDate).getTime() - new Date(a.startDate).getTime())
.map(edu => ({
degree: edu.degree,
institution: edu.institution,
startDate: edu.startDate,
endDate: edu.endDate,
location: edu.location
}))
})