{"id":20844519,"url":"https://github.com/pushpabrol/txn-message-store-sqlite","last_synced_at":"2026-04-20T22:04:24.243Z","repository":{"id":180222501,"uuid":"643706881","full_name":"pushpabrol/txn-message-store-sqlite","owner":"pushpabrol","description":null,"archived":false,"fork":false,"pushed_at":"2023-10-31T20:39:47.000Z","size":39,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-28T11:07:08.811Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/pushpabrol.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,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-05-22T01:37:32.000Z","updated_at":"2025-05-16T16:55:09.000Z","dependencies_parsed_at":"2023-10-31T22:33:38.306Z","dependency_job_id":null,"html_url":"https://github.com/pushpabrol/txn-message-store-sqlite","commit_stats":null,"previous_names":["pushpabrol/txn-message-store-sqlite"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/pushpabrol/txn-message-store-sqlite","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pushpabrol%2Ftxn-message-store-sqlite","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pushpabrol%2Ftxn-message-store-sqlite/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pushpabrol%2Ftxn-message-store-sqlite/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pushpabrol%2Ftxn-message-store-sqlite/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pushpabrol","download_url":"https://codeload.github.com/pushpabrol/txn-message-store-sqlite/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pushpabrol%2Ftxn-message-store-sqlite/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32067637,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-20T21:26:33.338Z","status":"ssl_error","status_checked_at":"2026-04-20T21:26:22.081Z","response_time":94,"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":[],"created_at":"2024-11-18T02:09:52.544Z","updated_at":"2026-04-20T22:04:24.204Z","avatar_url":"https://github.com/pushpabrol.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# Transaction Message Store API with Persistence\n\nThis project demonstrates a simple Express API with persistence functionality. It contains routes for message creation, retrieval by ID, and cleanup of messages.\n\n## Project Structure\n\nThe main file of this API is an Express Router which exports several routes related to handling messages. The `Persistence` module is used for interacting with the database.\n\n## API Endpoints\n\nThe following routes are defined:\n\n### PUT /api/message\n\nCreates a new message in the system.\n\n**Request Body:**\n\n- `id` (string): The unique identifier for the message.\n- `message` (string): The content of the message.\n\n**Response:**\n\nA JSON object containing the ID of the newly created message.\n\n**Errors:**\n\n- `400`: If the `id` or `message` is not provided.\n- `500`: If any internal server error occurs.\n\n### GET /api/message/:id\n\nRetrieves a message by its ID.\n\n**Parameters:**\n\n- `id` (string): The unique identifier for the message.\n\n**Response:**\n\nThe message object with the specified ID.\n\n**Errors:**\n\n- `500`: If any internal server error occurs.\n\n### POST /api/message/cleanup\n\nCleans up the messages in the system.\n\n**Response:**\n\nA JSON object indicating the number of rows cleaned up.\n\n**Errors:**\n\n- `500`: If any internal server error occurs.\n\n## Installation and Running the Project\n\nClone the project, navigate into the directory and install dependencies:\n\n```\ngit clone \u003crepository-url\u003e\ncd \u003crepository-directory\u003e\nnpm install\n```\n\nRun the server:\n\n```\nnpm start\n```\n\nThe server will start running at `http://localhost:3069`.\n\n## Testing\n\nThis API is not configured with any testing framework yet. If you want to test the API endpoints, you can use tools like Postman or curl.\n\n## Error Handling\n\nErrors are logged to the console for debugging.\n\n## Future Work\n\n- Include a testing framework for robust testing.\n- Expand the error handling to include more specific error messages and status codes.\n- Add more endpoints as necessary for the application's needs. \n- Add authentication/authorization for the api endpoints\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpushpabrol%2Ftxn-message-store-sqlite","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpushpabrol%2Ftxn-message-store-sqlite","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpushpabrol%2Ftxn-message-store-sqlite/lists"}