forked from 3ttercap/LocalBitcoins-API
-
Notifications
You must be signed in to change notification settings - Fork 0
/
example_wallet.php
68 lines (55 loc) · 1.68 KB
/
example_wallet.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
<?php
/* Uncomment if you wish to change default keys */
// $API_AUTH_KEY = '';
// $API_AUTH_SECRET = '';
$Lbc_Wallet = new LocalBitcoins_Wallet_API($API_AUTH_KEY,$API_AUTH_SECRET);
/** ---------------------------------------------------------------- TEST OK
/* Base: "/api/wallet/"
/* Documentation: https://localbitcoins.com/api-docs/#wallet
/* Permissions: Read
**/
/*
$res = $Lbc_Wallet->Infos();
print_r($res);
*/
/** ---------------------------------------------------------------- TEST OK
/* Base: "/api/wallet-balance/"
/* Documentation: https://localbitcoins.com/api-docs/#wallet-balance
/* Permissions: Read
**/
/*
$res = $Lbc_Wallet->Balance();
print_r($res);
*/
/** ---------------------------------------------------------------- NOT TESTED
/* Base: "/api/wallet-send/"
/* Documentation: https://localbitcoins.com/api-docs/#wallet-send
/* Permissions: Money
**/
/*
$address = '14Xmiu9V1yUMsvQ7d6NA6zEv4xyRX6u9wc';
$amount = '0.1';
$res = $Lbc_Wallet->Send($address,$amount);
print_r($res);
*/
/** ---------------------------------------------------------------- NOT TESTED
/* Base: "/api/wallet-send-pin/"
/* Documentation: https://localbitcoins.com/api-docs/#wallet-send-pin
/* Permissions: Money_pin
**/
/*
$address = '14Xmiu9V1yUMsvQ7d6NA6zEv4xyRX6u9wc';
$amount = '0.1';
$pincode = '1234';
$res = $Lbc_Wallet->SendPin($address,$amount,$pincode);
print_r($res);
*/
/** ---------------------------------------------------------------- TEST OK
/* Base: "/api/wallet-addr/"
/* Documentation: https://localbitcoins.com/api-docs/#wallet-addr
/* Permissions: Read
**/
/*
$res = $Lbc_Wallet->Addr();
print_r($res);
*/