DemoAuth.php 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <?php
  2. include 'DemoBase.php';
  3. global $client;
  4. $body = [
  5. 'Domain' => 'domain',
  6. 'SceneType' => 'push',
  7. "AuthDetailList" => [
  8. [
  9. "EncryptionAlgorithm" => "md5",
  10. "SecretKey" => "xx",
  11. ],
  12. ],
  13. ];
  14. $response = $client->updateAuthKey(['json' => $body]);
  15. echo $response;
  16. echo '<br>';
  17. $body = [
  18. 'Domain' => 'domain',
  19. 'SceneType' => 'push'
  20. ];
  21. $response = $client->describeAuth(['json' => $body]);
  22. echo $response;
  23. echo '<br>';
  24. $body = [
  25. 'Domain' => 'domain',
  26. 'App' => 'app',
  27. 'RefererInfoList' => [
  28. [
  29. 'Key' => 'asd',
  30. 'Type' => 'xx',
  31. 'Value' => 'sad',
  32. 'Priority' => 0,
  33. ],
  34. ],
  35. ];
  36. $response = $client->updateReferer(['json' => $body]);
  37. echo $response;
  38. echo '<br>';
  39. $body = [
  40. 'Domain' => 'domain',
  41. 'App' => 'app',
  42. ];
  43. $response = $client->describeReferer(['json' => $body]);
  44. echo $response;
  45. echo '<br>';
  46. $body = [
  47. 'Vhost' => 'vv',
  48. 'App' => 'app',
  49. ];
  50. $response = $client->deleteReferer(['json' => $body]);
  51. echo $response;
  52. echo '<br>';