diff --git a/apps/api/requests.http b/apps/api/requests.http index 4ce40b2c..9fe36aa7 100644 --- a/apps/api/requests.http +++ b/apps/api/requests.http @@ -46,4 +46,16 @@ content-type: application/json @batchScrapeId = {{batchScrape.response.body.$.id}} # @name batchScrapeStatus GET {{baseUrl}}/v1/crawl/{{batchScrapeId}} HTTP/1.1 -Authorization: Bearer {{$dotenv TEST_API_KEY}} \ No newline at end of file +Authorization: Bearer {{$dotenv TEST_API_KEY}} + + +### Map Website +# @name map +POST {{baseUrl}}/v1/map HTTP/1.1 +Authorization: Bearer {{$dotenv TEST_API_KEY}} +content-type: application/json + +{ + "url": "firecrawl.dev", + "sitemapOnly": true +} \ No newline at end of file diff --git a/apps/api/src/controllers/v1/map.ts b/apps/api/src/controllers/v1/map.ts index 8ab5c135..c8c07b6b 100644 --- a/apps/api/src/controllers/v1/map.ts +++ b/apps/api/src/controllers/v1/map.ts @@ -80,10 +80,6 @@ export async function getMapResults({ // If sitemapOnly is true, only get links from sitemap if (crawlerOptions.sitemapOnly) { - if (includeMetadata) { - throw new Error("includeMetadata is not supported with sitemapOnly"); - } - const sitemap = await crawler.tryGetSitemap(true, true); if (sitemap !== null) { sitemap.forEach((x) => {