# memos.AuthServiceApi All URIs are relative to */* Method | HTTP request | Description ------------- | ------------- | ------------- [**auth_service_get_auth_status**](AuthServiceApi.md#auth_service_get_auth_status) | **POST** /api/v1/auth/status | GetAuthStatus returns the current auth status of the user. [**auth_service_sign_in**](AuthServiceApi.md#auth_service_sign_in) | **POST** /api/v1/auth/signin | SignIn signs in the user with the given username and password. [**auth_service_sign_in_with_sso**](AuthServiceApi.md#auth_service_sign_in_with_sso) | **POST** /api/v1/auth/signin/sso | SignInWithSSO signs in the user with the given SSO code. [**auth_service_sign_out**](AuthServiceApi.md#auth_service_sign_out) | **POST** /api/v1/auth/signout | SignOut signs out the user. [**auth_service_sign_up**](AuthServiceApi.md#auth_service_sign_up) | **POST** /api/v1/auth/signup | SignUp signs up the user with the given username and password. # **auth_service_get_auth_status** > V1User auth_service_get_auth_status() GetAuthStatus returns the current auth status of the user. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.AuthServiceApi() try: # GetAuthStatus returns the current auth status of the user. api_response = api_instance.auth_service_get_auth_status() pprint(api_response) except ApiException as e: print("Exception when calling AuthServiceApi->auth_service_get_auth_status: %s\n" % e) ``` ### Parameters This endpoint does not need any parameter. ### Return type [**V1User**](V1User.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **auth_service_sign_in** > V1User auth_service_sign_in(username=username, password=password, never_expire=never_expire) SignIn signs in the user with the given username and password. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.AuthServiceApi() username = 'username_example' # str | The username to sign in with. (optional) password = 'password_example' # str | The password to sign in with. (optional) never_expire = true # bool | Whether the session should never expire. (optional) try: # SignIn signs in the user with the given username and password. api_response = api_instance.auth_service_sign_in(username=username, password=password, never_expire=never_expire) pprint(api_response) except ApiException as e: print("Exception when calling AuthServiceApi->auth_service_sign_in: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **str**| The username to sign in with. | [optional] **password** | **str**| The password to sign in with. | [optional] **never_expire** | **bool**| Whether the session should never expire. | [optional] ### Return type [**V1User**](V1User.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **auth_service_sign_in_with_sso** > V1User auth_service_sign_in_with_sso(idp_id=idp_id, code=code, redirect_uri=redirect_uri) SignInWithSSO signs in the user with the given SSO code. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.AuthServiceApi() idp_id = 56 # int | The ID of the SSO provider. (optional) code = 'code_example' # str | The code to sign in with. (optional) redirect_uri = 'redirect_uri_example' # str | The redirect URI. (optional) try: # SignInWithSSO signs in the user with the given SSO code. api_response = api_instance.auth_service_sign_in_with_sso(idp_id=idp_id, code=code, redirect_uri=redirect_uri) pprint(api_response) except ApiException as e: print("Exception when calling AuthServiceApi->auth_service_sign_in_with_sso: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **idp_id** | **int**| The ID of the SSO provider. | [optional] **code** | **str**| The code to sign in with. | [optional] **redirect_uri** | **str**| The redirect URI. | [optional] ### Return type [**V1User**](V1User.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **auth_service_sign_out** > object auth_service_sign_out() SignOut signs out the user. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.AuthServiceApi() try: # SignOut signs out the user. api_response = api_instance.auth_service_sign_out() pprint(api_response) except ApiException as e: print("Exception when calling AuthServiceApi->auth_service_sign_out: %s\n" % e) ``` ### Parameters This endpoint does not need any parameter. ### Return type **object** ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **auth_service_sign_up** > V1User auth_service_sign_up(username=username, password=password) SignUp signs up the user with the given username and password. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.AuthServiceApi() username = 'username_example' # str | The username to sign up with. (optional) password = 'password_example' # str | The password to sign up with. (optional) try: # SignUp signs up the user with the given username and password. api_response = api_instance.auth_service_sign_up(username=username, password=password) pprint(api_response) except ApiException as e: print("Exception when calling AuthServiceApi->auth_service_sign_up: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **str**| The username to sign up with. | [optional] **password** | **str**| The password to sign up with. | [optional] ### Return type [**V1User**](V1User.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)