Skip to content
ivanchak edited this page Jun 22, 2013 · 23 revisions

Apply for app key

ALL SNSAPI users must apply their own application keys to enable a certain platform (if it requires OAuth). Not only developers need a key! All the OSNs we currently touch do not allow other users to authorize test stage Apps, e.g. only the developer can authorize it. In this case, everyone needs to register as a developer first and apply their own key. Whenever you see sample usage of SNSAPI, remember to change their app_key and app_secret to yours. Alternatively, you can ask the key owner to assign you as a test user if you really want to use others' keys.

Tencent

Expiration: 3 months (for appkey owners)

Website: Tencent Open App Platform

This interface should be a good start for learning how to use snsapi. The application is easy while the authentication is also convenient.

Sina

Expiration: 5 years (for appkey owners)

Website: Sina Weibo Open App Platform

Problem: My personal account seems to be unusable ever since they adopted the OAuth 2.0 standard.

Renren

Expiration: 30 days

Website: Renren Open App Platform

Twitter

Expiration: NONE (for appkey owners)

Note, twitter do not need to authorize it every time. As developers, they provide you a permanent key to use. You can even get your app authority without waiting for their review. Very convenient!!

Procedure:

  1. Apply for your own twitter account at "https://twitter.com/" if you do not have one.
  2. Fill in the form at "https://dev.twitter.com/apps/new" and create your twitter application
  3. Click on Create My Access Token at the bottom of the page after finishing the form
  4. Now, you should configure the channel as follows.
"app_key" = "consumer key"  
"app_secret" = "consumer secret"  
"access_key" = "Access token"  
"access_secret" = "Access token secret"  

Facebook

Expiration: About an hour

Procedure:

  1. Refer to https://github.com/ivanchak/snsapi, there is a wiki (https://github.com/ivanchak/snsapi/wiki)showing the details.
  2. Generate your access token
  3. Configure the channel as follows.
"platform" = "FacebookStatus"
"access_token" = "your_access_token_here"
Clone this wiki locally