fork download
  1. <?php
  2.  
  3. $curl = curl_init();
  4.  
  5. CURLOPT_URL => 'https://s...content-available-to-author-only...s.com/api/gateway/hosted-form',
  6. CURLOPT_RETURNTRANSFER => true,
  7. CURLOPT_ENCODING => '',
  8. CURLOPT_MAXREDIRS => 10,
  9. CURLOPT_TIMEOUT => 0,
  10. CURLOPT_FOLLOWLOCATION => true,
  11. CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  12. CURLOPT_CUSTOMREQUEST => 'POST',
  13. CURLOPT_POSTFIELDS =>'{
  14. "dba": {
  15. "id": 9
  16. },
  17. "terminal": {
  18. "id": 24
  19. },
  20. "threeds": "Disabled",
  21. "amount": 2,
  22. "feeType": "amount",
  23. "fee": 2,
  24. "externalId": "example",
  25. "origin": "WEB",
  26. "returnUrl": "https://e...content-available-to-author-only...e.com",
  27. "returnUrlNavigation": "top",
  28. "useLogo": "Yes",
  29. "visibleNote": "Yes"
  30. }',
  31. CURLOPT_HTTPHEADER => array(
  32. 'Authorization: Bearer N8l8J.4XjO3CrEDhO0rK9dTx8YcMtC0bJmDEN3',
  33. 'Content-Type: application/json'
  34. ),
  35. ));
  36.  
  37. $response = curl_exec($curl);
  38.  
  39. curl_close($curl);
  40. echo $response;
  41.  
Success #stdin #stdout 0.03s 26348KB
stdin
Standard input is empty
stdout
Standard output is empty