Mayanode API connector

Note

This package is autogenerated from OpenAPI specs.

Warning

The following documentation is autogenerated and may not look pretty. Sorry for that, we are working on it.

Health API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.health_api.HealthApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

ping(**kwargs)

ping # noqa: E501

This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.ping(async_req=True) >>> result = thread.get()

:param async_req bool :return: Ping

If the method is called asynchronously, returns the request thread.

ping_with_http_info(**kwargs)

ping # noqa: E501

This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.ping_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :return: Ping

If the method is called asynchronously, returns the request thread.

MayaNames API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.mayanames_api.MayanamesApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

mayaname(name, **kwargs)

mayaname # noqa: E501

Returns addresses registered to the provided mayaname. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mayaname(name, async_req=True) >>> result = thread.get()

:param async_req bool :param str name: the mayanode to lookup (required) :param int height: optional block height, defaults to current tip :return: list[Mayaname1]

If the method is called asynchronously, returns the request thread.

mayaname_with_http_info(name, **kwargs)

mayaname # noqa: E501

Returns addresses registered to the provided mayaname. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mayaname_with_http_info(name, async_req=True) >>> result = thread.get()

:param async_req bool :param str name: the mayanode to lookup (required) :param int height: optional block height, defaults to current tip :return: list[Mayaname1]

If the method is called asynchronously, returns the request thread.

Liquidity API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.liquidity_providers_api.LiquidityProvidersApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

liquidity_provider(asset, address, **kwargs)

liquidity_provider # noqa: E501

Returns the liquidity provider information for an address and asset. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.liquidity_provider(asset, address, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param str address: (required) :param int height: optional block height, defaults to current tip :return: LiquidityProviderSummary

If the method is called asynchronously, returns the request thread.

liquidity_provider_with_http_info(asset, address, **kwargs)

liquidity_provider # noqa: E501

Returns the liquidity provider information for an address and asset. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.liquidity_provider_with_http_info(asset, address, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param str address: (required) :param int height: optional block height, defaults to current tip :return: LiquidityProviderSummary

If the method is called asynchronously, returns the request thread.

liquidity_providers(asset, **kwargs)

liquidity_providers # noqa: E501

Returns all liquidity provider information for an asset. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.liquidity_providers(asset, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param int height: optional block height, defaults to current tip :return: list[LiquidityProviderSummary]

If the method is called asynchronously, returns the request thread.

liquidity_providers_with_http_info(asset, **kwargs)

liquidity_providers # noqa: E501

Returns all liquidity provider information for an asset. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.liquidity_providers_with_http_info(asset, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param int height: optional block height, defaults to current tip :return: list[LiquidityProviderSummary]

If the method is called asynchronously, returns the request thread.

Mimir API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.mimir_api.MimirApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

mimir(**kwargs)

mimir # noqa: E501

Returns current active mimir configuration. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MimirResponse

If the method is called asynchronously, returns the request thread.

mimir_admin(**kwargs)

mimir_admin # noqa: E501

Returns current admin mimir configuration. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_admin(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MimirResponse

If the method is called asynchronously, returns the request thread.

mimir_admin_with_http_info(**kwargs)

mimir_admin # noqa: E501

Returns current admin mimir configuration. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_admin_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MimirResponse

If the method is called asynchronously, returns the request thread.

mimir_key(key, **kwargs)

mimir_key # noqa: E501

Returns current active mimir configuration for the provided key. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_key(key, async_req=True) >>> result = thread.get()

:param async_req bool :param str key: the mimir key to lookup (required) :param int height: optional block height, defaults to current tip :return: int

If the method is called asynchronously, returns the request thread.

mimir_key_with_http_info(key, **kwargs)

mimir_key # noqa: E501

Returns current active mimir configuration for the provided key. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_key_with_http_info(key, async_req=True) >>> result = thread.get()

:param async_req bool :param str key: the mimir key to lookup (required) :param int height: optional block height, defaults to current tip :return: int

If the method is called asynchronously, returns the request thread.

mimir_node(address, **kwargs)

mimir_node # noqa: E501

Returns current node mimir configuration for the provided node address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_node(address, async_req=True) >>> result = thread.get()

:param async_req bool :param str address: (required) :param int height: optional block height, defaults to current tip :return: MimirResponse

If the method is called asynchronously, returns the request thread.

mimir_node_with_http_info(address, **kwargs)

mimir_node # noqa: E501

Returns current node mimir configuration for the provided node address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_node_with_http_info(address, async_req=True) >>> result = thread.get()

:param async_req bool :param str address: (required) :param int height: optional block height, defaults to current tip :return: MimirResponse

If the method is called asynchronously, returns the request thread.

mimir_nodes(**kwargs)

mimir_nodes # noqa: E501

Returns current node mimir votes. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_nodes(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MimirNodesResponse

If the method is called asynchronously, returns the request thread.

mimir_nodes_with_http_info(**kwargs)

mimir_nodes # noqa: E501

Returns current node mimir votes. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_nodes_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MimirNodesResponse

If the method is called asynchronously, returns the request thread.

mimir_with_http_info(**kwargs)

mimir # noqa: E501

Returns current active mimir configuration. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.mimir_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MimirResponse

If the method is called asynchronously, returns the request thread.

Network API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.network_api.NetworkApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

ban(address, **kwargs)

ban # noqa: E501

Returns the ban status for the provided node address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.ban(address, async_req=True) >>> result = thread.get()

:param async_req bool :param str address: (required) :param int height: optional block height, defaults to current tip :return: BanResponse

If the method is called asynchronously, returns the request thread.

ban_with_http_info(address, **kwargs)

ban # noqa: E501

Returns the ban status for the provided node address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.ban_with_http_info(address, async_req=True) >>> result = thread.get()

:param async_req bool :param str address: (required) :param int height: optional block height, defaults to current tip :return: BanResponse

If the method is called asynchronously, returns the request thread.

constants(**kwargs)

constants # noqa: E501

Returns constant configuration, can be overridden by mimir. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.constants(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: ConstantsResponse

If the method is called asynchronously, returns the request thread.

constants_with_http_info(**kwargs)

constants # noqa: E501

Returns constant configuration, can be overridden by mimir. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.constants_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: ConstantsResponse

If the method is called asynchronously, returns the request thread.

inbound_addresses(**kwargs)

inbound_addresses # noqa: E501

Returns the set of asgard addresses that should be used for inbound transactions. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.inbound_addresses(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[InboundAddress]

If the method is called asynchronously, returns the request thread.

inbound_addresses_with_http_info(**kwargs)

inbound_addresses # noqa: E501

Returns the set of asgard addresses that should be used for inbound transactions. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.inbound_addresses_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[InboundAddress]

If the method is called asynchronously, returns the request thread.

lastblock(**kwargs)

lastblock # noqa: E501

Returns the last block information for all chains. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.lastblock(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[LastBlock]

If the method is called asynchronously, returns the request thread.

lastblock_chain(chain, **kwargs)

lastblock_chain # noqa: E501

Returns the last block information for the provided chain. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.lastblock_chain(chain, async_req=True) >>> result = thread.get()

:param async_req bool :param str chain: (required) :param int height: optional block height, defaults to current tip :return: list[LastBlock]

If the method is called asynchronously, returns the request thread.

lastblock_chain_with_http_info(chain, **kwargs)

lastblock_chain # noqa: E501

Returns the last block information for the provided chain. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.lastblock_chain_with_http_info(chain, async_req=True) >>> result = thread.get()

:param async_req bool :param str chain: (required) :param int height: optional block height, defaults to current tip :return: list[LastBlock]

If the method is called asynchronously, returns the request thread.

lastblock_with_http_info(**kwargs)

lastblock # noqa: E501

Returns the last block information for all chains. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.lastblock_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[LastBlock]

If the method is called asynchronously, returns the request thread.

network(**kwargs)

network # noqa: E501

Returns network overview statistics. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.network(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: NetworkResponse

If the method is called asynchronously, returns the request thread.

network_with_http_info(**kwargs)

network # noqa: E501

Returns network overview statistics. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.network_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: NetworkResponse

If the method is called asynchronously, returns the request thread.

ragnarok(**kwargs)

ragnarok # noqa: E501

Returns a boolean indicating whether the chain is in ragnarok. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.ragnarok(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: bool

If the method is called asynchronously, returns the request thread.

ragnarok_with_http_info(**kwargs)

ragnarok # noqa: E501

Returns a boolean indicating whether the chain is in ragnarok. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.ragnarok_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: bool

If the method is called asynchronously, returns the request thread.

version(**kwargs)

version # noqa: E501

Returns the network’s current MAYANode version, the network’s next MAYANode version, and the querier’s MAYANode version. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.version(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: VersionResponse

If the method is called asynchronously, returns the request thread.

version_with_http_info(**kwargs)

version # noqa: E501

Returns the network’s current MAYANode version, the network’s next MAYANode version, and the querier’s MAYANode version. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.version_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: VersionResponse

If the method is called asynchronously, returns the request thread.

Node API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.nodes_api.NodesApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

node(address, **kwargs)

node # noqa: E501

Returns node information for the provided node address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.node(address, async_req=True) >>> result = thread.get()

:param async_req bool :param str address: (required) :param int height: optional block height, defaults to current tip :return: Node

If the method is called asynchronously, returns the request thread.

node_with_http_info(address, **kwargs)

node # noqa: E501

Returns node information for the provided node address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.node_with_http_info(address, async_req=True) >>> result = thread.get()

:param async_req bool :param str address: (required) :param int height: optional block height, defaults to current tip :return: Node

If the method is called asynchronously, returns the request thread.

nodes(**kwargs)

nodes # noqa: E501

Returns node information for all registered validators. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.nodes(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Node]

If the method is called asynchronously, returns the request thread.

nodes_with_http_info(**kwargs)

nodes # noqa: E501

Returns node information for all registered validators. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.nodes_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Node]

If the method is called asynchronously, returns the request thread.

POL API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.pol_api.POLApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

pol(**kwargs)

pol # noqa: E501

Returns protocol owned liquidity overview statistics. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.pol(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: POLResponse

If the method is called asynchronously, returns the request thread.

pol_with_http_info(**kwargs)

pol # noqa: E501

Returns protocol owned liquidity overview statistics. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.pol_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: POLResponse

If the method is called asynchronously, returns the request thread.

Pool API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.pools_api.PoolsApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

pool(asset, **kwargs)

pool # noqa: E501

Returns the pool information for the provided asset. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.pool(asset, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param int height: optional block height, defaults to current tip :return: Pool

If the method is called asynchronously, returns the request thread.

pool_with_http_info(asset, **kwargs)

pool # noqa: E501

Returns the pool information for the provided asset. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.pool_with_http_info(asset, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param int height: optional block height, defaults to current tip :return: Pool

If the method is called asynchronously, returns the request thread.

pools(**kwargs)

pools # noqa: E501

Returns the pool information for all assets. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.pools(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Pool]

If the method is called asynchronously, returns the request thread.

pools_with_http_info(**kwargs)

pools # noqa: E501

Returns the pool information for all assets. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.pools_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Pool]

If the method is called asynchronously, returns the request thread.

Queue API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.queue_api.QueueApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

queue(**kwargs)

queue # noqa: E501

Returns queue statistics. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: QueueResponse

If the method is called asynchronously, returns the request thread.

queue_outbound(**kwargs)

queue_outbound # noqa: E501

Returns the outbound queue including estimated CACAO values. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue_outbound(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[TxOutItem]

If the method is called asynchronously, returns the request thread.

queue_outbound_with_http_info(**kwargs)

queue_outbound # noqa: E501

Returns the outbound queue including estimated CACAO values. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue_outbound_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[TxOutItem]

If the method is called asynchronously, returns the request thread.

queue_scheduled(**kwargs)

queue_scheduled # noqa: E501

Returns the scheduled queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue_scheduled(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[TxOutItem]

If the method is called asynchronously, returns the request thread.

queue_scheduled_with_http_info(**kwargs)

queue_scheduled # noqa: E501

Returns the scheduled queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue_scheduled_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[TxOutItem]

If the method is called asynchronously, returns the request thread.

queue_swap(**kwargs)

queue_swap # noqa: E501

Returns the swap queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue_swap(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[MsgSwap]

If the method is called asynchronously, returns the request thread.

queue_swap_with_http_info(**kwargs)

queue_swap # noqa: E501

Returns the swap queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue_swap_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[MsgSwap]

If the method is called asynchronously, returns the request thread.

queue_with_http_info(**kwargs)

queue # noqa: E501

Returns queue statistics. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.queue_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: QueueResponse

If the method is called asynchronously, returns the request thread.

Quote API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.quote_api.QuoteApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

quotesaverdeposit(**kwargs)

quotesaverdeposit # noqa: E501

Provide a quote estimate for the provided saver deposit. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.quotesaverdeposit(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :param str asset: the asset to deposit :param int amount: the source asset amount in 1e8 decimals :return: QuoteSaverDepositResponse

If the method is called asynchronously, returns the request thread.

quotesaverdeposit_with_http_info(**kwargs)

quotesaverdeposit # noqa: E501

Provide a quote estimate for the provided saver deposit. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.quotesaverdeposit_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :param str asset: the asset to deposit :param int amount: the source asset amount in 1e8 decimals :return: QuoteSaverDepositResponse

If the method is called asynchronously, returns the request thread.

quotesaverwithdraw(**kwargs)

quotesaverwithdraw # noqa: E501

Provide a quote estimate for the provided saver withdraw. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.quotesaverwithdraw(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :param str asset: the asset to withdraw :param str address: the address for the position :param int withdraw_bps: the basis points of the existing position to withdraw :return: QuoteSaverWithdrawResponse

If the method is called asynchronously, returns the request thread.

quotesaverwithdraw_with_http_info(**kwargs)

quotesaverwithdraw # noqa: E501

Provide a quote estimate for the provided saver withdraw. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.quotesaverwithdraw_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :param str asset: the asset to withdraw :param str address: the address for the position :param int withdraw_bps: the basis points of the existing position to withdraw :return: QuoteSaverWithdrawResponse

If the method is called asynchronously, returns the request thread.

quoteswap(**kwargs)

quoteswap # noqa: E501

Provide a quote estimate for the provided swap. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.quoteswap(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :param str from_asset: the source asset :param str to_asset: the target asset :param int amount: the source asset amount in 1e8 decimals :param str destination: the destination address, required to generate memo :param int streaming_interval: the interval in which streaming swaps are swapped :param int streaming_quantity: the quantity of swaps within a streaming swap :param int tolerance_bps: the maximum basis points from the current feeless swap price to set the limit in the generated memo :param int affiliate_bps: the affiliate fee in basis points :param str affiliate: the affiliate (address or mayaname) :return: QuoteSwapResponse

If the method is called asynchronously, returns the request thread.

quoteswap_with_http_info(**kwargs)

quoteswap # noqa: E501

Provide a quote estimate for the provided swap. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.quoteswap_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :param str from_asset: the source asset :param str to_asset: the target asset :param int amount: the source asset amount in 1e8 decimals :param str destination: the destination address, required to generate memo :param int streaming_interval: the interval in which streaming swaps are swapped :param int streaming_quantity: the quantity of swaps within a streaming swap :param int tolerance_bps: the maximum basis points from the current feeless swap price to set the limit in the generated memo :param int affiliate_bps: the affiliate fee in basis points :param str affiliate: the affiliate (address or mayaname) :return: QuoteSwapResponse

If the method is called asynchronously, returns the request thread.

Savers API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.savers_api.SaversApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

saver(asset, address, **kwargs)

saver # noqa: E501

Returns the saver position given then savers pool and address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.saver(asset, address, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param str address: (required) :param int height: optional block height, defaults to current tip :return: Saver

If the method is called asynchronously, returns the request thread.

saver_with_http_info(asset, address, **kwargs)

saver # noqa: E501

Returns the saver position given then savers pool and address. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.saver_with_http_info(asset, address, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param str address: (required) :param int height: optional block height, defaults to current tip :return: Saver

If the method is called asynchronously, returns the request thread.

savers(asset, **kwargs)

savers # noqa: E501

Returns all savers for the savers pool. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.savers(asset, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param int height: optional block height, defaults to current tip :return: list[Saver]

If the method is called asynchronously, returns the request thread.

savers_with_http_info(asset, **kwargs)

savers # noqa: E501

Returns all savers for the savers pool. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.savers_with_http_info(asset, async_req=True) >>> result = thread.get()

:param async_req bool :param str asset: (required) :param int height: optional block height, defaults to current tip :return: list[Saver]

If the method is called asynchronously, returns the request thread.

Transaction API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.transactions_api.TransactionsApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

tx(hash, **kwargs)

tx # noqa: E501

Returns the observed transaction for a provided inbound or outbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxResponse

If the method is called asynchronously, returns the request thread.

tx_signers(hash, **kwargs)

tx_signers # noqa: E501

Returns the signers for a provided inbound or outbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_signers(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxDetailsResponse

If the method is called asynchronously, returns the request thread.

tx_signers_old(hash, **kwargs)

tx_signers_old # noqa: E501

Deprecated - migrate to /mayachain/tx/details. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_signers_old(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxSignersResponse

If the method is called asynchronously, returns the request thread.

tx_signers_old_with_http_info(hash, **kwargs)

tx_signers_old # noqa: E501

Deprecated - migrate to /mayachain/tx/details. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_signers_old_with_http_info(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxSignersResponse

If the method is called asynchronously, returns the request thread.

tx_signers_with_http_info(hash, **kwargs)

tx_signers # noqa: E501

Returns the signers for a provided inbound or outbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_signers_with_http_info(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxDetailsResponse

If the method is called asynchronously, returns the request thread.

tx_stages(hash, **kwargs)

tx_stages # noqa: E501

Returns the processing stages of a provided inbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_stages(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxStagesResponse

If the method is called asynchronously, returns the request thread.

tx_stages_with_http_info(hash, **kwargs)

tx_stages # noqa: E501

Returns the processing stages of a provided inbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_stages_with_http_info(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxStagesResponse

If the method is called asynchronously, returns the request thread.

tx_status(hash, **kwargs)

tx_status # noqa: E501

Returns the status of a provided inbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_status(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxStatusResponse

If the method is called asynchronously, returns the request thread.

tx_status_with_http_info(hash, **kwargs)

tx_status # noqa: E501

Returns the status of a provided inbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_status_with_http_info(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxStatusResponse

If the method is called asynchronously, returns the request thread.

tx_with_http_info(hash, **kwargs)

tx # noqa: E501

Returns the observed transaction for a provided inbound or outbound hash. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.tx_with_http_info(hash, async_req=True) >>> result = thread.get()

:param async_req bool :param str hash: (required) :param int height: optional block height, defaults to current tip :return: TxResponse

If the method is called asynchronously, returns the request thread.

TSS API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.tss_api.TSSApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

keygen_pubkey(height, pubkey, **kwargs)

keygen_pubkey # noqa: E501

Returns keygen information for the provided height and pubkey - the pubkey being of one of the members of a keygen block for that height # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.keygen_pubkey(height, pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param int height: (required) :param str pubkey: (required) :return: KeygenResponse

If the method is called asynchronously, returns the request thread.

keygen_pubkey_with_http_info(height, pubkey, **kwargs)

keygen_pubkey # noqa: E501

Returns keygen information for the provided height and pubkey - the pubkey being of one of the members of a keygen block for that height # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.keygen_pubkey_with_http_info(height, pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param int height: (required) :param str pubkey: (required) :return: KeygenResponse

If the method is called asynchronously, returns the request thread.

keysign(height, **kwargs)

keysign # noqa: E501

Returns keysign information for the provided height - the height being the first block a tx out item appears in the signed-but-unobserved outbound queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.keysign(height, async_req=True) >>> result = thread.get()

:param async_req bool :param int height: (required) :return: KeysignResponse

If the method is called asynchronously, returns the request thread.

keysign_pubkey(height, pubkey, **kwargs)

keysign_pubkey # noqa: E501

Returns keysign information for the provided height and pubkey - the height being the block at which a tx out item is scheduled to be signed and moved from the scheduled outbound queue to the outbound queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.keysign_pubkey(height, pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param int height: (required) :param str pubkey: (required) :return: KeysignResponse

If the method is called asynchronously, returns the request thread.

keysign_pubkey_with_http_info(height, pubkey, **kwargs)

keysign_pubkey # noqa: E501

Returns keysign information for the provided height and pubkey - the height being the block at which a tx out item is scheduled to be signed and moved from the scheduled outbound queue to the outbound queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.keysign_pubkey_with_http_info(height, pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param int height: (required) :param str pubkey: (required) :return: KeysignResponse

If the method is called asynchronously, returns the request thread.

keysign_with_http_info(height, **kwargs)

keysign # noqa: E501

Returns keysign information for the provided height - the height being the first block a tx out item appears in the signed-but-unobserved outbound queue. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.keysign_with_http_info(height, async_req=True) >>> result = thread.get()

:param async_req bool :param int height: (required) :return: KeysignResponse

If the method is called asynchronously, returns the request thread.

metrics(**kwargs)

metrics # noqa: E501

Returns keygen and keysign metrics for current vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.metrics(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MetricsResponse

If the method is called asynchronously, returns the request thread.

metrics_keygen(pubkey, **kwargs)

metrics_keygen # noqa: E501

Returns keygen metrics for the provided vault pubkey. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.metrics_keygen(pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param str pubkey: (required) :param int height: optional block height, defaults to current tip :return: list[KeygenMetric]

If the method is called asynchronously, returns the request thread.

metrics_keygen_with_http_info(pubkey, **kwargs)

metrics_keygen # noqa: E501

Returns keygen metrics for the provided vault pubkey. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.metrics_keygen_with_http_info(pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param str pubkey: (required) :param int height: optional block height, defaults to current tip :return: list[KeygenMetric]

If the method is called asynchronously, returns the request thread.

metrics_with_http_info(**kwargs)

metrics # noqa: E501

Returns keygen and keysign metrics for current vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.metrics_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: MetricsResponse

If the method is called asynchronously, returns the request thread.

Vault API

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api.vaults_api.VaultsApi(api_client=None)

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen

asgard(**kwargs)

asgard # noqa: E501

Returns current asgard vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.asgard(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Vault]

If the method is called asynchronously, returns the request thread.

asgard_with_http_info(**kwargs)

asgard # noqa: E501

Returns current asgard vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.asgard_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Vault]

If the method is called asynchronously, returns the request thread.

vault(pubkey, **kwargs)

vault # noqa: E501

Returns the vault for the provided pubkey. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.vault(pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param str pubkey: (required) :param int height: optional block height, defaults to current tip :return: Vault

If the method is called asynchronously, returns the request thread.

vault_pubkeys(**kwargs)

vault_pubkeys # noqa: E501

Returns all pubkeys for current vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.vault_pubkeys(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: VaultPubkeysResponse

If the method is called asynchronously, returns the request thread.

vault_pubkeys_with_http_info(**kwargs)

vault_pubkeys # noqa: E501

Returns all pubkeys for current vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.vault_pubkeys_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: VaultPubkeysResponse

If the method is called asynchronously, returns the request thread.

vault_with_http_info(pubkey, **kwargs)

vault # noqa: E501

Returns the vault for the provided pubkey. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.vault_with_http_info(pubkey, async_req=True) >>> result = thread.get()

:param async_req bool :param str pubkey: (required) :param int height: optional block height, defaults to current tip :return: Vault

If the method is called asynchronously, returns the request thread.

yggdrasil(**kwargs)

yggdrasil # noqa: E501

Returns current yggdrasil vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.yggdrasil(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Vault]

If the method is called asynchronously, returns the request thread.

yggdrasil_with_http_info(**kwargs)

yggdrasil # noqa: E501

Returns current yggdrasil vaults. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.yggdrasil_with_http_info(async_req=True) >>> result = thread.get()

:param async_req bool :param int height: optional block height, defaults to current tip :return: list[Vault]

If the method is called asynchronously, returns the request thread.

API Client

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.api_client.ApiClient(configuration=None, header_name=None, header_value=None, cookie=None)

Bases: object

Generic API client for Swagger client library builds.

Swagger generic API client. This client handles the client- server communication, and is invariant across implementations. Specifics of the methods and models for each application are generated from the Swagger templates.

NOTE: This class is auto generated by the swagger code generator program. Ref: https://github.com/swagger-api/swagger-codegen Do not edit the class manually.

Parameters:
  • configuration – .Configuration object for this client

  • header_name – a header to pass when making calls to the API.

  • header_value – a header value to pass when making calls to the API.

  • cookie – a cookie to include in the header when making calls to the API

NATIVE_TYPES_MAPPING = {'bool': <class 'bool'>, 'date': <class 'datetime.date'>, 'datetime': <class 'datetime.datetime'>, 'float': <class 'float'>, 'int': <class 'int'>, 'long': <class 'int'>, 'object': <class 'object'>, 'str': <class 'str'>}
PRIMITIVE_TYPES = (<class 'float'>, <class 'bool'>, <class 'bytes'>, <class 'str'>, <class 'int'>)
call_api(resource_path, method, path_params=None, query_params=None, header_params=None, body=None, post_params=None, files=None, response_type=None, auth_settings=None, async_req=None, _return_http_data_only=None, collection_formats=None, _preload_content=True, _request_timeout=None)

Makes the HTTP request (synchronous) and returns deserialized data.

To make an async request, set the async_req parameter.

Parameters:
  • resource_path – Path to method endpoint.

  • method – Method to call.

  • path_params – Path parameters in the url.

  • query_params – Query parameters in the url.

  • header_params – Header parameters to be placed in the request header.

  • body – Request body.

  • dict (files) – Request post form parameters, for application/x-www-form-urlencoded, multipart/form-data.

  • list (auth_settings) – Auth Settings names for the request.

  • response – Response data type.

  • dict – key -> filename, value -> filepath, for multipart/form-data.

  • bool (async_req) – execute request asynchronously

  • _return_http_data_only – response data without head status code and headers

  • collection_formats – dict of collection formats for path, query, header, and post parameters.

  • _preload_content – if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

If async_req parameter is True, the request will be called asynchronously. The method will return the request thread. If parameter async_req is False or missing, then the method will return the response directly.

deserialize(response, response_type)

Deserializes response into an object.

Parameters:
  • response – RESTResponse object to be deserialized.

  • response_type – class literal for deserialized object, or string of class name.

Returns:

deserialized object.

parameters_to_tuples(params, collection_formats)

Get parameters as list of tuples, formatting collections.

Parameters:
  • params – Parameters as dict or list of two-tuples

  • collection_formats (dict) – Parameter collection formats

Returns:

Parameters as list of tuples, collections formatted

prepare_post_parameters(post_params=None, files=None)

Builds form parameters.

Parameters:
  • post_params – Normal form parameters.

  • files – File parameters.

Returns:

Form parameters with files.

request(method, url, query_params=None, headers=None, post_params=None, body=None, _preload_content=True, _request_timeout=None)

Makes the HTTP request using RESTClient.

sanitize_for_serialization(obj)

Builds a JSON POST object.

If obj is None, return None. If obj is str, int, long, float, bool, return directly. If obj is datetime.datetime, datetime.date

convert to string in iso8601 format.

If obj is list, sanitize each element in the list. If obj is dict, return the dict. If obj is swagger model, return the properties dict.

Parameters:

obj – The data to serialize.

Returns:

The serialized form of data.

select_header_accept(accepts)

Returns Accept based on an array of accepts provided.

Parameters:

accepts – List of headers.

Returns:

Accept (e.g. application/json).

select_header_content_type(content_types)

Returns Content-Type based on an array of content_types provided.

Parameters:

content_types – List of content-types.

Returns:

Content-Type (e.g. application/json).

set_default_header(header_name, header_value)
update_params_for_auth(headers, querys, auth_settings)

Updates header and query params based on authentication setting.

Parameters:
  • headers – Header parameters dict to be updated.

  • querys – Query parameters tuple list to be updated.

  • auth_settings – Authentication setting identifiers list.

property user_agent

User agent for this API client

Configuration

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

class xchainpy2_mayanode.configuration.Configuration

Bases: object

NOTE: This class is auto generated by the swagger code generator program.

Ref: https://github.com/swagger-api/swagger-codegen Do not edit the class manually.

auth_settings()

Gets Auth Settings dict for api client.

Returns:

The Auth Settings information dict.

property debug

Debug status

Parameters:

value – The debug status, True or False.

Type:

bool

get_api_key_with_prefix(identifier)

Gets API key (with prefix if set).

Parameters:

identifier – The identifier of apiKey.

Returns:

The token for api key authentication.

get_basic_auth_token()

Gets HTTP basic authentication header (string).

Returns:

The token for basic HTTP authentication.

property logger_file

The logger file.

If the logger_file is None, then add stream handler and remove file handler. Otherwise, add file handler and remove stream handler.

Parameters:

value – The logger_file path.

Type:

str

property logger_format

The logger format.

The logger_formatter will be updated when sets logger_format.

Parameters:

value – The format string.

Type:

str

to_debug_report()

Gets the essential information for debugging.

Returns:

The report for debugging.

class xchainpy2_mayanode.configuration.TypeWithDefault(name, bases, dct)

Bases: type

set_default(default)

Rest API helper functions

Mayanode API

Mayanode REST API. # noqa: E501

OpenAPI spec version: 1.112.0 Contact: devs@mayachain.org Generated by: https://github.com/swagger-api/swagger-codegen.git

exception xchainpy2_mayanode.rest.ApiException(status=None, reason=None, http_resp=None)

Bases: Exception

class xchainpy2_mayanode.rest.RESTClientObject(configuration, pools_size=4, maxsize=4)

Bases: object

async DELETE(url, headers=None, query_params=None, body=None, _preload_content=True, _request_timeout=None)
async GET(url, headers=None, query_params=None, _preload_content=True, _request_timeout=None)
async HEAD(url, headers=None, query_params=None, _preload_content=True, _request_timeout=None)
async OPTIONS(url, headers=None, query_params=None, post_params=None, body=None, _preload_content=True, _request_timeout=None)
async PATCH(url, headers=None, query_params=None, post_params=None, body=None, _preload_content=True, _request_timeout=None)
async POST(url, headers=None, query_params=None, post_params=None, body=None, _preload_content=True, _request_timeout=None)
async PUT(url, headers=None, query_params=None, post_params=None, body=None, _preload_content=True, _request_timeout=None)
async request(method, url, query_params=None, headers=None, body=None, post_params=None, _preload_content=True, _request_timeout=None)

Execute request

Parameters:
  • method – http request method

  • url – http request url

  • query_params – query parameters in the url

  • headers – http request headers

  • body – request json body, for application/json

  • post_params – request post parameters, application/x-www-form-urlencoded and multipart/form-data

  • _preload_content – this is a non-applicable field for the AiohttpClient.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

class xchainpy2_mayanode.rest.RESTResponse(resp, data)

Bases: IOBase

getheader(name, default=None)

Returns a given response header.

getheaders()

Returns a CIMultiDictProxy of the response headers.