jellyfin.generated.api_10_11.UserApi

All URIs are relative to http://localhost

Method HTTP request Description
authenticate_user_by_name POST /Users/AuthenticateByName Authenticates a user by name.
authenticate_with_quick_connect POST /Users/AuthenticateWithQuickConnect Authenticates a user with quick connect.
create_user_by_name POST /Users/New Creates a user.
delete_user DELETE /Users/{userId} Deletes a user.
forgot_password POST /Users/ForgotPassword Initiates the forgot password process for a local user.
forgot_password_pin POST /Users/ForgotPassword/Pin Redeems a forgot password pin.
get_current_user GET /Users/Me Gets the user based on auth token.
get_public_users GET /Users/Public Gets a list of publicly visible users for display on a login screen.
get_user_by_id GET /Users/{userId} Gets a user by Id.
get_users GET /Users Gets a list of users.
update_user POST /Users Updates a user.
update_user_configuration POST /Users/Configuration Updates a user configuration.
update_user_password POST /Users/Password Updates a user's password.
update_user_policy POST /Users/{userId}/Policy Updates a user policy.

authenticate_user_by_name

AuthenticationResult authenticate_user_by_name(authenticate_user_by_name)

Authenticates a user by name.

Example

import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.authenticate_user_by_name import AuthenticateUserByName
from jellyfin.generated.api_10_11.models.authentication_result import AuthenticationResult
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    authenticate_user_by_name = jellyfin.generated.api_10_11.AuthenticateUserByName() # AuthenticateUserByName | The M:Jellyfin.Api.Controllers.UserController.AuthenticateUserByName(Jellyfin.Api.Models.UserDtos.AuthenticateUserByName) request.

    try:
        # Authenticates a user by name.
        api_response = api_instance.authenticate_user_by_name(authenticate_user_by_name)
        print("The response of UserApi->authenticate_user_by_name:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->authenticate_user_by_name: %s\n" % e)

Parameters

Name Type Description Notes
authenticate_user_by_name AuthenticateUserByName The M:Jellyfin.Api.Controllers.UserController.AuthenticateUserByName(Jellyfin.Api.Models.UserDtos.AuthenticateUserByName) request.

Return type

AuthenticationResult

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 User authenticated. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.

[Back to top] [Back to API list] [Back to Model list] [Back to README]

authenticate_with_quick_connect

AuthenticationResult authenticate_with_quick_connect(quick_connect_dto)

Authenticates a user with quick connect.

Example

import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.authentication_result import AuthenticationResult
from jellyfin.generated.api_10_11.models.quick_connect_dto import QuickConnectDto
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    quick_connect_dto = jellyfin.generated.api_10_11.QuickConnectDto() # QuickConnectDto | The Jellyfin.Api.Models.UserDtos.QuickConnectDto request.

    try:
        # Authenticates a user with quick connect.
        api_response = api_instance.authenticate_with_quick_connect(quick_connect_dto)
        print("The response of UserApi->authenticate_with_quick_connect:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->authenticate_with_quick_connect: %s\n" % e)

Parameters

Name Type Description Notes
quick_connect_dto QuickConnectDto The Jellyfin.Api.Models.UserDtos.QuickConnectDto request.

Return type

AuthenticationResult

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 User authenticated. -
400 Missing token. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.

[Back to top] [Back to API list] [Back to Model list] [Back to README]

create_user_by_name

UserDto create_user_by_name(create_user_by_name)

Creates a user.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.create_user_by_name import CreateUserByName
from jellyfin.generated.api_10_11.models.user_dto import UserDto
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    create_user_by_name = jellyfin.generated.api_10_11.CreateUserByName() # CreateUserByName | The create user by name request body.

    try:
        # Creates a user.
        api_response = api_instance.create_user_by_name(create_user_by_name)
        print("The response of UserApi->create_user_by_name:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->create_user_by_name: %s\n" % e)

Parameters

Name Type Description Notes
create_user_by_name CreateUserByName The create user by name request body.

Return type

UserDto

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 User created. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -
403 Forbidden -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_user

delete_user(user_id)

Deletes a user.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    user_id = 'user_id_example' # str | The user id.

    try:
        # Deletes a user.
        api_instance.delete_user(user_id)
    except Exception as e:
        print("Exception when calling UserApi->delete_user: %s\n" % e)

Parameters

Name Type Description Notes
user_id str The user id.

Return type

void (empty response body)

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
204 User deleted. -
404 User not found. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -
403 Forbidden -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

forgot_password

ForgotPasswordResult forgot_password(forgot_password_dto)

Initiates the forgot password process for a local user.

Example

import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.forgot_password_dto import ForgotPasswordDto
from jellyfin.generated.api_10_11.models.forgot_password_result import ForgotPasswordResult
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    forgot_password_dto = jellyfin.generated.api_10_11.ForgotPasswordDto() # ForgotPasswordDto | The forgot password request containing the entered username.

    try:
        # Initiates the forgot password process for a local user.
        api_response = api_instance.forgot_password(forgot_password_dto)
        print("The response of UserApi->forgot_password:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->forgot_password: %s\n" % e)

Parameters

Name Type Description Notes
forgot_password_dto ForgotPasswordDto The forgot password request containing the entered username.

Return type

ForgotPasswordResult

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 Password reset process started. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.

[Back to top] [Back to API list] [Back to Model list] [Back to README]

forgot_password_pin

PinRedeemResult forgot_password_pin(forgot_password_pin_dto)

Redeems a forgot password pin.

Example

import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.forgot_password_pin_dto import ForgotPasswordPinDto
from jellyfin.generated.api_10_11.models.pin_redeem_result import PinRedeemResult
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    forgot_password_pin_dto = jellyfin.generated.api_10_11.ForgotPasswordPinDto() # ForgotPasswordPinDto | The forgot password pin request containing the entered pin.

    try:
        # Redeems a forgot password pin.
        api_response = api_instance.forgot_password_pin(forgot_password_pin_dto)
        print("The response of UserApi->forgot_password_pin:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->forgot_password_pin: %s\n" % e)

Parameters

Name Type Description Notes
forgot_password_pin_dto ForgotPasswordPinDto The forgot password pin request containing the entered pin.

Return type

PinRedeemResult

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 Pin reset process started. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_current_user

UserDto get_current_user()

Gets the user based on auth token.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.user_dto import UserDto
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)

    try:
        # Gets the user based on auth token.
        api_response = api_instance.get_current_user()
        print("The response of UserApi->get_current_user:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->get_current_user: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

UserDto

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 User returned. -
400 Token is not owned by a user. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -
403 Forbidden -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_public_users

List[UserDto] get_public_users()

Gets a list of publicly visible users for display on a login screen.

Example

import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.user_dto import UserDto
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)

    try:
        # Gets a list of publicly visible users for display on a login screen.
        api_response = api_instance.get_public_users()
        print("The response of UserApi->get_public_users:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->get_public_users: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

List[UserDto]

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 Public users returned. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_user_by_id

UserDto get_user_by_id(user_id)

Gets a user by Id.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.user_dto import UserDto
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    user_id = 'user_id_example' # str | The user id.

    try:
        # Gets a user by Id.
        api_response = api_instance.get_user_by_id(user_id)
        print("The response of UserApi->get_user_by_id:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->get_user_by_id: %s\n" % e)

Parameters

Name Type Description Notes
user_id str The user id.

Return type

UserDto

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 User returned. -
404 User not found. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -
403 Forbidden -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_users

List[UserDto] get_users(is_hidden=is_hidden, is_disabled=is_disabled)

Gets a list of users.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.user_dto import UserDto
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    is_hidden = True # bool | Optional filter by IsHidden=true or false. (optional)
    is_disabled = True # bool | Optional filter by IsDisabled=true or false. (optional)

    try:
        # Gets a list of users.
        api_response = api_instance.get_users(is_hidden=is_hidden, is_disabled=is_disabled)
        print("The response of UserApi->get_users:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling UserApi->get_users: %s\n" % e)

Parameters

Name Type Description Notes
is_hidden bool Optional filter by IsHidden=true or false. [optional]
is_disabled bool Optional filter by IsDisabled=true or false. [optional]

Return type

List[UserDto]

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
200 Users returned. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -
403 Forbidden -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_user

update_user(user_dto, user_id=user_id)

Updates a user.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.user_dto import UserDto
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    user_dto = jellyfin.generated.api_10_11.UserDto() # UserDto | The updated user model.
    user_id = 'user_id_example' # str | The user id. (optional)

    try:
        # Updates a user.
        api_instance.update_user(user_dto, user_id=user_id)
    except Exception as e:
        print("Exception when calling UserApi->update_user: %s\n" % e)

Parameters

Name Type Description Notes
user_dto UserDto The updated user model.
user_id str The user id. [optional]

Return type

void (empty response body)

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
204 User updated. -
400 User information was not supplied. -
403 User update forbidden. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_user_configuration

update_user_configuration(user_configuration, user_id=user_id)

Updates a user configuration.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.user_configuration import UserConfiguration
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    user_configuration = jellyfin.generated.api_10_11.UserConfiguration() # UserConfiguration | The new user configuration.
    user_id = 'user_id_example' # str | The user id. (optional)

    try:
        # Updates a user configuration.
        api_instance.update_user_configuration(user_configuration, user_id=user_id)
    except Exception as e:
        print("Exception when calling UserApi->update_user_configuration: %s\n" % e)

Parameters

Name Type Description Notes
user_configuration UserConfiguration The new user configuration.
user_id str The user id. [optional]

Return type

void (empty response body)

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
204 User configuration updated. -
403 User configuration update forbidden. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_user_password

update_user_password(update_user_password, user_id=user_id)

Updates a user's password.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.update_user_password import UpdateUserPassword
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    update_user_password = jellyfin.generated.api_10_11.UpdateUserPassword() # UpdateUserPassword | The M:Jellyfin.Api.Controllers.UserController.UpdateUserPassword(System.Nullable{System.Guid},Jellyfin.Api.Models.UserDtos.UpdateUserPassword) request.
    user_id = 'user_id_example' # str | The user id. (optional)

    try:
        # Updates a user's password.
        api_instance.update_user_password(update_user_password, user_id=user_id)
    except Exception as e:
        print("Exception when calling UserApi->update_user_password: %s\n" % e)

Parameters

Name Type Description Notes
update_user_password UpdateUserPassword The M:Jellyfin.Api.Controllers.UserController.UpdateUserPassword(System.Nullable{System.Guid},Jellyfin.Api.Models.UserDtos.UpdateUserPassword) request.
user_id str The user id. [optional]

Return type

void (empty response body)

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
204 Password successfully reset. -
403 User is not allowed to update the password. -
404 User not found. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_user_policy

update_user_policy(user_id, user_policy)

Updates a user policy.

Example

  • Api Key Authentication (CustomAuthentication):
import jellyfin.generated.api_10_11
from jellyfin.generated.api_10_11 import ApiClient, Configuration
from jellyfin.generated.api_10_11.models.user_policy import UserPolicy
from jellyfin.generated.api_10_11.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = Configuration(
    host = "http://localhost"
)

# Configure API key authorization: CustomAuthentication
configuration.api_key['CustomAuthentication'] = f'Token="{os.getenv("API_KEY")}"'
configuration.api_key_prefix['CustomAuthentication'] = "MediaBrowser"


# Enter a context with an instance of the API client
with ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = jellyfin.generated.api_10_11.UserApi(api_client)
    user_id = 'user_id_example' # str | The user id.
    user_policy = jellyfin.generated.api_10_11.UserPolicy() # UserPolicy | The new user policy.

    try:
        # Updates a user policy.
        api_instance.update_user_policy(user_id, user_policy)
    except Exception as e:
        print("Exception when calling UserApi->update_user_policy: %s\n" % e)

Parameters

Name Type Description Notes
user_id str The user id.
user_policy UserPolicy The new user policy.

Return type

void (empty response body)

Authorization

CustomAuthentication

HTTP request headers

  • Content-Type: application/json, text/json, application/*+json
  • Accept: application/json, application/json; profile="CamelCase", application/json; profile="PascalCase", text/html

HTTP response details

Status code Description Response headers
204 User policy updated. -
400 User policy was not supplied. -
403 User policy update forbidden. -
503 The server is currently starting or is temporarily not available. * Retry-After - A hint for when to retry the operation in full seconds.
* Message - A short plain-text reason why the server is not available.
401 Unauthorized -

[Back to top] [Back to API list] [Back to Model list] [Back to README]