You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Official OpenAPI Documentation for /api/v1 and /api/cli #857
I'd like to pick this up. I tried generating the spec with Scramble (latest release, v0.13.49), since it builds the document from routes, FormRequests and resources without annotations.
Most of the output looks good, but it gets the path parameters wrong on 19 routes: every /api/v1/users/{user:username}/... and /api/v1/remotes/@{partner:username}/... route.
Actual route
Generated by Scramble
POST /users/{user:username}/follow
/users/{follower}/follow (uuid)
POST /users/{user:username}/block
/users/{currentUser}/block (uuid)
GET /users/{user:username}/followers
/users/{currentUser}/followers (string|null)
PUT /remotes/@{partner:username}/read
/remotes/@{user}/read (uuid)
The cause seems to be how Scramble maps route parameters to controller arguments: it matches by type and position, so the injected #[CurrentUser] User argument wins over the real route-bound User. It also ignores the :username binding key and documents the parameter as the model's uuid primary key. Routes without an injected current user ({org}, {message}, {messageImage}) are generated correctly.
I confirmed it by swapping the argument order in UserFollowController::store: Scramble then produced the correct {user} parameter typed as a username string.
Activity
zangetsu02 commentedon Oct 25, 2026
I'd like to pick this up. I tried generating the spec with Scramble (latest release, v0.13.49), since it builds the document from routes, FormRequests and resources without annotations.
Most of the output looks good, but it gets the path parameters wrong on 19 routes: every
/api/v1/users/{user:username}/...and/api/v1/remotes/@{partner:username}/...route.POST /users/{user:username}/follow/users/{follower}/follow(uuid)POST /users/{user:username}/block/users/{currentUser}/block(uuid)GET /users/{user:username}/followers/users/{currentUser}/followers(string|null)PUT /remotes/@{partner:username}/read/remotes/@{user}/read(uuid)The cause seems to be how Scramble maps route parameters to controller arguments: it matches by type and position, so the injected
#[CurrentUser] Userargument wins over the real route-boundUser. It also ignores the:usernamebinding key and documents the parameter as the model's uuid primary key. Routes without an injected current user ({org},{message},{messageImage}) are generated correctly.I confirmed it by swapping the argument order in
UserFollowController::store: Scramble then produced the correct{user}parameter typed as a username string.eggplants commentedon Oct 26, 2026
See: https://egpl.dev/dev-null-tui/openapi/