# # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # # Authors: # Caner Candan <*****@*****.**>, http://caner.candan.fr # from duniterpy.api.bma import API, logging logger = logging.getLogger("duniter/ud") class Ud(API): def __init__(self, conn_handler, module='ud'): super(Ud, self).__init__(conn_handler, module) class History(Ud): """Get UD history.""" def __init__(self, conn_handler, pubkey, module='ud'): super(Ud, self).__init__(conn_handler, module) self.pubkey = pubkey async def __get__(self, session, **kwargs): assert self.pubkey is not None
# # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # # Authors: # Caner Candan <*****@*****.**>, http://caner.candan.fr # from duniterpy.api.bma import API, logging, parse_response logger = logging.getLogger("duniter/node") URL_PATH = 'node' async def summary(connection): """ GET Certification data over a member :param duniterpy.api.bma.ConnectionHandler connection: Connection handler instance :rtype: dict """ schema = { "type": "object", "properties": { "duniter": {
# # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # # Authors: # Caner Candan <*****@*****.**>, http://caner.candan.fr # from duniterpy.api.bma import API, logging, parse_response logger = logging.getLogger("duniter/network") URL_PATH = 'network' PEERING_SCHEMA = { "type": "object", "properties": { "version": { "type": ["number", "string"] }, "currency": { "type": "string" }, "pubkey": { "type": "string" },
# # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # # Authors: # Caner Candan <*****@*****.**>, http://caner.candan.fr # from duniterpy.api.bma import API, logging, parse_response logger = logging.getLogger("duniter/blockchain") URL_PATH = 'blockchain' BLOCK_SCHEMA = { "type": "object", "properties": { "version": { "type": "number" }, "currency": { "type": "string" }, "nonce": { "type": "number"
# (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # # Authors: # Caner Candan <*****@*****.**>, http://caner.candan.fr # from duniterpy.api.bma import API, logging, parse_response logger = logging.getLogger("duniter/wot") URL_PATH = 'wot' CERTIFICATIONS_SCHEMA = { "type": "object", "properties": { "pubkey": { "type": "string" }, "uid": { "type": "string" }, "isMember": { "type": "boolean" },
# # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # # Authors: # Caner Candan <*****@*****.**>, http://caner.candan.fr # from duniterpy.api.bma import API, logging, parse_response logger = logging.getLogger("duniter/tx") URL_PATH = 'tx' HISTORY_SCHEMA = { "type": "object", "properties": { "currency": { "type": "string" }, "pubkey": { "type": "string" }, "history": { "type": "object", "properties": {