Account Rest API¶
Overview
Resource |
Operation |
Description |
|---|---|---|
Account |
List all accounts. |
|
AccountParameter |
Update account information. |
|
Delete account information. |
||
Add account. |
||
Get account parameters. |
||
Attributes |
Delete account attribute |
|
Add account attribute |
||
list account attributes. |
||
GlobalAccountLimits |
Get global account limits. |
|
GlobalUsage |
Get global account usage. |
|
Identities |
Remove identity from account. |
|
Add identity to account. |
||
Get account idenitity mapping. |
||
LocalAccountLimits |
Get local account limits. |
|
LocalUsage |
Get local account usage. |
|
Rules |
Get rules for account. |
|
Scope |
Add to account. |
|
Scopes |
List scope for account. |
|
UsageHistory |
Get account usage history. |
Details
-
GET/accounts/¶ list all rucio accounts.
- Response Headers
Content-Type – application/x-json-stream
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
406 Not Acceptable – Not Acceptable
500 Internal Server Error – Database exception
- Returns
A list containing all account names as dict.
-
GET/accounts/(account)/limits/global/(rse_expression)¶
-
GET/accounts/(account)/limits/global¶ get the current global limits for an account on a specific RSE expression
- Parameters
account – The account name.
rse_expression – The rse expression.
- Response Headers
Content-Type – application/json
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – RSE not found.
406 Not Acceptable – Not Acceptable.
500 Internal Server Error – Database exception
- Returns
JSON dict containing informations about the requested user.
-
GET/accounts/(account)/limits/local/(rse)¶
-
GET/accounts/(account)/limits/local¶ get the current local limits for an account on a specific RSE
- Parameters
account – The account name.
rse – The rse name.
- Response Headers
Content-Type – application/json
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – RSE not found.
406 Not Acceptable – Not Acceptable.
500 Internal Server Error – Database exception
- Returns
JSON dict containing informations about the requested user.
-
GET/accounts/(account)/usage/history/(rse)¶ Return the account usage of the account.
- Parameters
account – The account name.
rse – The RSE.
- Response Headers
Content-Type – application/json
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
406 Not Acceptable – Not Acceptable.
500 Internal Server Error – Database exception.
- Returns
Line separated list of account usages.
Return the account usage of the account.
-
DELETE/accounts/(account)/identities¶ Delete an account’s identity mapping.
- Parameters
account – Account identifier.
- Request JSON Object
identity (string) – The identity name.
authtype (string) – The authentication type.
- Status Codes
200 OK – Successfully deleted.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
404 Not Found – Identity not found.
500 Internal Server Error – Database exception.
-
POST/accounts/(account)/identities¶ Grant an identity access to an account.
- Parameters
account – Account identifier.
- Request JSON Object
identity (string) – The identity name.
authtype (string) – The auth type of the identity.
email (string) – The email address.
- Status Codes
201 Created – Successfully added.
400 Bad Request – Parameter missing.
401 Unauthorized – Invalid auth token.
409 Conflict – Already exists.
404 Not Found – Account not found.
500 Internal Server Error – Database exception.
-
GET/accounts/(account)/identities¶ Get all identities mapped to an account.
- Response Headers
Content-Type – application/x-json-stream
- Parameters
account – The account identifier.
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
500 Internal Server Error – Database exception
- Statsu 406
Not Acceptable.
- Returns
Line separated dicts of identities.
-
POST/accounts/(account)/scopes/(scope)¶ create scope with given scope name.
- Parameters
account – The account identifier.
scope – The scope to be added.
- Status Codes
201 Created – Successfully added.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
409 Conflict – Scope already exists.
500 Internal Server Error – Database exception.
-
GET/accounts/(account)/scopes¶ list all scopes for an account.
- Parameters
account – The account identifier.
- Response Headers
Content-Type – application/x-json-stream
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
404 Not Found – Scope not found.
500 Internal Server Error – Database exception.
- Statsu 406
Not Acceptable
- Returns
A list containing all scope names for an account.
-
GET/accounts/(account)/usage/(rse)¶
-
GET/accounts/(account)/usage¶ Return the local account usage of the account.
- Parameters
account – The account name.
- Response Headers
Content-Type – application/x-json-stream
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
404 Not Found – RSE not found.
406 Not Acceptable – Not Acceptable.
500 Internal Server Error – Database exception.
- Returns
Line separated list of account usages.
-
GET/accounts/(account)/usage/(rse_expression)¶
-
GET/accounts/(account)/usage¶ Return the global account usage of the account.
- Parameters
account – The account name.
- Response Headers
Content-Type – application/x-json-stream
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
404 Not Found – RSE not found.
406 Not Acceptable – Not Acceptable.
500 Internal Server Error – Database exception.
- Returns
Line separated list of account usages.
-
GET/accounts/(account)/rules¶ Return all rules of a given account.
- Parameters
scope – The scope name.
- Response Headers
Content-Type – application/x-json-stream
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Rule not found.
406 Not Acceptable – Not Acceptable.
500 Internal Server Error – Database exception.
- Returns
Line separated list of rules.
-
DELETE/accounts/(account)/attr/(key)¶ Remove attribute from account.
- Parameters
account – Account identifier.
key – The attribute key.
- Status Codes
200 OK – Successfully deleted.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
500 Internal Server Error – Database Exception.
-
POST/accounts/(account)/attr/(key)¶ Add attributes to an account.
- Parameters
account – Account identifier.
key – The attribute key.
- Request JSON Object
key (string) – The attribute key.
value (string) – The attribute value.
- Status Codes
201 Created – Successfully created.
401 Unauthorized – Invalid auth token.
409 Conflict – Attribute already exists.
404 Not Found – Account not found.
500 Internal Server Error – Database Exception.
-
GET/accounts/(account)/attr¶ list all attributes for an account.
- Parameters
account – The account identifier.
- Response Headers
Content-Type – application/json
- Status Codes
200 OK – OK
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
406 Not Acceptable – Not Acceptable
500 Internal Server Error – Database Exception.
- Returns
JSON dict containing informations about the requested account.
-
PUT/accounts/(account)¶ update a parameter for a given account name
- Parameters
account – The account identifier.
- Status Codes
200 OK – OK.
400 Bad Request – Unknown status.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
500 Internal Server Error – Database exception.
-
DELETE/accounts/(account)¶ disable account with given account name.
- Parameters
account – The account identifier.
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
500 Internal Server Error – Database exception.
-
POST/accounts/(account)¶ create account with given account name.
- Parameters
account – The account identifier.
- Request JSON Object
type (string) – The account type.
email (string) – The account email.
- Status Codes
201 Created – Successfully created.
401 Unauthorized – Invalid auth token.
409 Conflict – Account already exists.
500 Internal Server Error – Database exception.
-
GET/accounts/(account)¶ get account parameters for given account name.
- Parameters
account – The account identifier.
- Status Codes
200 OK – OK.
401 Unauthorized – Invalid auth token.
404 Not Found – Account not found.
406 Not Acceptable – Not Acceptable.
500 Internal Server Error – Database exception.
- Returns
JSON dict containing informations about the requested user.