Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > 23738ce61b8ac1e2a4c2fd7cb9473d96 > files > 15

ocaml-bitcoin-devel-1.1.1-2.mga4.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<link rel="stylesheet" href="style.css" type="text/css">
<meta content="text/html; charset=iso-8859-1" http-equiv="Content-Type">
<link rel="Start" href="index.html">
<link rel="Up" href="Bitcoin.html">
<link title="Index of types" rel=Appendix href="index_types.html">
<link title="Index of exceptions" rel=Appendix href="index_exceptions.html">
<link title="Index of values" rel=Appendix href="index_values.html">
<link title="Index of modules" rel=Appendix href="index_modules.html">
<link title="Index of module types" rel=Appendix href="index_module_types.html">
<link title="Bitcoin" rel="Chapter" href="Bitcoin.html">
<link title="Bitcoin_ocamlnet" rel="Chapter" href="Bitcoin_ocamlnet.html"><title>Bitcoin.Make</title>
</head>
<body>
<div class="navbar">&nbsp;<a class="up" href="Bitcoin.html" title="Bitcoin">Up</a>
&nbsp;</div>
<h1>Functor <a href="type_Bitcoin.Make.html">Bitcoin.Make</a></h1>

<pre><span class="keyword">module</span> Make: <div class="sig_block"><code class="code">functor (</code><code class="code">Httpclient</code><code class="code"> : </code><code class="type"><a href="Bitcoin.HTTPCLIENT.html">HTTPCLIENT</a></code><code class="code">) -&gt; </code><div class="sig_block"><code class="code">functor (</code><code class="code">Connection</code><code class="code"> : </code><code class="type"><a href="Bitcoin.CONNECTION.html">CONNECTION</a></code><code class="code">) -&gt; </code><code class="type"><a href="Bitcoin.ENGINE.html">ENGINE</a></code><code class="type">  with type 'a monad_t = 'a Httpclient.Monad.t</code></div></div></pre><div class="info module top">
Functor that takes a concrete implementation of a <a href="Bitcoin.HTTPCLIENT.html"><code class="code">Bitcoin.HTTPCLIENT</code></a> and actual
	<a href="Bitcoin.CONNECTION.html"><code class="code">Bitcoin.CONNECTION</code></a> information, and creates a module with signature <a href="Bitcoin.ENGINE.html"><code class="code">Bitcoin.ENGINE</code></a>
	offering an API for communicating with a Bitcoin client.<br>
</div>
<table border="0" cellpadding="3" width="100%">
<tr>
<td align="left" valign="top" width="1%%"><b>Parameters: </b></td>
<td>
<table class="paramstable">
<tr>
<td align="center" valign="top" width="15%">
<code>Httpclient</code></td>
<td align="center" valign="top">:</td>
<td><code class="type"><a href="Bitcoin.HTTPCLIENT.html">HTTPCLIENT</a></code>
<tr>
<td align="center" valign="top" width="15%">
<code>Connection</code></td>
<td align="center" valign="top">:</td>
<td><code class="type"><a href="Bitcoin.CONNECTION.html">CONNECTION</a></code>
</table>
</td>
</tr>
</table>
<hr width="100%">

<pre><span id="TYPEmonad_t"><span class="keyword">type</span> <code class="type">'a</code> monad_t</span> </pre>


<pre><span id="VALaddnode"><span class="keyword">val</span> addnode</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEnode_t">Bitcoin.node_t</a> -> <a href="Bitcoin.html#TYPEaddnodeop_t">Bitcoin.addnodeop_t</a> -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Allows manually adding/removing a node.<br>
</div>

<pre><span id="VALbackupwallet"><span class="keyword">val</span> backupwallet</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> string -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Safely backs up wallet file to the given destination, which can be either a directory or a path with filename.<br>
</div>

<pre><span id="VALcreatemultisig"><span class="keyword">val</span> createmultisig</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       int -><br>       <a href="Bitcoin.html#TYPEpub_t">Bitcoin.pub_t</a> list -><br>       (<a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> * <a href="Bitcoin.html#TYPEhexspk_t">Bitcoin.hexspk_t</a>) <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Creates a m-of-n multi-signature address.  An invocation of <code class="code">createmultisig num pubs</code> where <code class="code">List.length pubs &gt;= num</code>
	    returns an address that requires the private keys of at least <code class="code">num</code> members of <code class="code">pubs</code> for spending.<br>
</div>

<pre><span id="VALcreaterawtransaction"><span class="keyword">val</span> createrawtransaction</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEtxoutput_t">Bitcoin.txoutput_t</a> list -><br>       (<a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> * <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a>) list -><br>       <a href="Bitcoin.html#TYPEhextx_t">Bitcoin.hextx_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
<code class="code">createrawtransaction inputs outputs</code> creates a raw transaction that transfers the given inputs
	    (a list of transaction outputs) to the given outputs (a list of addresses and amounts).  This
	    function returns the hex-encoded transaction, but neither does it transmit the transaction to
	    the network nor does it store the transaction in the wallet.  In addition, the transaction inputs
	    are not signed, and therefore the returned raw transaction cannot be directly transmitted to the
	    network with <a href="Bitcoin.ENGINE.html#VALsendrawtransaction"><code class="code">Bitcoin.ENGINE.sendrawtransaction</code></a> without it being previosuly signed with <a href="Bitcoin.ENGINE.html#VALsignrawtransaction"><code class="code">Bitcoin.ENGINE.signrawtransaction</code></a>.
<p>

	    A transaction fee is specified implicitly by making the total output amounts be smaller than the
	    total input amounts (ie, fee = total inputs - total outputs).
<p>

	    Beware that no checks are performed concerning the validity of the transaction.  If care is not taken,
	    it is possible to create a transaction that will not be accepted by the network, either because it
	    uses invalid inputs, has a greater total amount in the outputs than in the outputs, or does not offer
	    a sufficient transaction fee.<br>
</div>

<pre><span id="VALdecoderawtransaction"><span class="keyword">val</span> decoderawtransaction</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEhextx_t">Bitcoin.hextx_t</a> -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns an object containing information concerning the given raw transaction.<br>
</div>

<pre><span id="VALdumpprivkey"><span class="keyword">val</span> dumpprivkey</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -> <a href="Bitcoin.html#TYPEpriv_t">Bitcoin.priv_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the private key corresponding to the given address.  This private key can then be imported
	    into another wallet with <a href="Bitcoin.ENGINE.html#VALimportprivkey"><code class="code">Bitcoin.ENGINE.importprivkey</code></a>.  <b>(Requires unlocked wallet)</b>.<br>
</div>

<pre><span id="VALencryptwallet"><span class="keyword">val</span> encryptwallet</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> string -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Encrypts the wallet with the given passphrase.  Note that once encrypted, a wallet cannot be unencrypted
	    (though the passphrase may be changed with <a href="Bitcoin.ENGINE.html#VALwalletpassphrasechange"><code class="code">Bitcoin.ENGINE.walletpassphrasechange</code></a>), and operations requiring an unlocked
	    wallet must be preceded by a call to <a href="Bitcoin.ENGINE.html#VALwalletpassphrase"><code class="code">Bitcoin.ENGINE.walletpassphrase</code></a>.<br>
</div>

<pre><span id="VALgetaccount"><span class="keyword">val</span> getaccount</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -> <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the account associated with the given address.<br>
</div>

<pre><span id="VALgetaccountaddress"><span class="keyword">val</span> getaccountaddress</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -> <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the receiving address currently associated with the given account.
	    Note that a new address will automatically be generated upon funds being received on this address.<br>
</div>

<pre><span id="VALgetaddednodeinfo"><span class="keyword">val</span> getaddednodeinfo</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?node:<a href="Bitcoin.html#TYPEnode_t">Bitcoin.node_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the list of nodes manually added with <a href="Bitcoin.ENGINE.html#VALaddnode"><code class="code">Bitcoin.ENGINE.addnode</code></a>.<br>
</div>

<pre><span id="VALgetaddednodeinfo_verbose"><span class="keyword">val</span> getaddednodeinfo_verbose</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?node:<a href="Bitcoin.html#TYPEnode_t">Bitcoin.node_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the list of nodes manually added with <a href="Bitcoin.ENGINE.html#VALaddnode"><code class="code">Bitcoin.ENGINE.addnode</code></a>.<br>
</div>

<pre><span id="VALgetaddressesbyaccount"><span class="keyword">val</span> getaddressesbyaccount</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -> <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Return all addresses associated with the given account.<br>
</div>

<pre><span id="VALgetbalance"><span class="keyword">val</span> getbalance</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?account:<a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -><br>       ?minconf:int -> unit -> <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
If <code class="code">account</code> is provided, returns the balance available in that account.
	    If not, returns the total balance of all accounts.<br>
</div>

<pre><span id="VALgetblock"><span class="keyword">val</span> getblock</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEblkhash_t">Bitcoin.blkhash_t</a> -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the available data for the block with the given block hash.<br>
</div>

<pre><span id="VALgetblockcount"><span class="keyword">val</span> getblockcount</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> int <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the number of blocks in the longest block chain.<br>
</div>

<pre><span id="VALgetblockhash"><span class="keyword">val</span> getblockhash</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> int -> <a href="Bitcoin.html#TYPEblkhash_t">Bitcoin.blkhash_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the block hash for the block located at the given index in the longest block chain.<br>
</div>

<pre><span id="VALgetblocktemplate"><span class="keyword">val</span> getblocktemplate</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?obj:<a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns data needed to construct a block to work on.<br>
</div>

<pre><span id="VALgetconnectioncount"><span class="keyword">val</span> getconnectioncount</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> int <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the number of connections to peer nodes.<br>
</div>

<pre><span id="VALgetdifficulty"><span class="keyword">val</span> getdifficulty</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> float <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the current difficulty (as a multiple of the minimum difficulty).<br>
</div>

<pre><span id="VALgetgenerate"><span class="keyword">val</span> getgenerate</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> bool <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Are we currently trying to generate new blocks?<br>
</div>

<pre><span id="VALgethashespersec"><span class="keyword">val</span> gethashespersec</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> int <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns number of hashes per second we currently attain when attempting block generation.
	    Note that it returns 0 if block generation is switched off.<br>
</div>

<pre><span id="VALgetinfo"><span class="keyword">val</span> getinfo</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns an object containing various state information.<br>
</div>

<pre><span id="VALgetmininginfo"><span class="keyword">val</span> getmininginfo</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns an object containing mining related information.<br>
</div>

<pre><span id="VALgetnewaddress"><span class="keyword">val</span> getnewaddress</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?account:<a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -><br>       unit -> <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a newly generated address.  If <code class="code">account</code> is specified, the returned address is
	    associated with that account.  If not, the address is associated with the default account.<br>
</div>

<pre><span id="VALgetpeerinfo"><span class="keyword">val</span> getpeerinfo</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns information about each connected peer.<br>
</div>

<pre><span id="VALgetrawmempool"><span class="keyword">val</span> getrawmempool</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns all transaction IDs currently in the memory pool.<br>
</div>

<pre><span id="VALgetrawtransaction"><span class="keyword">val</span> getrawtransaction</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> -> <a href="Bitcoin.html#TYPEhextx_t">Bitcoin.hextx_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the raw transaction corresponding to the given transaction ID.<br>
</div>

<pre><span id="VALgetrawtransaction_verbose"><span class="keyword">val</span> getrawtransaction_verbose</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns all the raw information concerning the transaction with the given ID.
	    This function returns even more information than that available with <a href="Bitcoin.ENGINE.html#VALgettransaction"><code class="code">Bitcoin.ENGINE.gettransaction</code></a>.<br>
</div>

<pre><span id="VALgetreceivedbyaccount"><span class="keyword">val</span> getreceivedbyaccount</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -> <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -> <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the total amount received on the given account.  Note that only receiving transactions
	    are considered and therefore this function does not compute the account's current balance;
	    see <a href="Bitcoin.ENGINE.html#VALgetbalance"><code class="code">Bitcoin.ENGINE.getbalance</code></a> for that purpose.<br>
</div>

<pre><span id="VALgetreceivedbyaddress"><span class="keyword">val</span> getreceivedbyaddress</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -> <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -> <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns the total amount received on this address.  Note that only receiving transactions are considered
	    and therefore this function does not compute the balance currently associated with the address.<br>
</div>

<pre><span id="VALgettransaction"><span class="keyword">val</span> gettransaction</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns an object containing various information about the given transaction.<br>
</div>

<pre><span id="VALgettxout"><span class="keyword">val</span> gettxout</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?includemempool:bool -><br>       <a href="Bitcoin.html#TYPEtxoutput_t">Bitcoin.txoutput_t</a> -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns detailed information concerning a given unspent transaction output.<br>
</div>

<pre><span id="VALgettxoutsetinfo"><span class="keyword">val</span> gettxoutsetinfo</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns some statistics about the current set of unspent transaction outputs.<br>
</div>

<pre><span id="VALgetwork_with_data"><span class="keyword">val</span> getwork_with_data</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> <a href="Bitcoin.html#TYPEhexwork_t">Bitcoin.hexwork_t</a> -> bool <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Tries to solve the given block, returning a boolean indicating success status.<br>
</div>

<pre><span id="VALgetwork_without_data"><span class="keyword">val</span> getwork_without_data</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns formatted hash data to work on.<br>
</div>

<pre><span id="VALimportprivkey"><span class="keyword">val</span> importprivkey</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?account:<a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -><br>       ?rescan:bool -> <a href="Bitcoin.html#TYPEpriv_t">Bitcoin.priv_t</a> -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Adds a private key to the wallet.  This can be an externally generated key or one previously
	    obtained with <a href="Bitcoin.ENGINE.html#VALdumpprivkey"><code class="code">Bitcoin.ENGINE.dumpprivkey</code></a>.  If <code class="code">account</code> is provided, the key is associated with that account.
	    If not, the key is associated with the default account.  The <code class="code">rescan</code> parameter indicates
	    whether the blockchain should be rescanned for transactions involving the imported key.
	    It is <code class="code">true</code> be default.  <b>(Requires unlocked wallet)</b>.<br>
</div>

<pre><span id="VALkeypoolrefill"><span class="keyword">val</span> keypoolrefill</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Refills the keypool.  <b>(Requires unlocked wallet)</b>.<br>
</div>

<pre><span id="VALlistaccounts"><span class="keyword">val</span> listaccounts</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -><br>       unit -> (<a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> * <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a>) list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a list of all accounts and associated balance.<br>
</div>

<pre><span id="VALlistaddressgroupings"><span class="keyword">val</span> listaddressgroupings</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       unit -><br>       (<a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> * <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> * <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a>) list list<br>       <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a list of the groups of addresses whose common ownership has been made
	    public by common use as inputs or as the resulting change in past transactions.<br>
</div>

<pre><span id="VALlistlockunspent"><span class="keyword">val</span> listlockunspent</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       unit -> <a href="Bitcoin.html#TYPEtxoutput_t">Bitcoin.txoutput_t</a> list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a list of temporarily unspendable transaction outputs.  These are outputs previously locked by a call
	    of <a href="Bitcoin.ENGINE.html#VALlockunspent"><code class="code">Bitcoin.ENGINE.lockunspent</code></a>, and will not be spent by the system unless explicitly used in a raw transaction.<br>
</div>

<pre><span id="VALlistreceivedbyaccount"><span class="keyword">val</span> listreceivedbyaccount</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -><br>       ?includeempty:bool -><br>       unit -><br>       (<a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> * <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> * int) list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a list of the total amount received by each account.  Each returned list element is a tuple
	    consisting of an account, the total amount received for that account, and the number of confirmations.
	    Optional parameter <code class="code">includeempty</code> indicates whether accounts with nothing received will be included
	    in the returned list (defaults to <code class="code">false</code>).<br>
</div>

<pre><span id="VALlistreceivedbyaddress"><span class="keyword">val</span> listreceivedbyaddress</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -><br>       ?includeempty:bool -><br>       unit -><br>       (<a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> * <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> * <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> * int) list<br>       <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a list of the total amount received by each address.  Each returned list element is a tuple consisting
	    of the address, the associated account, the total amount received for that address, and the number of confirmations.
	    Optional parameter <code class="code">includeempty</code> indicates whether accounts with nothing received will be included in the returned
	    list (defaults to <code class="code">false</code>).<br>
</div>

<pre><span id="VALlistsinceblock"><span class="keyword">val</span> listsinceblock</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?blockhash:<a href="Bitcoin.html#TYPEblkhash_t">Bitcoin.blkhash_t</a> -><br>       ?minconf:int -><br>       unit -> (<a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> list * <a href="Bitcoin.html#TYPEblkhash_t">Bitcoin.blkhash_t</a>) <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a pair consisting of a list of all transactions and the block hash of the latest block.
	    If provided, the <code class="code">blockhash</code> parameter limits the list of transactions to those occurring after
	    (and not including) that block.  Note that if you want to provide a value for parameter <code class="code">minconf</code>,
	    then you must also provide <code class="code">blockhash</code>.<br>
</div>

<pre><span id="VALlisttransactions"><span class="keyword">val</span> listtransactions</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?account:<a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -><br>       ?count:int -><br>       ?from:int -> unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns up to <code class="code">count</code> most recent transactions skipping the first <code class="code">from</code> transactions for <code class="code">account</code>.
	    If <code class="code">account</code> is not provided, then all recent transactions from all accounts will be returned.
	    Note that <code class="code">count</code> and <code class="code">from</code> default to 10 and 0, respectively.<br>
</div>

<pre><span id="VALlistunspent"><span class="keyword">val</span> listunspent</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -><br>       ?maxconf:int -><br>       ?addresses:<a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> list -><br>       unit -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> list <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a list of the unspent transaction outputs that have between <code class="code">minconf</code> and <code class="code">maxconf</code> confirmations
	    (these default to 1 and 999_999, respectively).  If <code class="code">addresses</code> is provided, the returned list is filtered
	    to only include transaction outputs paid to the specified addresses.<br>
</div>

<pre><span id="VALlockunspent"><span class="keyword">val</span> lockunspent</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?outputs:<a href="Bitcoin.html#TYPEtxoutput_t">Bitcoin.txoutput_t</a> list -><br>       <a href="Bitcoin.html#TYPElockop_t">Bitcoin.lockop_t</a> -> bool <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Updates the list of temporarily unspendable transaction outputs.  If the operation is <code class="code">`Lock</code>, this function
	    will lock the specified outputs, preventing them from being spent outside of a raw transaction.  If the operation
	    is <code class="code">`Unlock</code>, this function will unlock the specified previously locked outputs.  To unlock all currently locked
	    outputs, set the operation to <code class="code">`Unlock</code> and do not provide any list of outputs.  Returns a boolean indicating
	    whether the operation was successfull.<br>
</div>

<pre><span id="VALmove"><span class="keyword">val</span> move</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -><br>       ?comment:string -><br>       <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -><br>       <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -> <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> -> bool <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
<code class="code">move ?minconf ?comment from_account to_account amount</code> transfers the given amount from one account to another.
	    If provided, <code class="code">comment</code> allows you to record a comment associated with the move.  Note that this is operation
	    only rearranges the internal balances on your wallet, and is not communicated to the Bitcoin network.<br>
</div>

<pre><span id="VALsendfrom"><span class="keyword">val</span> sendfrom</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -><br>       ?comment:string -><br>       ?recipient:string -><br>       <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -><br>       <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> -> <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Transfers a given amount to the specified address, deducting the balance of the given account.
	    If successful, the function returns the ID of the transaction recording the transfer. The optional
	    parameter <code class="code">comment</code> allows you to record an arbitrary comment about this transaction, whereas the
	    also optional <code class="code">recipient</code> assigns a string identifier to the recipient address.  Note that <code class="code">sendfrom</code>
	    is only performed if the account balance is sufficient to fund the transfer.  <b>(Requires unlocked wallet)</b>.<br>
</div>

<pre><span id="VALsendmany"><span class="keyword">val</span> sendmany</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?minconf:int -><br>       ?comment:string -><br>       <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -><br>       (<a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> * <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a>) list -><br>       <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Makes multiple transfers from a given account.  Besides the source account, this function accepts as
	    parameter a list whole elements are pairs consisting of each target address and the amount to be sent.
	    If successful, the function returns the ID of the transaction recording the transfer.  The optional
	    parameter <code class="code">comment</code> allows you to record an arbitrary comment about this transaction.  Note that <code class="code">sendmany</code>
	    is only performed if the account balance is sufficient to fund the transfer.  <b>(Requires unlocked wallet)</b>.<br>
</div>

<pre><span id="VALsendrawtransaction"><span class="keyword">val</span> sendrawtransaction</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEhextx_t">Bitcoin.hextx_t</a> -> <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Transmits the given raw transaction to the network.  Note that no attempt is made
	    to verify the validity of the transaction.  Other peers may choose to drop it if invalid.<br>
</div>

<pre><span id="VALsendtoaddress"><span class="keyword">val</span> sendtoaddress</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?comment:string -><br>       ?recipient:string -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -><br>       <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> -> <a href="Bitcoin.html#TYPEtxid_t">Bitcoin.txid_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Transfers a given amount to the specified address, deducting the balance of the defaul account.
	    If successful, the function returns the ID of the transaction recording the transfer. The optional
	    parameter <code class="code">comment</code> allows you to record an arbitrary comment about this transaction, whereas
	    the also optional <code class="code">recipient</code> assigns a string identifier to the recipient address.  Note that
	    <code class="code">sendtoaddress</code> is only performed if the total balance (not the balance of the default account!)
	    is sufficient to fund the transfer.  <b>(Requires unlocked wallet)</b>.<br>
</div>

<pre><span id="VALsetaccount"><span class="keyword">val</span> setaccount</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -> <a href="Bitcoin.html#TYPEaccount_t">Bitcoin.account_t</a> -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Associates the given address with the given account.<br>
</div>

<pre><span id="VALsetgenerate"><span class="keyword">val</span> setgenerate</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?genproclimit:int -> bool -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Turns on/off the generation of new blocks (a.k.a. "mining").
	    If provided, <code class="code">genproclimit</code> limits the number of CPUs to be used for generating.<br>
</div>

<pre><span id="VALsettxfee"><span class="keyword">val</span> settxfee</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> <a href="Bitcoin.html#TYPEamount_t">Bitcoin.amount_t</a> -> bool <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Sets the transaction fee to be used in subsequent transactions.<br>
</div>

<pre><span id="VALsignmessage"><span class="keyword">val</span> signmessage</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -> string -> <a href="Bitcoin.html#TYPEsig_t">Bitcoin.sig_t</a> <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Signs the given message with the private key of the given address.  The resulting
	    signed message can be validated with <a href="Bitcoin.ENGINE.html#VALvalidateaddress"><code class="code">Bitcoin.ENGINE.validateaddress</code></a>. <b>(Requires unlocked wallet)</b>.<br>
</div>

<pre><span id="VALsignrawtransaction"><span class="keyword">val</span> signrawtransaction</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       ?parents:(<a href="Bitcoin.html#TYPEtxoutput_t">Bitcoin.txoutput_t</a> * <a href="Bitcoin.html#TYPEhexspk_t">Bitcoin.hexspk_t</a>) list -><br>       ?keys:<a href="Bitcoin.html#TYPEpriv_t">Bitcoin.priv_t</a> list -><br>       ?sighash:<a href="Bitcoin.html#TYPEsigcomp_t">Bitcoin.sigcomp_t</a> * bool -><br>       <a href="Bitcoin.html#TYPEhextx_t">Bitcoin.hextx_t</a> -> (<a href="Bitcoin.html#TYPEhextx_t">Bitcoin.hextx_t</a> * bool) <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Signs a raw transaction, returning a pair with the signed transaction in hex format and a boolean indicating
	    whether all private keys required for a successful signing have been found.  A raw transaction created with
	    <a href="Bitcoin.ENGINE.html#VALcreaterawtransaction"><code class="code">Bitcoin.ENGINE.createrawtransaction</code></a> must be signed before broadcasting to the network with <a href="Bitcoin.ENGINE.html#VALsendrawtransaction"><code class="code">Bitcoin.ENGINE.sendrawtransaction</code></a>.  The
	    optional parameters <code class="code">parents</code>, <code class="code">keys</code>, and <code class="code">sighash</code> are only required if you wish to chain transactions
	    or if the private keys required for signing do not reside in the wallet.  Note that these optional parameters
	    have the particularity that providing a value for parameter <i>n</i> requires also providing a value for <i>n-1</i>.<br>
</div>

<pre><span id="VALsubmitblock"><span class="keyword">val</span> submitblock</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> <a href="Bitcoin.html#TYPEhexblk_t">Bitcoin.hexblk_t</a> -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Attempts to submit new block to network.<br>
</div>

<pre><span id="VALvalidateaddress"><span class="keyword">val</span> validateaddress</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -> <a href="Bitcoin.html#TYPEassoc_t">Bitcoin.assoc_t</a> option <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Is the given address a valid Bitcoin address?  If so, this function returns an object
	    containing miscelaneous information about that address.  Returns <code class="code">None</code> otherwise.<br>
</div>

<pre><span id="VALverifymessage"><span class="keyword">val</span> verifymessage</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -><br>       <a href="Bitcoin.html#TYPEaddress_t">Bitcoin.address_t</a> -> <a href="Bitcoin.html#TYPEsig_t">Bitcoin.sig_t</a> -> string -> bool <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Returns a boolean indicating whether a supposedly signed message does indeed correspond
	    to a source message signed with the given address.  Use <a href="Bitcoin.ENGINE.html#VALsignmessage"><code class="code">Bitcoin.ENGINE.signmessage</code></a> for signing messages.<br>
</div>

<pre><span id="VALwalletlock"><span class="keyword">val</span> walletlock</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> unit -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
Removes the wallet decryption key from memory, thus effectively locking the wallet.  After this
	    function is invoked, you may not perform any API calls that require an unlocked wallet unless
	    you beforehand unlock the wallet again with <a href="Bitcoin.ENGINE.html#VALwalletpassphrase"><code class="code">Bitcoin.ENGINE.walletpassphrase</code></a>.  Note that this function may
	    not be called on an already locked wallet or in one which is altogether unencrypted.<br>
</div>

<pre><span id="VALwalletpassphrase"><span class="keyword">val</span> walletpassphrase</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> string -> int -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
<code class="code">walletpassphrase passphrase timeout</code> unlocks an encrypted wallet, storing the decryption key
	    in memory.  If your wallet is encrypted (see <a href="Bitcoin.ENGINE.html#VALencryptwallet"><code class="code">Bitcoin.ENGINE.encryptwallet</code></a>) then you must invoke this function
	    prior to calling any of the functions which require an unlocked wallet.  Note that the unlocking
	    expires after <code class="code">timeout</code> seconds.  Regardless of the timeout, you may at any moment lock again the
	    wallet with <a href="Bitcoin.ENGINE.html#VALwalletlock"><code class="code">Bitcoin.ENGINE.walletlock</code></a>.<br>
</div>

<pre><span id="VALwalletpassphrasechange"><span class="keyword">val</span> walletpassphrasechange</span> : <code class="type">?conn:<a href="Bitcoin.html#TYPEconn_t">Bitcoin.conn_t</a> -> string -> string -> unit <a href="Bitcoin.ENGINE.html#TYPEmonad_t">monad_t</a></code></pre><div class="info ">
<code class="code">walletpassphrasechange old_passphrase new_passphrase</code> changes the wallet passphrase from
	    <code class="code">old_passphrase</code> to <code class="code">new_passphrase</code>.  Must only be called for an encrypted wallet.<br>
</div>
</body></html>