Bitcoin Forum
November 16, 2024, 04:03:33 PM *
News: Check out the artwork 1Dq created to commemorate this forum's 15th anniversary
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Api blockchain  (Read 100 times)
azaarps (OP)
Copper Member
Member
**
Offline Offline

Activity: 123
Merit: 39


View Profile
May 18, 2024, 08:06:44 PM
 #1


The code does not work and Bitcoin addresses are not received. What is the solution to this problem? Can someone solve the problem for me?

/*
 * ----------------------------------------------------------------------------
 * The way to use a simple programming function  : blockchain
 * Submitted by 0x32
 * ----------------------------------------------------------------------------
 */
 
The first step is to submit an order : https://www.blockchain.com/api/request
The second step is to add this code in your design with modification to some things
 * ----------------------------------------------------------------------------*
<?php
$api_key = "api"; /your api
$xpub = "xpub"; /your xpub
$secret = "your_secret"; //this can be anything you want
$rootURL = "your site"; $orderID = uniqid();  /your web site
$callback_url = $rootURL."/callback.php?invoice=".$orderID."&secret=".$secret;
$receive_url = "https://api.blockchain.info/v2/receive?key=".$api_key."&xpub=".$xpub."&callback=".urlencode($callback_url);
$ch = curl_init();
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, true);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_URL, $receive_url);
$ccc = curl_exec($ch);
$json = json_decode($ccc, true);
$payTo = $json['address'];
echo $payTo; // The API places you where your random address will appear.
?>
 * ----------------------------------------------------------------------------*

/*
 * ----------------------------------------------------------------------------
 * The way to use a simple programming function  : blockchain
 * Submitted by 0x32
 * ----------------------------------------------------------------------------
 */
 
TryNinja
Legendary
*
Offline Offline

Activity: 3024
Merit: 7443


Top Crypto Casino


View Profile WWW
May 18, 2024, 10:49:23 PM
Last edit: May 19, 2024, 02:23:18 AM by TryNinja
 #2

Which errror/response are you getting from the API?

Where is the uniqid() function coming from? thanks PowerGlove, wasn't aware of php functions.

███████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████

███████████████████████
.
BC.GAME
▄▄▀▀▀▀▀▀▀▄▄
▄▀▀░▄██▀░▀██▄░▀▀▄
▄▀░▐▀▄░▀░░▀░░▀░▄▀▌░▀▄
▄▀▄█▐░▀▄▀▀▀▀▀▄▀░▌█▄▀▄
▄▀░▀░░█░▄███████▄░█░░▀░▀▄
█░█░▀░█████████████░▀░█░█
█░██░▀█▀▀█▄▄█▀▀█▀░██░█
█░█▀██░█▀▀██▀▀█░██▀█░█
▀▄▀██░░░▀▀▄▌▐▄▀▀░░░██▀▄▀
▀▄▀██░░▄░▀▄█▄▀░▄░░██▀▄▀
▀▄░▀█░▄▄▄░▀░▄▄▄░█▀░▄▀
▀▄▄▀▀███▄███▀▀▄▄▀
██████▄▄▄▄▄▄▄██████
.
..CASINO....SPORTS....RACING..


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
PowerGlove
Hero Member
*****
hacker
Offline Offline

Activity: 617
Merit: 5313



View Profile
May 19, 2024, 02:22:28 AM
Merited by ABCbits (3), pooya87 (2), TryNinja (2)
 #3

Where is the uniqid() function coming from?
uniqid() is part of PHP (see: Miscellaneous Functions).

BTW, I'd take a peek at this user's trust page before deciding whether or not they're worth helping.
TryNinja
Legendary
*
Offline Offline

Activity: 3024
Merit: 7443


Top Crypto Casino


View Profile WWW
May 19, 2024, 02:25:03 AM
Merited by PowerGlove (1)
 #4

BTW, I'd take a peek at this user's trust page before deciding whether or not they're worth helping.
Wait, is bud literally asking for help to create a fake-wallet phishing scam? Godammit. Tongue

Thanks for the warning (trust not showing up by default on this board etc).

███████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████

███████████████████████
.
BC.GAME
▄▄▀▀▀▀▀▀▀▄▄
▄▀▀░▄██▀░▀██▄░▀▀▄
▄▀░▐▀▄░▀░░▀░░▀░▄▀▌░▀▄
▄▀▄█▐░▀▄▀▀▀▀▀▄▀░▌█▄▀▄
▄▀░▀░░█░▄███████▄░█░░▀░▀▄
█░█░▀░█████████████░▀░█░█
█░██░▀█▀▀█▄▄█▀▀█▀░██░█
█░█▀██░█▀▀██▀▀█░██▀█░█
▀▄▀██░░░▀▀▄▌▐▄▀▀░░░██▀▄▀
▀▄▀██░░▄░▀▄█▄▀░▄░░██▀▄▀
▀▄░▀█░▄▄▄░▀░▄▄▄░█▀░▄▀
▀▄▄▀▀███▄███▀▀▄▄▀
██████▄▄▄▄▄▄▄██████
.
..CASINO....SPORTS....RACING..


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
promise444c5
Sr. Member
****
Offline Offline

Activity: 476
Merit: 299


Learning never stops!


View Profile
May 19, 2024, 07:45:42 PM
Last edit: May 21, 2024, 12:49:47 PM by promise444c5
 #5


uniqid() is part of PHP (see: Miscellaneous Functions).

I did try it on laravel also..
Although there's no toomuch difference but there was no repetition only with the second & last value...





uniqid() is a bad choice Cryptography  Tongue



██
██
██████
R


▀▀██████▄▄
████████████████
▀█████▀▀▀█████
████████▌███▐████
▄█████▄▄▄█████
████████████████
▄▄██████▀▀
LLBIT
██████
██
██
██████
██
██
██
██
██
██
██
██
██
██
██
██████
██████████████
 
 TH#1 SOLANA CASINO 
██████████████
██████
██
██
██
██
██
██
██
██
██
██
██
██████
████████████▄
▀▀██████▀▀███
██▄▄▀▀▄▄████
████████████
██████████
███▀████████
▄▄█████████
████████████
████████████
████████████
████████████
█████████████
████████████▀
████████████▄
▀▀▀▀▀▀▀██████
████████████
███████████
██▄█████████
████▄███████
████████████
█░▀▀████████
▀▀██████████
█████▄█████
████▀▄▀████
▄▄▄▄▄▄▄██████
████████████▀
[
[
5,000+
GAMES
INSTANT
WITHDRAWALS
][
][
HUGE
   REWARDS   
VIP
PROGRAM
]
]
████
██
██
██
██
██
██
██
██
██
██
██
████
████████████████████████████████████████████████
 
PLAY NOW
 

████████████████████████████████████████████████
████
██
██
██
██
██
██
██
██
██
██
██
████
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!