diff --git a/src/routes/getPages.ts b/src/routes/getPages.ts index 0b4d86e..e670820 100644 --- a/src/routes/getPages.ts +++ b/src/routes/getPages.ts @@ -18,14 +18,27 @@ export const getPages = async ({ request, reply }) => { } `, variables: { - limit: parseInt(request.query.limit ?? 100), + limit: parseInt(request.query.limit ?? 50), offset: parseInt(request.query.offset ?? 0), }, }); return { status: 'success', - result: response, + result: response.map( + ({ + url, + id, + property: + { + id:property_id, + name:property_name + }, + scans: + { + updated_at:last_scanned + } + })=>({ url, id, property_name, property_id, last_scanned })), total: response?.count, }; } \ No newline at end of file