class ApiKeyAuthenticator implements SimplePreAuthenticatorInterface
{
public function createToken(Request $request, $providerKey)
{
// look for an apikey query parameter
//$apiKey = $request->query->get('apikey');
// or if you want to use an "apikey" header, then do something like this:
$apiKey = $request->headers->get('apikey');
//...
apikey
так же как, скажем, секцию User-Agent
, Accept
и т.п.