$entity, 'size' => 'small', ) ); $public_label = elgg_echo('apiadmin:public'); $private_label = elgg_echo('apiadmin:private'); $revoke_label = elgg_echo('apiadmin:revoke'); $ts = time(); $token = generate_action_token($ts); $info = "
{$entity->title} url}actions/apiadmin/revokekey?keyid={$entity->guid}&__elgg_token=$token&__elgg_ts=$ts\">$revoke_label
$public_label: {$entity->public}
";
if (isadminloggedin()) {
// Only show secret portion to admins
// Fetch key
$keypair = get_api_user($CONFIG->site_id, $entity->public);
$info .= "$private_label: {$keypair->secret}