for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Mrjoops\OAuth2\Client\Provider;
use League\OAuth2\Client\Provider\ResourceOwnerInterface;
use League\OAuth2\Client\Tool\ArrayAccessorTrait;
class JiraResourceOwner implements ResourceOwnerInterface
{
use ArrayAccessorTrait;
/**
* Raw response
*
* @var array
*/
protected $response;
* Creates new resource owner.
* @param array $response
public function __construct(array $response = [])
$this->response = $response;
}
* Get resource owner email
* @return string|null
public function getEmail()
return $this->getValueByKey($this->response, 'emailAddress');
* Get resource owner id
public function getId()
return $this->getValueByKey($this->response, 'accountId');
* Get resource owner name
public function getName()
return $this->getValueByKey($this->response, 'displayName');
* Get resource owner nickname
public function getNickname()
return $this->getValueByKey($this->response, 'name');
* Return all of the owner details available as an array.
* @return array
public function toArray()
return $this->response;