{"id":13602662,"url":"https://github.com/issue-db/issue-db","last_synced_at":"2025-04-11T09:30:41.877Z","repository":{"id":57278269,"uuid":"126666402","full_name":"issue-db/issue-db","owner":"issue-db","description":"☁️ Use GitHub Issues as a JSON datastore","archived":false,"fork":false,"pushed_at":"2018-03-30T22:24:01.000Z","size":10,"stargazers_count":65,"open_issues_count":0,"forks_count":5,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-17T04:18:59.405Z","etag":null,"topics":[],"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/issue-db.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":"2018-03-25T05:06:31.000Z","updated_at":"2024-12-17T20:32:27.000Z","dependencies_parsed_at":"2022-09-18T16:32:23.046Z","dependency_job_id":null,"html_url":"https://github.com/issue-db/issue-db","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/issue-db%2Fissue-db","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/issue-db%2Fissue-db/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/issue-db%2Fissue-db/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/issue-db%2Fissue-db/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/issue-db","download_url":"https://codeload.github.com/issue-db/issue-db/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248368173,"owners_count":21092314,"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":[],"created_at":"2024-08-01T18:01:33.190Z","updated_at":"2025-04-11T09:30:41.623Z","avatar_url":"https://github.com/issue-db.png","language":"JavaScript","readme":"# issue-db \n\n☁️ Use GitHub Issues as a JSON datastore\n\n## Installation\n\n```sh\nnpm install issue-db --save\n```\n\n## Usage\n\n```js\nconst db = require('issue-db')({\n  owner: 'some',\n  repo: 'repo',\n  token: process.env.GH_TOKEN\n})\n```\n\n## API\n\nAll methods are async.\n\n- [`db.put(object)`](#dbputobject)\n- [`db.get(number)`](#dbgetnumber)\n- [`db.list()`](#dblist)\n- [`db.purge()`](#dbpurge)\n\n### `db.put(object)`\n\n- `object` - Any JSON-serializable input, like a String, Number, or Object.\n\nReturns an object with the following properties:\n\n- `number` - The id of the generate GitHub issue.\n- `title` - The title of the issue. If `object` has a any of the following properties, they'll be used as the title: `title`, `name`, or `id`. Otherwise, the default title is `untitled`\n- `body` - Your input object.\n\n### `db.get(number)`\n\nRetrieve a record from the database.\n\n- `number` Number - A GitHub issue id.\n\nReturns an object with the following properties:\n\n- `number` - The unique id of the generated GitHub issue.\n- `title` - The title of the issue. If `object` has a any of the following properties, they'll be used as the title: `title`, `name`, or `id`. Otherwise, the default title is `untitled`\n- `body` - Your input object.\n\n### `db.list()`\n\nReturns an array of every record with a `state` of `open`\n\n### `db.purge()`\n\nSets the `state` of all `open` issues to `closed`, effectively deleting the \ncontents of your entire database. Use with caution!\n\n## Tests\n\n```sh\nnpm install\nnpm test\n```\n\n## Dependencies\n\n- [@octokit/rest](https://github.com/octokit/rest.js): GitHub REST API client for Node.js\n- [ellipsize](https://github.com/mvhenten/ellipsize): Ellipsizes a string at the nearest whitespace character near the end of allowed length\n\n## Dev Dependencies\n\n- [dotenv-safe](https://github.com/rolodato/dotenv-safe): Load environment variables from .env and ensure they are defined\n- [jest](https://github.com/facebook/jest): Delightful JavaScript Testing.\n- [make-promises-safe](https://github.com/mcollina/make-promises-safe): Crash or abort if you get an unhandledRejection\n- [standard](https://github.com/standard/standard): JavaScript Standard Style\n- [standard-markdown](https://github.com/zeke/standard-markdown): Test your Markdown files for Standard JavaScript Style™\n\n\n## License\n\nMIT\n","funding_links":[],"categories":["JavaScript","📦 Legacy \u0026 Inactive Projects"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fissue-db%2Fissue-db","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fissue-db%2Fissue-db","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fissue-db%2Fissue-db/lists"}