Skip to content

docs: fix incorrect SAT quick-start example in README#42

Open
dmchaledev wants to merge 1 commit into
mainfrom
claude/elegant-edison-taole5
Open

docs: fix incorrect SAT quick-start example in README#42
dmchaledev wants to merge 1 commit into
mainfrom
claude/elegant-edison-taole5

Conversation

@dmchaledev

Copy link
Copy Markdown
Contributor

Summary

The SAT "Enroll a User" quick-start example in README.md was factually wrong in three compounding ways, cross-checked against sat/openapi.yaml:

  • Wrong path/server: it posted to https://api.hailbytes.com/sat/v1/users, but the SAT spec's servers: block (sat/openapi.yaml:31-33) defines the server as /api, not /sat/v1.
  • Wrong endpoint semantics: POST /users/ (sat/openapi.yaml:1195-1204) is tagged Admin and described as "Creates a new system user. Requires modify_system permission" — it has nothing to do with enrolling a phishing-simulation target, and has no request body defined at all.
  • Nonexistent field: the example body used group_id, which doesn't appear on any schema in the spec.

The endpoint that actually matches "enroll a user" is POST /groups/ (createGroup, sat/openapi.yaml:899-917), which creates a target group from a Group schema containing a targets array of {email, first_name, last_name, ...} objects.

This fixes the example to hit the real endpoint with a request body that matches the Group/Target schemas.

Test plan

  • Verified POST /api/groups/ exists in sat/openapi.yaml and accepts a Group body with a targets array
  • Verified the ASM quick-start example elsewhere in the README already matches its spec's server/path (no change needed there)
  • Spectral lint / deploy-docs CI (README isn't linted by either workflow, but pushing to confirm nothing else breaks)

🤖 Generated with Claude Code

https://claude.ai/code/session_015e1CxUMwdy8rLKYgMuDZEL


Generated by Claude Code

The SAT enrollment example posted to a fictitious /sat/v1/users path
with a group_id field that doesn't exist on any schema. The real
endpoint (POST /api/groups/) creates a target group with a targets
array, per sat/openapi.yaml, and is what "enroll a user" maps to;
POST /users/ is an unrelated admin-only system-user endpoint.
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.

2 participants