pylons_sdk library

Library providing tools for writing client applications that interact with the Pylons blockchain through an IPC connection with a wallet app in Flutter.

Classes

CoinOutput
Thin wrapper for a possible coin output.
Cookbook
Wrapper object for a cookbook. Exactly one cookbook must be loaded at any one time; this will be used for all recipe, item, etc. queries and operations. Use Cookbook.load() to load the cookbook while your app is setting things up, and then use Cookbook.current when you need to retrieve that.
DecString
Very rough compatibility functions for Cosmos' decimal types.
DoubleInput
Thin wrapper for a double parameter input pattern. Describes the potential values for a parameter on an item input.
DoubleOutput
Thin wrapper for a double parameter output definition. Describes the potential values for a parameter on an item output.
DoubleWeightRange
Thin wrapper for a weighted range that the value of a double parameter could take.
Execution
Wrapper object for a recipe execution. The underlying functionality this object wraps is not currently operational, so it's just a stub object.
Item
Wrapper object for an item. These can be retrieved from a number of queries and operations, and are considered either 'complete' or 'partial.' Certain data is not available from partial items, and if those fields are needed, you have to call Item.get() with the ID from the partial item.
ItemInput
Thin wrapper for an item input pattern.
ItemOutput
Thin wrapper for a possible item output.
LongInput
Thin wrapper for an Int64 parameter input pattern. Describes the potential values for a parameter on an item input.
LongOutput
Thin wrapper for an Int64 parameter output definition. Describes the potential values for a parameter on an item output.
LongWeightRange
Thin wrapper for a weighted range that the value of a double parameter could take.
OutputSet
Thin wrapper for the total output set of a recipe. This is kinda complex - it contains both entries, which describe the possible actual item/coin outputs of the recipe, and weighted output lists, which describe the probabilities of those outputs being generated.
Profile
Wrapper object for the user's profile and associated state.
PylonsWallet
The PylonsWallet class is the main endpoint developers use for structured, high-level interactions with the Pylons wallet.
Recipe
Wrapper object for a recipe. These can be retrieved from a number of queries and operations, or created using an id alone. In the latter case, the recipe is considered partial, and does not support any operations other than executing it.
StringInput
Thin wrapper for a string parameter input pattern. Describes the potential values for a parameter on an item input.
StringOutput
Thin wrapper for a string parameter output definition. Describes the potential values for a parameter on an item output.
WeightedOutput
Thin wrapper for an output list for a recipe. This is a structure used to produce probabilistic outputs for recipes.

Enums

PylonsMode

Exceptions / Errors

AddressFormatException
Parent class for exceptions thrown during address encoding and decoding. An exception of type AddressFormatException should never be thrown; throw one of the child types instead.
AddressFormatExceptionBitConvertFail
Exception thrown by Bech32Cosmos when convertBits fails
AddressFormatExceptionChecksumFail
Exception thrown by Bech32Cosmos when trying to decode an address with a bad checksum
AddressFormatExceptionDataLength
Exception thrown by Bech32Cosmos when trying to decode an address with a data part of incorrect length
AddressFormatExceptionHrpLength
Exception thrown by Bech32Cosmos when trying to encode an address with a bad human-readable part
AddressFormatExceptionInputLength
Exception thrown by Bech32Cosmos when trying to decode an address of incorrect length
AddressFormatExceptionInvalidCharacter
Exception thrown by Bech32Cosmos when trying to decode an address containing an invalid character
AddressFormatExceptionNoHrp
Exception thrown by Bech32Cosmos when trying to decode an address with no human-readable part
CookbookAlreadyExistsException
Exception thrown by TX-emitting API calls when a cookbook already exists on chain while we're trying to create it.
CookbookDoesNotExistException
Exception thrown by TX-emitting API calls when a cookbook does not exist on the chain.
CookbookNotOwnedException
Exception thrown by TX-emitting API calls when a cookbook cannot be modified or a recipe cannot be created by the active profile because the cookbook is owned by a different one.
ItemDoesNotExistException
Exception thrown by TX-emitting API calls when an item to be used in executing a recipe or creating a trade does not exist.
ItemNotOwnedException
Exception thrown by TX-emitting API calls when an item to be used in executing a recipe or creating a trade is not owned by the active profile.
NodeInternalErrorException
Exception thrown by TX-emitting API calls when the Pylons node has an internal error during processing of the emitted TX. If this occurs in production environments, that's a problem.
NotAnAddressException
Exception thrown by API calls that accept an address as an argument when the supplied argument is not a valid address.
NoWalletException
Exception thrown by API calls when the wallet doesn't exist.
PaymentNotValidException
Exception thrown by TX-emitting API calls when a provided payment ID does not exist or is not correct for the purchase being made.
ProfileDoesNotExistException
Exception thrown by API calls when a profile does not exist on the chain.
ProfileStateException
Exception thrown by TX-emitting API calls when a profile is not in a valid state for the execution of a recipe.
RecipeAlreadyExistsException
Exception thrown by TX-emitting API calls when a recipe already exists on chain at the coordinates one is trying to be created at.
RecipeDoesNotExistException
Exception thrown by TX-emitting API calls when a recipe does not exist on the chain.
RecipeNotOwnedException
Exception thrown by TX-emitting API calls when a recipe cannot be modified by the active profile because it's owned by a different one.
RecipeStateException
Exception thrown by TX-emitting API calls when a recipe is not in a valid state for the operation that the transaction attempted to perform.
RecipeValidationException
Exception thrown by TX-emitting API calls when a recipe fails the sanity check performed before the transaction is generated.
ResponseException
Exception thrown when an outgoing message gets an illegal response. This should not be seen in production environments.
UnhandledErrorException
Exception thrown by API calls when they get an error they aren't prepared for. This should absolutely, 100 percent never be seen in production environments.
WalletInitializationAlreadyDoneException
Exception thrown when the user tries to setup the wallet again
WalletInitializationNotDone
Exception thrown when the user tries to setup the wallet again