php - Facebook apprequests can not send additional data to canvas page -


i used javascript sdk send apprequests user's friends, need additional data displayed on canvas page when user clicks notification.

after parsing signed request haven't found related data.

here code:

fb.ui({       method: 'apprequests',       message: 'message',       data: 'data here',    },     function (response) {    if (response) {        alert('successfully invited');    }     else {        alert('failed invite');    } }); 

what doing wrong ?

i have found solution. maybe else.

in canvas page need make 1 more call apprequests method using oauth_token signed_request , apprequest_id params , there see data passed app call.

    fb.api(             '{your_apprequest_id}?access_token=caahoneepb5ibaczbs4n9muvwhwz9csozc82jjrqqezc2kxwzcp8scmxck92qjkvh37h1zayzcm7dc1w8ils31m5ogvnzaoe7bnhtt8tg9dgsdzcfypr0ej5hu5bcogwvcxorcghoedrfq426we0q70o3dqinvrrlozcjt0xrrspebbrqxzahevxrfzrw8pojjoiqbnjzckaaavurwjzct5jnm7bhzb2w6czcosa7ezd',             'get',             {                 to: 'user_id_who_received_apprequest'             },     function (response) {         console.log(response);     } 

Comments

Popular posts from this blog

Fail to load namespace Spring Security http://www.springframework.org/security/tags -

sql - MySQL query optimization using coalesce -

unity3d - Unity local avoidance in user created world -