{"id":15011122,"url":"https://github.com/ozylog/http-errors","last_synced_at":"2025-10-03T20:31:53.601Z","repository":{"id":57134719,"uuid":"77567855","full_name":"ozylog/http-errors","owner":"ozylog","description":"HTTP errors","archived":true,"fork":false,"pushed_at":"2017-08-28T12:19:01.000Z","size":17,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2024-11-06T20:51:14.336Z","etag":null,"topics":["errors","http","nodejs"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/ozylog.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-12-28T23:34:47.000Z","updated_at":"2023-01-28T17:50:34.000Z","dependencies_parsed_at":"2022-08-25T21:11:51.305Z","dependency_job_id":null,"html_url":"https://github.com/ozylog/http-errors","commit_stats":null,"previous_names":["ozylog/ozylog-http-errors"],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ozylog%2Fhttp-errors","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ozylog%2Fhttp-errors/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ozylog%2Fhttp-errors/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ozylog%2Fhttp-errors/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ozylog","download_url":"https://codeload.github.com/ozylog/http-errors/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235184513,"owners_count":18949254,"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":["errors","http","nodejs"],"created_at":"2024-09-24T19:39:01.388Z","updated_at":"2025-10-03T20:31:48.317Z","avatar_url":"https://github.com/ozylog.png","language":"JavaScript","readme":"# http-errors\nCreate HTTP error objects\n\n[![Travis](https://img.shields.io/travis/ozylog/http-errors.svg?style=flat-square)](https://travis-ci.org/ozylog/http-errors) [![npm](https://img.shields.io/npm/dt/@ozylog/http-errors.svg?style=flat-square)](https://www.npmjs.com/package/@ozylog/http-errors)\n\n## Installation\n\n```\nnpm install @ozylog/http-errors --save\n```\n\n## List of errors\n```javascript\nnew BadRequestError([message = 'Bad Request'])\nnew ForbiddenError([message = 'Forbidden'])\nnew InternalServerError([message = 'Internal Server Error'])\nnew NotAcceptableError([message = 'Not Acceptable'])\nnew NotFoundError([message = 'Not Found'])\nnew NotImplementedError([message = 'Not Implemented'])\nnew UnauthorizedError([message = 'Unauthorized'])\nnew CreateError([message], [statusCode])\n```\n\n## Usage Example\n```javascript\nimport {BadRequestError} from '@ozylog/http-errors';\n\nexport function validate(req, res, next) {\n  if (!req.body.name) return next(new BadRequestError());\n}\n```\n\n## License\nMIT\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fozylog%2Fhttp-errors","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fozylog%2Fhttp-errors","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fozylog%2Fhttp-errors/lists"}