satellite/admin: add owner full name on /api/apikeys/{apikey} endpoint
Updates storj/gateway-mt#321 Change-Id: I6759ec5dbba49261bb183e42d8cb333c326cb9e8
This commit is contained in:
parent
d06e4589ae
commit
b1523f82c8
@ -422,6 +422,7 @@ A successful response body:
|
||||
},
|
||||
"owner": {
|
||||
"id": "12345678-1234-1234-1234-123456789abc",
|
||||
"fullName": "test user",
|
||||
"email": "bob@example.test",
|
||||
"paidTier": true
|
||||
}
|
||||
|
@ -164,6 +164,7 @@ func (server *Server) getAPIKey(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
type ownerData struct {
|
||||
ID uuid.UUID `json:"id"`
|
||||
FullName string `json:"fullName"`
|
||||
Email string `json:"email"`
|
||||
PaidTier bool `json:"paidTier"`
|
||||
}
|
||||
@ -184,6 +185,7 @@ func (server *Server) getAPIKey(w http.ResponseWriter, r *http.Request) {
|
||||
},
|
||||
Owner: ownerData{
|
||||
ID: user.ID,
|
||||
FullName: user.FullName,
|
||||
Email: user.Email,
|
||||
PaidTier: user.PaidTier,
|
||||
},
|
||||
|
@ -315,6 +315,7 @@ func TestAPIKeyManagementGet(t *testing.T) {
|
||||
}
|
||||
type ownerData struct {
|
||||
ID uuid.UUID `json:"id"`
|
||||
FullName string `json:"fullName"`
|
||||
Email string `json:"email"`
|
||||
PaidTier bool `json:"paidTier"`
|
||||
}
|
||||
@ -339,6 +340,7 @@ func TestAPIKeyManagementGet(t *testing.T) {
|
||||
},
|
||||
Owner: ownerData{
|
||||
ID: user.ID,
|
||||
FullName: "testuser123",
|
||||
Email: "test@email.com",
|
||||
PaidTier: true,
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user