{"id":15723457,"url":"https://github.com/sor4chi/hono-do","last_synced_at":"2025-04-11T13:23:21.117Z","repository":{"id":195504215,"uuid":"693039399","full_name":"sor4chi/hono-do","owner":"sor4chi","description":"A wrapper of Cloudflare Workers's Durable Object for Hono.","archived":false,"fork":false,"pushed_at":"2024-07-08T15:14:14.000Z","size":324,"stargazers_count":90,"open_issues_count":2,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-23T06:04:51.192Z","etag":null,"topics":["cloudflare","durable-objects","hono","workers"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/hono-do","language":"TypeScript","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/sor4chi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","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},"funding":{"github":["sor4chi"],"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"custom":null}},"created_at":"2023-09-18T08:17:36.000Z","updated_at":"2025-03-18T21:01:19.000Z","dependencies_parsed_at":"2023-11-30T14:29:30.821Z","dependency_job_id":"0a3cc779-4646-446c-aa4b-ec9efaf522c9","html_url":"https://github.com/sor4chi/hono-do","commit_stats":null,"previous_names":["sor4chi/hono-do"],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sor4chi%2Fhono-do","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sor4chi%2Fhono-do/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sor4chi%2Fhono-do/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sor4chi%2Fhono-do/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sor4chi","download_url":"https://codeload.github.com/sor4chi/hono-do/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248409321,"owners_count":21098767,"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":["cloudflare","durable-objects","hono","workers"],"created_at":"2024-10-03T22:11:43.385Z","updated_at":"2025-04-11T13:23:21.088Z","avatar_url":"https://github.com/sor4chi.png","language":"TypeScript","funding_links":["https://github.com/sponsors/sor4chi"],"categories":[],"sub_categories":[],"readme":"# Hono for Durable Object\n\nHono DO is a wrapper of [Cloudflare Workers](https://workers.cloudflare.com/) ' [Durable Object](https://developers.cloudflare.com/workers/learning/using-durable-objects), designed for [Hono](https://hono.dev/).\n\n\u003e [!IMPORTANT]\n\u003e Cloudflare released [RPC](https://developers.cloudflare.com/workers/runtime-apis/rpc/) feature, which is a better way to communicate between Durable Objects.\n\u003e This library was developed to improve the developer experience for Durable Objects when RPC was not yet available.\n\u003e So, please consider it before using this library.\n\n```bash\n$ npm install hono-do\n```\n\n## Usage\n\n```typescript\nexport const Counter = generateHonoObject(\"/counter\", async (app, state) =\u003e {\n  const { storage } = state;\n  let value = (await storage.get\u003cnumber\u003e(\"value\")) ?? 0;\n\n  app.post(\"/increment\", (c) =\u003e {\n    storage.put(\"value\", value++);\n    return c.text(value.toString());\n  });\n\n  app.post(\"/decrement\", (c) =\u003e {\n    storage.put(\"value\", value--);\n    return c.text(value.toString());\n  });\n\n  app.get(\"/\", (c) =\u003e {\n    return c.text(value.toString());\n  });\n});\n```\n\nYou want to find more? Check out the [examples](./examples)!\n\n## Support\n\n- [x] [Alarm API](https://developers.cloudflare.com/durable-objects/api/alarms/)\n- [x] [Hibernation Websocket API](https://developers.cloudflare.com/durable-objects/learning/websockets/#websocket-hibernation)\n\n## License\n\n[MIT](./LICENSE)\n\n## Contributing\n\nThis project is open for contributions. Feel free to open an issue or a pull request!\n[Contributing Guide](./CONTRIBUTING.md) for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsor4chi%2Fhono-do","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsor4chi%2Fhono-do","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsor4chi%2Fhono-do/lists"}