{"id":15710553,"url":"https://github.com/ivanhuay/hash-request","last_synced_at":"2026-05-03T02:44:12.142Z","repository":{"id":57261598,"uuid":"56873545","full_name":"ivanhuay/hash-request","owner":"ivanhuay","description":"Check changes in web using simple hash","archived":false,"fork":false,"pushed_at":"2026-04-21T06:43:47.000Z","size":63,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-04-21T08:36:33.875Z","etag":null,"topics":["changes","hash","npm","request","web"],"latest_commit_sha":null,"homepage":"","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/ivanhuay.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}},"created_at":"2016-04-22T17:30:19.000Z","updated_at":"2018-03-18T19:48:50.000Z","dependencies_parsed_at":"2022-08-25T06:02:05.383Z","dependency_job_id":null,"html_url":"https://github.com/ivanhuay/hash-request","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"purl":"pkg:github/ivanhuay/hash-request","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhuay%2Fhash-request","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhuay%2Fhash-request/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhuay%2Fhash-request/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhuay%2Fhash-request/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ivanhuay","download_url":"https://codeload.github.com/ivanhuay/hash-request/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhuay%2Fhash-request/sbom","scorecard":{"id":498122,"data":{"date":"2025-08-11","repo":{"name":"github.com/ivanhuay/hash-request","commit":"b4b9db86987f12d4985d5bed4ed5f171503f19be"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.6,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Code-Review","score":0,"reason":"Found 0/18 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 5 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-19T21:03:20.854Z","repository_id":57261598,"created_at":"2025-08-19T21:03:20.854Z","updated_at":"2025-08-19T21:03:20.854Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32556771,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-03T00:31:16.350Z","status":"online","status_checked_at":"2026-05-03T02:00:09.297Z","response_time":103,"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":["changes","hash","npm","request","web"],"created_at":"2024-10-03T21:08:36.149Z","updated_at":"2026-05-03T02:44:12.125Z","avatar_url":"https://github.com/ivanhuay.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# hash-request\n\nGet hash html for check changes.\n\n### installation\n\n\tnpm install hash-request\n\n### Usage\n\nhash-request use promises so you can use the .then() and .catch() for manage response and error.\n\n```javascript\nvar hashRequest = require('hash-request');\n\nhashRequest.getHash(\"httpd.apache.org/security_report.html\").then(function(response){\n    console.log(JSON.stringify(response));\n}).catch(function(err){\n\tconsole.error(err);\n});\n```\n\n\n#### response:\n\n```javascript\n  {\n      \"body\":\"912949687a6fe75350bf36928cf64b67\",\n      \"head\":\"d5655ad639b3b7d8746d8e55f22b423e\",\n      \"statusCode\":200,\n\t\t\t\"url\":\"httpd.apache.org/security_report.html\"\n      \"headers\":{\n          \"date\":\"Wed, 27 Apr 2016 12:52:26 GMT\",\n          \"server\":\"Apache/2.4.7 (Ubuntu)\",\n          \"last-modified\":\"Sat, 20 Feb 2016 10:44:41 GMT\",\n          \"etag\":\"\\\"1d63-52c3149824b03\\\"\",\n          \"accept-ranges\":\"bytes\",\n          \"content-length\":\"7523\",\n          \"vary\":\"Accept-Encoding\",\n          \"connection\":\"close\",\n          \"content-type\":\"text/html\"\n      }\n  }\n```\n### custom selector\n\nformat:\n\n\thashRequest.getHash(url,selector);\n\n```javascript\nvar hashRequest = require('hash-request');\n\nhashRequest.getHash(\"httpd.apache.org/security_report.html\",\"h1\").then(function(response){\n    console.log(JSON.stringify(response));\n});\n```\n\n#### response:\n```javascript\n{\n\t\"body\":\"912949687a6fe75350bf36928cf64b67\",\n\t\"head\":\"d5655ad639b3b7d8746d8e55f22b423e\",\n    \"selector\":\"d5655ad639b3b7d8746d8e55f22b423e\",//\u003c-- selector content hash\n    \"statusCode\":200,\n\t\"url\":\"httpd.apache.org/security_report.html\"\n    \"headers\":{\n        \"date\":\"Wed, 27 Apr 2016 12:52:26 GMT\",\n        \"server\":\"Apache/2.4.7 (Ubuntu)\",\n        \"last-modified\":\"Sat, 20 Feb 2016 10:44:41 GMT\",\n        \"etag\":\"\\\"1d63-52c3149824b03\\\"\",\n        \"accept-ranges\":\"bytes\",\n        \"content-length\":\"7523\",\n        \"vary\":\"Accept-Encoding\",\n        \"connection\":\"close\",\n        \"content-type\":\"text/html\"\n    }\n}\n```\n\n### multiples url\n\nformat:\n\n\thashRequest.getHash([url],selector);\n\n```javascript\nvar hashRequest = require('hash-request');\n\nhashRequest.getHash([\"httpd.apache.org/security_report.html\",\"https://www.npmjs.com\"],\"h1\").then(function(response){\n    console.log(JSON.stringify(response));\n});\n```\n\n#### response:\n```javascript\n{\n\t\"body\":\"912949687a6fe75350bf36928cf64b67\",\n\t\"head\":\"d5655ad639b3b7d8746d8e55f22b423e\",\n    \"selector\":\"d5655ad639b3b7d8746d8e55f22b423e\",//selector content hash\n    \"statusCode\":200,\n\t\"url\":\"httpd.apache.org/security_report.html\",\n    \"headers\":{\n        \"date\":\"Wed, 27 Apr 2016 12:52:26 GMT\",\n        \"server\":\"Apache/2.4.7 (Ubuntu)\",\n        \"last-modified\":\"Sat, 20 Feb 2016 10:44:41 GMT\",\n        \"etag\":\"\\\"1d63-52c3149824b03\\\"\",\n        \"accept-ranges\":\"bytes\",\n        \"content-length\":\"7523\",\n        \"vary\":\"Accept-Encoding\",\n        \"connection\":\"close\",\n        \"content-type\":\"text/html\"\n    }\n}\n```\n## new configurable options v0.2.x:\n1) handle_redirect: (default: true) Handle redirect status like 301. Con handle_redirect:false no redirege automaticamente las paginas http en https.\n2) html_response:true (default: false) Returns the json response.html with all selectors and the complete dom as html strings.\n\n## handle_redirect:\n\n```javascript\nvar hashRequest = require('hash-request');\n\nhashRequest.getHash(\"http://www.npmjs.com\").then(function(response){\n    console.log(JSON.stringify(response));\n});\n```\n### response: the https repose by redirect\n```javascript\n{ body: '80a50a1095fcb8feddfcda879f4d5781',\n  head: 'feceba948baefa9763ebc9b769c0b515',\n  statusCode: 200,\n  headers:\n   { date: 'Mon, 28 Nov 2016 23:03:38 GMT',\n     'content-type': 'text/html',\n     'transfer-encoding': 'chunked',\n     connection: 'close',\n     'set-cookie': [ '__cfduid=d87047e1f2f275de83642948504a295641480374218; expires=Tue, 28-Nov-17 23:03:38 GMT; path=/; domain=.nodejs.org; HttpOnly' ],\n     'last-modified': 'Mon, 28 Nov 2016 15:23:12 GMT',\n     'cf-cache-status': 'HIT',\n     expires: 'Tue, 29 Nov 2016 03:03:38 GMT',\n     'cache-control': 'public, max-age=14400',\n     server: 'cloudflare-nginx',\n     'cf-ray': '3091744edb0a163b-LIM' },\n  url: 'https://nodejs.org/en/' }\n\n```\n## html_response:\n\n```javascript\nvar hashRequest = require('hash-request');\n\nhashRequest.getHash(\"http://localhost/example\",{html_response:true}).then(function(response){\n    console.log(JSON.stringify(response));\n});\n```\n### response: html response in response.html\n```javascript\n{ body: '80a50a1095fcb8feddfcda879f4d5781',\n  head: 'feceba948baefa9763ebc9b769c0b515',\n  statusCode: 200,\n  headers:\n   {\n     'content-type': 'text/html',\n     connection: 'close',\n\t },\n  url: 'https://nodejs.org/en/',\n \thtml:{\n\t\tbody:'\u003ch1\u003eexample\u003c/h1\u003e',\n\t\thead:'\u003ctitle\u003esome example\u003c/title\u003e',\n\t\tall:'\u003chtml\u003e\u003chead\u003e\u003ctitle\u003esome example\u003c/title\u003e\u003c/head\u003e\u003cbody\u003e\u003ctitle\u003esome example\u003c/title\u003e\u003c/body\u003e\u003c/html\u003e'\n\t}}\n```\n\n## updates:\n\n* v0.1.0 - Promises and url in json response added.\n* v0.2.0 - Config, handle redirects, optional html reponse aditional to hash.\n\nhash-request: Improving every week!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanhuay%2Fhash-request","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fivanhuay%2Fhash-request","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanhuay%2Fhash-request/lists"}