Expose stored social verification evidence in the admin CLI - #214
Conversation
Co-authored-by: Sahil Lavingia <sahil@gumroad.com>
Greptile SummaryThis PR adds a read-only administrative command for inspecting stored social-verification evidence while preserving the API response for structured consumers.
Confidence Score: 5/5The PR appears safe to merge; no actionable correctness, security, or repository-rule violations remain. The new command stays on the shared authenticated admin read path, preserves raw JSON and JQ responses, safely renders plain and human output, and maintains the distinctions between unknown counts, zero counts, historical evidence, and current linkage. The previous explanatory-comment finding was manually resolved and the comment is absent from the current code.
|
| Filename | Overview |
|---|---|
| internal/cmd/admin/users/social_connections.go | Implements the read-only social-evidence request and safe rendering across supported output modes. |
| internal/cmd/admin/users/social_connections_test.go | Covers all lookup forms, structured and human output, nullable counts, escaping, empty results, and failures. |
| internal/cmd/admin/users/users.go | Registers the new command in the administrative users command group. |
| skills/gumroad/SKILL.md | Documents the response path, safety boundaries, nullable values, and plain-output column order. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart LR
Operator[Admin operator] --> Command[admin users social-connections]
Command --> Lookup[Validate user lookup]
Lookup --> Runner[Shared admin read runner]
Runner --> API[Internal admin API]
API --> Response[Stored social evidence]
Response --> Structured[JSON or JQ response]
Response --> Plain[Escaped tab-separated row]
Response --> Human[Labeled evidence view]
Reviews (2): Last reviewed commit: "Remove redundant renderer comment" | Re-trigger Greptile
TastelintThe only screenshot is terminal test-runner output, not a user interface, so there is nothing here for me to review visually. |
What
Adds
gumroad admin users social-connections, a read-only view of the existing internal admin endpoint. Shows whether each connection is currently linked, when it was verified, account/post history, and shared-identity count. Unknown audience counts stay distinct from zero. JSON/JQ preserve the full server response; plain output has a documented column order.This is one reviewer-tooling slice of https://github.com/antiwork/gumroad-private/issues/2371, not completion of that tracker. It does not add onboarding prompts, expose shadow scores, refresh providers, change eligibility, or release payouts.
Why
Social verification is already collected and exposed by the Rails API, but the CLI had no command to read it. Reusing the existing admin client avoids a parallel authorization or scoring implementation. Disconnected historical evidence is explicitly not presented as a current connection or payout approval.
Before/After
Recorded real main/branch binaries against a local API fixture matching the Rails serializer; no production accounts or writes. Main rejects the command; the branch renders disconnected evidence, unknown followers, zero posts, and shared identity. The recording was inspected by frame extraction and OCR. This is a CLI flow, not a hosted web UI.
gp2371-demo.mp4
Test Results
make test-cover GOFLAGS=-p=1— full suite and all coverage gates pass; admin users coverage 86.4%.The initial parallel suite hit timeout-sensitive media-upload tests; the same failure reproduced on unchanged main. Serial package execution passed the complete suite without changing those tests. The command recording remains current: later commits only strengthen tests and remove a comment.
QA steps
Run
gumroad admin users social-connections --help, then use an authorized existing admin lookup with--jsonto inspect stored evidence. Comparecurrently_linked, verification timestamps, nullable counts and shared identities against the same server response in human/plain modes. This does not fetch fresh provider data, expose shadow scores, approve sellers or release payouts.Premerge review: clean @ a5cd844
AI-assisted with OpenAI GPT-6 Astra via Hermes. Instructions: drain qualifying backlog, make verified social evidence available to risk reviewers through the CLI, preserve read-only scope and unknown/current-link distinctions, add tests and real command evidence. No automatic payout release or rollout changes.