{"id":48235435,"url":"https://github.com/idw111/use-google-spreadsheet","last_synced_at":"2026-04-04T19:58:40.204Z","repository":{"id":42941285,"uuid":"235015658","full_name":"idw111/use-google-spreadsheet","owner":"idw111","description":"react hook for using google spreadsheet as a data table (API endpoint)","archived":false,"fork":false,"pushed_at":"2023-05-04T09:00:10.000Z","size":631,"stargazers_count":104,"open_issues_count":3,"forks_count":7,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-10-26T23:20:37.047Z","etag":null,"topics":["google-spreadsheet","react","react-hook"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/idw111.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2020-01-20T04:03:14.000Z","updated_at":"2024-08-26T23:34:16.000Z","dependencies_parsed_at":"2024-06-21T17:40:44.419Z","dependency_job_id":"c657b54e-cbb8-42a6-a4d8-307b9addf0af","html_url":"https://github.com/idw111/use-google-spreadsheet","commit_stats":{"total_commits":30,"total_committers":3,"mean_commits":10.0,"dds":"0.19999999999999996","last_synced_commit":"0f51d322e8aab6d29fbd7fb0f8e8a1514d65aa33"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/idw111/use-google-spreadsheet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/idw111%2Fuse-google-spreadsheet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/idw111%2Fuse-google-spreadsheet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/idw111%2Fuse-google-spreadsheet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/idw111%2Fuse-google-spreadsheet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/idw111","download_url":"https://codeload.github.com/idw111/use-google-spreadsheet/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/idw111%2Fuse-google-spreadsheet/sbom","scorecard":{"id":481826,"data":{"date":"2025-08-11","repo":{"name":"github.com/idw111/use-google-spreadsheet","commit":"3732e8d3cb13021d41fc8890fb585c59f682b810"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.6,"checks":[{"name":"Code-Review","score":0,"reason":"Found 1/15 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":"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":"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":"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":"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":"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":"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":"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":"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":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"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"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 19 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"}}]},"last_synced_at":"2025-08-19T16:50:15.567Z","repository_id":42941285,"created_at":"2025-08-19T16:50:15.567Z","updated_at":"2025-08-19T16:50:15.567Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31411504,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-04T19:29:44.979Z","status":"ssl_error","status_checked_at":"2026-04-04T19:29:11.535Z","response_time":60,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["google-spreadsheet","react","react-hook"],"created_at":"2026-04-04T19:58:37.383Z","updated_at":"2026-04-04T19:58:40.195Z","avatar_url":"https://github.com/idw111.png","language":"TypeScript","readme":"# use-google-spreadsheet\n\n\u003e helps developers use google spreadsheet as their data table (backend endpoint)\n\n[Live Demo](https://idw111.github.io/use-google-spreadsheet/example/)\n\n## install\n\n```bash\nnpm install use-google-spreadsheet\n```\n\n## usage\n\n1. Configure Google Cloud Console to get API key for Google Sheets API (API_KEY)\n\n    - It uses Google Sheets API v4, when API_KEY is given\n    - If API_KEY is not given, it falls back to Google Sheets API v3 which would be deprecated soon\n\n2. Create a google spreadsheet\n\n    - Insert keys in the first row\n    - Insert values after first row\n\n3. Publish the spreadsheet to web (File \u003e Publish to Web)\n4. Use the share url to fetch the data (File \u003e Share)\n5. You'll fetch the spreadsheet as the following\n\n![spreadsheet](https://user-images.githubusercontent.com/445464/72701147-aacbc880-3b91-11ea-81c5-d75c5c476f31.png)\n\n```json\n// fetched data (rows)\n[\n\t{ \"key1\": \"row1:value1\", \"key2\": \"row1:value2\", \"key3\": \"row1:value3\" },\n\t{ \"key2\": \"row2:value1\", \"key2\": \"row2:value2\", \"key3\": \"row2:value3\" },\n\t{ \"key3\": \"row3:value1\", \"key2\": \"row3:value2\", \"key3\": \"row3:value3\" }\n]\n```\n\n## example\n\n```javascript\nimport useGoogleSpreadsheet from 'use-google-spreadsheet';\n\nconst SomeComponent = ({}) =\u003e {\n\tconst API_KEY = 'XXXXXXXXXXXX';\n\tconst shareUrl = 'https://docs.google.com/spreadsheets/d/1W5D9WvlrXvndEc0b42OsdzJTT1M-MxKVYdPEtleqRQY/edit?usp=sharing';\n\tconst { rows, isFetching } = useGoogleSpreadsheet(shareUrl, API_KEY);\n\treturn isFetching ? (\n\t\t\u003cSpinner /\u003e\n\t) : rows ? (\n\t\t\u003cul\u003e\n\t\t\t{rows.map((row, i) =\u003e {\n\t\t\t\treturn (\n\t\t\t\t\t\u003cli key={i}\u003e\n\t\t\t\t\t\t{Object.keys(row).map((key, i) =\u003e (\n\t\t\t\t\t\t\t\u003cspan key={i}\u003e\n\t\t\t\t\t\t\t\t{key}: {row[key]}\n\t\t\t\t\t\t\t\t\u003cbr /\u003e\n\t\t\t\t\t\t\t\u003c/span\u003e\n\t\t\t\t\t\t))}\n\t\t\t\t\t\u003c/li\u003e\n\t\t\t\t);\n\t\t\t})}\n\t\t\u003c/ul\u003e\n\t) : (\n\t\t\u003cspan\u003eNo Data\u003c/span\u003e\n\t);\n};\n```\n\n## api\n\n### useGoogleSpreadsheet\n\n    -   params @{string} shareUrl or sheetId\n    -   params @{string} apiKey (optional)\n    -   returns @{object}\n        -   rows @{array}\n        -   isFetching @{boolean}\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fidw111%2Fuse-google-spreadsheet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fidw111%2Fuse-google-spreadsheet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fidw111%2Fuse-google-spreadsheet/lists"}