last day (14 days later) » 

9:37 AM
-1
Q: Attend to a facebook event from ionic app

AryI have a hybrid app and I'm trying to have a button that when the user clicks it, say yes to a facebook event. I have the rsvp_event permission from facebook and I have this code: in app.js file: ngFB.init({appId: '[APP_ID]'}); In the login, I get the access_token, and to attend an event I hav...

 
you should not create another thread for the same question. about tokens, you should read this: devils-heaven.com/facebook-access-tokens
 
Ary
@luschn is not duplicate because is not the unique question
 
what is the unique question then? it´s even the exact same code.
if the question is "how to get a user token for offline usage", then just read the 2 links i posted.
 
Ary
@luschn No, in the other question I get the events, in this question I need to post because is not the same
 
it´s the same error (undefined and stuff), so it does not really look like it´s a different issue, to be honest.
 
Ary
9:37 AM
@luschn Yes it is, I need to go an event, no to get the list of users in the event.
Do you know how can I resolve my problem?
Hi @e666 are you here?
 
Yes I am here
Sorry for the issue you had with duplicate
I did not mean to open exact same question
 
Ary
no problem, I only want to resolve my issue
 
Yeah but not good for stack overflow :/
 
Ary
Do you know about my issue? I edited the post
 
@luschn is it a good practise to edit the post and answer as long as the user progress ?
 
Ary
9:44 AM
he is not in the chat
 
You need to do a post
request
 
Ary
I did, but it isn't working
I used the facebook api doc, the same and it doesn't work...
 
You are missing a permission
 
Ary
I have the correct permission I think. The rsvp_event
 
You added it to the token you used ?
 
Ary
10:01 AM
How can I add it?
 
When you ask the token
in the scope
But I haven't found how to do it with the graph explorer
 
Ary
Yes, I put it now
I forgot
But it's the same error
openfb.js:256 GET graph.facebook.comundefined/……MH6C‌​dXKnBS0uA8Bo9GdzPoACxEmAFVDnvTWNxQ9CZAwSIF1sS6l5blAZCQYUnIms5v4yzgZDZD net::ERR_NAME_NOT_RESOLVED
I have this
ngFB.api(
"/666945880120392/attending",
function (response) {
if (response && !response.error) {
console.dir(response);
}
}
);
this is the code that is in the facebook docs
 
You're still doing the same thing that before
Not using well the api method
 
Ary
It's in the documentation of facebook
I have to use the same code you writted?
 
yes with a post
can you give me the link of facebook docs ?
 
Ary
10:10 AM
yes
YES! Now works!! Thanks a million!!!!
 
Ary
10:36 AM
Can I ask you another question? It's just yes or not answer
 
sure, hit me
or that other guy...lol
 
Ary
it's about facebook
can I do in a hybrid app to login on his own facebook app?
 
btw, it´s better not to use too many plugins, like ngFB. you can easily just use the javascript sdk of facebook on your own - and learn a lot in the process. it´s just a few lines of code.
what do you mean with "his own facebook app"?
your app?
 
Ary
if you have the facebook app in your device, to login without the details of login
Show directly the page of permissions
 
i guess you are talking about "SSO"
single sign on
 
Ary
10:39 AM
yes
 
you would have to use a cordova plugin for that
because it´s native stuff, and your javascript runs in a webkit browser engine only
but for a hybrid app, you should use a cordova plugin for fb login anyway
 
Ary
but if I use this plugin to I can't attend to an event, because it's only possible with the graph API isn't it?
 
scroll down on that page, you can use the graph api with the plugin
facebookConnectPlugin.api
 
Ary
Ok I'm going to investigate. Thanks for the help
 
you´re welcome. see you around on stackoverflow ;)
 

last day (14 days later) »