xerotic

HF API v2 Field List

Jun 1st, 2020
1,317
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.88 KB | None | 0 0
  1. <?php
  2.  
  3. require_once "hf_api.php";
  4.  
  5. // Initialize api instance
  6. $api = new HF_API();
  7.  
  8. // Set the access token for the specific authorized member
  9. $api->setAccessToken("ACCESS_TOKEN_HERE");
  10.  
  11. // What data do we want to retrieve from the API? Send an array and process the call.
  12. $read = $api->read([
  13.     "me" => [ // Basic Info & Advanced Info Permissions
  14.         'uid',
  15.         'username',
  16.         'usergroup',
  17.         'displaygroup',
  18.         'additionalgroups',
  19.         'postnum',
  20.         'awards',
  21.         'myps',
  22.         'threadnum',
  23.         'avatar',
  24.         'avatardimensions',
  25.         'avatartype',
  26.         'lastvisit',
  27.         'usertitle',
  28.         'website',
  29.         'timeonline',
  30.         'reputation',
  31.         'referrals',
  32.         'lastactive',
  33.         'unreadpms',
  34.         'invisible',
  35.         'totalpms',
  36.         'warningpoints',
  37.         'lastactive', // Advanced Info Permission Only
  38.         'unreadpms', // Advanced Info Permission Only
  39.         'invisible', // Advanced Info Permission Only
  40.         'totalpms', // Advanced Info Permission Only
  41.         'warningpoints' // Advanced Info Permission Only
  42.     ],
  43.     "forums" => [ // Posts Permissions
  44.         'fid',
  45.         'name',
  46.         'description',
  47.         'type',
  48.     ],
  49.     "threads" => [ // Posts Permissions
  50.         'tid',
  51.         'uid',
  52.         'fid',
  53.         'subject',
  54.         'closed',
  55.         'numreplies',
  56.         'views',
  57.         'dateline',
  58.         'firstpost',
  59.         'lastpost',
  60.         'lastposter',
  61.         'lastposteruid',
  62.         'prefix',
  63.         'icon',
  64.         'poll',
  65.         'username',
  66.         'sticky',
  67.         'bestpid',
  68.         'firstpost' => [
  69.             '<Post>',
  70.         ]
  71.     ],
  72.     "posts" => [ // Posts Permissions
  73.         'pid',
  74.         'tid',
  75.         'uid',
  76.         'fid',
  77.         'dateline',
  78.         'message',
  79.         'subject',
  80.         'edituid',
  81.         'edittime',
  82.         'editreason',
  83.         'author' => [
  84.             '<User>',
  85.         ],
  86.     ],
  87.     "users" => [ // Users Permissions
  88.         'uid',
  89.         'username',
  90.         'usergroup',
  91.         'displaygroup',
  92.         'additionalgroups',
  93.         'postnum',
  94.         'awards',
  95.         'myps',
  96.         'threadnum',
  97.         'avatar',
  98.         'avatardimensions',
  99.         'avatartype',
  100.         'usertitle',
  101.         'website',
  102.         'timeonline',
  103.         'reputation',
  104.         'referrals'
  105.     ]
  106. ]);
Add Comment
Please, Sign In to add comment