17119: add documentation.
[arvados.git] / doc / api / methods / api_client_authorizations.html.textile.liquid
index 75ffd3ffbed0e191915749855b34fd4964a13466..bcf77564c5e793f12646fca760cf22dd9c575640 100644 (file)
@@ -5,56 +5,69 @@ navmenu: API Methods
 title: "api_client_authorizations"
 
 ...
+{% comment %}
+Copyright (C) The Arvados Authors. All rights reserved.
 
+SPDX-License-Identifier: CC-BY-SA-3.0
+{% endcomment %}
 
+API endpoint base: @https://{{ site.arvados_api_host }}/arvados/v1/api_client_authorizations@
 
-Required arguments are displayed in %{background:#ccffcc}green%.
+Object type: @gj3su@
 
+Example UUID: @zzzzz-gj3su-0123456789abcde@
 
-h2. create
+h2. Resource
 
-Create a new ApiClientAuthorization.
+The @api_client_authorizations@ resource stores the API tokens that have been issued to permit access the API server.
 
-Arguments:
+An ApiClientAuthorization is *not* a generic Arvados resource.  The full list of properties that belong to an ApiClientAuthorization is:
 
 table(table table-bordered table-condensed).
-|_. Argument |_. Type |_. Description |_. Location |_. Example |
-|api_client_authorization|object||query||
+|_. Attribute|_. Type|_. Description|_. Example|
+|uuid|string|An identifier used to refer to the token without exposing the actual token.||
+|api_token|string|The actual token string that is expected in the Authorization header.||
+|api_client_id|integer|-||
+|user_id|integer|-||
+|created_by_ip_address|string|-||
+|last_used_by_ip_address|string|The network address of the most recent client using this token.||
+|last_used_at|datetime|Timestamp of the most recent request using this token.||
+|expires_at|datetime|Time at which the token is no longer valid.  May be set to a time in the past in order to immediately expire a token.||
+|owner_uuid|string|The user associated with the token.  All operations using this token are checked against the permissions of this user.||
+|scopes|array|A list of resources this token is allowed to access.  A scope of ["all"] allows all resources.  See "API Authorization":{{site.baseurl}}/api/tokens.html#scopes for details.||
+
+h2. Methods
+
+See "Common resource methods":{{site.baseurl}}/api/methods.html for more information about @create@, @delete@, @get@, @list@, and @update@.
 
-h2. create_system_auth
-
-create_system_auth api_client_authorizations
-
-Arguments:
+Required arguments are displayed in %{background:#ccffcc}green%.
 
-table(table table-bordered table-condensed).
-|_. Argument |_. Type |_. Description |_. Location |_. Example |
-|api_client_id|integer||query||
-|scopes|array||query||
+h3(#create). create
 
-h2. delete
+Create a new ApiClientAuthorization.
 
-Delete an existing ApiClientAuthorization.
+Regular users may only create self-owned API tokens, but may provide a restricted "scope":{{site.baseurl}}/api/tokens.html#scopes .  Administrators may create API tokens corresponding to any user.
 
 Arguments:
 
 table(table table-bordered table-condensed).
 |_. Argument |_. Type |_. Description |_. Location |_. Example |
-{background:#ccffcc}.|uuid|string|The UUID of the ApiClientAuthorization in question.|path||
+|api_client_authorization|object||query||
 
-h2. destroy
+h3. create_system_auth
 
-destroy api_client_authorizations
+create_system_auth api_client_authorizations
 
 Arguments:
 
 table(table table-bordered table-condensed).
 |_. Argument |_. Type |_. Description |_. Location |_. Example |
-{background:#ccffcc}.|uuid|string||path||
+|api_client_id|integer||query||
+|scopes|array||query||
 
-h2. get
+h3. delete
 
-Gets a ApiClientAuthorization's metadata by UUID.
+Delete an existing ApiClientAuthorization.
 
 Arguments:
 
@@ -62,42 +75,23 @@ table(table table-bordered table-condensed).
 |_. Argument |_. Type |_. Description |_. Location |_. Example |
 {background:#ccffcc}.|uuid|string|The UUID of the ApiClientAuthorization in question.|path||
 
-h2. index
+h3. get
 
-index api_client_authorizations
+Gets an ApiClientAuthorization's metadata by UUID.
 
 Arguments:
 
 table(table table-bordered table-condensed).
 |_. Argument |_. Type |_. Description |_. Location |_. Example |
-|order|string||query||
-|where|object||query||
+{background:#ccffcc}.|uuid|string|The UUID of the ApiClientAuthorization in question.|path||
 
-h2. list
+h3. list
 
 List api_client_authorizations.
 
-Arguments:
-
-table(table table-bordered table-condensed).
-|_. Argument |_. Type |_. Description |_. Location |_. Example |
-|limit|integer (default 100)|Maximum number of api_client_authorizations to return.|query||
-|order|string|Order in which to return matching api_client_authorizations.|query||
-|pageToken|string|Page token.|query||
-|q|string|Query string for searching api_client_authorizations.|query||
-|where|object|Conditions for filtering api_client_authorizations.|query||
-
-h2. show
-
-show api_client_authorizations
-
-Arguments:
-
-table(table table-bordered table-condensed).
-|_. Argument |_. Type |_. Description |_. Location |_. Example |
-{background:#ccffcc}.|uuid|string||path||
+See "common resource list method.":{{site.baseurl}}/api/methods.html#index
 
-h2. update
+h3. update
 
 Update attributes of an existing ApiClientAuthorization.