This repository has been archived on 2024-07-30. You can view files and clone it, but cannot push or open issues or pull requests.
python-aternos/docs/build/python_aternos.html

3426 lines
329 KiB
HTML
Raw Normal View History

2022-06-17 14:34:47 +04:00
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />
<title>python_aternos package &#8212; python-aternos 1.0.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" />
<link rel="stylesheet" type="text/css" href="_static/alabaster.css" />
<script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script>
<script src="_static/jquery.js"></script>
<script src="_static/underscore.js"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script>
<script src="_static/doctools.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="stylesheet" href="_static/custom.css" type="text/css" />
<meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9" />
</head><body>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<section id="python-aternos-package">
<h1>python_aternos package<a class="headerlink" href="#python-aternos-package" title="Permalink to this heading"></a></h1>
<section id="submodules">
<h2>Submodules<a class="headerlink" href="#submodules" title="Permalink to this heading"></a></h2>
</section>
<section id="module-python_aternos.atclient">
<span id="python-aternos-atclient-module"></span><h2>python_aternos.atclient module<a class="headerlink" href="#module-python_aternos.atclient" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atclient.Client">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atclient.</span></span><span class="sig-name descname"><span class="pre">Client</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atconn</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><span class="pre">AternosConnect</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atclient.Client" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Aternos API Client class whose object contains user’s auth data</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>atconn</strong> (<a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><em>python_aternos.atconnect.AternosConnect</em></a>) – <a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconnect.AternosConnect</span></code></a> instance with initialized Aternos session</p>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.change_email">
<span class="sig-name descname"><span class="pre">change_email</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atclient.Client.change_email" title="Permalink to this definition"></a></dt>
<dd><p>Changes an e-mail in your Aternos account</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New e-mail</p>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><strong>ValueError</strong> – If an invalid e-mail address is passed to the function</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.change_password">
<span class="sig-name descname"><span class="pre">change_password</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">old</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">new</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atclient.Client.change_password" title="Permalink to this definition"></a></dt>
<dd><p>Changes a password in your Aternos account</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>old</strong> (<em>str</em>) – Old password</p></li>
<li><p><strong>new</strong> (<em>str</em>) – New password</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.change_username">
<span class="sig-name descname"><span class="pre">change_username</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atclient.Client.change_username" title="Permalink to this definition"></a></dt>
<dd><p>Changes a username in your Aternos account</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New username</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.from_credentials">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">from_credentials</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">username</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">password</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atclient.Client.from_credentials" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos with a username and a plain password</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>username</strong> (<em>str</em>) – Your username</p></li>
<li><p><strong>password</strong> (<em>str</em>) – Your password without any encryption</p></li>
</ul>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Client instance</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.from_hashed">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">from_hashed</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">username</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">md5</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atclient.Client.from_hashed" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos with a username and a hashed password</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>username</strong> (<em>str</em>) – Your username</p></li>
<li><p><strong>md5</strong> (<em>str</em>) – Your password hashed with MD5</p></li>
</ul>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.aterrors.CredentialsError" title="python_aternos.aterrors.CredentialsError"><strong>CredentialsError</strong></a> – If the API doesn’t return a valid session cookie</p>
</dd>
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Client instance</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.from_session">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">from_session</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">session</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atclient.Client.from_session" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos using a session cookie value</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>session</strong> (<em>str</em>) – Value of ATERNOS_SESSION cookie</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Client instance</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.get_server">
<span class="sig-name descname"><span class="pre">get_server</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">servid</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a></span></span><a class="headerlink" href="#python_aternos.atclient.Client.get_server" title="Permalink to this definition"></a></dt>
<dd><p>Creates a server object from the server ID.
Use this instead of list_servers if you know the ID to save some time.</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> object</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer">python_aternos.atserver.AternosServer</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.list_servers">
<span class="sig-name descname"><span class="pre">list_servers</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.atclient.Client.list_servers" title="Permalink to this definition"></a></dt>
<dd><p>Parses a list of your servers from Aternos website</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>List of <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> objects</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>list</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.md5encode">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">md5encode</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">passwd</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atclient.Client.md5encode" title="Permalink to this definition"></a></dt>
<dd><p>Encodes the given string with MD5</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>passwd</strong> (<em>str</em>) – String to encode</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Hexdigest hash of the string in lowercase</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.restore_session">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">restore_session</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">file</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'~/.aternos'</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atclient.Client.restore_session" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos using a saved ATERNOS_SESSION cookie</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>file</strong> (<em>str</em><em>, </em><em>optional</em>) – File where a session cookie was saved, deafults to ~/.aternos</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Client instance</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atclient.Client.save_session">
<span class="sig-name descname"><span class="pre">save_session</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">file</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'~/.aternos'</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atclient.Client.save_session" title="Permalink to this definition"></a></dt>
<dd><p>Saves an ATERNOS_SESSION cookie to a file</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>file</strong> (<em>str</em><em>, </em><em>optional</em>) – File where a session cookie must be saved, defaults to ~/.aternos</p>
</dd>
</dl>
</dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos.atconf">
<span id="python-aternos-atconf-module"></span><h2>python_aternos.atconf module<a class="headerlink" href="#module-python_aternos.atconf" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atconf.</span></span><span class="sig-name descname"><span class="pre">AternosConfig</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atconf.AternosConfig" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for editing server settings</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> object</p>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.get_java">
<span class="sig-name descname"><span class="pre">get_java</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">int</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.get_java" title="Permalink to this definition"></a></dt>
<dd><p>Parses Java version from options page</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Java image version</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>int</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.get_server_props">
<span class="sig-name descname"><span class="pre">get_server_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">proptyping</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.get_server_props" title="Permalink to this definition"></a></dt>
<dd><p>Parses all server.properties from options page</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>proptyping</strong> – If the returned dict should contain value</p>
</dd>
</dl>
<p>that matches property type (e.g. max-players will be int)
instead of string, defaults to True
:type proptyping: bool, optional
:return: Server.properties dict
:rtype: Dict[str,Any]</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.get_timezone">
<span class="sig-name descname"><span class="pre">get_timezone</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.get_timezone" title="Permalink to this definition"></a></dt>
<dd><p>Parses timezone from options page</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Area/Location</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.get_world_props">
<span class="sig-name descname"><span class="pre">get_world_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">world</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'world'</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">proptyping</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.get_world_props" title="Permalink to this definition"></a></dt>
<dd><p>Parses level.dat from specified world’s options page</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>world</strong> (<em>str</em><em>, </em><em>optional</em>) – Name of the world, defaults to ‘world’</p></li>
<li><p><strong>proptyping</strong> – If the returned dict should contain the value</p></li>
</ul>
</dd>
</dl>
<p>that matches property type (e.g. randomTickSpeed will be bool)
instead of string, defaults to True
:type proptyping: bool, optional
:return: Level.dat dict
:rtype: Dict[str,Any]</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.set_java">
<span class="sig-name descname"><span class="pre">set_java</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.set_java" title="Permalink to this definition"></a></dt>
<dd><p>Sets new Java version</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>int</em>) – New Java image version</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.set_server_prop">
<span class="sig-name descname"><span class="pre">set_server_prop</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">option</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.set_server_prop" title="Permalink to this definition"></a></dt>
<dd><p>Sets server.properties option</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>option</strong> (<em>str</em>) – Option name</p></li>
<li><p><strong>value</strong> (<em>Any</em>) – New value</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.set_server_props">
<span class="sig-name descname"><span class="pre">set_server_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">props</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.set_server_props" title="Permalink to this definition"></a></dt>
<dd><p>Updates server.properties options with the given dict</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>props</strong> (<em>Dict</em><em>[</em><em>str</em><em>,</em><em>Any</em><em>]</em>) – Dict with properties <cite>{key:value}</cite></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.set_timezone">
<span class="sig-name descname"><span class="pre">set_timezone</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.set_timezone" title="Permalink to this definition"></a></dt>
<dd><p>Sets new timezone</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New timezone</p>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><strong>ValueError</strong> – If given string</p>
</dd>
</dl>
<p>doesn’t match Area/Location format</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.set_world_prop">
<span class="sig-name descname"><span class="pre">set_world_prop</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">option</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atconf.WorldOpts" title="python_aternos.atconf.WorldOpts"><span class="pre">WorldOpts</span></a><span class="p"><span class="pre">,</span></span><span class="w"> </span><a class="reference internal" href="#python_aternos.atconf.WorldRules" title="python_aternos.atconf.WorldRules"><span class="pre">WorldRules</span></a><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">gamerule</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">world</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'world'</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.set_world_prop" title="Permalink to this definition"></a></dt>
<dd><p>Sets level.dat option for specified world</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>option</strong> (<em>Union</em><em>[</em><a class="reference internal" href="#python_aternos.atconf.WorldOpts" title="python_aternos.atconf.WorldOpts"><em>WorldOpts</em></a><em>,</em><a class="reference internal" href="#python_aternos.atconf.WorldRules" title="python_aternos.atconf.WorldRules"><em>WorldRules</em></a><em>]</em>) – Option name</p></li>
<li><p><strong>value</strong> (<em>Any</em>) – New value</p></li>
<li><p><strong>gamerule</strong> – If the option</p></li>
</ul>
</dd>
</dl>
<p>is a gamerule, defaults to False
:type gamerule: bool, optional
:param world: Name of the world which
level.dat must be edited, defaults to ‘world’
:type world: str, optional</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconf.AternosConfig.set_world_props">
<span class="sig-name descname"><span class="pre">set_world_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">props</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atconf.AternosConfig.set_world_props" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atconf.Difficulty">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atconf.</span></span><span class="sig-name descname"><span class="pre">Difficulty</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atconf.Difficulty" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>/difficulty numeric list</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Difficulty.easy">
<span class="sig-name descname"><span class="pre">easy</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.atconf.Difficulty.easy" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Difficulty.hard">
<span class="sig-name descname"><span class="pre">hard</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#python_aternos.atconf.Difficulty.hard" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Difficulty.normal">
<span class="sig-name descname"><span class="pre">normal</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#python_aternos.atconf.Difficulty.normal" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Difficulty.peaceful">
<span class="sig-name descname"><span class="pre">peaceful</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.atconf.Difficulty.peaceful" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atconf.Gamemode">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atconf.</span></span><span class="sig-name descname"><span class="pre">Gamemode</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atconf.Gamemode" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>/gamemode numeric list</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Gamemode.adventure">
<span class="sig-name descname"><span class="pre">adventure</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#python_aternos.atconf.Gamemode.adventure" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Gamemode.creative">
<span class="sig-name descname"><span class="pre">creative</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.atconf.Gamemode.creative" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Gamemode.spectator">
<span class="sig-name descname"><span class="pre">spectator</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#python_aternos.atconf.Gamemode.spectator" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.Gamemode.survival">
<span class="sig-name descname"><span class="pre">survival</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.atconf.Gamemode.survival" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atconf.</span></span><span class="sig-name descname"><span class="pre">ServerOpts</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atconf.ServerOpts" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>server.options file</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.animals">
<span class="sig-name descname"><span class="pre">animals</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-animals'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.animals" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.cmdblock">
<span class="sig-name descname"><span class="pre">cmdblock</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'enable-command-block'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.cmdblock" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.cmds">
<span class="sig-name descname"><span class="pre">cmds</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'allow-cheats'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.cmds" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.difficulty">
<span class="sig-name descname"><span class="pre">difficulty</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'difficulty'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.difficulty" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.flight">
<span class="sig-name descname"><span class="pre">flight</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'allow-flight'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.flight" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.forcegm">
<span class="sig-name descname"><span class="pre">forcegm</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'force-gamemode'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.forcegm" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.gm">
<span class="sig-name descname"><span class="pre">gm</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'gamemode'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.gm" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.monsters">
<span class="sig-name descname"><span class="pre">monsters</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-monsters'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.monsters" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.nether">
<span class="sig-name descname"><span class="pre">nether</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'allow-nether'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.nether" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.online">
<span class="sig-name descname"><span class="pre">online</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'online-mode'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.online" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.pack">
<span class="sig-name descname"><span class="pre">pack</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'resource-pack'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.pack" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.packreq">
<span class="sig-name descname"><span class="pre">packreq</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'require-resource-pack'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.packreq" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.players">
<span class="sig-name descname"><span class="pre">players</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'max-players'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.players" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.pvp">
<span class="sig-name descname"><span class="pre">pvp</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'pvp'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.pvp" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.spawnlock">
<span class="sig-name descname"><span class="pre">spawnlock</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-protection'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.spawnlock" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.villagers">
<span class="sig-name descname"><span class="pre">villagers</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-npcs'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.villagers" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.ServerOpts.whl">
<span class="sig-name descname"><span class="pre">whl</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'white-list'</span></em><a class="headerlink" href="#python_aternos.atconf.ServerOpts.whl" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldOpts">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atconf.</span></span><span class="sig-name descname"><span class="pre">WorldOpts</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atconf.WorldOpts" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>level.dat file</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldOpts.difficulty">
<span class="sig-name descname"><span class="pre">difficulty</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'Difficulty'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldOpts.difficulty" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldOpts.hardcore">
<span class="sig-name descname"><span class="pre">hardcore</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'hardcore'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldOpts.hardcore" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldOpts.seed">
<span class="sig-name descname"><span class="pre">seed</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'seed'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldOpts.seed" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldOpts.seed12">
<span class="sig-name descname"><span class="pre">seed12</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'randomseed'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldOpts.seed12" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atconf.</span></span><span class="sig-name descname"><span class="pre">WorldRules</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atconf.WorldRules" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>/gamerule list</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.admincmdlog">
<span class="sig-name descname"><span class="pre">admincmdlog</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'logAdminCommands'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.admincmdlog" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.advs">
<span class="sig-name descname"><span class="pre">advs</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'announceAdvancements'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.advs" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.blockdrop">
<span class="sig-name descname"><span class="pre">blockdrop</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doTileDrops'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.blockdrop" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.cmdfb">
<span class="sig-name descname"><span class="pre">cmdfb</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'sendCommandFeedback'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.cmdfb" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.cmdlen">
<span class="sig-name descname"><span class="pre">cmdlen</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'maxCommandChainLength'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.cmdlen" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.cmdout">
<span class="sig-name descname"><span class="pre">cmdout</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'commandBlockOutput'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.cmdout" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.daynight">
<span class="sig-name descname"><span class="pre">daynight</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doDaylightCycle'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.daynight" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.deathmsg">
<span class="sig-name descname"><span class="pre">deathmsg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'showDeathMessages'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.deathmsg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.drowndmg">
<span class="sig-name descname"><span class="pre">drowndmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'drowningDamage'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.drowndmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.elytra">
<span class="sig-name descname"><span class="pre">elytra</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'disableElytraMovementCheck'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.elytra" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.entcram">
<span class="sig-name descname"><span class="pre">entcram</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'maxEntityCramming'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.entcram" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.entdrop">
<span class="sig-name descname"><span class="pre">entdrop</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doEntityDrops'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.entdrop" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.falldmg">
<span class="sig-name descname"><span class="pre">falldmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'fallDamage'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.falldmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.fire">
<span class="sig-name descname"><span class="pre">fire</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doFireTick'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.fire" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.firedmg">
<span class="sig-name descname"><span class="pre">firedmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'fireDamage'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.firedmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.forgive">
<span class="sig-name descname"><span class="pre">forgive</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'forgiveDeadPlayers'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.forgive" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.immrespawn">
<span class="sig-name descname"><span class="pre">immrespawn</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doImmediateRespawn'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.immrespawn" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.keepinv">
<span class="sig-name descname"><span class="pre">keepinv</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'keepInventory'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.keepinv" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.limitcraft">
<span class="sig-name descname"><span class="pre">limitcraft</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doLimitedCrafting'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.limitcraft" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.mobgrief">
<span class="sig-name descname"><span class="pre">mobgrief</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'mobGriefing'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.mobgrief" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.mobloot">
<span class="sig-name descname"><span class="pre">mobloot</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doMobLoot'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.mobloot" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.mobs">
<span class="sig-name descname"><span class="pre">mobs</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doMobSpawning'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.mobs" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.patrols">
<span class="sig-name descname"><span class="pre">patrols</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doPatrolSpawning'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.patrols" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.phantoms">
<span class="sig-name descname"><span class="pre">phantoms</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doInsomnia'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.phantoms" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.raids">
<span class="sig-name descname"><span class="pre">raids</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'disableRaids'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.raids" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.reducedf3">
<span class="sig-name descname"><span class="pre">reducedf3</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'reducedDebugInfo'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.reducedf3" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.regen">
<span class="sig-name descname"><span class="pre">regen</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'naturalRegeneration'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.regen" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.rndtick">
<span class="sig-name descname"><span class="pre">rndtick</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'randomTickSpeed'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.rndtick" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.sleeppct">
<span class="sig-name descname"><span class="pre">sleeppct</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'playersSleepingPercentage'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.sleeppct" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.snowdmg">
<span class="sig-name descname"><span class="pre">snowdmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'freezeDamage'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.snowdmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.spawnradius">
<span class="sig-name descname"><span class="pre">spawnradius</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawnRadius'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.spawnradius" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.spectchunkgen">
<span class="sig-name descname"><span class="pre">spectchunkgen</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spectatorsGenerateChunks'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.spectchunkgen" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.traders">
<span class="sig-name descname"><span class="pre">traders</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doTraderSpawning'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.traders" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.univanger">
<span class="sig-name descname"><span class="pre">univanger</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'universalAnger'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.univanger" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atconf.WorldRules.weather">
<span class="sig-name descname"><span class="pre">weather</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doWeatherCycle'</span></em><a class="headerlink" href="#python_aternos.atconf.WorldRules.weather" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos.atconnect">
<span id="python-aternos-atconnect-module"></span><h2>python_aternos.atconnect module<a class="headerlink" href="#module-python_aternos.atconnect" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atconnect.AternosConnect">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atconnect.</span></span><span class="sig-name descname"><span class="pre">AternosConnect</span></span><a class="headerlink" href="#python_aternos.atconnect.AternosConnect" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for sending API requests bypass Cloudflare
and parsing responses</p>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconnect.AternosConnect.convert_num">
<span class="sig-name descname"><span class="pre">convert_num</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">num</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">float</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">base</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">frombase</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">10</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atconnect.AternosConnect.convert_num" title="Permalink to this definition"></a></dt>
<dd><p>Converts an integer to specified base</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>num</strong> – Integer in any base to convert.</p>
</dd>
</dl>
<p>If it is a float started with <cite>0,</cite>,
zero and comma will be removed to get int
:type num: Union[int,float,str]
:param base: New base
:type base: int
:param frombase: Given number base, defaults to 10
:type frombase: int, optional
:return: Number converted to a specified base
:rtype: str</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconnect.AternosConnect.generate_aternos_rand">
<span class="sig-name descname"><span class="pre">generate_aternos_rand</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">randlen</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">16</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atconnect.AternosConnect.generate_aternos_rand" title="Permalink to this definition"></a></dt>
<dd><p>Generates a random string using
Aternos algorithm from main.js file</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>randlen</strong> (<em>int</em><em>, </em><em>optional</em>) – Random string length, defaults to 16</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Random string for SEC token</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconnect.AternosConnect.generate_sec">
<span class="sig-name descname"><span class="pre">generate_sec</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atconnect.AternosConnect.generate_sec" title="Permalink to this definition"></a></dt>
<dd><p>Generates Aternos SEC token which
is also needed for most API requests</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Random SEC key:value string</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconnect.AternosConnect.parse_token">
<span class="sig-name descname"><span class="pre">parse_token</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atconnect.AternosConnect.parse_token" title="Permalink to this definition"></a></dt>
<dd><p>Parses Aternos ajax token that
is needed for most requests</p>
<dl class="field-list simple">
<dt class="field-odd">Raises<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>RuntimeWarning</strong> – If the parser</p>
</dd>
</dl>
<p>can not find &lt;head&gt; tag in HTML response
:raises CredentialsError: If the parser
is unable to extract ajax token in HTML
:return: Aternos ajax token
:rtype: str</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atconnect.AternosConnect.request_cloudflare">
<span class="sig-name descname"><span class="pre">request_cloudflare</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">url</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">method</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">params</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">data</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">headers</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">reqcookies</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">sendtoken</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">redirect</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">retry</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">3</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Response</span></span></span><a class="headerlink" href="#python_aternos.atconnect.AternosConnect.request_cloudflare" title="Permalink to this definition"></a></dt>
<dd><p>Sends a request to Aternos API bypass Cloudflare</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>url</strong> (<em>str</em>) – Request URL</p></li>
<li><p><strong>method</strong> (<em>str</em>) – Request method, must be GET or POST</p></li>
<li><p><strong>params</strong> (<em>Optional</em><em>[</em><em>dict</em><em>]</em><em>, </em><em>optional</em>) – URL parameters, defaults to None</p></li>
<li><p><strong>data</strong> – POST request data, if the method is GET,</p></li>
</ul>
</dd>
</dl>
<p>this dict will be combined with params, defaults to None
:type data: Optional[dict], optional
:param headers: Custom headers, defaults to None
:type headers: Optional[dict], optional
:param reqcookies: Cookies only for this request, defaults to None
:type reqcookies: Optional[dict], optional
:param sendtoken: If the ajax and SEC token
should be sent, defaults to False
:type sendtoken: bool, optional
:param redirect: If requests lib should follow
Location header in 3xx responses, defaults to True
:type redirect: bool, optional
:param retry: How many times parser must retry
connection to API bypass Cloudflare, defaults to 3
:type retry: int, optional
:raises CloudflareError:
When the parser has exceeded retries count
:raises NotImplementedError:
When the specified method is not GET or POST
:return: API response
:rtype: requests.Response</p>
</dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos.aterrors">
<span id="python-aternos-aterrors-module"></span><h2>python_aternos.aterrors module<a class="headerlink" href="#module-python_aternos.aterrors" title="Permalink to this heading"></a></h2>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.AternosError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">AternosError</span></span><a class="headerlink" href="#python_aternos.aterrors.AternosError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Exception</span></code></p>
<p>Common error class</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.CloudflareError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">CloudflareError</span></span><a class="headerlink" href="#python_aternos.aterrors.CloudflareError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when the parser is unable to bypass Cloudflare protection</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.CredentialsError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">CredentialsError</span></span><a class="headerlink" href="#python_aternos.aterrors.CredentialsError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when a session cookie is empty which means incorrect credentials</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.FileError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">FileError</span></span><a class="headerlink" href="#python_aternos.aterrors.FileError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when trying to execute a disallowed by Aternos file operation</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.ServerError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">ServerError</span></span><a class="headerlink" href="#python_aternos.aterrors.ServerError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Common class for server errors</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.ServerEulaError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">ServerEulaError</span></span><a class="headerlink" href="#python_aternos.aterrors.ServerEulaError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when trying to start without confirming Mojang EULA</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.ServerRunningError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">ServerRunningError</span></span><a class="headerlink" href="#python_aternos.aterrors.ServerRunningError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when trying to start already running server</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.ServerSoftwareError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">ServerSoftwareError</span></span><a class="headerlink" href="#python_aternos.aterrors.ServerSoftwareError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when Aternos notifies about incorrect software version</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.ServerStorageError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">ServerStorageError</span></span><a class="headerlink" href="#python_aternos.aterrors.ServerStorageError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when Aternos notifies about violation of storage limits (4 GB for now)</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.aterrors.TokenError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.aterrors.</span></span><span class="sig-name descname"><span class="pre">TokenError</span></span><a class="headerlink" href="#python_aternos.aterrors.TokenError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when the parser is unable to extract Aternos ajax token</p>
</dd></dl>
</section>
<section id="module-python_aternos.atfile">
<span id="python-aternos-atfile-module"></span><h2>python_aternos.atfile module<a class="headerlink" href="#module-python_aternos.atfile" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atfile.</span></span><span class="sig-name descname"><span class="pre">AternosFile</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a></span></em>, <em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">ftype</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atfile.FileType" title="python_aternos.atfile.FileType"><span class="pre">FileType</span></a></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">FileType.file</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">float</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">0</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atfile.AternosFile" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>File class which contains info about its path, type and size</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance</p></li>
<li><p><strong>path</strong> (<em>str</em>) – Path to the file</p></li>
<li><p><strong>name</strong> (<em>str</em>) – Filename</p></li>
<li><p><strong>ftype</strong> (<a class="reference internal" href="#python_aternos.atfile.FileType" title="python_aternos.atfile.FileType"><em>python_aternos.atfile.FileType</em></a>) – File or directory</p></li>
<li><p><strong>size</strong> (<em>Union</em><em>[</em><em>int</em><em>,</em><em>float</em><em>]</em><em>, </em><em>optional</em>) – File size, defaults to 0</p></li>
</ul>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.delete">
<span class="sig-name descname"><span class="pre">delete</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atfile.AternosFile.delete" title="Permalink to this definition"></a></dt>
<dd><p>Deletes the file</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.full">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">full</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atfile.AternosFile.full" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.get_content">
<span class="sig-name descname"><span class="pre">get_content</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">bytes</span></span></span><a class="headerlink" href="#python_aternos.atfile.AternosFile.get_content" title="Permalink to this definition"></a></dt>
<dd><p>Requests file content in bytes (downloads it)</p>
<dl class="field-list simple">
<dt class="field-odd">Raises<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.aterrors.FileError" title="python_aternos.aterrors.FileError"><strong>FileError</strong></a> – If downloading</p>
</dd>
</dl>
<p>the file is not allowed by Aternos
:return: File content
:rtype: bytes</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.get_text">
<span class="sig-name descname"><span class="pre">get_text</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atfile.AternosFile.get_text" title="Permalink to this definition"></a></dt>
<dd><p>Requests editing the file as a text
(try it if downloading is disallowed)</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>File text content</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.is_dir">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">is_dir</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">bool</span></em><a class="headerlink" href="#python_aternos.atfile.AternosFile.is_dir" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.is_file">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">is_file</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">bool</span></em><a class="headerlink" href="#python_aternos.atfile.AternosFile.is_file" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.name">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">name</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atfile.AternosFile.name" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.path">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">path</span></span><a class="headerlink" href="#python_aternos.atfile.AternosFile.path" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.set_content">
<span class="sig-name descname"><span class="pre">set_content</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bytes</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atfile.AternosFile.set_content" title="Permalink to this definition"></a></dt>
<dd><p>Modifies the file content</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>bytes</em>) – New content</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.set_text">
<span class="sig-name descname"><span class="pre">set_text</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atfile.AternosFile.set_text" title="Permalink to this definition"></a></dt>
<dd><p>Modifies the file content,
but unlike set_content takes
a string as a new value</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New content</p>
</dd>
</dl>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atfile.AternosFile.size">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">size</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">float</span></em><a class="headerlink" href="#python_aternos.atfile.AternosFile.size" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atfile.FileType">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atfile.</span></span><span class="sig-name descname"><span class="pre">FileType</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atfile.FileType" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>File or dierctory</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atfile.FileType.directory">
<span class="sig-name descname"><span class="pre">directory</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.atfile.FileType.directory" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atfile.FileType.file">
<span class="sig-name descname"><span class="pre">file</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.atfile.FileType.file" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos.atfm">
<span id="python-aternos-atfm-module"></span><h2>python_aternos.atfm module<a class="headerlink" href="#module-python_aternos.atfm" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atfm.FileManager">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atfm.</span></span><span class="sig-name descname"><span class="pre">FileManager</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atfm.FileManager" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Aternos file manager class for viewing files structure</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance</p>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfm.FileManager.convert_size">
<span class="sig-name descname"><span class="pre">convert_size</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">num</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">float</span><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">measure</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">float</span></span></span><a class="headerlink" href="#python_aternos.atfm.FileManager.convert_size" title="Permalink to this definition"></a></dt>
<dd><p>Converts “human” file size to size in bytes</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>num</strong> (<em>Union</em><em>[</em><em>int</em><em>,</em><em>float</em><em>]</em>) – Size</p></li>
<li><p><strong>measure</strong> (<em>str</em>) – Units (B, kB, MB, GB)</p></li>
</ul>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Size in bytes</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>float</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfm.FileManager.dl_file">
<span class="sig-name descname"><span class="pre">dl_file</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">bytes</span></span></span><a class="headerlink" href="#python_aternos.atfm.FileManager.dl_file" title="Permalink to this definition"></a></dt>
<dd><p>Returns the file content in bytes (downloads it)</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – Path to file including its filename</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>File content</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bytes</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfm.FileManager.dl_world">
<span class="sig-name descname"><span class="pre">dl_world</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">world</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'world'</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">bytes</span></span></span><a class="headerlink" href="#python_aternos.atfm.FileManager.dl_world" title="Permalink to this definition"></a></dt>
<dd><p>Returns the world zip file content
by its name (downloads it)</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>world</strong> (<em>str</em><em>, </em><em>optional</em>) – Name of world, defaults to ‘world’</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Zip file content</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bytes</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfm.FileManager.get_file">
<span class="sig-name descname"><span class="pre">get_file</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><span class="pre">AternosFile</span></a><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.atfm.FileManager.get_file" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfile.AternosFile</span></code></a>
instance by its path</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – Path to file including its filename</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>_description_</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>Optional[<a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile">AternosFile</a>]</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atfm.FileManager.listdir">
<span class="sig-name descname"><span class="pre">listdir</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">''</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><span class="pre">AternosFile</span></a><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.atfm.FileManager.listdir" title="Permalink to this definition"></a></dt>
<dd><p>Requests a list of files
in the specified directory</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>path</strong> – Directory</p>
</dd>
</dl>
<p>(an empty string means root), defaults to ‘’
:type path: str, optional
:return: List of <a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfile.AternosFile</span></code></a>
:rtype: List[AternosFile]</p>
</dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos.atjsparse">
<span id="python-aternos-atjsparse-module"></span><h2>python_aternos.atjsparse module<a class="headerlink" href="#module-python_aternos.atjsparse" title="Permalink to this heading"></a></h2>
<dl class="py function">
<dt class="sig sig-object py" id="python_aternos.atjsparse.atob">
<span class="sig-prename descclassname"><span class="pre">python_aternos.atjsparse.</span></span><span class="sig-name descname"><span class="pre">atob</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">s</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atjsparse.atob" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="python_aternos.atjsparse.exec">
<span class="sig-prename descclassname"><span class="pre">python_aternos.atjsparse.</span></span><span class="sig-name descname"><span class="pre">exec</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">f</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Any</span></span></span><a class="headerlink" href="#python_aternos.atjsparse.exec" title="Permalink to this definition"></a></dt>
<dd><p>Executes a JavaScript function</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>f</strong> (<em>str</em>) – ECMA6 function</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>JavaScript interpreter context</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>Any</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="python_aternos.atjsparse.to_ecma5_function">
<span class="sig-prename descclassname"><span class="pre">python_aternos.atjsparse.</span></span><span class="sig-name descname"><span class="pre">to_ecma5_function</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">f</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atjsparse.to_ecma5_function" title="Permalink to this definition"></a></dt>
<dd><p>Converts a ECMA6 function to ECMA5 format (without arrow expressions)</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>f</strong> (<em>str</em>) – ECMA6 function</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>ECMA5 function</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>str</p>
</dd>
</dl>
</dd></dl>
</section>
<section id="module-python_aternos.atplayers">
<span id="python-aternos-atplayers-module"></span><h2>python_aternos.atplayers module<a class="headerlink" href="#module-python_aternos.atplayers" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atplayers.Lists">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atplayers.</span></span><span class="sig-name descname"><span class="pre">Lists</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atplayers.Lists" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>An enumeration.</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atplayers.Lists.ban">
<span class="sig-name descname"><span class="pre">ban</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'banned-players'</span></em><a class="headerlink" href="#python_aternos.atplayers.Lists.ban" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atplayers.Lists.ips">
<span class="sig-name descname"><span class="pre">ips</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'banned-ips'</span></em><a class="headerlink" href="#python_aternos.atplayers.Lists.ips" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atplayers.Lists.ops">
<span class="sig-name descname"><span class="pre">ops</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'ops'</span></em><a class="headerlink" href="#python_aternos.atplayers.Lists.ops" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atplayers.Lists.whl">
<span class="sig-name descname"><span class="pre">whl</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'whitelist'</span></em><a class="headerlink" href="#python_aternos.atplayers.Lists.whl" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atplayers.PlayersList">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atplayers.</span></span><span class="sig-name descname"><span class="pre">PlayersList</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">lst</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><span class="pre">Lists</span></a><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atplayers.PlayersList" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for managing operators, whitelist and banned players lists</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>lst</strong> – Players list type, must be</p>
</dd>
</dl>
<p><a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.Lists</span></code></a> enum value
:type lst: Union[str,Lists]
:param atserv: <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance
:type atserv: python_aternos.atserver.AternosServer</p>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atplayers.PlayersList.add">
<span class="sig-name descname"><span class="pre">add</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atplayers.PlayersList.add" title="Permalink to this definition"></a></dt>
<dd><p>Appends a player to the list by the nickname</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>name</strong> (<em>str</em>) – Player’s nickname</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atplayers.PlayersList.list_players">
<span class="sig-name descname"><span class="pre">list_players</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">cache</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.atplayers.PlayersList.list_players" title="Permalink to this definition"></a></dt>
<dd><p>Parse a players list</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>cache</strong> (<em>bool</em><em>, </em><em>optional</em>) – If the function can return cached list (highly recommended), defaults to True</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>List of players nicknames</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>List[str]</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atplayers.PlayersList.remove">
<span class="sig-name descname"><span class="pre">remove</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atplayers.PlayersList.remove" title="Permalink to this definition"></a></dt>
<dd><p>Removes a player from the list by the nickname</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>name</strong> (<em>str</em>) – Player’s nickname</p>
</dd>
</dl>
</dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos.atserver">
<span id="python-aternos-atserver-module"></span><h2>python_aternos.atserver module<a class="headerlink" href="#module-python_aternos.atserver" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atserver.</span></span><span class="sig-name descname"><span class="pre">AternosServer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">servid</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">atconn</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><span class="pre">AternosConnect</span></a></span></em>, <em class="sig-param"><span class="n"><span class="pre">reqinfo</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atserver.AternosServer" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for controlling your Aternos Minecraft server</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>servid</strong> (<em>str</em>) – Unique server IDentifier</p></li>
<li><p><strong>atconn</strong><a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconnect.AternosConnect</span></code></a></p></li>
</ul>
</dd>
</dl>
<p>instance with initialized Aternos session
:type atconn: python_aternos.atconnect.AternosConnect
:param reqinfo: Automatically call AternosServer.fetch() to get all info, defaults to <cite>True</cite>
:type reqinfo: bool, optional</p>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.address">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">address</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.address" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.atserver_request">
<span class="sig-name descname"><span class="pre">atserver_request</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">url</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">method</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">params</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">data</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">headers</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">sendtoken</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Response</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.atserver_request" title="Permalink to this definition"></a></dt>
<dd><p>Sends a request to Aternos API
with server IDenitfier parameter</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>url</strong> (<em>str</em>) – Request URL</p></li>
<li><p><strong>method</strong> (<em>str</em>) – Request method, must be GET or POST</p></li>
<li><p><strong>params</strong> (<em>Optional</em><em>[</em><em>dict</em><em>]</em><em>, </em><em>optional</em>) – URL parameters, defaults to None</p></li>
<li><p><strong>data</strong> – POST request data, if the method is GET,</p></li>
</ul>
</dd>
</dl>
<p>this dict will be combined with params, defaults to None
:type data: Optional[dict], optional
:param headers: Custom headers, defaults to None
:type headers: Optional[dict], optional
:param sendtoken: If the ajax and SEC token
should be sent, defaults to False
:type sendtoken: bool, optional
:return: API response
:rtype: requests.Response</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.cancel">
<span class="sig-name descname"><span class="pre">cancel</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.cancel" title="Permalink to this definition"></a></dt>
<dd><p>Cancels server launching</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.config">
<span class="sig-name descname"><span class="pre">config</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig"><span class="pre">AternosConfig</span></a></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.config" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconf.AternosConfig</span></code></a>
instance for editing server settings</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconf.AternosConfig</span></code></a> object</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig">python_aternos.atconf.AternosConfig</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.confirm">
<span class="sig-name descname"><span class="pre">confirm</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.confirm" title="Permalink to this definition"></a></dt>
<dd><p>Confirms server launching</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.domain">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">domain</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.domain" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.edition">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">edition</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.edition" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.eula">
<span class="sig-name descname"><span class="pre">eula</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.eula" title="Permalink to this definition"></a></dt>
<dd><p>Accepts the Mojang EULA</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.fetch">
<span class="sig-name descname"><span class="pre">fetch</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.fetch" title="Permalink to this definition"></a></dt>
<dd><p>Send a request to Aternos API to get all server info</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.files">
<span class="sig-name descname"><span class="pre">files</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager"><span class="pre">FileManager</span></a></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.files" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfm.FileManager</span></code></a>
instance for file operations</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfm.FileManager</span></code></a> object</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager">python_aternos.atfm.FileManager</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.motd">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">motd</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.motd" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.players">
<span class="sig-name descname"><span class="pre">players</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">lst</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><span class="pre">Lists</span></a></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atplayers.PlayersList" title="python_aternos.atplayers.PlayersList"><span class="pre">PlayersList</span></a></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.players" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atplayers.PlayersList" title="python_aternos.atplayers.PlayersList"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.PlayersList</span></code></a>
instance for managing operators, whitelist and banned players lists</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>lst</strong> – Players list type, must be</p>
</dd>
</dl>
<p>the <a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.Lists</span></code></a> enum value
:type lst: python_aternos.atplayers.Lists
:return: <a class="reference internal" href="#python_aternos.atplayers.PlayersList" title="python_aternos.atplayers.PlayersList"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.PlayersList</span></code></a>
:rtype: python_aternos.atplayers.PlayersList</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.players_count">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">players_count</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.players_count" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.players_list">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">players_list</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.players_list" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.port">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">port</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.port" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.ram">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ram</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.ram" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.restart">
<span class="sig-name descname"><span class="pre">restart</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.restart" title="Permalink to this definition"></a></dt>
<dd><p>Restarts the server</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.slots">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">slots</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.slots" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.software">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">software</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.software" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.start">
<span class="sig-name descname"><span class="pre">start</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">headstart</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">accepteula</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.start" title="Permalink to this definition"></a></dt>
<dd><p>Starts a server</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>headstart</strong> (<em>bool</em><em>, </em><em>optional</em>) – Start a server in the headstart mode which allows you to skip all queue, defaults to <cite>False</cite></p></li>
<li><p><strong>accepteula</strong> (<em>bool</em><em>, </em><em>optional</em>) – Automatically accept the Mojang EULA, defaults to <cite>True</cite></p></li>
</ul>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.aterrors.ServerEulaError" title="python_aternos.aterrors.ServerEulaError"><strong>ServerEulaError</strong></a> – When trying to start a server</p>
</dd>
</dl>
<p>without accepting the Mojang EULA
:raises ServerRunningError: When trying to start a server
which is alreday running
:raises ServerSoftwareError: When Aternos notifies about
incorrect software version
:raises ServerStorageError: When Aternos notifies about
voilation of storage limits (4 GB for now)
:raises ServerError: When API is unable to start a Minecraft server
due to unavailability of Aternos’ file servers or other problems</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.status">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">status</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.status" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.status_num">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">status_num</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.status_num" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.stop">
<span class="sig-name descname"><span class="pre">stop</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.stop" title="Permalink to this definition"></a></dt>
<dd><p>Stops the server</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.subdomain">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">subdomain</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.subdomain" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.version">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">version</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.atserver.AternosServer.version" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atserver.AternosServer.wss">
<span class="sig-name descname"><span class="pre">wss</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">autoconfirm</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atwss.AternosWss" title="python_aternos.atwss.AternosWss"><span class="pre">AternosWss</span></a></span></span><a class="headerlink" href="#python_aternos.atserver.AternosServer.wss" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atwss.AternosWss" title="python_aternos.atwss.AternosWss"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atwss.AternosWss</span></code></a> instance for listening server streams in real-time</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>autoconfirm</strong> – Automatically start server status listener</p>
</dd>
</dl>
<p>when AternosWss connects to API to confirm server launching, defaults to <cite>False</cite>
:type autoconfirm: bool, optional
:return: <a class="reference internal" href="#python_aternos.atwss.AternosWss" title="python_aternos.atwss.AternosWss"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atwss.AternosWss</span></code></a> object
:rtype: python_aternos.atwss.AternosWss</p>
</dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atserver.Edition">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atserver.</span></span><span class="sig-name descname"><span class="pre">Edition</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atserver.Edition" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>Server edition type enum</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Edition.bedrock">
<span class="sig-name descname"><span class="pre">bedrock</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.atserver.Edition.bedrock" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Edition.java">
<span class="sig-name descname"><span class="pre">java</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.atserver.Edition.java" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atserver.Status">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atserver.</span></span><span class="sig-name descname"><span class="pre">Status</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atserver.Status" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>Server numeric status enum.
It is highly recommended to use
<cite>AternosServer.status</cite> instead of
<cite>AternosServer.status_num</cite></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Status.confirm">
<span class="sig-name descname"><span class="pre">confirm</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">10</span></em><a class="headerlink" href="#python_aternos.atserver.Status.confirm" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Status.error">
<span class="sig-name descname"><span class="pre">error</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">7</span></em><a class="headerlink" href="#python_aternos.atserver.Status.error" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Status.off">
<span class="sig-name descname"><span class="pre">off</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.atserver.Status.off" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Status.on">
<span class="sig-name descname"><span class="pre">on</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.atserver.Status.on" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Status.shutdown">
<span class="sig-name descname"><span class="pre">shutdown</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#python_aternos.atserver.Status.shutdown" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Status.starting">
<span class="sig-name descname"><span class="pre">starting</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#python_aternos.atserver.Status.starting" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atserver.Status.unknown">
<span class="sig-name descname"><span class="pre">unknown</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">6</span></em><a class="headerlink" href="#python_aternos.atserver.Status.unknown" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos.atwss">
<span id="python-aternos-atwss-module"></span><h2>python_aternos.atwss module<a class="headerlink" href="#module-python_aternos.atwss" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atwss.</span></span><span class="sig-name descname"><span class="pre">AternosWss</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a></span></em>, <em class="sig-param"><span class="n"><span class="pre">autoconfirm</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atwss.AternosWss" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for managing websocket connection</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance</p></li>
<li><p><strong>autoconfirm</strong> – Automatically start server status listener</p></li>
</ul>
</dd>
</dl>
<p>when AternosWss connects to API to confirm server launching, defaults to <cite>False</cite>
:type autoconfirm: bool, optional</p>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.close">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">close</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.close" title="Permalink to this definition"></a></dt>
<dd><p>Closes websocket connection and stops all listeners</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.confirm">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">confirm</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.confirm" title="Permalink to this definition"></a></dt>
<dd><p>Simple way to call AternosServer.confirm from this class</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.connect">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">connect</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.connect" title="Permalink to this definition"></a></dt>
<dd><p>Connect to the websocket server and start all stream listeners</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.keepalive">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">keepalive</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.keepalive" title="Permalink to this definition"></a></dt>
<dd><p>Each 49 seconds sends keepalive ping to websocket server</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.receiver">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">receiver</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.receiver" title="Permalink to this definition"></a></dt>
<dd><p>Receives messages from websocket servers
and calls user’s streams listeners</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.send">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">send</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">obj</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.send" title="Permalink to this definition"></a></dt>
<dd><p>Sends a message to websocket server</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>obj</strong> (<em>Union</em><em>[</em><em>Dict</em><em>[</em><em>str</em><em>, </em><em>Any</em><em>]</em><em>,</em><em>str</em><em>]</em>) – Message, may be a string or a dict</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.wssreceiver">
<span class="sig-name descname"><span class="pre">wssreceiver</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">stream</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atwss.Streams" title="python_aternos.atwss.Streams"><span class="pre">Streams</span></a></span></em>, <em class="sig-param"><span class="o"><span class="pre">*</span></span><span class="n"><span class="pre">args</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Callable</span><span class="p"><span class="pre">[</span></span><span class="p"><span class="pre">[</span></span><span class="pre">Callable</span><span class="p"><span class="pre">[</span></span><span class="p"><span class="pre">[</span></span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Coroutine</span><span class="p"><span class="pre">[</span></span><span class="pre">Any</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">None</span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.wssreceiver" title="Permalink to this definition"></a></dt>
<dd><p>Decorator that marks your function as a stream receiver.
When websocket receives message from the specified stream,
it calls all listeners created with this decorator.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>stream</strong> (<a class="reference internal" href="#python_aternos.atwss.Streams" title="python_aternos.atwss.Streams"><em>python_aternos.atwss.Streams</em></a>) – Stream that your function should listen</p></li>
<li><p><strong>args</strong> (<em>tuple</em><em>, </em><em>optional</em>) – Arguments which will be passed to your function</p></li>
</ul>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p><p></p>
</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>Callable[[Callable[[Any],Coroutine[Any,Any,None]]],Any]</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.atwss.AternosWss.wssworker">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">wssworker</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.atwss.AternosWss.wssworker" title="Permalink to this definition"></a></dt>
<dd><p>Starts async tasks in background
for receiving websocket messages
and sending keepalive ping</p>
</dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.atwss.Streams">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.atwss.</span></span><span class="sig-name descname"><span class="pre">Streams</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.atwss.Streams" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>WebSocket streams types</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atwss.Streams.console">
<span class="sig-name descname"><span class="pre">console</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(2,</span> <span class="pre">'console')</span></em><a class="headerlink" href="#python_aternos.atwss.Streams.console" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atwss.Streams.queue">
<span class="sig-name descname"><span class="pre">queue</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(1,</span> <span class="pre">None)</span></em><a class="headerlink" href="#python_aternos.atwss.Streams.queue" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atwss.Streams.ram">
<span class="sig-name descname"><span class="pre">ram</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(3,</span> <span class="pre">'heap')</span></em><a class="headerlink" href="#python_aternos.atwss.Streams.ram" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atwss.Streams.status">
<span class="sig-name descname"><span class="pre">status</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(0,</span> <span class="pre">None)</span></em><a class="headerlink" href="#python_aternos.atwss.Streams.status" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.atwss.Streams.tps">
<span class="sig-name descname"><span class="pre">tps</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(4,</span> <span class="pre">'tick')</span></em><a class="headerlink" href="#python_aternos.atwss.Streams.tps" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
</section>
<section id="module-python_aternos">
<span id="module-contents"></span><h2>Module contents<a class="headerlink" href="#module-python_aternos" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.AternosConfig">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">AternosConfig</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.AternosServer" title="python_aternos.AternosServer"><span class="pre">AternosServer</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.AternosConfig" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for editing server settings</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> object</p>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.get_java">
<span class="sig-name descname"><span class="pre">get_java</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">int</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.get_java" title="Permalink to this definition"></a></dt>
<dd><p>Parses Java version from options page</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Java image version</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>int</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.get_server_props">
<span class="sig-name descname"><span class="pre">get_server_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">proptyping</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.get_server_props" title="Permalink to this definition"></a></dt>
<dd><p>Parses all server.properties from options page</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>proptyping</strong> – If the returned dict should contain value</p>
</dd>
</dl>
<p>that matches property type (e.g. max-players will be int)
instead of string, defaults to True
:type proptyping: bool, optional
:return: Server.properties dict
:rtype: Dict[str,Any]</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.get_timezone">
<span class="sig-name descname"><span class="pre">get_timezone</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.get_timezone" title="Permalink to this definition"></a></dt>
<dd><p>Parses timezone from options page</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Area/Location</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.get_world_props">
<span class="sig-name descname"><span class="pre">get_world_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">world</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'world'</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">proptyping</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.get_world_props" title="Permalink to this definition"></a></dt>
<dd><p>Parses level.dat from specified world’s options page</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>world</strong> (<em>str</em><em>, </em><em>optional</em>) – Name of the world, defaults to ‘world’</p></li>
<li><p><strong>proptyping</strong> – If the returned dict should contain the value</p></li>
</ul>
</dd>
</dl>
<p>that matches property type (e.g. randomTickSpeed will be bool)
instead of string, defaults to True
:type proptyping: bool, optional
:return: Level.dat dict
:rtype: Dict[str,Any]</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.set_java">
<span class="sig-name descname"><span class="pre">set_java</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.set_java" title="Permalink to this definition"></a></dt>
<dd><p>Sets new Java version</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>int</em>) – New Java image version</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.set_server_prop">
<span class="sig-name descname"><span class="pre">set_server_prop</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">option</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.set_server_prop" title="Permalink to this definition"></a></dt>
<dd><p>Sets server.properties option</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>option</strong> (<em>str</em>) – Option name</p></li>
<li><p><strong>value</strong> (<em>Any</em>) – New value</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.set_server_props">
<span class="sig-name descname"><span class="pre">set_server_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">props</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.set_server_props" title="Permalink to this definition"></a></dt>
<dd><p>Updates server.properties options with the given dict</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>props</strong> (<em>Dict</em><em>[</em><em>str</em><em>,</em><em>Any</em><em>]</em>) – Dict with properties <cite>{key:value}</cite></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.set_timezone">
<span class="sig-name descname"><span class="pre">set_timezone</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.set_timezone" title="Permalink to this definition"></a></dt>
<dd><p>Sets new timezone</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New timezone</p>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><strong>ValueError</strong> – If given string</p>
</dd>
</dl>
<p>doesn’t match Area/Location format</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.set_world_prop">
<span class="sig-name descname"><span class="pre">set_world_prop</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">option</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atconf.WorldOpts" title="python_aternos.atconf.WorldOpts"><span class="pre">WorldOpts</span></a><span class="p"><span class="pre">,</span></span><span class="w"> </span><a class="reference internal" href="#python_aternos.atconf.WorldRules" title="python_aternos.atconf.WorldRules"><span class="pre">WorldRules</span></a><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">gamerule</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">world</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'world'</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.set_world_prop" title="Permalink to this definition"></a></dt>
<dd><p>Sets level.dat option for specified world</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>option</strong> (<em>Union</em><em>[</em><a class="reference internal" href="#python_aternos.WorldOpts" title="python_aternos.WorldOpts"><em>WorldOpts</em></a><em>,</em><a class="reference internal" href="#python_aternos.WorldRules" title="python_aternos.WorldRules"><em>WorldRules</em></a><em>]</em>) – Option name</p></li>
<li><p><strong>value</strong> (<em>Any</em>) – New value</p></li>
<li><p><strong>gamerule</strong> – If the option</p></li>
</ul>
</dd>
</dl>
<p>is a gamerule, defaults to False
:type gamerule: bool, optional
:param world: Name of the world which
level.dat must be edited, defaults to ‘world’
:type world: str, optional</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConfig.set_world_props">
<span class="sig-name descname"><span class="pre">set_world_props</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">props</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosConfig.set_world_props" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.AternosConnect">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">AternosConnect</span></span><a class="headerlink" href="#python_aternos.AternosConnect" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for sending API requests bypass Cloudflare
and parsing responses</p>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConnect.convert_num">
<span class="sig-name descname"><span class="pre">convert_num</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">num</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">float</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">base</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">frombase</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">10</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.AternosConnect.convert_num" title="Permalink to this definition"></a></dt>
<dd><p>Converts an integer to specified base</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>num</strong> – Integer in any base to convert.</p>
</dd>
</dl>
<p>If it is a float started with <cite>0,</cite>,
zero and comma will be removed to get int
:type num: Union[int,float,str]
:param base: New base
:type base: int
:param frombase: Given number base, defaults to 10
:type frombase: int, optional
:return: Number converted to a specified base
:rtype: str</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConnect.generate_aternos_rand">
<span class="sig-name descname"><span class="pre">generate_aternos_rand</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">randlen</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">16</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.AternosConnect.generate_aternos_rand" title="Permalink to this definition"></a></dt>
<dd><p>Generates a random string using
Aternos algorithm from main.js file</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>randlen</strong> (<em>int</em><em>, </em><em>optional</em>) – Random string length, defaults to 16</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Random string for SEC token</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConnect.generate_sec">
<span class="sig-name descname"><span class="pre">generate_sec</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.AternosConnect.generate_sec" title="Permalink to this definition"></a></dt>
<dd><p>Generates Aternos SEC token which
is also needed for most API requests</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Random SEC key:value string</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConnect.parse_token">
<span class="sig-name descname"><span class="pre">parse_token</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.AternosConnect.parse_token" title="Permalink to this definition"></a></dt>
<dd><p>Parses Aternos ajax token that
is needed for most requests</p>
<dl class="field-list simple">
<dt class="field-odd">Raises<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>RuntimeWarning</strong> – If the parser</p>
</dd>
</dl>
<p>can not find &lt;head&gt; tag in HTML response
:raises CredentialsError: If the parser
is unable to extract ajax token in HTML
:return: Aternos ajax token
:rtype: str</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosConnect.request_cloudflare">
<span class="sig-name descname"><span class="pre">request_cloudflare</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">url</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">method</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">params</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">data</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">headers</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">reqcookies</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">sendtoken</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">redirect</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">retry</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">3</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Response</span></span></span><a class="headerlink" href="#python_aternos.AternosConnect.request_cloudflare" title="Permalink to this definition"></a></dt>
<dd><p>Sends a request to Aternos API bypass Cloudflare</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>url</strong> (<em>str</em>) – Request URL</p></li>
<li><p><strong>method</strong> (<em>str</em>) – Request method, must be GET or POST</p></li>
<li><p><strong>params</strong> (<em>Optional</em><em>[</em><em>dict</em><em>]</em><em>, </em><em>optional</em>) – URL parameters, defaults to None</p></li>
<li><p><strong>data</strong> – POST request data, if the method is GET,</p></li>
</ul>
</dd>
</dl>
<p>this dict will be combined with params, defaults to None
:type data: Optional[dict], optional
:param headers: Custom headers, defaults to None
:type headers: Optional[dict], optional
:param reqcookies: Cookies only for this request, defaults to None
:type reqcookies: Optional[dict], optional
:param sendtoken: If the ajax and SEC token
should be sent, defaults to False
:type sendtoken: bool, optional
:param redirect: If requests lib should follow
Location header in 3xx responses, defaults to True
:type redirect: bool, optional
:param retry: How many times parser must retry
connection to API bypass Cloudflare, defaults to 3
:type retry: int, optional
:raises CloudflareError:
When the parser has exceeded retries count
:raises NotImplementedError:
When the specified method is not GET or POST
:return: API response
:rtype: requests.Response</p>
</dd></dl>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.AternosError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">AternosError</span></span><a class="headerlink" href="#python_aternos.AternosError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Exception</span></code></p>
<p>Common error class</p>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.AternosFile">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">AternosFile</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.AternosServer" title="python_aternos.AternosServer"><span class="pre">AternosServer</span></a></span></em>, <em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">ftype</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atfile.FileType" title="python_aternos.atfile.FileType"><span class="pre">FileType</span></a></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">FileType.file</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">float</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">0</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.AternosFile" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>File class which contains info about its path, type and size</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance</p></li>
<li><p><strong>path</strong> (<em>str</em>) – Path to the file</p></li>
<li><p><strong>name</strong> (<em>str</em>) – Filename</p></li>
<li><p><strong>ftype</strong> (<a class="reference internal" href="#python_aternos.atfile.FileType" title="python_aternos.atfile.FileType"><em>python_aternos.atfile.FileType</em></a>) – File or directory</p></li>
<li><p><strong>size</strong> (<em>Union</em><em>[</em><em>int</em><em>,</em><em>float</em><em>]</em><em>, </em><em>optional</em>) – File size, defaults to 0</p></li>
</ul>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosFile.delete">
<span class="sig-name descname"><span class="pre">delete</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosFile.delete" title="Permalink to this definition"></a></dt>
<dd><p>Deletes the file</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosFile.full">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">full</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosFile.full" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosFile.get_content">
<span class="sig-name descname"><span class="pre">get_content</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">bytes</span></span></span><a class="headerlink" href="#python_aternos.AternosFile.get_content" title="Permalink to this definition"></a></dt>
<dd><p>Requests file content in bytes (downloads it)</p>
<dl class="field-list simple">
<dt class="field-odd">Raises<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.FileError" title="python_aternos.FileError"><strong>FileError</strong></a> – If downloading</p>
</dd>
</dl>
<p>the file is not allowed by Aternos
:return: File content
:rtype: bytes</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosFile.get_text">
<span class="sig-name descname"><span class="pre">get_text</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.AternosFile.get_text" title="Permalink to this definition"></a></dt>
<dd><p>Requests editing the file as a text
(try it if downloading is disallowed)</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>File text content</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosFile.is_dir">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">is_dir</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">bool</span></em><a class="headerlink" href="#python_aternos.AternosFile.is_dir" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosFile.is_file">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">is_file</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">bool</span></em><a class="headerlink" href="#python_aternos.AternosFile.is_file" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosFile.name">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">name</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosFile.name" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosFile.path">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">path</span></span><a class="headerlink" href="#python_aternos.AternosFile.path" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosFile.set_content">
<span class="sig-name descname"><span class="pre">set_content</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bytes</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosFile.set_content" title="Permalink to this definition"></a></dt>
<dd><p>Modifies the file content</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>bytes</em>) – New content</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosFile.set_text">
<span class="sig-name descname"><span class="pre">set_text</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosFile.set_text" title="Permalink to this definition"></a></dt>
<dd><p>Modifies the file content,
but unlike set_content takes
a string as a new value</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New content</p>
</dd>
</dl>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosFile.size">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">size</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">float</span></em><a class="headerlink" href="#python_aternos.AternosFile.size" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.AternosServer">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">AternosServer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">servid</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">atconn</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><span class="pre">AternosConnect</span></a></span></em>, <em class="sig-param"><span class="n"><span class="pre">reqinfo</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.AternosServer" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for controlling your Aternos Minecraft server</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>servid</strong> (<em>str</em>) – Unique server IDentifier</p></li>
<li><p><strong>atconn</strong><a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconnect.AternosConnect</span></code></a></p></li>
</ul>
</dd>
</dl>
<p>instance with initialized Aternos session
:type atconn: python_aternos.atconnect.AternosConnect
:param reqinfo: Automatically call AternosServer.fetch() to get all info, defaults to <cite>True</cite>
:type reqinfo: bool, optional</p>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.address">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">address</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosServer.address" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.atserver_request">
<span class="sig-name descname"><span class="pre">atserver_request</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">url</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">method</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">params</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">data</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">headers</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><span class="pre">dict</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">sendtoken</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Response</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.atserver_request" title="Permalink to this definition"></a></dt>
<dd><p>Sends a request to Aternos API
with server IDenitfier parameter</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>url</strong> (<em>str</em>) – Request URL</p></li>
<li><p><strong>method</strong> (<em>str</em>) – Request method, must be GET or POST</p></li>
<li><p><strong>params</strong> (<em>Optional</em><em>[</em><em>dict</em><em>]</em><em>, </em><em>optional</em>) – URL parameters, defaults to None</p></li>
<li><p><strong>data</strong> – POST request data, if the method is GET,</p></li>
</ul>
</dd>
</dl>
<p>this dict will be combined with params, defaults to None
:type data: Optional[dict], optional
:param headers: Custom headers, defaults to None
:type headers: Optional[dict], optional
:param sendtoken: If the ajax and SEC token
should be sent, defaults to False
:type sendtoken: bool, optional
:return: API response
:rtype: requests.Response</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.cancel">
<span class="sig-name descname"><span class="pre">cancel</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.cancel" title="Permalink to this definition"></a></dt>
<dd><p>Cancels server launching</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.config">
<span class="sig-name descname"><span class="pre">config</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig"><span class="pre">AternosConfig</span></a></span></span><a class="headerlink" href="#python_aternos.AternosServer.config" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconf.AternosConfig</span></code></a>
instance for editing server settings</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconf.AternosConfig</span></code></a> object</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.atconf.AternosConfig" title="python_aternos.atconf.AternosConfig">python_aternos.atconf.AternosConfig</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.confirm">
<span class="sig-name descname"><span class="pre">confirm</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.confirm" title="Permalink to this definition"></a></dt>
<dd><p>Confirms server launching</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.domain">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">domain</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosServer.domain" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.edition">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">edition</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.AternosServer.edition" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.eula">
<span class="sig-name descname"><span class="pre">eula</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.eula" title="Permalink to this definition"></a></dt>
<dd><p>Accepts the Mojang EULA</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.fetch">
<span class="sig-name descname"><span class="pre">fetch</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.fetch" title="Permalink to this definition"></a></dt>
<dd><p>Send a request to Aternos API to get all server info</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.files">
<span class="sig-name descname"><span class="pre">files</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager"><span class="pre">FileManager</span></a></span></span><a class="headerlink" href="#python_aternos.AternosServer.files" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfm.FileManager</span></code></a>
instance for file operations</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfm.FileManager</span></code></a> object</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.atfm.FileManager" title="python_aternos.atfm.FileManager">python_aternos.atfm.FileManager</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.motd">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">motd</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosServer.motd" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.players">
<span class="sig-name descname"><span class="pre">players</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">lst</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><span class="pre">Lists</span></a></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atplayers.PlayersList" title="python_aternos.atplayers.PlayersList"><span class="pre">PlayersList</span></a></span></span><a class="headerlink" href="#python_aternos.AternosServer.players" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atplayers.PlayersList" title="python_aternos.atplayers.PlayersList"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.PlayersList</span></code></a>
instance for managing operators, whitelist and banned players lists</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>lst</strong> – Players list type, must be</p>
</dd>
</dl>
<p>the <a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.Lists</span></code></a> enum value
:type lst: python_aternos.atplayers.Lists
:return: <a class="reference internal" href="#python_aternos.atplayers.PlayersList" title="python_aternos.atplayers.PlayersList"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.PlayersList</span></code></a>
:rtype: python_aternos.atplayers.PlayersList</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.players_count">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">players_count</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.AternosServer.players_count" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.players_list">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">players_list</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></em><a class="headerlink" href="#python_aternos.AternosServer.players_list" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.port">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">port</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.AternosServer.port" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.ram">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ram</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.AternosServer.ram" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.restart">
<span class="sig-name descname"><span class="pre">restart</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.restart" title="Permalink to this definition"></a></dt>
<dd><p>Restarts the server</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.slots">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">slots</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.AternosServer.slots" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.software">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">software</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosServer.software" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.start">
<span class="sig-name descname"><span class="pre">start</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">headstart</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">accepteula</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.start" title="Permalink to this definition"></a></dt>
<dd><p>Starts a server</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>headstart</strong> (<em>bool</em><em>, </em><em>optional</em>) – Start a server in the headstart mode which allows you to skip all queue, defaults to <cite>False</cite></p></li>
<li><p><strong>accepteula</strong> (<em>bool</em><em>, </em><em>optional</em>) – Automatically accept the Mojang EULA, defaults to <cite>True</cite></p></li>
</ul>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.ServerEulaError" title="python_aternos.ServerEulaError"><strong>ServerEulaError</strong></a> – When trying to start a server</p>
</dd>
</dl>
<p>without accepting the Mojang EULA
:raises ServerRunningError: When trying to start a server
which is alreday running
:raises ServerSoftwareError: When Aternos notifies about
incorrect software version
:raises ServerStorageError: When Aternos notifies about
voilation of storage limits (4 GB for now)
:raises ServerError: When API is unable to start a Minecraft server
due to unavailability of Aternos’ file servers or other problems</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.status">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">status</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosServer.status" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.status_num">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">status_num</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">int</span></em><a class="headerlink" href="#python_aternos.AternosServer.status_num" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.stop">
<span class="sig-name descname"><span class="pre">stop</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosServer.stop" title="Permalink to this definition"></a></dt>
<dd><p>Stops the server</p>
</dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.subdomain">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">subdomain</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosServer.subdomain" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py property">
<dt class="sig sig-object py" id="python_aternos.AternosServer.version">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">version</span></span><em class="property"><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="pre">str</span></em><a class="headerlink" href="#python_aternos.AternosServer.version" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosServer.wss">
<span class="sig-name descname"><span class="pre">wss</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">autoconfirm</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atwss.AternosWss" title="python_aternos.atwss.AternosWss"><span class="pre">AternosWss</span></a></span></span><a class="headerlink" href="#python_aternos.AternosServer.wss" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atwss.AternosWss" title="python_aternos.atwss.AternosWss"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atwss.AternosWss</span></code></a> instance for listening server streams in real-time</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>autoconfirm</strong> – Automatically start server status listener</p>
</dd>
</dl>
<p>when AternosWss connects to API to confirm server launching, defaults to <cite>False</cite>
:type autoconfirm: bool, optional
:return: <a class="reference internal" href="#python_aternos.atwss.AternosWss" title="python_aternos.atwss.AternosWss"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atwss.AternosWss</span></code></a> object
:rtype: python_aternos.atwss.AternosWss</p>
</dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.AternosWss">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">AternosWss</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.AternosServer" title="python_aternos.AternosServer"><span class="pre">AternosServer</span></a></span></em>, <em class="sig-param"><span class="n"><span class="pre">autoconfirm</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.AternosWss" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for managing websocket connection</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance</p></li>
<li><p><strong>autoconfirm</strong> – Automatically start server status listener</p></li>
</ul>
</dd>
</dl>
<p>when AternosWss connects to API to confirm server launching, defaults to <cite>False</cite>
:type autoconfirm: bool, optional</p>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.close">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">close</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosWss.close" title="Permalink to this definition"></a></dt>
<dd><p>Closes websocket connection and stops all listeners</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.confirm">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">confirm</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosWss.confirm" title="Permalink to this definition"></a></dt>
<dd><p>Simple way to call AternosServer.confirm from this class</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.connect">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">connect</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosWss.connect" title="Permalink to this definition"></a></dt>
<dd><p>Connect to the websocket server and start all stream listeners</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.keepalive">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">keepalive</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosWss.keepalive" title="Permalink to this definition"></a></dt>
<dd><p>Each 49 seconds sends keepalive ping to websocket server</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.receiver">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">receiver</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosWss.receiver" title="Permalink to this definition"></a></dt>
<dd><p>Receives messages from websocket servers
and calls user’s streams listeners</p>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.send">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">send</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">obj</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosWss.send" title="Permalink to this definition"></a></dt>
<dd><p>Sends a message to websocket server</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>obj</strong> (<em>Union</em><em>[</em><em>Dict</em><em>[</em><em>str</em><em>, </em><em>Any</em><em>]</em><em>,</em><em>str</em><em>]</em>) – Message, may be a string or a dict</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.wssreceiver">
<span class="sig-name descname"><span class="pre">wssreceiver</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">stream</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atwss.Streams" title="python_aternos.atwss.Streams"><span class="pre">Streams</span></a></span></em>, <em class="sig-param"><span class="o"><span class="pre">*</span></span><span class="n"><span class="pre">args</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Callable</span><span class="p"><span class="pre">[</span></span><span class="p"><span class="pre">[</span></span><span class="pre">Callable</span><span class="p"><span class="pre">[</span></span><span class="p"><span class="pre">[</span></span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Coroutine</span><span class="p"><span class="pre">[</span></span><span class="pre">Any</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">None</span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">]</span></span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.AternosWss.wssreceiver" title="Permalink to this definition"></a></dt>
<dd><p>Decorator that marks your function as a stream receiver.
When websocket receives message from the specified stream,
it calls all listeners created with this decorator.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>stream</strong> (<a class="reference internal" href="#python_aternos.atwss.Streams" title="python_aternos.atwss.Streams"><em>python_aternos.atwss.Streams</em></a>) – Stream that your function should listen</p></li>
<li><p><strong>args</strong> (<em>tuple</em><em>, </em><em>optional</em>) – Arguments which will be passed to your function</p></li>
</ul>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p><p></p>
</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>Callable[[Callable[[Any],Coroutine[Any,Any,None]]],Any]</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.AternosWss.wssworker">
<em class="property"><span class="pre">async</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">wssworker</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.AternosWss.wssworker" title="Permalink to this definition"></a></dt>
<dd><p>Starts async tasks in background
for receiving websocket messages
and sending keepalive ping</p>
</dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.Client">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">Client</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atconn</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><span class="pre">AternosConnect</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Client" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Aternos API Client class whose object contains user’s auth data</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>atconn</strong> (<a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><em>python_aternos.atconnect.AternosConnect</em></a>) – <a class="reference internal" href="#python_aternos.atconnect.AternosConnect" title="python_aternos.atconnect.AternosConnect"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atconnect.AternosConnect</span></code></a> instance with initialized Aternos session</p>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.change_email">
<span class="sig-name descname"><span class="pre">change_email</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.Client.change_email" title="Permalink to this definition"></a></dt>
<dd><p>Changes an e-mail in your Aternos account</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New e-mail</p>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><strong>ValueError</strong> – If an invalid e-mail address is passed to the function</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.change_password">
<span class="sig-name descname"><span class="pre">change_password</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">old</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">new</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.Client.change_password" title="Permalink to this definition"></a></dt>
<dd><p>Changes a password in your Aternos account</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>old</strong> (<em>str</em>) – Old password</p></li>
<li><p><strong>new</strong> (<em>str</em>) – New password</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.change_username">
<span class="sig-name descname"><span class="pre">change_username</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.Client.change_username" title="Permalink to this definition"></a></dt>
<dd><p>Changes a username in your Aternos account</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>str</em>) – New username</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.from_credentials">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">from_credentials</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">username</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">password</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Client.from_credentials" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos with a username and a plain password</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>username</strong> (<em>str</em>) – Your username</p></li>
<li><p><strong>password</strong> (<em>str</em>) – Your password without any encryption</p></li>
</ul>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Client instance</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.from_hashed">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">from_hashed</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">username</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">md5</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Client.from_hashed" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos with a username and a hashed password</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>username</strong> (<em>str</em>) – Your username</p></li>
<li><p><strong>md5</strong> (<em>str</em>) – Your password hashed with MD5</p></li>
</ul>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.CredentialsError" title="python_aternos.CredentialsError"><strong>CredentialsError</strong></a> – If the API doesn’t return a valid session cookie</p>
</dd>
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>Client instance</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.from_session">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">from_session</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">session</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Client.from_session" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos using a session cookie value</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>session</strong> (<em>str</em>) – Value of ATERNOS_SESSION cookie</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Client instance</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.get_server">
<span class="sig-name descname"><span class="pre">get_server</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">servid</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a></span></span><a class="headerlink" href="#python_aternos.Client.get_server" title="Permalink to this definition"></a></dt>
<dd><p>Creates a server object from the server ID.
Use this instead of list_servers if you know the ID to save some time.</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> object</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer">python_aternos.atserver.AternosServer</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.list_servers">
<span class="sig-name descname"><span class="pre">list_servers</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><span class="pre">AternosServer</span></a><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.Client.list_servers" title="Permalink to this definition"></a></dt>
<dd><p>Parses a list of your servers from Aternos website</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>List of <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> objects</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>list</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.md5encode">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">md5encode</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">passwd</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.Client.md5encode" title="Permalink to this definition"></a></dt>
<dd><p>Encodes the given string with MD5</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>passwd</strong> (<em>str</em>) – String to encode</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Hexdigest hash of the string in lowercase</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>str</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.restore_session">
<em class="property"><span class="pre">classmethod</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">restore_session</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">file</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'~/.aternos'</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Client.restore_session" title="Permalink to this definition"></a></dt>
<dd><p>Log in to Aternos using a saved ATERNOS_SESSION cookie</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>file</strong> (<em>str</em><em>, </em><em>optional</em>) – File where a session cookie was saved, deafults to ~/.aternos</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Client instance</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p><a class="reference internal" href="#python_aternos.Client" title="python_aternos.Client">python_aternos.Client</a></p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.Client.save_session">
<span class="sig-name descname"><span class="pre">save_session</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">file</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'~/.aternos'</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.Client.save_session" title="Permalink to this definition"></a></dt>
<dd><p>Saves an ATERNOS_SESSION cookie to a file</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>file</strong> (<em>str</em><em>, </em><em>optional</em>) – File where a session cookie must be saved, defaults to ~/.aternos</p>
</dd>
</dl>
</dd></dl>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.CloudflareError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">CloudflareError</span></span><a class="headerlink" href="#python_aternos.CloudflareError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when the parser is unable to bypass Cloudflare protection</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.CredentialsError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">CredentialsError</span></span><a class="headerlink" href="#python_aternos.CredentialsError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when a session cookie is empty which means incorrect credentials</p>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.Difficulty">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">Difficulty</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Difficulty" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>/difficulty numeric list</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Difficulty.easy">
<span class="sig-name descname"><span class="pre">easy</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.Difficulty.easy" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Difficulty.hard">
<span class="sig-name descname"><span class="pre">hard</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#python_aternos.Difficulty.hard" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Difficulty.normal">
<span class="sig-name descname"><span class="pre">normal</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#python_aternos.Difficulty.normal" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Difficulty.peaceful">
<span class="sig-name descname"><span class="pre">peaceful</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.Difficulty.peaceful" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.Edition">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">Edition</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Edition" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>Server edition type enum</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Edition.bedrock">
<span class="sig-name descname"><span class="pre">bedrock</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.Edition.bedrock" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Edition.java">
<span class="sig-name descname"><span class="pre">java</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.Edition.java" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.FileError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">FileError</span></span><a class="headerlink" href="#python_aternos.FileError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when trying to execute a disallowed by Aternos file operation</p>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.FileManager">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">FileManager</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.AternosServer" title="python_aternos.AternosServer"><span class="pre">AternosServer</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.FileManager" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Aternos file manager class for viewing files structure</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>atserv</strong> (<a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><em>python_aternos.atserver.AternosServer</em></a>) – <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance</p>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.FileManager.convert_size">
<span class="sig-name descname"><span class="pre">convert_size</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">num</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">float</span><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">measure</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">float</span></span></span><a class="headerlink" href="#python_aternos.FileManager.convert_size" title="Permalink to this definition"></a></dt>
<dd><p>Converts “human” file size to size in bytes</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>num</strong> (<em>Union</em><em>[</em><em>int</em><em>,</em><em>float</em><em>]</em>) – Size</p></li>
<li><p><strong>measure</strong> (<em>str</em>) – Units (B, kB, MB, GB)</p></li>
</ul>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Size in bytes</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>float</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.FileManager.dl_file">
<span class="sig-name descname"><span class="pre">dl_file</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">bytes</span></span></span><a class="headerlink" href="#python_aternos.FileManager.dl_file" title="Permalink to this definition"></a></dt>
<dd><p>Returns the file content in bytes (downloads it)</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – Path to file including its filename</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>File content</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bytes</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.FileManager.dl_world">
<span class="sig-name descname"><span class="pre">dl_world</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">world</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">'world'</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">bytes</span></span></span><a class="headerlink" href="#python_aternos.FileManager.dl_world" title="Permalink to this definition"></a></dt>
<dd><p>Returns the world zip file content
by its name (downloads it)</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>world</strong> (<em>str</em><em>, </em><em>optional</em>) – Name of world, defaults to ‘world’</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>Zip file content</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bytes</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.FileManager.get_file">
<span class="sig-name descname"><span class="pre">get_file</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Optional</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><span class="pre">AternosFile</span></a><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.FileManager.get_file" title="Permalink to this definition"></a></dt>
<dd><p>Returns <a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfile.AternosFile</span></code></a>
instance by its path</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – Path to file including its filename</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>_description_</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>Optional[<a class="reference internal" href="#python_aternos.AternosFile" title="python_aternos.AternosFile">AternosFile</a>]</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.FileManager.listdir">
<span class="sig-name descname"><span class="pre">listdir</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">path</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">''</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><span class="pre">AternosFile</span></a><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.FileManager.listdir" title="Permalink to this definition"></a></dt>
<dd><p>Requests a list of files
in the specified directory</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>path</strong> – Directory</p>
</dd>
</dl>
<p>(an empty string means root), defaults to ‘’
:type path: str, optional
:return: List of <a class="reference internal" href="#python_aternos.atfile.AternosFile" title="python_aternos.atfile.AternosFile"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atfile.AternosFile</span></code></a>
:rtype: List[AternosFile]</p>
</dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.FileType">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">FileType</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.FileType" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>File or dierctory</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.FileType.directory">
<span class="sig-name descname"><span class="pre">directory</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.FileType.directory" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.FileType.file">
<span class="sig-name descname"><span class="pre">file</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.FileType.file" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.Gamemode">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">Gamemode</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Gamemode" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>/gamemode numeric list</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Gamemode.adventure">
<span class="sig-name descname"><span class="pre">adventure</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#python_aternos.Gamemode.adventure" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Gamemode.creative">
<span class="sig-name descname"><span class="pre">creative</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.Gamemode.creative" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Gamemode.spectator">
<span class="sig-name descname"><span class="pre">spectator</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#python_aternos.Gamemode.spectator" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Gamemode.survival">
<span class="sig-name descname"><span class="pre">survival</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.Gamemode.survival" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.Lists">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">Lists</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Lists" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>An enumeration.</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Lists.ban">
<span class="sig-name descname"><span class="pre">ban</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'banned-players'</span></em><a class="headerlink" href="#python_aternos.Lists.ban" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Lists.ips">
<span class="sig-name descname"><span class="pre">ips</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'banned-ips'</span></em><a class="headerlink" href="#python_aternos.Lists.ips" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Lists.ops">
<span class="sig-name descname"><span class="pre">ops</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'ops'</span></em><a class="headerlink" href="#python_aternos.Lists.ops" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Lists.whl">
<span class="sig-name descname"><span class="pre">whl</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'whitelist'</span></em><a class="headerlink" href="#python_aternos.Lists.whl" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.PlayersList">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">PlayersList</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">lst</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Union</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><span class="pre">Lists</span></a><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">atserv</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#python_aternos.AternosServer" title="python_aternos.AternosServer"><span class="pre">AternosServer</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.PlayersList" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Class for managing operators, whitelist and banned players lists</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>lst</strong> – Players list type, must be</p>
</dd>
</dl>
<p><a class="reference internal" href="#python_aternos.atplayers.Lists" title="python_aternos.atplayers.Lists"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atplayers.Lists</span></code></a> enum value
:type lst: Union[str,Lists]
:param atserv: <a class="reference internal" href="#python_aternos.atserver.AternosServer" title="python_aternos.atserver.AternosServer"><code class="xref py py-class docutils literal notranslate"><span class="pre">python_aternos.atserver.AternosServer</span></code></a> instance
:type atserv: python_aternos.atserver.AternosServer</p>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.PlayersList.add">
<span class="sig-name descname"><span class="pre">add</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.PlayersList.add" title="Permalink to this definition"></a></dt>
<dd><p>Appends a player to the list by the nickname</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>name</strong> (<em>str</em>) – Player’s nickname</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.PlayersList.list_players">
<span class="sig-name descname"><span class="pre">list_players</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">cache</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#python_aternos.PlayersList.list_players" title="Permalink to this definition"></a></dt>
<dd><p>Parse a players list</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>cache</strong> (<em>bool</em><em>, </em><em>optional</em>) – If the function can return cached list (highly recommended), defaults to True</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>List of players nicknames</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>List[str]</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt class="sig sig-object py" id="python_aternos.PlayersList.remove">
<span class="sig-name descname"><span class="pre">remove</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#python_aternos.PlayersList.remove" title="Permalink to this definition"></a></dt>
<dd><p>Removes a player from the list by the nickname</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>name</strong> (<em>str</em>) – Player’s nickname</p>
</dd>
</dl>
</dd></dl>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.ServerError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">ServerError</span></span><a class="headerlink" href="#python_aternos.ServerError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Common class for server errors</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.ServerEulaError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">ServerEulaError</span></span><a class="headerlink" href="#python_aternos.ServerEulaError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when trying to start without confirming Mojang EULA</p>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.ServerOpts">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">ServerOpts</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.ServerOpts" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>server.options file</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.animals">
<span class="sig-name descname"><span class="pre">animals</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-animals'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.animals" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.cmdblock">
<span class="sig-name descname"><span class="pre">cmdblock</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'enable-command-block'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.cmdblock" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.cmds">
<span class="sig-name descname"><span class="pre">cmds</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'allow-cheats'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.cmds" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.difficulty">
<span class="sig-name descname"><span class="pre">difficulty</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'difficulty'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.difficulty" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.flight">
<span class="sig-name descname"><span class="pre">flight</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'allow-flight'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.flight" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.forcegm">
<span class="sig-name descname"><span class="pre">forcegm</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'force-gamemode'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.forcegm" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.gm">
<span class="sig-name descname"><span class="pre">gm</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'gamemode'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.gm" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.monsters">
<span class="sig-name descname"><span class="pre">monsters</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-monsters'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.monsters" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.nether">
<span class="sig-name descname"><span class="pre">nether</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'allow-nether'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.nether" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.online">
<span class="sig-name descname"><span class="pre">online</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'online-mode'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.online" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.pack">
<span class="sig-name descname"><span class="pre">pack</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'resource-pack'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.pack" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.packreq">
<span class="sig-name descname"><span class="pre">packreq</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'require-resource-pack'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.packreq" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.players">
<span class="sig-name descname"><span class="pre">players</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'max-players'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.players" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.pvp">
<span class="sig-name descname"><span class="pre">pvp</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'pvp'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.pvp" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.spawnlock">
<span class="sig-name descname"><span class="pre">spawnlock</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-protection'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.spawnlock" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.villagers">
<span class="sig-name descname"><span class="pre">villagers</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawn-npcs'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.villagers" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.ServerOpts.whl">
<span class="sig-name descname"><span class="pre">whl</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'white-list'</span></em><a class="headerlink" href="#python_aternos.ServerOpts.whl" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.ServerRunningError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">ServerRunningError</span></span><a class="headerlink" href="#python_aternos.ServerRunningError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when trying to start already running server</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.ServerSoftwareError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">ServerSoftwareError</span></span><a class="headerlink" href="#python_aternos.ServerSoftwareError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when Aternos notifies about incorrect software version</p>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.ServerStorageError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">ServerStorageError</span></span><a class="headerlink" href="#python_aternos.ServerStorageError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.ServerError" title="python_aternos.aterrors.ServerError"><code class="xref py py-class docutils literal notranslate"><span class="pre">ServerError</span></code></a></p>
<p>Raised when Aternos notifies about violation of storage limits (4 GB for now)</p>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.Status">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">Status</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Status" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">IntEnum</span></code></p>
<p>Server numeric status enum.
It is highly recommended to use
<cite>AternosServer.status</cite> instead of
<cite>AternosServer.status_num</cite></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Status.confirm">
<span class="sig-name descname"><span class="pre">confirm</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">10</span></em><a class="headerlink" href="#python_aternos.Status.confirm" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Status.error">
<span class="sig-name descname"><span class="pre">error</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">7</span></em><a class="headerlink" href="#python_aternos.Status.error" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Status.off">
<span class="sig-name descname"><span class="pre">off</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#python_aternos.Status.off" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Status.on">
<span class="sig-name descname"><span class="pre">on</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#python_aternos.Status.on" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Status.shutdown">
<span class="sig-name descname"><span class="pre">shutdown</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#python_aternos.Status.shutdown" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Status.starting">
<span class="sig-name descname"><span class="pre">starting</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#python_aternos.Status.starting" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Status.unknown">
<span class="sig-name descname"><span class="pre">unknown</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">6</span></em><a class="headerlink" href="#python_aternos.Status.unknown" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.Streams">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">Streams</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.Streams" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>WebSocket streams types</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Streams.console">
<span class="sig-name descname"><span class="pre">console</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(2,</span> <span class="pre">'console')</span></em><a class="headerlink" href="#python_aternos.Streams.console" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Streams.queue">
<span class="sig-name descname"><span class="pre">queue</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(1,</span> <span class="pre">None)</span></em><a class="headerlink" href="#python_aternos.Streams.queue" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Streams.ram">
<span class="sig-name descname"><span class="pre">ram</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(3,</span> <span class="pre">'heap')</span></em><a class="headerlink" href="#python_aternos.Streams.ram" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Streams.status">
<span class="sig-name descname"><span class="pre">status</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(0,</span> <span class="pre">None)</span></em><a class="headerlink" href="#python_aternos.Streams.status" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.Streams.tps">
<span class="sig-name descname"><span class="pre">tps</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">(4,</span> <span class="pre">'tick')</span></em><a class="headerlink" href="#python_aternos.Streams.tps" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py exception">
<dt class="sig sig-object py" id="python_aternos.TokenError">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">TokenError</span></span><a class="headerlink" href="#python_aternos.TokenError" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#python_aternos.aterrors.AternosError" title="python_aternos.aterrors.AternosError"><code class="xref py py-class docutils literal notranslate"><span class="pre">AternosError</span></code></a></p>
<p>Raised when the parser is unable to extract Aternos ajax token</p>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.WorldOpts">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">WorldOpts</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.WorldOpts" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>level.dat file</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldOpts.difficulty">
<span class="sig-name descname"><span class="pre">difficulty</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'Difficulty'</span></em><a class="headerlink" href="#python_aternos.WorldOpts.difficulty" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldOpts.hardcore">
<span class="sig-name descname"><span class="pre">hardcore</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'hardcore'</span></em><a class="headerlink" href="#python_aternos.WorldOpts.hardcore" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldOpts.seed">
<span class="sig-name descname"><span class="pre">seed</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'seed'</span></em><a class="headerlink" href="#python_aternos.WorldOpts.seed" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldOpts.seed12">
<span class="sig-name descname"><span class="pre">seed12</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'randomseed'</span></em><a class="headerlink" href="#python_aternos.WorldOpts.seed12" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py class">
<dt class="sig sig-object py" id="python_aternos.WorldRules">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">WorldRules</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#python_aternos.WorldRules" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Enum</span></code></p>
<p>/gamerule list</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.admincmdlog">
<span class="sig-name descname"><span class="pre">admincmdlog</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'logAdminCommands'</span></em><a class="headerlink" href="#python_aternos.WorldRules.admincmdlog" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.advs">
<span class="sig-name descname"><span class="pre">advs</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'announceAdvancements'</span></em><a class="headerlink" href="#python_aternos.WorldRules.advs" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.blockdrop">
<span class="sig-name descname"><span class="pre">blockdrop</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doTileDrops'</span></em><a class="headerlink" href="#python_aternos.WorldRules.blockdrop" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.cmdfb">
<span class="sig-name descname"><span class="pre">cmdfb</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'sendCommandFeedback'</span></em><a class="headerlink" href="#python_aternos.WorldRules.cmdfb" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.cmdlen">
<span class="sig-name descname"><span class="pre">cmdlen</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'maxCommandChainLength'</span></em><a class="headerlink" href="#python_aternos.WorldRules.cmdlen" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.cmdout">
<span class="sig-name descname"><span class="pre">cmdout</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'commandBlockOutput'</span></em><a class="headerlink" href="#python_aternos.WorldRules.cmdout" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.daynight">
<span class="sig-name descname"><span class="pre">daynight</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doDaylightCycle'</span></em><a class="headerlink" href="#python_aternos.WorldRules.daynight" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.deathmsg">
<span class="sig-name descname"><span class="pre">deathmsg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'showDeathMessages'</span></em><a class="headerlink" href="#python_aternos.WorldRules.deathmsg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.drowndmg">
<span class="sig-name descname"><span class="pre">drowndmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'drowningDamage'</span></em><a class="headerlink" href="#python_aternos.WorldRules.drowndmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.elytra">
<span class="sig-name descname"><span class="pre">elytra</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'disableElytraMovementCheck'</span></em><a class="headerlink" href="#python_aternos.WorldRules.elytra" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.entcram">
<span class="sig-name descname"><span class="pre">entcram</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'maxEntityCramming'</span></em><a class="headerlink" href="#python_aternos.WorldRules.entcram" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.entdrop">
<span class="sig-name descname"><span class="pre">entdrop</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doEntityDrops'</span></em><a class="headerlink" href="#python_aternos.WorldRules.entdrop" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.falldmg">
<span class="sig-name descname"><span class="pre">falldmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'fallDamage'</span></em><a class="headerlink" href="#python_aternos.WorldRules.falldmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.fire">
<span class="sig-name descname"><span class="pre">fire</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doFireTick'</span></em><a class="headerlink" href="#python_aternos.WorldRules.fire" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.firedmg">
<span class="sig-name descname"><span class="pre">firedmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'fireDamage'</span></em><a class="headerlink" href="#python_aternos.WorldRules.firedmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.forgive">
<span class="sig-name descname"><span class="pre">forgive</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'forgiveDeadPlayers'</span></em><a class="headerlink" href="#python_aternos.WorldRules.forgive" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.immrespawn">
<span class="sig-name descname"><span class="pre">immrespawn</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doImmediateRespawn'</span></em><a class="headerlink" href="#python_aternos.WorldRules.immrespawn" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.keepinv">
<span class="sig-name descname"><span class="pre">keepinv</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'keepInventory'</span></em><a class="headerlink" href="#python_aternos.WorldRules.keepinv" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.limitcraft">
<span class="sig-name descname"><span class="pre">limitcraft</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doLimitedCrafting'</span></em><a class="headerlink" href="#python_aternos.WorldRules.limitcraft" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.mobgrief">
<span class="sig-name descname"><span class="pre">mobgrief</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'mobGriefing'</span></em><a class="headerlink" href="#python_aternos.WorldRules.mobgrief" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.mobloot">
<span class="sig-name descname"><span class="pre">mobloot</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doMobLoot'</span></em><a class="headerlink" href="#python_aternos.WorldRules.mobloot" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.mobs">
<span class="sig-name descname"><span class="pre">mobs</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doMobSpawning'</span></em><a class="headerlink" href="#python_aternos.WorldRules.mobs" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.patrols">
<span class="sig-name descname"><span class="pre">patrols</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doPatrolSpawning'</span></em><a class="headerlink" href="#python_aternos.WorldRules.patrols" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.phantoms">
<span class="sig-name descname"><span class="pre">phantoms</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doInsomnia'</span></em><a class="headerlink" href="#python_aternos.WorldRules.phantoms" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.raids">
<span class="sig-name descname"><span class="pre">raids</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'disableRaids'</span></em><a class="headerlink" href="#python_aternos.WorldRules.raids" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.reducedf3">
<span class="sig-name descname"><span class="pre">reducedf3</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'reducedDebugInfo'</span></em><a class="headerlink" href="#python_aternos.WorldRules.reducedf3" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.regen">
<span class="sig-name descname"><span class="pre">regen</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'naturalRegeneration'</span></em><a class="headerlink" href="#python_aternos.WorldRules.regen" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.rndtick">
<span class="sig-name descname"><span class="pre">rndtick</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'randomTickSpeed'</span></em><a class="headerlink" href="#python_aternos.WorldRules.rndtick" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.sleeppct">
<span class="sig-name descname"><span class="pre">sleeppct</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'playersSleepingPercentage'</span></em><a class="headerlink" href="#python_aternos.WorldRules.sleeppct" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.snowdmg">
<span class="sig-name descname"><span class="pre">snowdmg</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'freezeDamage'</span></em><a class="headerlink" href="#python_aternos.WorldRules.snowdmg" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.spawnradius">
<span class="sig-name descname"><span class="pre">spawnradius</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spawnRadius'</span></em><a class="headerlink" href="#python_aternos.WorldRules.spawnradius" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.spectchunkgen">
<span class="sig-name descname"><span class="pre">spectchunkgen</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'spectatorsGenerateChunks'</span></em><a class="headerlink" href="#python_aternos.WorldRules.spectchunkgen" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.traders">
<span class="sig-name descname"><span class="pre">traders</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doTraderSpawning'</span></em><a class="headerlink" href="#python_aternos.WorldRules.traders" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.univanger">
<span class="sig-name descname"><span class="pre">univanger</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'universalAnger'</span></em><a class="headerlink" href="#python_aternos.WorldRules.univanger" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="python_aternos.WorldRules.weather">
<span class="sig-name descname"><span class="pre">weather</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'doWeatherCycle'</span></em><a class="headerlink" href="#python_aternos.WorldRules.weather" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="python_aternos.atob">
<span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">atob</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">s</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.atob" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="python_aternos.exec">
<span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">exec</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">f</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">Any</span></span></span><a class="headerlink" href="#python_aternos.exec" title="Permalink to this definition"></a></dt>
<dd><p>Executes a JavaScript function</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>f</strong> (<em>str</em>) – ECMA6 function</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>JavaScript interpreter context</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>Any</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="python_aternos.to_ecma5_function">
<span class="sig-prename descclassname"><span class="pre">python_aternos.</span></span><span class="sig-name descname"><span class="pre">to_ecma5_function</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">f</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#python_aternos.to_ecma5_function" title="Permalink to this definition"></a></dt>
<dd><p>Converts a ECMA6 function to ECMA5 format (without arrow expressions)</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>f</strong> (<em>str</em>) – ECMA6 function</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>ECMA5 function</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>str</p>
</dd>
</dl>
</dd></dl>
</section>
</section>
</div>
</div>
</div>
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
<div class="sphinxsidebarwrapper">
<h1 class="logo"><a href="index.html">python-aternos</a></h1>
<h3>Navigation</h3>
<div class="relations">
<h3>Related Topics</h3>
<ul>
<li><a href="index.html">Documentation overview</a><ul>
</ul></li>
</ul>
</div>
<div id="searchbox" style="display: none" role="search">
<h3 id="searchlabel">Quick search</h3>
<div class="searchformwrapper">
<form class="search" action="search.html" method="get">
<input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
<input type="submit" value="Go" />
</form>
</div>
</div>
<script>document.getElementById('searchbox').style.display = "block"</script>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="footer">
&copy;2022, DarkCat09.
|
Powered by <a href="http://sphinx-doc.org/">Sphinx 5.0.2</a>
&amp; <a href="https://github.com/bitprophet/alabaster">Alabaster 0.7.12</a>
|
<a href="_sources/python_aternos.rst.txt"
rel="nofollow">Page source</a>
</div>
</body>
</html>