1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: Apache-2.0
9 // APIClientAuthorization is an arvados#apiClientAuthorization resource.
10 type APIClientAuthorization struct {
11 UUID string `json:"uuid"`
12 APIToken string `json:"api_token"`
13 CreatedAt time.Time `json:"created_at"`
14 CreatedByIPAddress string `json:"created_by_ip_address"`
15 Etag string `json:"etag"`
16 ExpiresAt time.Time `json:"expires_at"`
17 LastUsedAt time.Time `json:"last_used_at"`
18 LastUsedByIPAddress string `json:"last_used_by_ip_address"`
19 ModifiedAt time.Time `json:"modified_at"`
20 ModifiedByUserUUID string `json:"modified_by_user_uuid"`
21 OwnerUUID string `json:"owner_uuid"`
22 Scopes []string `json:"scopes"`
25 // APIClientAuthorizationList is an arvados#apiClientAuthorizationList resource.
26 type APIClientAuthorizationList struct {
27 Items []APIClientAuthorization `json:"items"`
30 func (aca APIClientAuthorization) TokenV2() string {
31 return "v2/" + aca.UUID + "/" + aca.APIToken