Facebook

Enabling Brightspot to post to Facebook requires the following steps:

  1. Creating a Facebook App
  2. Connecting Brightspot to a Facebook App
  3. Authorizing Posts to a Facebook Profile or Authorizing Posts to a Facebook Page

Creating a Facebook App

A Facebook App is the mechanism which allows third-party applications to authenticate and post directly to Facebook accounts. Brightspot uses the Oauth 1.0 model for authentication with Facebook. Under this model, you create a Facebook app with its own ID and secret string (password). You then connect Brightspot to the app using those credentials, at which point Facebook requests your permission to allow Brightspot to connect. After that initial setup, you can post to Facebook directly from Brightspot.

In this procedure you create an app that Brightspot uses to post to Facebook.

  1. Install the Social plugin; contact your Brightspot developer for details.

  2. Create a developer account for the target Facebook profile if you don’t already have one. For details, see Developer Account.

  3. Log in to the target Facebook developer account.

  4. Create a new app by doing the following:

    1. Go to https://developers.facebook.com/apps/.

    2. Click Create a New App, or from the My Apps menu click Create New App. The Create a New App ID widget appears.

      ../../../_images/fb-create-new-app-id.png
    3. In the Display Name field, type a name for the app.

    4. In the Contact Email field, type a contact email.

    5. Click Create App ID and respond to any security prompts. A dashboard appears for the app.

      ../../../_images/fb-app-dashboard.png
    6. In the dashboard’s left rail, under Settings, click Basic. The app’s basic settings appear.

      ../../../_images/fb-app-settings.png
    7. In the App Secret field, click Show. The secret string appears in plain text.

    8. Copy the App ID and App Secret into a text editor; you’ll paste these values into Brightspot.

    9. In the Display Name field, enter a display name. This name appears as an attribution on your posts from Brightspot.

    10. At the bottom of the page, click Add Platform, then click Website. The Website widget appears.

    11. In the Site URL field, enter the URL of your Brightspot site. (This is the setting in Brightspot’s Admin > Sites & Settings > (site name) > Main tab > Urls field.)

      ../../../_images/fb-app-website.png
    12. Scroll up to the basic settings, and in the App Domains field, enter the URL you used in step k.

    13. Click Save Changes.

  5. Configure access to the new app by doing the following:

    1. In the left rail, click + next to PRODUCTS.

      ../../../_images/fb-add-products.png

      A list of available products appears.

    2. Under Facebook Login click Set Up.

      ../../../_images/fb-fbook-login.png

      Facebook Login appears in the left rail under Products, and a list of available platforms appears.

      ../../../_images/fb-app-platforms.png
    3. Click Web. A form appears with the prompt Tell Us about Your Website. Leave the form’s values at their defaults, no need to click Save.

    4. In the left rail, under Facebook Login, click Settings. The Client OAuth Settings widget appears.

      ../../../_images/fb-client-oauth.png
    5. Leave the field Valid OAuth redirect URIs blank; you’ll add two URIs in that field as explained in Authorizing Posts to Facebook.

    6. Still in the Client OAuth Settings widget, make additional settings as indicated in the following table:

      Setting Value
      Client OAuth Login Yes
      Web OAuth Login Yes
      Force Web OAuth Reauthentication No
      Use Strict Mode for Redirect URIs Yes
      Enforce HTTPS Yes
      Embedded Browser OAuth Login No
      Login from Devices No
    7. Click Save Changes.

Your Facebook app is now available for connection to Brightspot; continue with the procedure in Connecting Brightspot to a Facebook App.

See also:

Connecting Brightspot to a Facebook App

Note

Perform the steps in this section from a Brightspot instance running over HTTPS. Facebook does not allow connections from sites running over HTTP.

  1. In Brightspot, switch to the site from which you will be connecting to Facebook. For details, see Switching Between Sites.

  2. From the Navigation Menu, select Social > Services.

  3. In the Services widget, click New Facebook Service. The New Facebook Service widget appears.

    ../../../_images/new-fb-service.png
  4. In the New Facebook Service widget, do the following:

    1. In the Name field, type a name for the service.

    2. In the App ID and App Secret fields, type the values you copied from step 4.h in Creating a Facebook App.

    3. Click Save. Your Brightspot instance is now connected to a Facebook app, and a URL with two query parameters appears in your browser’s address bar.

    4. In your browser’s URL, copy into a text editor the value for the query parameter id. This is your Facebook’s service ID within Brightspot, and you’ll need this value when establishing redirect URIs in your Facebook app’s settings.

      ../../../_images/service-id.svg

      Service ID in Brightspot URL

    5. Proceed to Adding Callback URIs to a Facebook App.

Adding Callback URIs to a Facebook App

The procedure in the section Connecting Brightspot to a Facebook App generated a service ID that you pasted into a text editor. With that service ID you add two callback URIs to your Facebook app that allow your Brightspot instance to log in to Facebook and to post to profiles and pages. The callback URIs have the following formats:

https://my-domain.com/_social/services/facebook/connect?serviceId=<serviceID>&action=USER_AUTH_CALLBACK
https://my-domain.com/_social/services/facebook/connect?serviceId=<serviceID>&action=PAGES_AUTH_CALLBACK
  1. Return to Facebook’s Client OAuth Settings widget for your app.

    ../../../_images/fb-client-oauth.png
  2. In the Valid OAuth Redirect URIs field, enter the two callback URIs for your Brightspot instance: one for action=USER_AUTH_CALLBACK and another for action=PAGES_AUTH_CALLBACK.

    ../../../_images/fb-redirect-uris.png
  3. Click Save Changes.

Authorizing Posts to Facebook

Many applications on the Internet provide access to other applications. Cross-access between applications is very useful if you have several social media accounts and you want to post an article to one of them and then link to it on your other accounts. For example, if you posted an article on LinkedIn, you can share a link to that article on your Facebook, Twitter, and Google+ accounts. The same feature is available with Brightspot: you can post a story to your web site from Brightspot, and then share links to that story on your social media accounts right from the content edit page. The mechanism by which one application grants access to another one is called Open Authorization (OAuth).

This section describes how to authorize posts to Facebook from Brightspot using OAuth.

Authorizing Posts to a Facebook Profile

In this step, Facebook requests authorization to post to the target Facebook account from Brightspot. (For information about posting to a Facebook page, see Authorizing Posts to a Facebook Page.)

Note

Perform the steps in this section from a Brightspot instance running over HTTPS. Facebook does not allow connections from sites running over HTTP.

  1. In Brightspot, from the Navigation Menu, select Social > Accounts. (If you don’t see Social, contact your Brightspot developer to install the Social plugin.) The Connect Accounts widget appears with your Facebook service listed.

    ../../../_images/create-accounts-fb.png
  2. In the Connect Accounts widget, under the required Facebook service, do the following (if you don’t see a Facebook service, add one by following the procedure in Connecting Brightspot to a Facebook App):

    1. Click Connect Profile. A request from Facebook appears asking for authentication.

      ../../../_images/fb-submit-login-review.png
    2. Complete the authentication request. You return to the Connect Accounts widget, and the target Facebook account is listed.

    ../../../_images/fb-account-icon.png

Brightspot users can now publish links to Facebook; for details, see Social Publishing.

Authorizing Posts to a Facebook Page

Some companies have Facebook pages dedicated to target audiences. You can publish from Brightspot directly to those pages. (For information about posting to a Facebook profile page, see Authorizing Posts to a Facebook Profile.)

Note

Perform the steps in this section from a Brightspot instance running over HTTPS. Facebook does not allow connections from sites running over HTTP.

  1. In Brightspot, from the Navigation Menu, select Social > Accounts. (If you don’t see Social, ask your developer to install the Social plugin.) The Connect Accounts widget appears with your Facebook service listed.

    ../../../_images/create-accounts-fb.png
  2. In the Connect Accounts widget, under the required Facebook service, do the following (if you don’t see a Facebook service, add one by following the procedure in Connecting Brightspot to a Facebook App):

    1. Click Connect Page. A request from Facebook appears asking for authentication.

      ../../../_images/fb-pages-authentication.png
    2. Click OK. You return to Brightspot showing a list of your Facebook pages.

      ../../../_images/fb-choose-fb-page.png
    3. Select the required page. You return to the Connect Accounts widget, and the target Facebook page is listed.

Brightspot users can now publish links to Facebook; for details, see Social Publishing.