{"id":17462865,"url":"https://github.com/mralias/redact","last_synced_at":"2025-04-19T18:54:48.744Z","repository":{"id":59047174,"uuid":"531586558","full_name":"MrAlias/redact","owner":"MrAlias","description":"Redact OpenTelemetry tracing data.","archived":false,"fork":false,"pushed_at":"2025-04-06T11:49:44.000Z","size":108,"stargazers_count":4,"open_issues_count":3,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-16T15:14:42.807Z","etag":null,"topics":["go","golang","opentelemetry","opentelemetry-go","otel","tracing"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MrAlias.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":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-09-01T15:51:00.000Z","updated_at":"2025-02-09T15:35:30.000Z","dependencies_parsed_at":"2023-11-12T17:23:39.142Z","dependency_job_id":"61cb1bea-98c8-4c5e-8bf2-8f70a3811b58","html_url":"https://github.com/MrAlias/redact","commit_stats":{"total_commits":78,"total_committers":4,"mean_commits":19.5,"dds":"0.39743589743589747","last_synced_commit":"f4d89c916448d01fd08155cc5ce67205c36e94eb"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MrAlias%2Fredact","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MrAlias%2Fredact/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MrAlias%2Fredact/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MrAlias%2Fredact/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MrAlias","download_url":"https://codeload.github.com/MrAlias/redact/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249770394,"owners_count":21323067,"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":["go","golang","opentelemetry","opentelemetry-go","otel","tracing"],"created_at":"2024-10-18T09:10:10.821Z","updated_at":"2025-04-19T18:54:48.666Z","avatar_url":"https://github.com/MrAlias.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Redact\n\n[![Go Reference](https://pkg.go.dev/badge/github.com/MrAlias/redact.svg)](https://pkg.go.dev/github.com/MrAlias/redact)\n\nUnfortunately, you are here.\nYou have [OpenTelemetry] tracing data that shouldn't exist and you want it gone.\nIdeally, you are able to stop the generation of this data.\nBut until that day arrives, `redact` can help!\n\n## Getting Started\n\nPass your needed redact option to a new [OpenTelemetry] [TracerProvider].\n\n### Redact Attributes\n\nReplace attributes from new spans that have keys matching `\"password\"`, `\"user\"`, and `\"secret\"` with a redacted value.\n\n```go\ntracerProvider := trace.NewTracerProvider(\n\tredact.Attributes(\"password\", \"user\", \"secret\"),\n\t/* ... */\n)\n```\n\n### Redact Spans based on name\n\nDrop spans whose name is `\"really-annoying-span\"` or any that match `\"health?check*\"` (e.g. `\"health-check\"`, `\"healthcheck-my-service\"`).\n\n```go\ntracerProvider := trace.NewTracerProvider(\n\tredact.Span(\"really-annoying-span\", \"health?check*\"),\n\t/* ... */\n)\n```\n\n[OpenTelemetry]: https://opentelemetry.io/\n[TracerProvider]: https://pkg.go.dev/go.opentelemetry.io/otel/sdk/trace#TracerProvider\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmralias%2Fredact","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmralias%2Fredact","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmralias%2Fredact/lists"}