Allow ClientsController to authenticate as API.

Ripped straight out of EntriesController. That is_navigational_format
thing is a hack to make browser requests behave better, but requires API
requests to pass a bogus format like .js even though they're requesting
HTML.
check for api requests vs. browser requests
Truncate urn to heroku limit when building cms link
test authenticatable api protects api type requests
Move app name logic into class
Use app name formatter in client model
Simplify removal of trailing dash
Merge pull request #62 from G5/fix-cms-links-78687834

Truncate urn to heroku limit when building cms link
Merge pull request #63 from G5/auth_fix

Auth fix
Remove circle.yml

When we moved this repo to open source we also moved to travis ci, but it looks
like this file was forgotten...
Merge pull request #64 from G5/remove-circle

Remove circle.yml
Adding integration settings to location

commit 4b8ed949f091fa1ddafa5dd2b572d92bbf15c34e
Merge: caa3f46 22b35ef
Author: Perry Hertler <perry@hertler.org>
Date:   Tue Sep 16 14:01:12 2014 -0500

    Merge branch 'master' into integration-settings

commit caa3f4690bcd15f2e4d905b70177d838fb1b2486
Author: Perry Hertler <perry@hertler.org>
Date:   Mon Sep 15 15:03:35 2014 -0500

    making circleci happy

commit 4673b52ee534448c070e43fc51d37c9f911d7d97
Author: Perry Hertler <perry@hertler.org>
Date:   Mon Sep 15 14:32:57 2014 -0500

    valid integration setting microformat

commit 5998d0fff8bbce05dc11d9e2dead7bdafa287858
Author: Perry Hertler <perry@hertler.org>
Date:   Mon Sep 15 11:47:25 2014 -0500

    microformatting integration settings

commit 55a0331faf936d0349f30df59f3a6e7b074adeeb
Author: Perry Hertler <perry@hertler.org>
Date:   Fri Sep 12 12:42:27 2014 -0500

    scope finding of location by parent client

commit b64b32b41f7576ac1db33239c44ad68affdf979f
Author: Perry Hertler <perry@hertler.org>
Date:   Fri Sep 12 12:30:16 2014 -0500

    accepting nested attributes for custom settings

commit b7a81bc8738f6a3e991820b0c907a6c87610ee04
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 18:53:01 2014 -0500

    adding form fields for integration settings

commit 0c1fa7484db2564d93d380be2a8cd283b106d4c8
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 14:49:56 2014 -0500

    adding integration_settings form

commit e960751eecd7e1b62b2c074c6816c11684a771bd
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 14:26:57 2014 -0500

    making sure correct integration_setting is assigned

commit 9bebb8c43b7470637bba1c9b2b4d180819bdf715
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 14:21:26 2014 -0500

    adding integration_settings_controller

commit 52b87667b50e9fab5add3a516ba7ecc54b3b7923
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 11:43:07 2014 -0500

    bumping travis to use ruby 2.1.2

commit 97e6d47b2d349781976f97ecc32877efb97055e5
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 10:57:51 2014 -0500

    adding integration settings models

commit 4c462397711b38dd03e81bdfe8c6f1246f908aff
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 10:57:09 2014 -0500

    ignoring .idea

commit 5cc7b88846d704d9ce2aadf094c59aa1990e76c7
Author: Perry Hertler <perry@hertler.org>
Date:   Thu Sep 11 10:56:49 2014 -0500

    bumping to ruby 2.1.2
not concerning user if edit or new integration setting

has_one
not needed because we're no longer using circleci
Merge pull request #65 from G5/integration-setting

Adding integration settings to location
Use rack-cors to permit cross-origin requests.
Merge branch 'allow-cors'
adding lead-integrations
lead integrations microformat
Merge pull request #67 from G5/lead-integrations

Lead integrations