Administration

class jelastic.api.administration.Administration(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: ClientAbstract

property Analytics: _Analytics
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Analytics

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Analytics

property Cluster: _Cluster
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Cluster

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Cluster

property Config: _Config
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Config

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Config

property Host: _Host
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Host

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Host

property HostGroup: _HostGroup
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.HostGroup

Ref: https://docs.jelastic.com/api/private/#!/api/administration.HostGroup

property Monitoring: _Monitoring
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Monitoring

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Monitoring

property Resource: _Resource
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Resource

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Resource

property Subscription: _Subscription
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Subscription

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Subscription

property Template: _Template
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Template

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Template

property Update: _Update
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Update

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Update

property Utils: _Utils
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.Utils

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Utils

property VirtualNetwork: _VirtualNetwork
>>> from jelastic import Jelastic
>>> jelastic = Jelastic('https://app.xapp.cloudmydc.com', token='d6f4e314a5b5fefd164995169f28ae32d987704f')
>>> jelastic.administration.VirtualNetwork

Ref: https://docs.jelastic.com/api/private/#!/api/administration.VirtualNetwork

class jelastic.api.administration._Analytics(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Config

GetNodesAffinitySuggestion(target_app_ids: list[str] | None = None, node_groups: list[str] | None = None, uids: list[int] | None = None, thread_count: int | None = None, ruk: str | None = None)[source]

A list of environments with one node in every layer where distribution can be optimized

Parameters:
  • target_app_ids – list of the exact environments that should be analyzed

  • node_groups – list of the node group IDs that should be analyzed

  • uids – list of the user IDs that should be analyzed :param thread_count: a number of threads for container distribution analysis

GetNodesAntiAffinitySuggestion(target_app_ids: list[str] | None = None, mode: Literal['STRONG', 'MODERATE', 'WEAK'] | None = None, node_groups: list[str] | None = None, uids: list[int] | None = None, thread_count: int | None = None, ruk: str | None = None)[source]

A list of environments with non-optimal container distribution with optimization suggestions

Parameters:
  • target_app_ids – list of the exact environments that should be analyzed

  • mode – a mode of the anti-affinity analysis

  • node_groups – list of the node group IDs that should be analyzed

  • uids – list of the user IDs that should be analyzed

  • thread_count – a number of threads for container distribution analysis

class jelastic.api.administration._Cluster(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

AddActionToIsolationQueue(count: int | None = None, delay: int | None = None, ruk: str | None = None)[source]
AddCartridge(manifest_url: str, ruk: str | None = None)[source]
AddCertifiedTemplates(repositories: str, publish: bool | None = None, ruk: str | None = None)[source]
AddExtIps(ipfrom: str, ipto: str, regions: str, ruk: str | None = None)[source]
AddHardWareNodeMessage(hn_id: int, message_type: str, process_response_code: int, percentage: int, message: str, custom_data: str, ruk: str | None = None)[source]
AddHdNode(hdnode: dict, set_as_docker_host: bool | None = None, skip_configuration: bool | None = None, ruk: str | None = None)[source]
AddHdNodeGroup(data: dict, ruk: str | None = None)[source]
AddIps(ipfrom: str, ipto: str, region: str, ruk: str | None = None)[source]
AddIpv6Network(region: str, network: str | None = None, ruk: str | None = None)[source]
AddNameserver(node_id: int, nameserver: str, ruk: str | None = None)[source]
AddRegion(data: dict, test_authentication: bool | None = None, ruk: str | None = None)[source]
Parameters:
  • data – JSON object with the new hardware region data.

  • test_authentication – defines whether to check (true) or not (false) authentication on the region’s Docker host.

AddRegionDomain(region_id: int, domain: str, primary: bool | None = None, ruk: str | None = None)[source]
Parameters:
  • region_id – unique identifier of the target region.

  • domain – new domain name to be added for the region.

  • primary – defines whether to set the domain name as the region’s primary (true) or not (false).

AddRegionReseller(reseller_id: int, domain: str, type: str, generate_dns: bool, ssl_type: str | None = None, region_id: int | None = None, key: str | None = None, intermediate: str | None = None, cert: str | None = None, source502: str | None = None, ruk: str | None = None)[source]
Parameters:
  • reseller_id – unique identifier of the target reseller platform.

  • domain – reseller platform domain name.

  • type – region type (PLATFORM or REGION).

  • generate_dns – defines whether to generate new DNS records (true) or just update existing SSL settings (false).

  • ssl_type – SSL certificate type (CUSTOM or LETSENCRYPT).

  • region_id – unique identifier of the existing region on the main platform.

  • key – SSL certificate key.

  • intermediate – intermediate SSL certificate.

  • cert – SSL certificate body.

  • source502 – path to the 50x error pages source files.

AddRegionSsl(region_id: int, ssl_type: str, domain_id: int | None = None, cert_key: str | None = None, intermediate: str | None = None, cert: str | None = None, ruk: str | None = None)[source]
Parameters:
  • region_id – unique identifier of the target region.

  • ssl_type – SSL certificates type (CUSTOM - manually provided certificates; LETSENCRYPT - automatically issued Let’s Encrypt certificates).

  • domain_id – unique identifier of the target domain name.

  • cert_key – server key certificate (for CUSTOM sslType only).

  • intermediate – intermediate certificate CA (for CUSTOM sslType only).

  • cert – domain certificate (for CUSTOM sslType only).

AddTemplate(registry_id: int, repository: str, tags: str, node_type: str, node_mission: str, display_name: str, engine_type: str | None = None, images_data: str | None = None, auto_update: bool | None = None, keep_selected_tags: bool | None = None, update_default_tag: bool | None = None, skip_tags_from_auto_update: str | None = None, ruk: str | None = None)[source]
AddTemplateRegistry(data: str, ruk: str | None = None)[source]
AddUserToContainer(node_id: int | None = None, container_id: int | None = None, regenerate_keys: bool | None = None, ruk: str | None = None)[source]
AddUsersToGate(ruk: str | None = None)[source]
ApplyFirewallRules(ruk: str | None = None)[source]
CheckMigrationEnvPossibility(target_appid: str | None = None, hardware_node_group: str | None = None, ruk: str | None = None)[source]
CleanTemplateManifestCache(ruk: str | None = None)[source]
ClearPool(hnid: int | None = None, ruk: str | None = None)[source]
ConvertPasswords(ruk: str | None = None)[source]
DeactivateRegionDomain(region_id: int, domain_id: int, ruk: str | None = None)[source]
DeleteEnv(target_appid: str, password: str, ruk: str | None = None)[source]
DeleteEnvsByChecksum(checksum: str, uid: int, target_appid: str, ruk: str | None = None)[source]
Parameters:
  • checksum – checksum of the request.

  • uid – unique identifier of the target user.

  • target_appid – A semicolon-separated list of target environment IDs.

DeleteEnvsByUidByChecksum(uid: int, ruk: str | None = None)[source]
Parameters:

uid – unique identifier of the target user.

DeleteHDNode(hdnodeid: int, force: bool | None = None, ruk: str | None = None)[source]
EditHdNode(hdnode: dict, set_as_docker_host: bool | None = None, ruk: str | None = None)[source]
EditHdNodeGroup(data: dict, ruk: str | None = None)[source]
EditRegion(data: dict, test_authentication: bool | None = None, ruk: str | None = None)[source]
EditTemplate(node_type: str, tags: str | None = None, display_name: str | None = None, engine_type: str | None = None, images_data: str | None = None, auto_update: bool | None = None, keep_selected_tags: bool | None = None, update_default_tag: bool | None = None, skip_tags_from_auto_update: str | None = None, ruk: str | None = None)[source]
EditTemplateRegistry(data: str, ruk: str | None = None)[source]
EvacuateContainers(source_hn_id: str, possible_target_node_ids: str | None = None, is_online: bool | None = None, ruk: str | None = None)[source]
ExecHnCMD(cmd: str, hn_id: int | None = None, infra_only: bool | None = None, run_on_broken: bool | None = None, vz_version: str | None = None, docker_host_only: bool | None = None, ruk: str | None = None)[source]
ExecHostCmd(cmd: str, host_id: int | None = None, infra_only: bool | None = None, run_on_broken: bool | None = None, vz_version: str | None = None, docker_host_only: bool | None = None, ruk: str | None = None)[source]
GeneratePool(node_type: str | None = None, hnid: int | None = None, ruk: str | None = None)[source]
GetAddHdNodeCmd(hard_node_group: str | None = None, ruk: str | None = None)[source]
GetAddHostCmd(host_group: str | None = None, ruk: str | None = None)[source]
GetAllContainers(ruk: str | None = None)[source]
GetAllRegionReseller(ruk: str | None = None)[source]
GetAllSumStatByUid(duration: int | None = None, endtime: datetime | None = None, uid: int | None = None, ruk: str | None = None)[source]
GetAppidByDomain(domain: str | None = None, ruk: str | None = None)[source]
GetBillableItems(ruk: str | None = None)[source]
GetClusterLoadHistory(starttime: datetime, endtime: datetime, ruk: str | None = None)[source]
GetClusterLoadInfo(ruk: str | None = None)[source]
GetClusterLoadPercent(checksum: str, ruk: str | None = None)[source]
GetClusterStatus(check_smtp: bool | None = None, cached: bool | None = None, ruk: str | None = None)[source]
GetClusterUsage(ruk: str | None = None)[source]
GetContainerConfig(node_id: int, ruk: str | None = None)[source]
GetDefaultRegion(ruk: str | None = None)[source]
GetDefaultTagInfo(node_type: str, engine: str | None = None, ruk: str | None = None)[source]
GetDomainByIp(ips: str, ruk: str | None = None)[source]
GetEngineTypes(ruk: str | None = None)[source]
GetEnvGroupsByUid(uid: int, ruk: str | None = None)[source]
GetEnvInfo(target_appid: str, ruk: str | None = None)[source]
GetEnvStat(starttime: datetime, endtime: datetime, ruk: str | None = None)[source]
GetEnvironmentGroupPopulations(start: datetime, end: datetime, ruk: str | None = None)[source]

rows ordered by time asc not more than 1000 rows

Parameters:
  • start – slice start in date and time in ISO 8601

  • end – slice end in date and time in ISO 8601

GetEnvs(uid: int, rights: list[str] | None = None, lazy: bool | None = None, owner_uid: int | None = None, ssh_access_only: bool | None = None, ruk: str | None = None)[source]

A list of suitable environments.

Parameters:
  • uid – unique identifier of the target user.

  • rights – a comma-separated list of rights to filter environments. The filtering won’t be applied if this parameter is not specified (all environments are displayed).

  • lazy – enables/disables lazy (on-demand) loading.

  • owner_uid – unique identifier of the target user account.

  • ssh_access_only – filter to environments with SSH access.

GetEvacuationState(hard_node_id: int, ruk: str | None = None)[source]

EvacuationState entity or null

GetExtIpPoolInfo(search: dict, ruk: str | None = None)[source]
GetHdNodeGroups(ruk: str | None = None)[source]
GetHdNodeStatus(ruk: str | None = None)[source]
GetHdNodes(ids: str | None = None, ruk: str | None = None)[source]
GetHdNodesLoad(duration: int, hdnodes: str | None = None, ruk: str | None = None)[source]
GetHdNodesLoadInfo(ids: str | None = None, ruk: str | None = None)[source]
GetHosts(ids: str | None = None, ruk: str | None = None)[source]
GetIpPoolInfo(search: dict, ruk: str | None = None)[source]
GetIpv6Networks(ruk: str | None = None)[source]
GetIpv6SubnetsInfo(search: str | None = None, ruk: str | None = None)[source]
GetJelasticAppid(ruk: str | None = None)[source]
GetJobNames(ruk: str | None = None)[source]
GetLastHardWareNodeMessage(id: int, ruk: str | None = None)[source]
GetNodeInfo(target_appid: str, node_id: int, ruk: str | None = None)[source]

Result of operation or error.

Parameters:
  • target_appid – appid of user environment

  • node_id – id of SoftNode that belongs to env

GetNodeMissions(ruk: str | None = None)[source]
GetNodePassword(nodeid: int | None = None, ruk: str | None = None)[source]
GetNodes(hdnodeid: int, name: str | None = None, start_row: int | None = None, result_count: int | None = None, ruk: str | None = None)[source]
GetOOMKilledProcesses(search: dict, ruk: str | None = None)[source]
GetPcsClusterList(ruk: str | None = None)[source]
GetPoolStatus(ruk: str | None = None)[source]
GetRegion(id: int, ruk: str | None = None)[source]
GetRegionDnsRecords(id: int, ruk: str | None = None)[source]
GetRegionDomains(region_id: int | None = None, ruk: str | None = None)[source]

param region_id: unique identifier of the target region.

GetRegionResellerByResellerId(id: int, ruk: str | None = None)[source]
GetRegions(ruk: str | None = None)[source]
GetRepositoryTags(repository: str, registry_id: int | None = None, ruk: str | None = None)[source]
GetSoftNodeInfo(node_id: int, ruk: str | None = None)[source]
GetStandByStatus(ruk: str | None = None)[source]
GetStats(duration: int, interval: int, target_appid: str, endtime: datetime | None = None, nodeid: int | None = None, nodetype: str | None = None, node_group: str | None = None, ruk: str | None = None)[source]
GetSumStat(duration: int | None = None, endtime: datetime | None = None, target_appid: str | None = None, ruk: str | None = None)[source]
GetSystemLog(search: str, ruk: str | None = None)[source]
GetTemplateInfo(node_type: str, ruk: str | None = None)[source]
GetTemplateLabels(repository: str, registry_id: int | None = None, tag: str | None = None, ruk: str | None = None)[source]
GetTemplateRegistries(ruk: str | None = None)[source]
GetTemplates(type: str | None = None, published: bool | None = None, lazy: bool | None = None, ruk: str | None = None)[source]
GetUserActivity(uid: int, starttime: datetime, endtime: datetime, target_appid: str | None = None, start_row: int | None = None, result_count: int | None = None, service_name: str | None = None, search_text: str | None = None, action_types: str | None = None, order_field: str | None = None, order_direction: str | None = None, ruk: str | None = None)[source]

param: uid: unique identifier of the target user. param: starttime: a start time of a period for which user activity should be shown. In the format “yyyy-MM-dd hh:mm:ss”, e.g. “2022-11-16 00:00:00”. param: endtime: an end time of a period for which user activity should be shown. In the format “yyyy-MM-dd hh:mm:ss”, e.g. “2022-11-16 00:00:00”. param: target_appid: target environment name. param: start_row: returns information starting from the specified row in the response (starts with 0, by default). param: result_count: returns the specified number of rows from the response (0 – unlimited – by default). param: service_name: filters results by the specified service name. param: search_text: filters results by the provided string. param: action_types: filters results by the action type. params order_field: sorts results by the specified field. param: order_direction: sorts results in the ascending (ASC) or descending (DESC) order.

GetUsersActivities(starttime: datetime, endtime: datetime, start_row: int | None = None, result_count: int | None = None, ruk: str | None = None)[source]
L2Update(hn_id: int, ruk: str | None = None)[source]
MigrateEnv(target_appid: str | None = None, hardware_node_group: str | None = None, is_online: bool | None = None, ruk: str | None = None)[source]
MigrateNode(nodeid: int, hdnodeid: int, is_online: bool | None = None, manage_dns_state: bool | None = None, ruk: str | None = None)[source]

param nodeid: unique identifier of the target node (container). param hdnodeid: unique identifier of the target host. param is_online: defines whether to perform online (true) or offline (false) migration. param manage_dns_state: defines whether to exclude a target node from DNS for the duration of the operation (true) or not (false, by default). This parameter only works with the sequential processes (isSequential=true) and is ignored otherwise. Enabling the parameter will bring additional delay (as the DNS records have TTL and cannot be disabled instantly), while disabling can cause some of the requests to be lost.

RedeployContainers(target_env_name: str, tag: str, node_group: str | None = None, node_id: int | None = None, use_existing_volumes: bool | None = None, login: str | None = None, password: str | None = None, skip_reinstall: bool | None = None, ruk: str | None = None)[source]
RefreshEmailTemplates(modules: str, ruk: str | None = None)[source]
RefreshUser(language: str | None = None, ruk: str | None = None)[source]
RegeneratePool(node_type: str, exclude: str | None = None, ruk: str | None = None)[source]
RegisterInfaModule(module: str | None = None, dst_env_name: str | None = None, dry_run: bool | None = None, ruk: str | None = None)[source]
RemoveExtIps(ips: str | None = None, ruk: str | None = None)[source]
RemoveHdNodeGroup(id: int, ruk: str | None = None)[source]
RemoveIpv6Network(id: int, ruk: str | None = None)[source]
RemoveRegion(id: int, ruk: str | None = None)[source]
RemoveRegionReseller(reseller_id: int, remove_dns: bool, region_id: int | None = None, ruk: str | None = None)[source]
RemoveRegionSsl(region_id: int, domain_id: int | None = None, reseller_id: int | None = None, ruk: str | None = None)[source]

param region_id: unique identifier of the target region. param domain_id: unique identifier of the target domain name. param reseller_id: unique identifier of the target reseller platform.

RemoveTemplate(node_type: str, ruk: str | None = None)[source]
RemoveTemplateRegistry(id: int, ruk: str | None = None)[source]
ReplaceNodeInEnv(dst_env_name: str | None = None, dst_node_id: int | None = None, src_env_id: str | None = None, src_hn_id: int | None = None, ruk: str | None = None)[source]
ReviveInstallHdNode(id: int, ruk: str | None = None)[source]
SearchEnvs(search: dict, ruk: str | None = None)[source]
SearchNodes(search: dict, ruk: str | None = None)[source]
SetDefaultTemplateTag(node_type: str, tag: str, ruk: str | None = None)[source]
SetEnvNote(target_appid: str | None = None, note: str | None = None, ruk: str | None = None)[source]

param target_appid: target environment name param note: custom note for the target environment

SetEnvStatus(target_appid: str, status: int, ruk: str | None = None)[source]

param target_appid: appid of the required environment param status: new status for the specified environment whose appid equals to {@code targetAppid}.

SetEnvsStatus(target_appid: str, status: int, ruk: str | None = None)[source]

param target_appid: list of appids separated by commas param status: new status for each environment whose appid is in {@code targetAppids}.

SetEnvsStatusByUid(uid: int, status: int, ruk: str | None = None)[source]
SetEnvsStatusByUidByChecksum(uid: int, status: int, ruk: str | None = None)[source]
SetRegionDnsRecords(id: int, data: int, ruk: str | None = None)[source]
SetRegionPrimaryDomain(region_id: int, domain_id: int, ruk: str | None = None)[source]

param region_id: unique identifier of the target region. param domain_id: unique identifier of the target domain name.

SetStandbyMode(enabled: bool, ruk: str | None = None)[source]
SetTemplatePublished(node_type: str, published: bool, ruk: str | None = None)[source]
Sleep(starttime: datetime | None = None, endtime: datetime | None = None, deactivate_after: int | None = None, ruk: str | None = None)[source]

param starttime: start of the period (date and time in format yyyy-MM-dd HH:mm:ss, timezone GMT+0) param endtime: end of the period (date and time in format yyyy-MM-dd HH:mm:ss, timezone GMT+0) param deactivate_after: in milliseconds. deactivate only environment inactive more than this time. *

StartEnv(target_appid: str, ruk: str | None = None)[source]
StopBalanceResources(ruk: str | None = None)[source]
StopEnv(target_appid: str, ruk: str | None = None)[source]
StopEvacuation(hard_node_id: int, ruk: str | None = None)[source]
SyncCloudlets(starttime: datetime, debug: bool | None = None, ruk: str | None = None)[source]
SyncInfaModule(node_group: str, dst_env_name: str, components: str, target_tag: str | None = None, ruk: str | None = None)[source]
UpdateRegionSsl(region_id: int, domain_id: int | None = None, ruk: str | None = None)[source]

param region_id: unique identifier of the target region. param domain_id: unique identifier of the target domain name.

UpdateResellerSsl(region_id: int, reseller_id: int, ruk: str | None = None)[source]
UpdateTemplate(node_type: int, icons_only: bool | None = None, ruk: str | None = None)[source]
Validate(ruk: str | None = None)[source]
ValidateAll(ruk: str | None = None)[source]
ValidateSsl(domain: str, key: str | None = None, intermediate: str | None = None, cert: str | None = None, ruk: str | None = None)[source]
class jelastic.api.administration._Config(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Config

ApplyConfig(type: str, password: str, ruk: str | None = None)[source]
ApplyDefaults(edition: str, ruk: str | None = None)[source]
ApplyResellerConfig(type: str, password: str, reseller_id: str, ruk: str | None = None)[source]
ChangeConfigKey(type: str, key: str, value: str | None = None, ruk: str | None = None)[source]
ChangePropertiesForReseller(reseller_id: str, ruk: str | None = None)[source]
CreatingConfigType(type: str, description: str, ruk: str | None = None)[source]
CreatingKeyConfig(type: str, key: str, value: str, default_value: str, expert: str, description: str, key_type: str, ruk: str | None = None)[source]
FindConfigKey(value: str, ruk: str | None = None)[source]
GetAllConfigType(expert: str, ruk: str | None = None)[source]
GetAllKeyConfigByType(type: str, expert: str, ruk: str | None = None)[source]
GetConfigKey(type: str, key: str, ruk: str | None = None)[source]
Parameters:
  • type – configuration type

  • key – configuration key name

GetConfigKeyByResellerId(type: str, key: str, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • type – configuration type

  • key – configuration key name

  • reseller_id – unique identifier of the reseller (Optional)

GetConfigKeys(type: list[str] | None = None, key: list[str] | None = None, ruk: str | None = None)[source]
Parameters:
  • type – a comma-separated list of the setting types (for filtering).

  • key – a comma-separated list of the setting names (for filtering).

RemoveConfigKey(type: str, key: str, ruk: str | None = None)[source]
RemoveConfigType(type: str, ruk: str | None = None)[source]
RemoveResellerProperties(reseller_id: int, ruk: str | None = None)[source]
RevertConfigKey(type: str, key: str, ruk: str | None = None)[source]
SetResellerConfigKey(type: str, key: str, value: str, reseller_id: int, ruk: str | None = None)[source]
class jelastic.api.administration._Resource(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Resource

AddStatistics(resource_name: str, uid: int, value: int, start_date: date | None = None, end_date: date | None = None, env_name: str | None = None, node_id: int | None = None, note: str | None = None, value_group: str | None = None, ruk: str | None = None)[source]
class jelastic.api.administration._Subscription(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Subscription

AddCategory(category: dict, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • category – JSON representation of an object (subscription Category) that should be created

  • reseller_id – unique identifier of the target reseller platform.

AddProduct(product: dict | None = None, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • category – JSON representation of an object (subscription Product) that should be created.

  • product – unique identifier of the target reseller platform.

AddServicePlan(service_plan: dict, reseller_id: int | None = None, expand_fields: str | None = None, ruk: str | None = None)[source]
Parameters:
  • service_plan – JSON representation of an object (subscription Service Plan) that should be created.

  • reseller_id – unique identifier of the target reseller platform.

  • expand_fields – there are fields that are not included in responses by default. You can request these fields as an expanded response by listing required object paths in this parameter (e.g. account.group).

AddSubscriptionItemResource(subscription_id: int, item_id: int, item_resource_id: int, resources: dict, ruk: str | None = None)[source]
Parameters:
  • subscription_id – unique identifier of the target subscription.

  • item_id – unique identifier of the target subscription item.

  • item_resource_id – unique identifier of the target subscription item resource.

  • resources – JSON representation of an object (subscription item resource) that should be created.

AdjustProduct(subscription_id: int, item_id: int, item_resource_id: int, ruk: str | None = None)[source]
Parameters:
  • subscription_id – unique identifier of the target subscription.

  • item_id – unique identifier of the target subscription item.

  • item_resource_id – unique identifier of the target subscription item resource.

DeleteCategory(id: int, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the target category.

  • reseller_id – unique identifier of the target reseller platform.

DeleteProduct(id: int, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the target product.

  • reseller_id – unique identifier of the target reseller platform.

DeleteServicePlan(id: int, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the target service plan.

  • reseller_id – unique identifier of the target reseller platform.

EditCategory(category: dict, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • category – JSON representation of an object (subscription Category) that should be created.

  • reseller_id – unique identifier of the target reseller platform.

EditProduct(category: dict, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • category – JSON representation of an object (subscription Product) that should be created.

  • reseller_id – unique identifier of the target reseller platform.

EditServicePlan(service_plan: dict, reseller_id: int | None = None, expend_fields: str | None = None, ruk: str | None = None)[source]
Parameters:
  • service_plan – JSON representation of an object (subscription Service Plan) that should be created.

  • reseller_id – unique identifier of the target reseller platform.

  • expend_fields – there are fields that are not included in responses by default. You can request these fields as an expanded response by listing required object paths in this parameter (e.g. account.group).

GetCategories(reseller_id: int | None = None, expend_fields: str | None = None, ruk: str | None = None)[source]
Parameters:
  • reseller_id – unique identifier of the target reseller platform.

  • expend_fields – there are fields that are not included in responses by default. You can request these fields as an expanded response by listing required object paths in this parameter (e.g. account.group).

GetProducts(id: int | None = None, status: list[str] | None = None, reseller_id: int | None = None, subscription_status: list[str] | None = None, expend_fields: str | None = None, start_row: int | None = None, result_count: int | None = None, order_field: str | None = None, order_direction: str | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the product (for filtering).

  • status – a comma-separated list of the subscription Product statuses (ProductStatus) that should be returned.

  • reseller_id – unique identifier of the target reseller platform.

  • subscription_status – a comma-separated list of the subscription statuses (SubscriptionStatus) that should be returned.

  • expend_fields – there are fields that are not included in responses by default. You can request these fields as an expanded response by listing required object paths in this parameter (e.g. account.group).

  • start_row – returns information starting from the specified row in the response (starts with 0, by default).

  • result_count – returns the specified number of rows from the response (0 – unlimited – by default).

  • order_field – sorts results by the specified field

  • order_direction – sorts results in the ascending (ASC) or descending (DESC) order

GetServicePlans(id: int | None = None, has_products: bool | None = None, subscription_status: list[str] | None = None, product_id: int | None = None, expend_fields: str | None = None, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the service plan (for filtering).

  • has_products – a flag that indicates if returned Service Plans should have (true) or not (false) assigned products

  • subscription_status – a comma-separated list of the subscription statuses (SubscriptionStatus) that should be returned.

  • product_id – unique identifier of the subscription product (for filtering).

  • expend_fields – there are fields that are not included in responses by default. You can request these fields as an expanded response by listing required object paths in this parameter (e.g. account.group).

  • reseller_id – unique identifier of the target reseller platform.

GetSubscriptions(id: int | None = None, uid: int | None = None, status: list[str] | None = None, reseller_id: int | None = None, product_id: int | None = None, service_plan_id: int | None = None, expend_fields: str | None = None, start_row: int | None = None, result_count: int | None = None, order_field: str | None = None, order_direction: str | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the subscription (for filtering).

  • uid – unique identifier of the target user.

  • status – a comma-separated list of the subscription statuses (SubscriptionStatus) that should be returned.

  • reseller_id – unique identifier of the target reseller platform.

  • product_id – unique identifier of the target product.

  • service_plan_id – unique identifier of the target service plan.

  • expend_fields – there are fields that are not included in responses by default. You can request these fields as an expanded response by listing required object paths in this parameter (e.g. account.group).

  • start_row – returns information starting from the specified row in the response (starts with 0, by default).

  • result_count – returns the specified number of rows from the response (0 – unlimited – by default).

  • order_field – sorts results by the specified field

  • order_direction – sorts results in the ascending (ASC) or descending (DESC) order

SetCategoryPublished(id: int, published: bool, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the target category.

  • published – publishes (true) or unpublishes (false) the subscription Category.

  • reseller_id – unique identifier of the target reseller platform.

SetProductStatus(id: int, status: str, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the target product.

  • status – a new status (ProductStatus) that should be set for the subscription Product.

  • reseller_id – unique identifier of the target reseller platform.

SetServicePlanStatus(id: int, status: str, reseller_id: int | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the target service plan.

  • status – a new status (ServicePlanStatus) that should be set for the subscription Service Plan.

  • reseller_id – unique identifier of the target reseller platform.

TerminateSubscription(subscription_id: int, password: str, ruk: str | None = None)[source]
Parameters:
  • subscription_id – unique identifier of the target subscription.

  • password – current (admin) user’s password to confirm subscription resources deletion.

class jelastic.api.administration._Update(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Update

FixExtDns(uid: int | None = None, target_app_id: str | None = None, ruk: str | None = None)[source]
RestoreEnv(env_name: str | None = None, uid: int | None = None, region: str | None = None, ruk: str | None = None)[source]
SyncInfraEnv(domain: str | None = None, registry: str | None = None, ruk: str | None = None)[source]
class jelastic.api.administration._Monitoring(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Monitoring

GetDockerPullStatus(ruk: str | None = None)[source]

Returns cached result of the “docker pull” operation (cache lifetime = 600s). Pulled image is selected randomly from the list of published DOCKERIZED templates. This method is used for monitoring.

GetHostFirewallStatus(ruk: str | None = None)[source]
class jelastic.api.administration._Template(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Template

SetDefaultRegistry(id: int | None = None, ruk: str | None = None)[source]
Parameters:

id – identifier of the registry.

SetDistribution(node_types: str, distribution: str | None = None, ruk: str | None = None)[source]
Parameters:
  • node_type – templates where distribution should be set.

  • distribution – zone configuration JSON string, example: {“mode”:”STRICT”,”zones”:”windows”}.

class jelastic.api.administration._HostGroup(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.HostGroup

Add(data: dict, ruk: str | None = None)[source]
Parameters:

data – JSON representation of an object (host group) that should be created.

AddEndpoints(host_group: str, end_points: dict, ruk: str | None = None)[source]
Parameters:
  • host_group – unique identifier of the target host group.

  • end_points – JSON array of endpoint objects.

Edit(data: dict, ruk: str | None = None)[source]
Parameters:

data – JSON representation of an object (host group) that should be edited.

EditEndpoints(host_group: str, end_points: dict, ruk: str | None = None)[source]
Parameters:

end_points – JSON array of endpoint objects

Get(ruk: str | None = None)[source]
GetEndpoints(host_group: str, ruk: str | None = None)[source]
Parameters:

host_group – unique identifier of the target host group.

Remove(id: int, ruk: str | None = None)[source]

:param id:unique identifier of the target host group.

RemoveEndpoints(id: int, ruk: str | None = None)[source]

:param id:unique identifier of the target endpoint.

RenameRemoteUser(uid: int, email: str, ruk: str | None = None)[source]
Parameters:
  • uid – unique identifier of the target user.

  • email – new email address for the user.

TestEndpoints(end_points: dict, ruk: str | None = None)[source]
Parameters:

end_points – JSON array with endpoints objects with ids.

class jelastic.api.administration._Host(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Host

AddLabels(ids: str, labels: str, ruk: str | None = None)[source]
CheckHostConnection(host_id: str, port: int | None = None, check_external_ip: bool | None = None, ruk: str | None = None)[source]
Parameters:
  • host_id – unique identifier of the target host.

  • port – checks the connection through the custom port (host’s SSH port from the settings if not specified).

GetHostFirewallSets(ruk: str | None = None)[source]
RemoveLabels(ids: str, labels: str, ruk: str | None = None)[source]
SetLabels(ids: str, labels: str, ruk: str | None = None)[source]
UpdateHostFirewall(host_id: int | None = None, force: bool | None = None, check_external_ip: bool | None = None, ruk: str | None = None)[source]
Parameters:
  • host_id – unique identifier of the target host (all hosts if not defined).

  • force – proceeds (true) or interrupts (false) the operation in case of errors.

class jelastic.api.administration._Utils(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.Utils

AddSystemExternalDNSRecord(record_data: str, name: str, ttl: int, record_data_type: str, ssl_enabled: bool | None = None, enabled: bool | None = None, ruk: str | None = None)[source]
Parameters:
  • record_data – custom data for the DNS record.

  • name – name for DNS records (must be the same as one of the existing record).

  • ttl – TTL (time to live) value for the DNS record.

  • record_data_type – type of the DNS record data (currently, only the ‘TXT’ value is supported).

  • ssl_enabled – defines whether the SSL is enabled for the record (true, by default) or not (false).

  • enabled – defines whether the record is enabled (true, by default) or not (false).

AnalizeEnv(domain: str, ruk: str | None = None)[source]
BalanceResources(domain: int, ruk: str | None = None)[source]
ClearEnvs(ruk: str | None = None)[source]
DeleteBrokenEnvs(target_app_ids: str | None = None, ruk: str | None = None)[source]
EditSystemExternalDNSRecord(id: int, record_data: str | None = None, name: str | None = None, ttl: int | None = None, record_data_type: str | None = None, ssl_enabled: bool | None = None, enabled: bool | None = None, ruk: str | None = None)[source]
Parameters:
  • id – unique identifier of the target custom external DNS record.

  • record_data – new custom data for the DNS record.

  • name – name for DNS records (must be the same as one of the existing record).

  • ttl – TTL (time to live) value for the DNS record.

  • record_data_type – type of the DNS record data (currently, only the ‘TXT’ value is supported).

  • ssl_enabled – defines whether the SSL is enabled for the record (true, by default) or not (false).

  • enabled – defines whether the record is enabled (true, by default) or not (false).

ExportEnv(target_app_id: str, ruk: str | None = None)[source]
FixExtDns(uid: int | None = None, target_app_id: str | None = None, ruk: str | None = None)[source]
FixLaunching(ruk: str | None = None)[source]
GenerateZone(generate_slept: bool, ruk: str | None = None)[source]
GetAvgs(ruk: str | None = None)[source]
GetAvgs2(ruk: str | None = None)[source]
GetBalancerStat(start_time: datetime, end_time: datetime, ruk: str | None = None)[source]
GetCloudletsUsage(ruk: str | None = None)[source]
GetDBCreationStat(start_time: datetime, end_time: datetime, ruk: str | None = None)[source]
GetErrors(start_time: datetime, end_time: datetime, start_row: int, result_count: int, filter: int | None = None, ruk: str | None = None)[source]
GetErrorsByDate(start_time: datetime, end_time: datetime, interval: int, filter: int | None = None, ruk: str | None = None)[source]
GetSystemExternalDNSRecords(ruk: str | None = None)[source]
GetZone(ruk: str | None = None)[source]
ImportEnv(env_info: str, env_name: str | None = None, enable_firewall: bool | None = None, ruk: str | None = None)[source]
InspectEnvs(remove: bool | None = None, ruk: str | None = None)[source]
ManageService(node_id: int, command: str, service_name: str, ruk: str | None = None)[source]
RemoveSystemExternalDNSRecord(id: int, ruk: str | None = None)[source]
UpdateEnv(target_app_id: str, ruk: str | None = None)[source]
UpdateEnvInThread(target_app_id: str, ruk: str | None = None)[source]
UpdateNodes(ruk: str | None = None)[source]
class jelastic.api.administration._VirtualNetwork(session: Session, token: str, debug: bool = False, ruk: str | None = None)[source]

Bases: Administration

Ref: https://docs.jelastic.com/api/private/#!/api/administration.VirtualNetwork

AddVirtualNetwork(virtual_network: dict, ruk: str | None = None)[source]
Parameters:

virtual_network – a list of the target virtual networks’ unique identifiers.

ApplyVirtualNetworks(host_id: int | None = None, ruk: str | None = None)[source]
Parameters:

host_id – unique identifier of the target host (all hosts if not defined).

DeleteVirtualNetworks(ids: int | None = None, ruk: str | None = None)[source]
Parameters:

ids – a list of the target virtual networks’ unique identifiers.

GetVirtualNetworks(ids: int | None = None, ruk: str | None = None)[source]
Parameters:

ids – a list of the target virtual networks’ unique identifiers.