API Token Based Access Laravel 5.1 (Yet another article on this)
API Token Laravel 5.2 introduces the auth token guard setup which is way simpler than Oauth. Also it does not assume a certain level of complexity in needs like Scopes and expirations of tokens that we do not need for our internal app to app communications. We are using 5.1 so this will implement it. See some docs here https://gistlog.co/JacobBennett/090369fbab0b31130b51 For creating a user the AppServiceProvider boots the user record and if no api_token is present it will set one.
Using VCR for PHP API Testing
Testing that your code works against an API can take up lots of un-needed time. With this php-vcr library you can do ONE real request that saves a fixture file that will automatically be used with each additional requests! They have decent docs on setting up but I will walk through them here. I will base this off a seed phpunit repo I have https://github.com/alnutile/base_library_repo You will need to add to the composer.
CORS and Laravel
When doing some API work using Laravel as the REST server I was getting a common error "No 'Access-Control-Allow-Origin' header is present on the requested resource." which happens when the REST server is on a different domain than the client server. I installed this package https://github.com/barryvdh/laravel-cors and it now works fine.