{"id":17008707,"url":"https://github.com/i-e-b/gasconade","last_synced_at":"2026-05-01T21:32:04.449Z","repository":{"id":139825165,"uuid":"124519748","full_name":"i-e-b/gasconade","owner":"i-e-b","description":"A self-documenting logging system","archived":false,"fork":false,"pushed_at":"2018-11-26T08:22:26.000Z","size":172,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-04-14T02:14:55.244Z","etag":null,"topics":["documentation","documentation-tool","logging","production-ready","swagger","ui","working"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/i-e-b.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-03-09T09:36:09.000Z","updated_at":"2023-08-30T12:44:30.000Z","dependencies_parsed_at":"2023-07-10T08:00:38.506Z","dependency_job_id":null,"html_url":"https://github.com/i-e-b/gasconade","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/i-e-b/gasconade","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i-e-b%2Fgasconade","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i-e-b%2Fgasconade/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i-e-b%2Fgasconade/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i-e-b%2Fgasconade/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/i-e-b","download_url":"https://codeload.github.com/i-e-b/gasconade/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i-e-b%2Fgasconade/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32513517,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["documentation","documentation-tool","logging","production-ready","swagger","ui","working"],"created_at":"2024-10-14T05:29:03.739Z","updated_at":"2026-05-01T21:32:04.431Z","avatar_url":"https://github.com/i-e-b.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Gasconade\n\n\u003cimg src=\"https://github.com/i-e-b/gasconade/raw/master/icon.png\"/\u003e\nhttps://www.nuget.org/packages/Gasconade\n\nA self-documenting logging system for .Net -- like Swagger (UI) for logs.\n\nConcepts\n--------\n\n### Configuring:\n```csharp\npublic class MyListenerClass: ILogListener { . . . }\n. . .\nLog.AddListener(new MyListenerClass());\n```\n\n### Calling:\n```csharp\nLog.Warning(new FailedToSend{Client=\"WhizbangSvc\", Reason=\"it was rejected by client\"});\n```\n\n### Message Setup:\n```csharp\n// This is the structure of the message, with replacement blocks:\n[LogMessageTemplate(\"Could not send message to {Client} because {Reason}\")]\n// This text explains why the message would be logged, and what to do about it -- to be used by an Operations team:\n[LogMessageDescription(\"A message was to be sent to a 3rd party client, but a non-network error occured.\",\n                       Causes = \"Sent as a warning if it is not customer-impacting, as an error otherwise.\",\n                       Actions = \"Check configuration matches accounts if one client gets repeated errors.\")]\npublic class FailedToSend : TemplatedLogMessage {\n    [LogParam(\"The 3rd party we were trying to send to\")]\n    public string Client {get;set;}\n\n    [LogParam(\"Human-readable reason the message failed\")]\n    public string Reason {get;set;}\n}\n```\n\n### Sample Result:\n\u003e Could not send message to WhizbangSvc because it was rejected by client\n\n# Gasconade UI\n\n## Aspnet Core MVC\n\nAdd to application configuration like:\n```csharp\napp.UseMvc();\napp.UseGasconadeUI(config =\u003e {\n    config.AddAssembly(typeof(AnyMessageInTheProject).Assembly);\n});\n```\n\n## .Net Framework MVC WebApi\n\nAdd in global config like:\n```csharp\nprotected void Application_Start() {\n    . . .\n    GlobalConfiguration.Configure(MyGasconadeConfig.Register);\n}\n```\n\nAnd a class like:\n```csharp\npublic class GasconadeConfig {\n    public static void Register(HttpConfiguration config) {\n        config.EnableGasconadeUi();\n    }\n}\n```\n\n## Accessing the UI\n\nIf the setup is correct, there should be a route at `http(s)://. . ./gasconade` that exposes the UI.\nYou can add a link from your SwaggerUI like this:\n\n```csharp\nconfig.EnableSwagger(c =\u003e {\n            c.SingleApiVersion(\"v1\", \"SampleWebApi\")\n             .Description(\"A sample web application.\u003cbr/\u003eFor logging details, see \" + GasconadeUi.Link(\"here\"));\n        })\n    .EnableSwaggerUi(c =\u003e {\n            c.DocumentTitle(\"My Swagger UI\");\n        });\n```\n\nIf your message definitions are in a different assembly, you can add them like this:\n\n```csharp\nconfig.EnableGasconadeUi(c =\u003e\n    {\n        c.AddAssembly(typeof(AnyMessageInTheProject).Assembly);\n    });\n```\n\nYou can add a link back to Swagger UI like this:\n\n```csharp\nconfig.EnableGasconadeUi(c =\u003e\n    {\n        . . .\n        c.AddSwaggerLink();\n    });\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fi-e-b%2Fgasconade","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fi-e-b%2Fgasconade","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fi-e-b%2Fgasconade/lists"}