Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Namecoin utility library
Synopsis
- data RPCRequest = RPCRequest {}
- data RPCResponse = RPCResponse {}
- data RPCError = RPCError {}
- rpcRequest :: String -> String -> [String] -> IO (Error Value)
- data Name = Name {}
- nameList :: String -> IO (Error [Name])
- nameUpdate :: String -> Name -> IO Int
- uri :: Text -> Error String
JSON-RPC client
data RPCRequest Source #
JSON-RPC 1.0 request record
Instances
data RPCResponse Source #
JSON-RPC 1.0 response record
Instances
Namecoin API error record
Instances
FromJSON RPCError Source # | |
ToJSON RPCError Source # | |
Generic RPCError Source # | |
type Rep RPCError Source # | |
Defined in Namecoin type Rep RPCError = D1 ('MetaData "RPCError" "Namecoin" "namecoin-update-0.2.3.0-inplace" 'False) (C1 ('MetaCons "RPCError" 'PrefixI 'True) (S1 ('MetaSel ('Just "code") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int) :*: S1 ('MetaSel ('Just "message") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String))) |
:: String | the URI of the JSON-RPC endpoint |
-> String | the method name |
-> [String] | the method parameters |
-> IO (Error Value) | and error or the wanted result |
Execute an RPC method
Name operations
Namecoin API Value record
Instances
FromJSON Name Source # | |
Generic Name Source # | |
Show Name Source # | |
type Rep Name Source # | |
Defined in Namecoin type Rep Name = D1 ('MetaData "Name" "Namecoin" "namecoin-update-0.2.3.0-inplace" 'False) (C1 ('MetaCons "Name" 'PrefixI 'True) (S1 ('MetaSel ('Just "name") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String) :*: (S1 ('MetaSel ('Just "value") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String) :*: S1 ('MetaSel ('Just "expires_in") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int)))) |
nameUpdate :: String -> Name -> IO Int Source #
Issue an udpate for a name (confirming its current value)