Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Add `dkit audit-log`: look up Discord audit log event types

Open
#69 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
62/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
python
Domain
cli, devtools

Research direction

Start by reading the existing CLI command implementations and data registration in src/dkit/core/data.py, then inspect the README and tests for similar offline lookups. Add the event dataset at src/dkit/data/audit_log_events.json from the documented Audit Log Events table and cover listing, lookups, search, JSON output, and invalid input. Done means the documented event fields and gaps are preserved, the dataset count is updated, and the stated tests, lint, formatting, README, and changelog requirements are met.

Written by the indexing model from the issue text.

Description

enhancement new command

Problem

Discord audit log entries use numeric action_type values. Developers often need to identify an event from its value or find the value for an event name, but dkit has no offline lookup.

Proposed behaviour

Add dkit audit-log to list and look up the documented Audit Log Events.

$ dkit audit-log 22
MEMBER_BAN_ADD

$ dkit audit-log CHANNEL_CREATE
10

$ dkit --json audit-log --search MESSAGE
  • Include the event name, numeric value, description, and documented “Object Changed” field when present.
  • Support listing, numeric/name lookup, searching, and --json.
  • Unknown values should exit with code 2 and a useful hint.
  • Keep this as an offline reference only; do not query or modify a guild audit log.
  • Preserve gaps in the documented numeric values.

Data

  • Add src/dkit/data/audit_log_events.json with source, source_rendered, and last_verified.
  • Copy rows from “Audit Log Events” in developers/resources/audit-log.mdx:
    https://discord.com/developers/docs/resources/audit-log#audit-log-entry-object-audit-log-events.
  • The documented examples are MEMBER_BAN_ADD = 22 and CHANNEL_CREATE = 10.
  • Register the dataset in src/dkit/core/data.py and increase the exact JSON-file count in .github/workflows/ci.yml by one from the current base branch count.

Acceptance criteria

  • Tests cover representative events with and without an “Object Changed” value, numeric/name lookups, search, JSON output, and invalid input.
  • Tests fail if documented event names, values, descriptions, or object associations are changed incorrectly.
  • 100% line and branch coverage; ruff check and ruff format --check pass.
  • Update the README and add one bullet to the existing ### Added block under [Unreleased] in CHANGELOG.md; do not remove existing changelog lines.
  • Please comment on this issue before starting, as required by CONTRIBUTING.md. AI-assisted contributions are welcome; disclose AI use in the PR description.
Dominant language
Python
Stars
1
Forks
7
Avg merge
11h 50m
Merged PRs (30d)
35

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Bytewave1/dkit

All issues in Bytewave1/dkit

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.