{"id":23012726,"url":"https://github.com/velddev/aspnetcore.exceptions","last_synced_at":"2025-04-02T17:14:00.483Z","repository":{"id":54868012,"uuid":"325397827","full_name":"velddev/AspNetCore.Exceptions","owner":"velddev","description":"AspNetCore exception-based error handler","archived":false,"fork":false,"pushed_at":"2022-09-30T22:45:53.000Z","size":32,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-08T07:42:23.918Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C#","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/velddev.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":"2020-12-29T22:15:01.000Z","updated_at":"2022-09-30T22:45:58.000Z","dependencies_parsed_at":"2022-08-14T05:10:45.412Z","dependency_job_id":null,"html_url":"https://github.com/velddev/AspNetCore.Exceptions","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/velddev%2FAspNetCore.Exceptions","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/velddev%2FAspNetCore.Exceptions/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/velddev%2FAspNetCore.Exceptions/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/velddev%2FAspNetCore.Exceptions/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/velddev","download_url":"https://codeload.github.com/velddev/AspNetCore.Exceptions/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246856677,"owners_count":20844974,"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-12-15T10:18:58.079Z","updated_at":"2025-04-02T17:14:00.451Z","avatar_url":"https://github.com/velddev.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AspNetCore.Exceptions\nAspNetCore exception-based error handler\n\n## Examples\n\n### With attributes\nFor existing exceptions, a simple attribute to define the returning status code.\n\n```cs\n[StatusCode(400)]\nclass MyException : Exception \n{\n  ...\n}\n```\n\n### With parent types\nTo define a new exception which is going to be handled, use `HttpException` as your parent class.\n\n```cs\nclass MyException : HttpException {\n  public MyException()\n    : base(400)\n  {}\n}\n```\n\n### With message\nTo create a user-friendly response message \n\n```cs\nclass MyException : HttpException, IExplainableException {\n  public MyException()\n    : base(400)\n  {}\n\n  object Explain() {\n    return \"Could not finish the example.\";\n  }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvelddev%2Faspnetcore.exceptions","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvelddev%2Faspnetcore.exceptions","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvelddev%2Faspnetcore.exceptions/lists"}