Skip to content

Instantly share code, notes, and snippets.

@rodde177
Created March 10, 2015 07:55
Show Gist options
  • Save rodde177/b2d8d1c8b3b7f853c016 to your computer and use it in GitHub Desktop.
Save rodde177/b2d8d1c8b3b7f853c016 to your computer and use it in GitHub Desktop.
Magento check API role
<?php
$apikey = Mage::getModel('api/user')->load(1)->getApiKey();
print_r($apikey);
$roles = Mage::getModel('api/roles')->getCollection();
foreach($roles as $role):
echo '<br/>Role : '.$role->getId()." | ".$role->getRoleName();
endforeach;
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment