All URIs are relative to http://localhost:8091
| Method | HTTP request | Description |
|---|---|---|
| activate_theme | PUT /apis/api.console.halo.run/v1alpha1/themes/{name}/activation | |
| fetch_activated_theme | GET /apis/api.console.halo.run/v1alpha1/themes/-/activation | |
| fetch_theme_json_config | GET /apis/api.console.halo.run/v1alpha1/themes/{name}/json-config | |
| fetch_theme_setting | GET /apis/api.console.halo.run/v1alpha1/themes/{name}/setting | |
| install_theme | POST /apis/api.console.halo.run/v1alpha1/themes/install | |
| install_theme_from_uri | POST /apis/api.console.halo.run/v1alpha1/themes/-/install-from-uri | |
| invalidate_cache | PUT /apis/api.console.halo.run/v1alpha1/themes/{name}/invalidate-cache | |
| list_themes | GET /apis/api.console.halo.run/v1alpha1/themes | |
| reload | PUT /apis/api.console.halo.run/v1alpha1/themes/{name}/reload | |
| reset_theme_config | PUT /apis/api.console.halo.run/v1alpha1/themes/{name}/reset-config | |
| update_theme_json_config | PUT /apis/api.console.halo.run/v1alpha1/themes/{name}/json-config | |
| upgrade_theme | POST /apis/api.console.halo.run/v1alpha1/themes/{name}/upgrade | |
| upgrade_theme_from_uri | POST /apis/api.console.halo.run/v1alpha1/themes/{name}/upgrade-from-uri |
Theme activate_theme(name)
Activate a theme by name.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.theme import Theme
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
try:
api_response = api_instance.activate_theme(name)
print("The response of ThemeV1alpha1ConsoleApi->activate_theme:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->activate_theme: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str |
- Content-Type: Not defined
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Theme fetch_activated_theme()
Fetch the activated theme.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.theme import Theme
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
try:
api_response = api_instance.fetch_activated_theme()
print("The response of ThemeV1alpha1ConsoleApi->fetch_activated_theme:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->fetch_activated_theme: %s\n" % e)This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
object fetch_theme_json_config(name)
Fetch converted json config of theme by configured configMapName.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
try:
api_response = api_instance.fetch_theme_json_config(name)
print("The response of ThemeV1alpha1ConsoleApi->fetch_theme_json_config:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->fetch_theme_json_config: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str |
object
- Content-Type: Not defined
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Setting fetch_theme_setting(name)
Fetch setting of theme.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.setting import Setting
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
try:
api_response = api_instance.fetch_theme_setting(name)
print("The response of ThemeV1alpha1ConsoleApi->fetch_theme_setting:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->fetch_theme_setting: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str |
- Content-Type: Not defined
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Theme install_theme()
Install a theme by uploading a zip file.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.theme import Theme
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
try:
api_response = api_instance.install_theme()
print("The response of ThemeV1alpha1ConsoleApi->install_theme:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->install_theme: %s\n" % e)This endpoint does not need any parameter.
- Content-Type: multipart/form-data
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Theme install_theme_from_uri(install_from_uri_request)
Install a theme from uri.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.install_from_uri_request import InstallFromUriRequest
from halo_client.models.theme import Theme
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
install_from_uri_request = halo_client.InstallFromUriRequest() # InstallFromUriRequest |
try:
api_response = api_instance.install_theme_from_uri(install_from_uri_request)
print("The response of ThemeV1alpha1ConsoleApi->install_theme_from_uri:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->install_theme_from_uri: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| install_from_uri_request | InstallFromUriRequest |
- Content-Type: application/json
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
invalidate_cache(name)
Invalidate theme template cache.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
try:
api_instance.invalidate_cache(name)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->invalidate_cache: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str |
void (empty response body)
- Content-Type: Not defined
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 204 | No Content | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ThemeList list_themes(page=page, size=size, label_selector=label_selector, field_selector=field_selector, uninstalled=uninstalled)
List themes.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.theme_list import ThemeList
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
page = 56 # int | Page number. Default is 0. (optional)
size = 56 # int | Size number. Default is 0. (optional)
label_selector = ['label_selector_example'] # List[str] | Label selector. e.g.: hidden!=true (optional)
field_selector = ['field_selector_example'] # List[str] | Field selector. e.g.: metadata.name==halo (optional)
uninstalled = True # bool | Whether to list uninstalled themes. (optional)
try:
api_response = api_instance.list_themes(page=page, size=size, label_selector=label_selector, field_selector=field_selector, uninstalled=uninstalled)
print("The response of ThemeV1alpha1ConsoleApi->list_themes:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->list_themes: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| page | int | Page number. Default is 0. | [optional] |
| size | int | Size number. Default is 0. | [optional] |
| label_selector | List[str] | Label selector. e.g.: hidden!=true | [optional] |
| field_selector | List[str] | Field selector. e.g.: metadata.name==halo | [optional] |
| uninstalled | bool | Whether to list uninstalled themes. | [optional] |
- Content-Type: Not defined
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Theme reload(name)
Reload theme setting.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.theme import Theme
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
try:
api_response = api_instance.reload(name)
print("The response of ThemeV1alpha1ConsoleApi->reload:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->reload: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str |
- Content-Type: Not defined
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ConfigMap reset_theme_config(name)
Reset the configMap of theme setting.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.config_map import ConfigMap
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
try:
api_response = api_instance.reset_theme_config(name)
print("The response of ThemeV1alpha1ConsoleApi->reset_theme_config:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->reset_theme_config: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str |
- Content-Type: Not defined
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
update_theme_json_config(name, body)
Update the configMap of theme setting.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
body = None # object |
try:
api_instance.update_theme_json_config(name, body)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->update_theme_json_config: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | ||
| body | object |
void (empty response body)
- Content-Type: application/json
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 204 | No Content | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
upgrade_theme(name, file)
Upgrade theme
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
file = None # bytes |
try:
api_instance.upgrade_theme(name, file)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->upgrade_theme: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | ||
| file | bytes |
void (empty response body)
- Content-Type: multipart/form-data
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Theme upgrade_theme_from_uri(name, upgrade_from_uri_request)
Upgrade a theme from uri.
- Basic Authentication (basicAuth):
- Bearer (JWT) Authentication (bearerAuth):
import halo_client
from halo_client.models.theme import Theme
from halo_client.models.upgrade_from_uri_request import UpgradeFromUriRequest
from halo_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost:8091
# See configuration.py for a list of all supported configuration parameters.
configuration = halo_client.Configuration(
host = "http://localhost:8091"
)
# 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 HTTP basic authorization: basicAuth
configuration = halo_client.Configuration(
username = os.environ["USERNAME"],
password = os.environ["PASSWORD"]
)
# Configure Bearer authorization (JWT): bearerAuth
configuration = halo_client.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with halo_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = halo_client.ThemeV1alpha1ConsoleApi(api_client)
name = 'name_example' # str |
upgrade_from_uri_request = halo_client.UpgradeFromUriRequest() # UpgradeFromUriRequest |
try:
api_response = api_instance.upgrade_theme_from_uri(name, upgrade_from_uri_request)
print("The response of ThemeV1alpha1ConsoleApi->upgrade_theme_from_uri:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ThemeV1alpha1ConsoleApi->upgrade_theme_from_uri: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | ||
| upgrade_from_uri_request | UpgradeFromUriRequest |
- Content-Type: application/json
- Accept: /
| Status code | Description | Response headers |
|---|---|---|
| 0 | default response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]