dev-master
9999999-devToken Auth Bundle
The Requires
api auth igdr
Wallogit.com
2017 © Pedro Peláez
Token Auth Bundle
Add the bundle to your composer.json:, (*1)
composer require igdr/token-auth-bundle
Then add the IgdrEmployeeBundle to your application kernel:, (*2)
// app/AppKernel.php
public function registerBundles()
{
return array(
// ...
new Igdr\Bundle\TokenAuthBundle\IgdrTokenAuthBundle(),
// ...
);
}
config.yml, (*3)
doctrine:
orm:
....
resolve_target_entities:
Symfony\Component\Security\Core\User\UserInterface: App\Bundle\UserBundle\Entity\User
securiry.yml, (*4)
security:
firewalls:
api_token_secured:
pattern: ^/api/.*
stateless: true
api_token: true
anonymous: true
console: php app/console doctrine:schema:update --force, (*5)
Token Auth Bundle
api auth igdr