{"id":15640896,"url":"https://github.com/tiagodanin/scraperscript","last_synced_at":"2026-02-26T23:33:33.827Z","repository":{"id":33156334,"uuid":"153465805","full_name":"TiagoDanin/ScraperScript","owner":"TiagoDanin","description":"ScraperScript is a query language for Web Scraping","archived":false,"fork":false,"pushed_at":"2025-03-28T16:57:47.000Z","size":261,"stargazers_count":1,"open_issues_count":24,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-14T21:53:15.015Z","etag":null,"topics":["language","query","scraper","scraping","scrapper-script"],"latest_commit_sha":null,"homepage":"https://tiagodanin.github.io/ScraperScript/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TiagoDanin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2018-10-17T13:54:52.000Z","updated_at":"2021-05-09T03:48:56.000Z","dependencies_parsed_at":"2024-05-28T22:58:34.470Z","dependency_job_id":"d34e14ba-b816-43c5-8dd8-611db9040d56","html_url":"https://github.com/TiagoDanin/ScraperScript","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiagoDanin%2FScraperScript","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiagoDanin%2FScraperScript/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiagoDanin%2FScraperScript/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiagoDanin%2FScraperScript/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TiagoDanin","download_url":"https://codeload.github.com/TiagoDanin/ScraperScript/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248968754,"owners_count":21191158,"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","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":["language","query","scraper","scraping","scrapper-script"],"created_at":"2024-10-03T11:40:32.701Z","updated_at":"2026-02-26T23:33:33.758Z","avatar_url":"https://github.com/TiagoDanin.png","language":"JavaScript","readme":"# ScraperScript\n\n[![Travis](https://img.shields.io/travis/TiagoDanin/ScraperScript.svg?branch=master\u0026style=flat-square)](https://travis-ci.org/TiagoDanin/ScraperScript) [![Downloads](https://img.shields.io/npm/dt/scraperscript.svg?style=flat-square)](https://npmjs.org/package/scraperscript) [![Node](https://img.shields.io/node/v/scraperscript.svg?style=flat-square)](https://npmjs.org/package/scraperscript) [![Version](https://img.shields.io/npm/v/scraperscript.svg?style=flat-square)](https://npmjs.org/package/scraperscript) [![XO code style](https://img.shields.io/badge/code%20style-XO-red.svg?style=flat-square)](https://github.com/xojs/xo) \n\nScraperScript is a query language for Web Scraping\n\n## Installation\n\nModule available through the [npm registry](https://www.npmjs.com/). It can be installed using the  [`npm`](https://docs.npmjs.com/getting-started/installing-npm-packages-locally) or [`yarn`](https://yarnpkg.com/en/) command line tools.\n\n```sh\n# NPM\nnpm install scraperscript --global\n# Or Using Yarn\nyarn global add scraperscript\n```\n\n## Documentation\n\nUse the command `scraperscript myfile` or server\n\nExample file.\n\n```markdown\n@https://helloword.site/list\n!! A comment ...\n- names: html \u003e\u003e body \u003e\u003e div \u003e\u003e h2 @\u003e {number, text, bold} :array\n- hasTitle: html \u003e\u003e head \u003e\u003e title == \" my string \" :boolean\n- title: html \u003e\u003e head \u003e\u003e title :string\n```\n\nThis return an json:\n\n```json\n\"error\": false,\n\"errorsMsg\": [],\n\"names\": [\n\t{\n\t\t\"number\": 0,\n\t\t\"text\": \"Tiago\"\n\t},\n\t{\n\t\t\"number\": 0,\n\t\t\"text\": \"James\"\n\t}\n],\n\"hasTitle\": true,\n\"title\": \"my string\"\n```\n\n## Syntax\nPlace the URL in the first line: `@http://myurl.com`\n\nOther lines: `- key: query :type`\n\nPS: Space is important.\n\n### Key\nName\n\nRules:\n- Use at the beginning of the line\n- Format `- key:`\n\nExample: `- name:`\n\n### Type\nReturn type\n\nRules:\n- Use at the end of the line\n- Format `:type`\n\nTypes:\n- array\n- object\n- boolean\n- string\n- number\n\nExample: `:string`\n\n### Query\n\n**String**\n\n`\" my string \"`\n\nNOTE: `\"my string\"` is invalid\n\n**Comment**\n\n`!! my comment in ScrapperScript`\n\n**Elements**\n\n`nameOfHtmlElementOne \u003e\u003e nameOfHtmlElementTwo`\n\n**Map elements [String]**\n\n`nameOfHtmlElementOne @\u003e nameOfSubHtmlElement`\n\n**Map elements [Array]**\n\n`nameOfHtmlElementOne @\u003e [nameOfSubHtmlElement]`\n\n**Map elements [Object]**\n\n`nameOfHtmlElementOne @\u003e {nameOfIndex, nameOfData, nameOfSubHtmlElement}`\n\n**Addition**\n\n`nameOfHtmlElementOne ++ nameOfHtmlElementTwo`\n\n**Replace**\n\n`nameOfHtmlElementOne -- nameOfHtmlElementTwo`\n\n**Equal comparison or Different**\n\n`nameOfHtmlElementOne == nameOfHtmlElementTwo`\n\n`nameOfHtmlElementOne ~= nameOfHtmlElementTwo`\n\n**OR**\n\n`nameOfHtmlElementOne || nameOfHtmlElementTwo`\n\n## Tests\n\nTo run the test suite, first install the dependencies, then run `test`:\n\n```sh\n# NPM\nnpm test\n# Or Using Yarn\nyarn test\n```\n\n## Dependencies\n\n- [axios](https://ghub.io/axios): Promise based HTTP client for the browser and node.js\n- [cheerio](https://ghub.io/cheerio): Tiny, fast, and elegant implementation of core jQuery designed specifically for the server\n\n## Dev Dependencies\n\n- [body-parser](https://ghub.io/body-parser): Node.js body parsing middleware\n- [express](https://ghub.io/express): Fast, unopinionated, minimalist web framework\n- [mocha](https://ghub.io/mocha): simple, flexible, fun test framework\n- [xo](https://ghub.io/xo): JavaScript happiness style linter ❤️\n\n## Contributors\n\nPull requests and stars are always welcome. For bugs and feature requests, please [create an issue](https://github.com/TiagoDanin/ScraperScript/issues). [List of all contributors](https://github.com/TiagoDanin/ScraperScript/graphs/contributors).\n\n## License\n\n[MIT](LICENSE) © [Tiago Danin](https://TiagoDanin.github.io)","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiagodanin%2Fscraperscript","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftiagodanin%2Fscraperscript","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiagodanin%2Fscraperscript/lists"}