{"id":13808333,"url":"https://github.com/odwyersoftware/sheet2api-js","last_synced_at":"2025-04-11T03:36:44.848Z","repository":{"id":128904400,"uuid":"279412986","full_name":"odwyersoftware/sheet2api-js","owner":"odwyersoftware","description":"JavaScript Library for Google Sheets/Microsoft Excel Online through sheet2api. https://sheet2api.com/","archived":false,"fork":false,"pushed_at":"2023-01-10T14:24:08.000Z","size":148,"stargazers_count":92,"open_issues_count":0,"forks_count":0,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-25T01:38:10.181Z","etag":null,"topics":["api-client","excel","google-sheets-api","javascript","spreadsheets"],"latest_commit_sha":null,"homepage":"https://sheet2api.com/","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/odwyersoftware.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}},"created_at":"2020-07-13T21:13:25.000Z","updated_at":"2025-01-11T01:19:16.000Z","dependencies_parsed_at":"2023-06-04T15:45:41.663Z","dependency_job_id":null,"html_url":"https://github.com/odwyersoftware/sheet2api-js","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/odwyersoftware%2Fsheet2api-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/odwyersoftware%2Fsheet2api-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/odwyersoftware%2Fsheet2api-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/odwyersoftware%2Fsheet2api-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/odwyersoftware","download_url":"https://codeload.github.com/odwyersoftware/sheet2api-js/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248338026,"owners_count":21087150,"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":["api-client","excel","google-sheets-api","javascript","spreadsheets"],"created_at":"2024-08-04T01:01:40.315Z","updated_at":"2025-04-11T03:36:44.824Z","avatar_url":"https://github.com/odwyersoftware.png","language":"JavaScript","readme":"# sheet2api JavaScript Client\n\nJavaScript Library for Google Sheets/Microsoft Excel Online through sheet2api. https://sheet2api.com/\n\n## Installation\n\nThe sheet2api JS library can be installed through npm.\n\n```bash\nnpm install sheet2api-js --save\n```\n\n## Example Usage\n\nTo get started you need to provide your sheet2api Spreadsheet API URL. You can find it on the [sheet2api Dashboard](https://sheet2api.com).\n\nTry it out with the codepen https://codepen.io/sheet2api/pen/MWKZrqW\n\n### Importing the library\n\n```html\n\u003c!-- Server import --\u003e\n\u003cscript src=\"//sheet2api.com/v1/api.js\"\u003e\u003c/script\u003e\n```\n```js\n// Or, Require import\nconst Sheet2API = require('sheet2api-js');\n// Or, ES6 import\nimport Sheet2API from 'sheet2api-js';\n```\n\n### Read rows\n\n```html\n\u003cscript src=\"//sheet2api.com/v1/api.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\nconst url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';\nconst options = {};\nSheet2API.read(url, options).then(function(result){\n  console.log(result);\n}, function(error){\n  console.log(error);\n});\n\u003c/script\u003e\n```\n\n### Read rows matching a search query\n\n```html\n\u003cscript src=\"//sheet2api.com/v1/api.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\nconst url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';\nconst options = {query: { 'Name': 'Bugs Bunny' }};\nSheet2API.read(url, options).then(function(result){\n  console.log(result);\n}, function(error){\n  console.log(error);\n});\n\u003c/script\u003e\n```\n\n### Create new rows\n\n```html\n\u003cscript src=\"//sheet2api.com/v1/api.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\nconst url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';\nconst newRowData = { \"Favourite Thing\": \"Carrots\", \"Name\": \"Bugs Bunny\" };\nconst options = {};\nSheet2API.write(url, options, newRowData).then(function(result){\n  console.log(result);\n}, function(error){\n  console.log(error);\n});\n\u003c/script\u003e\n```\n\n### Update existing rows matching a search query\n\n```html\n\u003cscript src=\"//sheet2api.com/v1/api.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\nconst url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';\nconst updateWithData = { \"Favourite Thing\": \"Beer\", \"Name\": \"Bugs Bunny\" };\nconst options = {query: { 'Name': 'Bugs Bunny' }};\nSheet2API.update(url, options, updateWithData).then(function(result){\n  console.log(result);\n}, function(error){\n  console.log(error);\n});\n\u003c/script\u003e\n```\n\n### Update partially, existing rows matching a search query\n\nNote, If you don’t include values for all columns (Name, Favourite Thing, Image) in the request body, then missing column values will not be updated, just the ones which were present in the request body.\n\n```html\n\u003cscript src=\"//sheet2api.com/v1/api.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\nconst url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';\nconst updateWithData = { \"Name\": \"Bugs\" };\nconst options = {query: { 'Name': 'Bugs Bunny' }};\nSheet2API.updatePartial(url, options, updateWithData).then(function(result){\n  console.log(result);\n}, function(error){\n  console.log(error);\n});\n\u003c/script\u003e\n```\n\n### Authentication\n\nIf you have enabled Basic Authentication on your sheet2api API.\n\n```javascript\nconst options = {\n  auth: ['username', 'password']\n};\nSheet2API.read(url, options).then(function(result){\n  console.log(result);\n}, function(error){\n  console.log(error);\n});\n\u003c/script\u003e\n```\n\nSomething missing you'd like to see? Please create an issue.\n","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fodwyersoftware%2Fsheet2api-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fodwyersoftware%2Fsheet2api-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fodwyersoftware%2Fsheet2api-js/lists"}