3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Bitfinex { private $api_key; private $api_secret; private $api_version; private $base_url = 'https://api.bitfinex.com'; public function __construct($api_key, $api_secret, $api_version = 'v1') { $this->api_key = $api_key; $this->api_secret = $api_secret; $this->api_version = $api_version; } public function new_offer($currency, $amount, $rate, $period, $direction = "lend") { $request = '/' . $this->api_version . '/offer/new'; $data = array( 'request' => $request, 'currency' => $currency, 'amount' => $amount, 'rate' => $rate, 'period' => $period, 'direction' => $direction ); return $this->send_signed_request($data); } public function cancel_offer($offer_id) { $request = '/' . $this->api_version . '/offer/cancel'; $data = array( 'request' => $request, 'offer_id' => $offer_id ); return $this->send_signed_request($data); } public function get_offer($offer_id) { $request = '/' . $this->api_version . '/offer/status'; $data = array( 'request' => $request, 'offer_id' => $offer_id ); return $this->send_signed_request($data); } public function get_trades() { $request = '/' . $this->api_version . '/trades/btcusd'; $data = array( 'request' => $request, 'options' => array() ); return $this->send_signed_request($data); } public function get_offers() { $request = '/' . $this->api_version . '/offers'; $data = array( 'request' => $request, 'options' => array() ); return $this->send_signed_request($data); } public function get_credits() { $request = '/' . $this->api_version . '/credits'; $data = array( 'request' => $request, 'options' => array() ); return $this->send_signed_request($data); } public function get_balances() { $request = '/' . $this->api_version . '/balances'; echo $request; $data = array( 'request' => $request, 'options' => array() ); return $this->send_signed_request($data); } public function get_history($currency, $limit = 1, $wallet = 'trading') { $request = '/' . $this->api_version . '/history'; $data = array( 'request' => $request, 'currency' => $currency, 'limit' => $limit, 'wallet' => $wallet ); return $this->send_signed_request($data); } public function get_lendbook($symbol = "usd") { $request = '/v1/lendbook/' . $symbol; return $this->send_unsigned_request($request); } public function get_lends($symbol = "usd") { $request = '/v1/lends/' . $symbol; return $this->send_unsigned_request($request); } public function get_ticker($symbol = "btcusd") { $request = '/' . $this->api_version . '/ticker/' . $symbol; return $this->send_unsigned_request($request); } private function prepare_header($data) { $data['nonce'] = 144800329405116; //(string) number_format(round(microtime(true) * 100000),0,'.',''); echo $data; echo "Json encode <br/> "; echo json_encode($data); echo "<br/>"; $payload = base64_encode(json_encode($data)); $signature = hash_hmac('sha384', $payload, $this->api_secret); echo "payload"; echo $payload; return array( 'X-BFX-APIKEY: ' . $this->api_key, 'X-BFX-PAYLOAD: ' . $payload, 'X-BFX-SIGNATURE: ' . $signature ); } private function send_signed_request($data) { $ch = curl_init(); $url = $this->base_url . $data['request']; echo $url; $headers = $this->prepare_header($data); curl_setopt_array($ch, array( CURLOPT_URL => $url, CURLOPT_POST => true, CURLOPT_RETURNTRANSFER => true, CURLOPT_HTTPHEADER => $headers, CURLOPT_SSL_VERIFYPEER => false, CURLOPT_POSTFIELDS => "" )); // echo $result; if( !$result = curl_exec($ch) ) { echo "NO <br/>"; return false; } else { echo "YES <br/>"; return json_decode($result, true); } } private function send_unsigned_request($request) { $ch = curl_init(); $url = $this->base_url . $request; curl_setopt_array($ch, array( CURLOPT_URL => $url, CURLOPT_RETURNTRANSFER => true, CURLOPT_SSL_VERIFYPEER => false )); if( !$result = curl_exec($ch) ) { echo "NO <br/>"; return false; } else { echo "YES <br/>"; echo $result; echo "<br/>"; return json_decode($result, true); } } } $la = new Bitfinex('1', '1', '1'); $drek = $la->get_balances(); echo '<br/>'; echo 'Recived data'; echo $drek; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  (null)
number of ops:  13
compiled vars:  !0 = $la, !1 = $drek
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  223     0  E >   NEW                                              $2      'Bitfinex'
          1        SEND_VAL_EX                                              '1'
          2        SEND_VAL_EX                                              '1'
          3        SEND_VAL_EX                                              '1'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !0, $2
  225     6        INIT_METHOD_CALL                                         !0, 'get_balances'
          7        DO_FCALL                                      0  $5      
          8        ASSIGN                                                   !1, $5
  226     9        ECHO                                                     '%3Cbr%2F%3E'
  227    10        ECHO                                                     'Recived+data'
  228    11        ECHO                                                     !1
  229    12      > RETURN                                                   1

Class Bitfinex:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  __construct
number of ops:  10
compiled vars:  !0 = $api_key, !1 = $api_secret, !2 = $api_version
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV_INIT                                        !2      'v1'
   10     3        ASSIGN_OBJ                                               'api_key'
          4        OP_DATA                                                  !0
   11     5        ASSIGN_OBJ                                               'api_secret'
          6        OP_DATA                                                  !1
   12     7        ASSIGN_OBJ                                               'api_version'
          8        OP_DATA                                                  !2
   13     9      > RETURN                                                   null

End of function __construct

Function new_offer:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  new_offer
number of ops:  21
compiled vars:  !0 = $currency, !1 = $amount, !2 = $rate, !3 = $period, !4 = $direction, !5 = $request, !6 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
          3        RECV                                             !3      
          4        RECV_INIT                                        !4      'lend'
   17     5        FETCH_OBJ_R                                      ~7      'api_version'
          6        CONCAT                                           ~8      '%2F', ~7
          7        CONCAT                                           ~9      ~8, '%2Foffer%2Fnew'
          8        ASSIGN                                                   !5, ~9
   20     9        INIT_ARRAY                                       ~11     !5, 'request'
   21    10        ADD_ARRAY_ELEMENT                                ~11     !0, 'currency'
   22    11        ADD_ARRAY_ELEMENT                                ~11     !1, 'amount'
   23    12        ADD_ARRAY_ELEMENT                                ~11     !2, 'rate'
   24    13        ADD_ARRAY_ELEMENT                                ~11     !3, 'period'
   25    14        ADD_ARRAY_ELEMENT                                ~11     !4, 'direction'
   19    15        ASSIGN                                                   !6, ~11
   27    16        INIT_METHOD_CALL                                         'send_signed_request'
         17        SEND_VAR_EX                                              !6
         18        DO_FCALL                                      0  $13     
         19      > RETURN                                                   $13
   29    20*     > RETURN                                                   null

End of function new_offer

Function cancel_offer:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  cancel_offer
number of ops:  13
compiled vars:  !0 = $offer_id, !1 = $request, !2 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   31     0  E >   RECV                                             !0      
   33     1        FETCH_OBJ_R                                      ~3      'api_version'
          2        CONCAT                                           ~4      '%2F', ~3
          3        CONCAT                                           ~5      ~4, '%2Foffer%2Fcancel'
          4        ASSIGN                                                   !1, ~5
   36     5        INIT_ARRAY                                       ~7      !1, 'request'
   37     6        ADD_ARRAY_ELEMENT                                ~7      !0, 'offer_id'
   35     7        ASSIGN                                                   !2, ~7
   40     8        INIT_METHOD_CALL                                         'send_signed_request'
          9        SEND_VAR_EX                                              !2
         10        DO_FCALL                                      0  $9      
         11      > RETURN                                                   $9
   41    12*     > RETURN                                                   null

End of function cancel_offer

Function get_offer:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_offer
number of ops:  13
compiled vars:  !0 = $offer_id, !1 = $request, !2 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   43     0  E >   RECV                                             !0      
   45     1        FETCH_OBJ_R                                      ~3      'api_version'
          2        CONCAT                                           ~4      '%2F', ~3
          3        CONCAT                                           ~5      ~4, '%2Foffer%2Fstatus'
          4        ASSIGN                                                   !1, ~5
   48     5        INIT_ARRAY                                       ~7      !1, 'request'
   49     6        ADD_ARRAY_ELEMENT                                ~7      !0, 'offer_id'
   47     7        ASSIGN                                                   !2, ~7
   52     8        INIT_METHOD_CALL                                         'send_signed_request'
          9        SEND_VAR_EX                                              !2
         10        DO_FCALL                                      0  $9      
         11      > RETURN                                                   $9
   53    12*     > RETURN                                                   null

End of function get_offer

Function get_trades:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_trades
number of ops:  12
compiled vars:  !0 = $request, !1 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   57     0  E >   FETCH_OBJ_R                                      ~2      'api_version'
          1        CONCAT                                           ~3      '%2F', ~2
          2        CONCAT                                           ~4      ~3, '%2Ftrades%2Fbtcusd'
          3        ASSIGN                                                   !0, ~4
   60     4        INIT_ARRAY                                       ~6      !0, 'request'
          5        ADD_ARRAY_ELEMENT                                ~6      <array>, 'options'
   59     6        ASSIGN                                                   !1, ~6
   64     7        INIT_METHOD_CALL                                         'send_signed_request'
          8        SEND_VAR_EX                                              !1
          9        DO_FCALL                                      0  $8      
         10      > RETURN                                                   $8
   65    11*     > RETURN                                                   null

End of function get_trades

Function get_offers:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_offers
number of ops:  12
compiled vars:  !0 = $request, !1 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   69     0  E >   FETCH_OBJ_R                                      ~2      'api_version'
          1        CONCAT                                           ~3      '%2F', ~2
          2        CONCAT                                           ~4      ~3, '%2Foffers'
          3        ASSIGN                                                   !0, ~4
   72     4        INIT_ARRAY                                       ~6      !0, 'request'
          5        ADD_ARRAY_ELEMENT                                ~6      <array>, 'options'
   71     6        ASSIGN                                                   !1, ~6
   76     7        INIT_METHOD_CALL                                         'send_signed_request'
          8        SEND_VAR_EX                                              !1
          9        DO_FCALL                                      0  $8      
         10      > RETURN                                                   $8
   77    11*     > RETURN                                                   null

End of function get_offers

Function get_credits:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_credits
number of ops:  12
compiled vars:  !0 = $request, !1 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   81     0  E >   FETCH_OBJ_R                                      ~2      'api_version'
          1        CONCAT                                           ~3      '%2F', ~2
          2        CONCAT                                           ~4      ~3, '%2Fcredits'
          3        ASSIGN                                                   !0, ~4
   84     4        INIT_ARRAY                                       ~6      !0, 'request'
          5        ADD_ARRAY_ELEMENT                                ~6      <array>, 'options'
   83     6        ASSIGN                                                   !1, ~6
   88     7        INIT_METHOD_CALL                                         'send_signed_request'
          8        SEND_VAR_EX                                              !1
          9        DO_FCALL                                      0  $8      
         10      > RETURN                                                   $8
   89    11*     > RETURN                                                   null

End of function get_credits

Function get_balances:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_balances
number of ops:  13
compiled vars:  !0 = $request, !1 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   93     0  E >   FETCH_OBJ_R                                      ~2      'api_version'
          1        CONCAT                                           ~3      '%2F', ~2
          2        CONCAT                                           ~4      ~3, '%2Fbalances'
          3        ASSIGN                                                   !0, ~4
   95     4        ECHO                                                     !0
   98     5        INIT_ARRAY                                       ~6      !0, 'request'
          6        ADD_ARRAY_ELEMENT                                ~6      <array>, 'options'
   97     7        ASSIGN                                                   !1, ~6
  102     8        INIT_METHOD_CALL                                         'send_signed_request'
          9        SEND_VAR_EX                                              !1
         10        DO_FCALL                                      0  $8      
         11      > RETURN                                                   $8
  103    12*     > RETURN                                                   null

End of function get_balances

Function get_history:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_history
number of ops:  17
compiled vars:  !0 = $currency, !1 = $limit, !2 = $wallet, !3 = $request, !4 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  105     0  E >   RECV                                             !0      
          1        RECV_INIT                                        !1      1
          2        RECV_INIT                                        !2      'trading'
  107     3        FETCH_OBJ_R                                      ~5      'api_version'
          4        CONCAT                                           ~6      '%2F', ~5
          5        CONCAT                                           ~7      ~6, '%2Fhistory'
          6        ASSIGN                                                   !3, ~7
  110     7        INIT_ARRAY                                       ~9      !3, 'request'
  111     8        ADD_ARRAY_ELEMENT                                ~9      !0, 'currency'
  112     9        ADD_ARRAY_ELEMENT                                ~9      !1, 'limit'
  113    10        ADD_ARRAY_ELEMENT                                ~9      !2, 'wallet'
  109    11        ASSIGN                                                   !4, ~9
  116    12        INIT_METHOD_CALL                                         'send_signed_request'
         13        SEND_VAR_EX                                              !4
         14        DO_FCALL                                      0  $11     
         15      > RETURN                                                   $11
  117    16*     > RETURN                                                   null

End of function get_history

Function get_lendbook:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_lendbook
number of ops:  8
compiled vars:  !0 = $symbol, !1 = $request
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  119     0  E >   RECV_INIT                                        !0      'usd'
  121     1        CONCAT                                           ~2      '%2Fv1%2Flendbook%2F', !0
          2        ASSIGN                                                   !1, ~2
  123     3        INIT_METHOD_CALL                                         'send_unsigned_request'
          4        SEND_VAR_EX                                              !1
          5        DO_FCALL                                      0  $4      
          6      > RETURN                                                   $4
  125     7*     > RETURN                                                   null

End of function get_lendbook

Function get_lends:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_lends
number of ops:  8
compiled vars:  !0 = $symbol, !1 = $request
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  127     0  E >   RECV_INIT                                        !0      'usd'
  129     1        CONCAT                                           ~2      '%2Fv1%2Flends%2F', !0
          2        ASSIGN                                                   !1, ~2
  131     3        INIT_METHOD_CALL                                         'send_unsigned_request'
          4        SEND_VAR_EX                                              !1
          5        DO_FCALL                                      0  $4      
          6      > RETURN                                                   $4
  133     7*     > RETURN                                                   null

End of function get_lends

Function get_ticker:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  get_ticker
number of ops:  11
compiled vars:  !0 = $symbol, !1 = $request
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  135     0  E >   RECV_INIT                                        !0      'btcusd'
  137     1        FETCH_OBJ_R                                      ~2      'api_version'
          2        CONCAT                                           ~3      '%2F', ~2
          3        CONCAT                                           ~4      ~3, '%2Fticker%2F'
          4        CONCAT                                           ~5      ~4, !0
          5        ASSIGN                                                   !1, ~5
  139     6        INIT_METHOD_CALL                                         'send_unsigned_request'
          7        SEND_VAR_EX                                              !1
          8        DO_FCALL                                      0  $7      
          9      > RETURN                                                   $7
  140    10*     > RETURN                                                   null

End of function get_ticker

Function prepare_header:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  prepare_header
number of ops:  35
compiled vars:  !0 = $data, !1 = $payload, !2 = $signature
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  142     0  E >   RECV                                             !0      
  144     1        ASSIGN_DIM                                               !0, 'nonce'
          2        OP_DATA                                                  144800329405116
  147     3        ECHO                                                     !0
  148     4        ECHO                                                     'Json+encode+%3Cbr%2F%3E+'
  149     5        INIT_FCALL                                               'json_encode'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $4      
          8        ECHO                                                     $4
  150     9        ECHO                                                     '%3Cbr%2F%3E'
  151    10        INIT_FCALL                                               'base64_encode'
         11        INIT_FCALL                                               'json_encode'
         12        SEND_VAR                                                 !0
         13        DO_ICALL                                         $5      
         14        SEND_VAR                                                 $5
         15        DO_ICALL                                         $6      
         16        ASSIGN                                                   !1, $6
  152    17        INIT_FCALL                                               'hash_hmac'
         18        SEND_VAL                                                 'sha384'
         19        SEND_VAR                                                 !1
         20        FETCH_OBJ_R                                      ~8      'api_secret'
         21        SEND_VAL                                                 ~8
         22        DO_ICALL                                         $9      
         23        ASSIGN                                                   !2, $9
  154    24        ECHO                                                     'payload'
  155    25        ECHO                                                     !1
  158    26        FETCH_OBJ_R                                      ~11     'api_key'
         27        CONCAT                                           ~12     'X-BFX-APIKEY%3A+', ~11
         28        INIT_ARRAY                                       ~13     ~12
  159    29        CONCAT                                           ~14     'X-BFX-PAYLOAD%3A+', !1
         30        ADD_ARRAY_ELEMENT                                ~13     ~14
  160    31        CONCAT                                           ~15     'X-BFX-SIGNATURE%3A+', !2
         32        ADD_ARRAY_ELEMENT                                ~13     ~15
         33      > RETURN                                                   ~13
  162    34*     > RETURN                                                   null

End of function prepare_header

Function send_signed_request:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 35, Position 2 = 38
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 38
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  send_signed_request
number of ops:  45
compiled vars:  !0 = $data, !1 = $ch, !2 = $url, !3 = $headers, !4 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  164     0  E >   RECV                                             !0      
  166     1        INIT_FCALL_BY_NAME                                       'curl_init'
          2        DO_FCALL                                      0  $5      
          3        ASSIGN                                                   !1, $5
  167     4        FETCH_OBJ_R                                      ~7      'base_url'
          5        FETCH_DIM_R                                      ~8      !0, 'request'
          6        CONCAT                                           ~9      ~7, ~8
          7        ASSIGN                                                   !2, ~9
  169     8        ECHO                                                     !2
  171     9        INIT_METHOD_CALL                                         'prepare_header'
         10        SEND_VAR                                                 !0
         11        DO_FCALL                                      0  $11     
         12        ASSIGN                                                   !3, $11
  173    13        INIT_FCALL_BY_NAME                                       'curl_setopt_array'
         14        SEND_VAR_EX                                              !1
  174    15        FETCH_CONSTANT                                   ~13     'CURLOPT_URL'
         16        INIT_ARRAY                                       ~14     !2, ~13
  175    17        FETCH_CONSTANT                                   ~15     'CURLOPT_POST'
  174    18        ADD_ARRAY_ELEMENT                                ~14     <true>, ~15
  176    19        FETCH_CONSTANT                                   ~16     'CURLOPT_RETURNTRANSFER'
  174    20        ADD_ARRAY_ELEMENT                                ~14     <true>, ~16
  177    21        FETCH_CONSTANT                                   ~17     'CURLOPT_HTTPHEADER'
         22        ADD_ARRAY_ELEMENT                                ~14     !3, ~17
  178    23        FETCH_CONSTANT                                   ~18     'CURLOPT_SSL_VERIFYPEER'
  174    24        ADD_ARRAY_ELEMENT                                ~14     <false>, ~18
  179    25        FETCH_CONSTANT                                   ~19     'CURLOPT_POSTFIELDS'
         26        ADD_ARRAY_ELEMENT                                ~14     '', ~19
         27        SEND_VAL_EX                                              ~14
         28        DO_FCALL                                      0          
  184    29        INIT_FCALL_BY_NAME                                       'curl_exec'
         30        SEND_VAR_EX                                              !1
         31        DO_FCALL                                      0  $21     
         32        ASSIGN                                           ~22     !4, $21
         33        BOOL_NOT                                         ~23     ~22
         34      > JMPZ                                                     ~23, ->38
  186    35    >   ECHO                                                     'NO+%3Cbr%2F%3E'
  188    36      > RETURN                                                   <false>
         37*       JMP                                                      ->44
  192    38    >   ECHO                                                     'YES+%3Cbr%2F%3E'
  193    39        INIT_FCALL                                               'json_decode'
         40        SEND_VAR                                                 !4
         41        SEND_VAL                                                 <true>
         42        DO_ICALL                                         $24     
         43      > RETURN                                                   $24
  195    44*     > RETURN                                                   null

End of function send_signed_request

Function send_unsigned_request:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 23, Position 2 = 26
Branch analysis from position: 23
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 26
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m1XAY
function name:  send_unsigned_request
number of ops:  35
compiled vars:  !0 = $request, !1 = $ch, !2 = $url, !3 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  197     0  E >   RECV                                             !0      
  199     1        INIT_FCALL_BY_NAME                                       'curl_init'
          2        DO_FCALL                                      0  $4      
          3        ASSIGN                                                   !1, $4
  200     4        FETCH_OBJ_R                                      ~6      'base_url'
          5        CONCAT                                           ~7      ~6, !0
          6        ASSIGN                                                   !2, ~7
  202     7        INIT_FCALL_BY_NAME                                       'curl_setopt_array'
          8        SEND_VAR_EX                                              !1
  203     9        FETCH_CONSTANT                                   ~9      'CURLOPT_URL'
         10        INIT_ARRAY                                       ~10     !2, ~9
  204    11        FETCH_CONSTANT                                   ~11     'CURLOPT_RETURNTRANSFER'
  203    12        ADD_ARRAY_ELEMENT                                ~10     <true>, ~11
  205    13        FETCH_CONSTANT                                   ~12     'CURLOPT_SSL_VERIFYPEER'
  203    14        ADD_ARRAY_ELEMENT                                ~10     <false>, ~12
         15        SEND_VAL_EX                                              ~10
         16        DO_FCALL                                      0          
  208    17        INIT_FCALL_BY_NAME                                       'curl_exec'
         18        SEND_VAR_EX                                              !1
         19        DO_FCALL                                      0  $14     
         20        ASSIGN                                           ~15     !3, $14
         21        BOOL_NOT                                         ~16     ~15
         22      > JMPZ                                                     ~16, ->26
  210    23    >   ECHO                                                     'NO+%3Cbr%2F%3E'
  211    24      > RETURN                                                   <false>
         25*       JMP                                                      ->34
  215    26    >   ECHO                                                     'YES+%3Cbr%2F%3E'
  216    27        ECHO                                                     !3
  217    28        ECHO                                                     '%3Cbr%2F%3E'
  218    29        INIT_FCALL                                               'json_decode'
         30        SEND_VAR                                                 !3
         31        SEND_VAL                                                 <true>
         32        DO_ICALL                                         $17     
         33      > RETURN                                                   $17
  220    34*     > RETURN                                                   null

End of function send_unsigned_request

End of class Bitfinex.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.38 ms | 1424 KiB | 21 Q