Skip to main content

Pyramid routes and helpers for Facebook canvas applications

Project description

Provides simple pyramid routes/views for facebook canvas application.

Some documentation on http://pyramid_facebook.rtfd.org

Configuration

  1. Create facebook application on https://developers.facebook.com/apps

  2. Add facebook settings in .ini file under application section and fill with facebook application parameters:

    facebook.app_id =
    facebook.secret_key =
    facebook.namespace =
    facebook.scope =
  3. In the app settings on https://developers.facebook.com/apps, set callbak url to point to

    http://127.0.0.1:6543/[facebook app namespace]/
  4. Include pyramid_facebook in your config:

    config.include('pyramid_facebook')
    config.scan()
  5. Define your facebook canvas view:

    from pyramid_facebook.canvas import facebook_canvas
    
    @facebook_canvas()
    def canvas(context, request):
       # canvas is available only to users who accepted facebook permission
       # defined in setting['facebook.scope'].
       # context.facebook_data dict contains signed_request content.
       # i.e.:
       # user_id = context.facebook["user_id"]
       ...
       return Response('Hello Facebok World')
  6. Browse to your app on

    http://apps.facebook.com/[app namespace]

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyramid_facebook-0.2.243.tar.gz (24.4 kB view details)

Uploaded Source

File details

Details for the file pyramid_facebook-0.2.243.tar.gz.

File metadata

File hashes

Hashes for pyramid_facebook-0.2.243.tar.gz
Algorithm Hash digest
SHA256 9e58d1d28090ce7955d740e94caac4f8b2f6c1f73ac6ca3c595cc6c5bcd4c4cf
MD5 46d5ccfda1655111517b2bec73885284
BLAKE2b-256 b30a960e6d730bb886afc791d9de0f31571f11000e15b98a0b6760b9d2d9211b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page