Skip to content
Peter Hoyes edited this page Jul 4, 2018 · 5 revisions

With a fresh checkout, only password-based and Raven logins can be used without any additional setup. Other login methods (Facebook, Google etc) require API keys to be generated on a per-hostname basis.

Below is a list of all the APIs that can be used and details of how and where to get the API keys.

Facebook

  • Go to https://developers.facebook.com/apps
  • Click 'Create New App'
  • Enter an app name and namespace
  • Copy the 'App ID' and 'App Secret' into parameters.yml (facebook_id and facebook_secret)

Twitter

  • Go to https://dev.twitter.com/apps
  • Click 'Create a new application'
  • Fill in the details. There's no need to provide a callback URL
  • On the app page, click 'Create my access token' at the bottom
  • Copy 'Consumer key', 'Consumer secret', 'Access token', and 'Access token secret' to parameters.yml (twitter_key, twitter_secret, twitter_token, twitter_token_secret)

Google

The instructions below assume you are using the new 'Cloud Console'

  • Go to https://code.google.com/apis/console/ and log in
  • Click 'APIs & Auth', then 'Credentials'
  • 'Create a new client ID'
  • In 'Authorized Javascript origins' enter your checkout's hostname (e.g. http://local.camdram.net)
  • Enter the following URLs in 'Authorized redirect URI' (changing the hostname as appropriate):
http://local.camdram.net/app_dev.php/extauth/login/google
http://local.camdram.net/extauth/login/google
https://local.camdram.net/app_dev.php/extauth/login/google
https://local.camdram.net/extauth/login/google
  • Click 'Create Client ID'
  • Copy the 'Client ID' and 'Client Secret' into parameters.yml (google_client_id, google_client_secret)

The Google Map on the venues page also requires a 'Public Access Key', which can be created by scrolling down and clicking 'Create new key'. Select 'Browser key' and enter your checkout's hostname as before. Insert the generated key next to 'google_key' in parameters.yml

Github

This is only used to pull the ticket names on the 'Development' page, and it should work without an API albeit with a much lower rate limit. Included for completeness.

  • Go to the Github settings (click on the icon of a spanner and screwdriver in the top right)
  • Go to 'Applications' and click 'Register new application'
  • Fill in some suitable details. The 'authorisation URL' is irrelevant as we don't use the Github login flow.
  • Insert the generated client ID and client secret into parameters.yml (github_id, github_secret)

The API applications used by the live sites are stored under the 'Camdram' Github organisation (click 'camdram' after going to the settings page.