Skip to content

feat(redteam): custom target adapter commands (list/get/create/update/delete/validate) - #308

Merged
cdot65 merged 4 commits into
mainfrom
cdot65/feat/redteam-adapters
Aug 5, 2026
Merged

feat(redteam): custom target adapter commands (list/get/create/update/delete/validate)#308
cdot65 merged 4 commits into
mainfrom
cdot65/feat/redteam-adapters

Conversation

@cdot65

@cdot65 cdot65 commented Aug 1, 2026

Copy link
Copy Markdown
Owner

Summary

Slice 4 of #299: Red Team custom target adapters (SDK 0.16.0), additive to the existing redteam group. Stacked on #305 (pin bump) — independent of the AI Gateway slices.

Changes

  • SdkRedTeamService adapter methods: listAdapters/getAdapter/createAdapter/updateAdapter/deleteAdapter/validateAdapter
  • Update is read-modify-write: upstream PUT is full-replacement and an omitted variable key is DELETED — the CLI merges overrides onto the current record and resends stored variables (secrets as value: null = keep stored). --variables explicitly replaces the whole set. --prompt required (upstream never stores it)
  • Secrets render (redacted) keyed off is_redacted (live tenant masks with '**********', not null)
  • Validate: preflights broker channel ONLINE with a clear failure message; auto-fills the required full variables array from --adapter <uuid>; renders the execution outcome with stderr/traceback on failure and exit 1
  • --script-file (auto-base64) / --script-b64; --draft saves without running the script
  • Docs page docs-site/docs/cli/redteam/adapters.md; changeset (minor)

Testing

  • TDD: 9 failing wrapper specs committed first; +9 helper specs (script resolution, variables parsing)
  • 885 tests green on this branch; tsc + Biome + docs build clean

Closes #303

@cdot65
cdot65 force-pushed the cdot65/feat/redteam-adapters branch from c7d0287 to 9d3f6f1 Compare August 5, 2026 21:51
@cdot65
cdot65 merged commit f389f89 into main Aug 5, 2026
4 checks passed
@cdot65
cdot65 deleted the cdot65/feat/redteam-adapters branch August 5, 2026 21:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(redteam): custom target adapter commands (list/get/create/update/delete/validate)

1 participant