libica.openapi.v2.UserApi¶
All URIs are relative to /ica/rest
Method | HTTP request | Description |
---|---|---|
approve_user | POST /api/users/{userId}:approve | Approve a user. |
assign_tenant_admin_rights_to_user | POST /api/users/{userId}:assignTenantAdministratorRights | Assign tenant administrator rights to a user. |
get_user | GET /api/users/{userId} | Retrieve a user. |
get_users | GET /api/users | Retrieve a list of users. |
revoke_tenant_admin_rights_to_user | POST /api/users/{userId}:revokeTenantAdministratorRights | Revoke tenant administrator rights to a user. |
update_user | PUT /api/users/{userId} | Update a user. |
approve_user¶
approve_user(user_id)
Approve a user.
Endpoint for approving a user.This is a non-RESTful endpoint, as the path of this endpoint is not representing a REST resource.
Example¶
- Api Key Authentication (ApiKeyAuth):
- Bearer (JWT) Authentication (JwtAuth):
import time
import libica.openapi.v2
from libica.openapi.v2.api import user_api
from libica.openapi.v2.model.problem import Problem
from pprint import pprint
# Defining the host is optional and defaults to /ica/rest
# See configuration.py for a list of all supported configuration parameters.
configuration = libica.openapi.v2.Configuration(
host = "/ica/rest"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Configure Bearer authorization (JWT): JwtAuth
configuration = libica.openapi.v2.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with libica.openapi.v2.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = user_api.UserApi(api_client)
user_id = "userId_example" # str |
# example passing only required values which don't have defaults set
try:
# Approve a user.
api_instance.approve_user(user_id)
except libica.openapi.v2.ApiException as e:
print("Exception when calling UserApi->approve_user: %s\n" % e)
Parameters¶
Name | Type | Description | Notes |
---|---|---|---|
user_id | str |
Return type¶
void (empty response body)
Authorization¶
HTTP request headers¶
- Content-Type: Not defined
- Accept: application/problem+json
HTTP response details¶
Status code | Description | Response headers |
---|---|---|
204 | The user is successfully approved. | - |
0 | A problem occurred. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
assign_tenant_admin_rights_to_user¶
assign_tenant_admin_rights_to_user(user_id)
Assign tenant administrator rights to a user.
Endpoint for assigning tenant administrator rights to a user.This is a non-RESTful endpoint, as the path of this endpoint is not representing a REST resource.
Example¶
- Api Key Authentication (ApiKeyAuth):
- Bearer (JWT) Authentication (JwtAuth):
import time
import libica.openapi.v2
from libica.openapi.v2.api import user_api
from libica.openapi.v2.model.problem import Problem
from pprint import pprint
# Defining the host is optional and defaults to /ica/rest
# See configuration.py for a list of all supported configuration parameters.
configuration = libica.openapi.v2.Configuration(
host = "/ica/rest"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Configure Bearer authorization (JWT): JwtAuth
configuration = libica.openapi.v2.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with libica.openapi.v2.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = user_api.UserApi(api_client)
user_id = "userId_example" # str |
# example passing only required values which don't have defaults set
try:
# Assign tenant administrator rights to a user.
api_instance.assign_tenant_admin_rights_to_user(user_id)
except libica.openapi.v2.ApiException as e:
print("Exception when calling UserApi->assign_tenant_admin_rights_to_user: %s\n" % e)
Parameters¶
Name | Type | Description | Notes |
---|---|---|---|
user_id | str |
Return type¶
void (empty response body)
Authorization¶
HTTP request headers¶
- Content-Type: Not defined
- Accept: application/problem+json
HTTP response details¶
Status code | Description | Response headers |
---|---|---|
204 | The tenant administrator rights are successfully assigned. | - |
0 | A problem occurred. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_user¶
User get_user(user_id)
Retrieve a user.
Example¶
- Api Key Authentication (ApiKeyAuth):
- Bearer (JWT) Authentication (JwtAuth):
import time
import libica.openapi.v2
from libica.openapi.v2.api import user_api
from libica.openapi.v2.model.user import User
from libica.openapi.v2.model.problem import Problem
from pprint import pprint
# Defining the host is optional and defaults to /ica/rest
# See configuration.py for a list of all supported configuration parameters.
configuration = libica.openapi.v2.Configuration(
host = "/ica/rest"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Configure Bearer authorization (JWT): JwtAuth
configuration = libica.openapi.v2.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with libica.openapi.v2.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = user_api.UserApi(api_client)
user_id = "userId_example" # str |
# example passing only required values which don't have defaults set
try:
# Retrieve a user.
api_response = api_instance.get_user(user_id)
pprint(api_response)
except libica.openapi.v2.ApiException as e:
print("Exception when calling UserApi->get_user: %s\n" % e)
Parameters¶
Name | Type | Description | Notes |
---|---|---|---|
user_id | str |
Return type¶
Authorization¶
HTTP request headers¶
- Content-Type: Not defined
- Accept: application/problem+json, application/vnd.illumina.v3+json
HTTP response details¶
Status code | Description | Response headers |
---|---|---|
200 | The user is successfully retrieved. | * ETag - The current version of the resource. Can be passed to the corresponding PUT endpoint to enable conflict exposure (409 response). |
0 | A problem occurred. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_users¶
UserList get_users()
Retrieve a list of users.
Example¶
- Api Key Authentication (ApiKeyAuth):
- Bearer (JWT) Authentication (JwtAuth):
import time
import libica.openapi.v2
from libica.openapi.v2.api import user_api
from libica.openapi.v2.model.user_list import UserList
from libica.openapi.v2.model.problem import Problem
from pprint import pprint
# Defining the host is optional and defaults to /ica/rest
# See configuration.py for a list of all supported configuration parameters.
configuration = libica.openapi.v2.Configuration(
host = "/ica/rest"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Configure Bearer authorization (JWT): JwtAuth
configuration = libica.openapi.v2.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with libica.openapi.v2.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = user_api.UserApi(api_client)
email_address = "emailAddress_example" # str, none_type | The email address to filter on (optional)
# example passing only required values which don't have defaults set
# and optional values
try:
# Retrieve a list of users.
api_response = api_instance.get_users(email_address=email_address)
pprint(api_response)
except libica.openapi.v2.ApiException as e:
print("Exception when calling UserApi->get_users: %s\n" % e)
Parameters¶
Name | Type | Description | Notes |
---|---|---|---|
email_address | str, none_type | The email address to filter on | [optional] |
Return type¶
Authorization¶
HTTP request headers¶
- Content-Type: Not defined
- Accept: application/problem+json, application/vnd.illumina.v3+json
HTTP response details¶
Status code | Description | Response headers |
---|---|---|
200 | The list of users is successfully retrieved. | - |
0 | A problem occurred. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
revoke_tenant_admin_rights_to_user¶
revoke_tenant_admin_rights_to_user(user_id)
Revoke tenant administrator rights to a user.
Endpoint for revoking tenant administrator rights to a user.This is a non-RESTful endpoint, as the path of this endpoint is not representing a REST resource.
Example¶
- Api Key Authentication (ApiKeyAuth):
- Bearer (JWT) Authentication (JwtAuth):
import time
import libica.openapi.v2
from libica.openapi.v2.api import user_api
from libica.openapi.v2.model.problem import Problem
from pprint import pprint
# Defining the host is optional and defaults to /ica/rest
# See configuration.py for a list of all supported configuration parameters.
configuration = libica.openapi.v2.Configuration(
host = "/ica/rest"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Configure Bearer authorization (JWT): JwtAuth
configuration = libica.openapi.v2.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with libica.openapi.v2.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = user_api.UserApi(api_client)
user_id = "userId_example" # str |
# example passing only required values which don't have defaults set
try:
# Revoke tenant administrator rights to a user.
api_instance.revoke_tenant_admin_rights_to_user(user_id)
except libica.openapi.v2.ApiException as e:
print("Exception when calling UserApi->revoke_tenant_admin_rights_to_user: %s\n" % e)
Parameters¶
Name | Type | Description | Notes |
---|---|---|---|
user_id | str |
Return type¶
void (empty response body)
Authorization¶
HTTP request headers¶
- Content-Type: Not defined
- Accept: application/problem+json
HTTP response details¶
Status code | Description | Response headers |
---|---|---|
204 | The tenant administrator rights are successfully revoked. | - |
0 | A problem occurred. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
update_user¶
User update_user(user_id, user)
Update a user.
Fields which can be updated: - greeting - two factor authentication - job title - first name - last name - mobile phone number - phone number - fax number - address lines - postal code - city - country - state
Example¶
- Api Key Authentication (ApiKeyAuth):
- Bearer (JWT) Authentication (JwtAuth):
import time
import libica.openapi.v2
from libica.openapi.v2.api import user_api
from libica.openapi.v2.model.user import User
from libica.openapi.v2.model.problem import Problem
from pprint import pprint
# Defining the host is optional and defaults to /ica/rest
# See configuration.py for a list of all supported configuration parameters.
configuration = libica.openapi.v2.Configuration(
host = "/ica/rest"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Configure Bearer authorization (JWT): JwtAuth
configuration = libica.openapi.v2.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with libica.openapi.v2.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = user_api.UserApi(api_client)
user_id = "userId_example" # str |
user = User(
id="id_example",
time_created=dateutil_parser('1970-01-01T00:00:00.00Z'),
time_modified=dateutil_parser('1970-01-01T00:00:00.00Z'),
owner_id="owner_id_example",
tenant_id="tenant_id_example",
tenant_name="tenant_name_example",
username="username_example",
email="email_example",
firstname="firstname_example",
lastname="lastname_example",
active=True,
tenant_administrator=True,
job_title="job_title_example",
greeting="MR",
mobile_phone_number="mobile_phone_number_example",
phone_number="phone_number_example",
fax_number="fax_number_example",
email_verified=True,
two_factor_authentication=True,
country=Country(
id="id_example",
time_created=dateutil_parser('1970-01-01T00:00:00.00Z'),
time_modified=dateutil_parser('1970-01-01T00:00:00.00Z'),
owner_id="owner_id_example",
tenant_id="tenant_id_example",
tenant_name="tenant_name_example",
code="code_example",
name="name_example",
region="region_example",
),
address_line1="address_line1_example",
address_line2="address_line2_example",
address_line3="address_line3_example",
postal_code="postal_code_example",
city="city_example",
state="state_example",
) # User |
if_match = "If-Match_example" # str | Optional header parameter to enable conflict exposure. If the client provides this header, then it must contains the client's most recent value of the 'ETag' response header, and the server will respond with a 409 code if it detects a conflict. If the client does not provide this header, then the server will not do a conflict check, which means that as a client you can override the resource even when the server has a more recent version. (optional)
# example passing only required values which don't have defaults set
try:
# Update a user.
api_response = api_instance.update_user(user_id, user)
pprint(api_response)
except libica.openapi.v2.ApiException as e:
print("Exception when calling UserApi->update_user: %s\n" % e)
# example passing only required values which don't have defaults set
# and optional values
try:
# Update a user.
api_response = api_instance.update_user(user_id, user, if_match=if_match)
pprint(api_response)
except libica.openapi.v2.ApiException as e:
print("Exception when calling UserApi->update_user: %s\n" % e)
Parameters¶
Name | Type | Description | Notes |
---|---|---|---|
user_id | str | ||
user | User | ||
if_match | str | Optional header parameter to enable conflict exposure. If the client provides this header, then it must contains the client's most recent value of the 'ETag' response header, and the server will respond with a 409 code if it detects a conflict. If the client does not provide this header, then the server will not do a conflict check, which means that as a client you can override the resource even when the server has a more recent version. | [optional] |
Return type¶
Authorization¶
HTTP request headers¶
- Content-Type: application/vnd.illumina.v3+json, application/json
- Accept: application/problem+json, application/vnd.illumina.v3+json
HTTP response details¶
Status code | Description | Response headers |
---|---|---|
200 | The user is successfully updated. | * ETag - The current version of the resource. Can be passed to the corresponding PUT endpoint to enable conflict exposure (409 response). |
0 | A problem occurred. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]