-
Notifications
You must be signed in to change notification settings - Fork 136
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Description
Token creation via API v2 fails because the frontend sends snake_case
token request fields, while the backend expects camelCase fields.
Steps to Reproduce
- Build FOSSologyUI pointing to API v2:
NEXT_PUBLIC_SERVER_URL=localhost/repo/api/v2
- Attempt to create a new authentication token via the UI or REST call.
- Observe token creation failure or missing token metadata.
Expected Behavior
Token should be created successfully with correct token name, scope,
and expiry.
Actual Behavior
Token metadata is ignored or token creation fails because the backend
does not recognize the provided request fields.
Root Cause
The backend TokenRequest::fromArray() explicitly expects camelCase
fields (tokenName, tokenScope, tokenExpire), but the frontend
sends snake_case fields (token_name, token_scope, token_expire).
Environment
- FOSSologyUI version: main branch
- API version: v2
- OS: macOS (Apple Silicon)
- Browser: Chrome
Additional Context
This issue only affects API v2 authentication token creation.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working