Check if the linked address belongs to someone before trying to send micropayments

Endpoint

https://anonwallet.net/micro/api/v1/checkaddress

POST Body Parameters

ParametertypeExampleIs Required?
addressstring1BthisisandummybitcoinaddressYes
currencystringBTCNo (default is BTC)

Code Example

/**
 * Requires libcurl
 */

$curl = curl_init();

$payload = array(
  "address" => "1Bthisisandummybitcoinaddress",
  "currency" => "BTC",
);

curl_setopt_array($curl, [
  CURLOPT_HTTPHEADER => [
    "Content-Type: application/json",
    "Authorization: Bearer YOUR_API_KEY_HERE"
  ],
  CURLOPT_POSTFIELDS => json_encode($payload),
  CURLOPT_URL => "https://anonwallet.net/micro/api/v1/checkaddress",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_CUSTOMREQUEST => "POST",
]);

$response = curl_exec($curl);
$error = curl_error($curl);

curl_close($curl);

if ($error) {
  echo "cURL Error #:" . $error;
} else {
  echo $response;
}

API Response

{
    "status": 200,
    "message": "OK",
    "user_identify": "F7yOmL9XIGdU2JEV2Br6LyHpEzGCQ85uTexample"
}