{"id":20915304,"url":"https://github.com/oguzhan18/crt-scrapper","last_synced_at":"2026-02-10T05:32:54.168Z","repository":{"id":240113103,"uuid":"798888991","full_name":"oguzhan18/crt-scrapper","owner":"oguzhan18","description":"Scraper Library is a versatile tool for scraping data from web pages. It provides various events to customize and control the scraping process, allowing users to retrieve data efficiently and reliably.","archived":false,"fork":false,"pushed_at":"2024-05-16T18:07:25.000Z","size":9,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-21T11:50:27.282Z","etag":null,"topics":["javascript-library","library","nestjs","node-library","scrape","scraper","scraper-library"],"latest_commit_sha":null,"homepage":"https://crt-scrapper-docs.vercel.app/#/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/oguzhan18.png","metadata":{"files":{"readme":"ReadMe.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-10T17:29:23.000Z","updated_at":"2024-05-17T05:49:14.000Z","dependencies_parsed_at":"2024-05-16T20:27:02.432Z","dependency_job_id":"b24c076a-3205-49b2-ba4a-0a7b17baae98","html_url":"https://github.com/oguzhan18/crt-scrapper","commit_stats":null,"previous_names":["oguzhan18/crt-scrapper"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/oguzhan18/crt-scrapper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan18%2Fcrt-scrapper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan18%2Fcrt-scrapper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan18%2Fcrt-scrapper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan18%2Fcrt-scrapper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oguzhan18","download_url":"https://codeload.github.com/oguzhan18/crt-scrapper/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan18%2Fcrt-scrapper/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270803531,"owners_count":24648688,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-17T02:00:09.016Z","response_time":129,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["javascript-library","library","nestjs","node-library","scrape","scraper","scraper-library"],"created_at":"2024-11-18T16:14:00.909Z","updated_at":"2026-02-10T05:32:54.103Z","avatar_url":"https://github.com/oguzhan18.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CRT Scrapper Library (1.0.4)\n\n## Overview\nCRT Scrapper Library is a versatile and easy-to-use tool for scraping data from web pages. It provides a robust and flexible framework for performing web scraping tasks on backend technologies such as Node.js and NestJS.\n\n## Features\n- Scrapes data from web pages based on provided URL and target class\n- Supports optional configurations for scraping process\n- Provides events for handling various stages of scraping process, including before request, after request, error handling, and more\n- Retry logic for handling temporary network issues\n- Timeout configuration to prevent long-running requests\n- Customizable HTTP headers for requests\n\n## Installation\nTo install CRT Scrapper Library, run the following command:\n\n```bash\nnpm install crt-scrapper\n````\n\n## Usage\n\n```javascript\nconst { scrapeData } = require('crt-scrapper');\n\nasync function getDataFromUrl(url, targetClass) {\n    try {\n        const result = await scrapeData(url, targetClass, {\n            retry: 3,\n            timeout: 10000,\n            headers: {\n                'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3',\n            },\n            beforeRequest: (url) =\u003e {\n                console.log(`Sending request to ${url}`);\n            },\n            afterRequest: (response) =\u003e {\n                console.log(`Received response with status code ${response.status}`);\n            },\n            onError: (error) =\u003e {\n                console.error('An error occurred during scraping:', error);\n            },\n            beforeParse: ($) =\u003e {\n                console.log('Parsing HTML content...');\n            },\n            afterParse: (data) =\u003e {\n                console.log('Scraping completed successfully:', data);\n            },\n        });\n\n        console.log('Scraped data:', result.data);\n    } catch (error) {\n        console.error('Failed to scrape data:', error);\n    }\n}\n\n/* It will be sufficient if you provide the website you will  scrape and the HTML class whose data you want to get.\n*/\ngetDataFromUrl('https://example.com', '.content');\n\n```\n\n## Documentation\n\nFor detailed documentation and API reference, please refer to the API Documentation file.\n\n## License\nWeb Scraper Library is licensed under the MIT License. See the LICENSE file for details.\n\n## Contribution\nContributions are welcome! Please feel free to submit issues or pull requests on GitHub.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foguzhan18%2Fcrt-scrapper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foguzhan18%2Fcrt-scrapper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foguzhan18%2Fcrt-scrapper/lists"}