I am hoping to create a slackbot which when it's asked something to respond with a question and listen for an answer to that specific question, only when its asked though.
For example
User: #Hubot Please add a link to youtube
Hubot: #User Can you please post a link to youtube
User: #Hubot youtube.com
Hubot: #User A link to youtube has been added
However I don't hubot to always listen for a url to be posted to it, I only want it to listen for a url after its been asked to add one. Hubot will timeout after a certain amount of time if a url hasn't been sent to it.
For example
User: #Hubot Please add a link to youtube
Hubot: #User Can you please post a link to youtube
Hubot: #User Timeout: 1min url not added, you will need to add link to youtube again to save
The plan is to save the website name and url to the brain and when its asked for the website hubot will post the url. It is only the conversation part I'm having trouble with.
I looked into this functionality for our Hubot a few weeks ago, but haven't got back to actually building it. This is the module I was planning on using:
https://github.com/lmarkus/hubot-conversation
Related
In facebook site you able to make a comment and attach image to it. Is it possible to do the same things with facebook api?
I have read this facebook for dev link and there is no answer to my question.
If you read the documentation properly, it says-
message is the only parameter in this API call. It should be a string containing the comment text.
So, using the API you can just comment a message to the object using-
POST /{object-id}/comments?
message='This is my message'
, no link/picture could be attached alongwith.
I don't know if it is a recent change in the way Facebook handles this, but if I put the complete url in the comment, Facebook detects it as an image and shows it there (along with the url).
Maybe it's not the cleanest way, but it's a way.
Hei,
I am wondering if this is possible:
I have a page of my own where I occasionally post. What I want is that when ever I post something facebook does a POST to a url of my choice.
I guess real time updates for pages in the graph API would let me achieve this ? am I right?
https://developers.facebook.com/docs/reference/api/page/#realtime
If so then how do I do this ? I have been trying to make sense of it but I don't seem to be able to get it working. I created an app but I don't understand how to connect the dots together here.
In my app's Real Time updates panel I have create a subscription for object 'Page' for fields 'feed', I have specified callback url as well. But now I am confused on how to connect the app with the page ?
Even though I have made the app a 'page tab' app but I can not find out a way to add the app to my page's tab ??
please help !
-A
I found the answer to this here:
https://developers.facebook.com/docs/reference/api/page/#realtime
On my website, I just added links to discuss posts on Facebook; you can see such a link at http://jonathanscorner.com/steel/ . The link redirects to https://www.facebook.com/pages/CJS-Hayward/9506801167, which lets people post but is initially empty.
I would like, if possible, to create a link that prepopulates the text of the comment to include the title and URL on my site. So someone who clicked on that link would have a posting that is prepopulated, '''I just finished "Within the Steel Orb" at http://JonathansCorner.com/steel/. '''
Is there some URL parameter I can use ('''...?text=I%20just%20finished...''') or other interface to prepopulate a comment in a JavaScript-generated link?
Thanks,
Short answer, you can't. Even with the feed dialog you can't prepopulate the comment area with some pre-defined text. What you can do is, using the feed dialog making people write their comments, and the connection of that feed redirects to your website.
The only problem is that this feed dialog would appear on the users feed an not on your page wall.
Another way, and this is the best option in my opinion, add the comments social plugin to your site, this way people would discuss that article on your page and every time they comment using this social plugin, the comments would appear on their facebook wall making their friends curious about that and maybe visit your site.
You can read more about that here: https://developers.facebook.com/docs/reference/plugins/comments/
This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
How can I move a URL via 301 redirect and retain the page’s Facebook likes and Open Graph information?
I run this blog http://everythingyoumightneed.blogspot.comI am thinking of moving my blogspot blog to a custom domain. I did some research and I found out that if I do so I will lose all my G+ plusones and Facebook likes for my posts. Same thing with Facebook comments. (I have Facebook comment social plugin on each post of my blog)
My question is, whether there is a way, using to avoid this
You cannot change the url associated with the comments. You can, however, modify the code on your new site so that each post points to the comments page for the old url.
on each page on the new domain this will associate the facebook comments with the old domain:
<fb:comments href="THE-OLD-URL"></fb:comments>
So for example for http://newdomain.com/thenewpage.html:
<fb:comments href="http://olddomain.com/theoldpage.html"></fb:comments>
To get this working, first get facebook comments working on your new site using the facebook documentation. Once you have that working, you can put the code above anywhere on the page (I usually put it in the head somewhere). That will tell facebook to use the old url instead.
This will apply to likes, comments, and everything else.
I have created a static webpage and have included facebook comment plugin.
A person commented but i did not receive any notification in facebook or in my email.
What should i do to get notifications to my email when people post using facebook comment?
do i have to do something like this
FB.subscribe('comment.create', function(response){
//make an ajax request to a server side script
// and in that i can send a mail to my email... isn't it?
}
});
since that page is totally html i dont want to use any more javascripts yet if needed then i will have to use.
so is that the way to notify myself when an user posts a comment using the facebook comment plugin...
in the official documentation (http://developers.facebook.com/docs/reference/plugins/comments/) it says in the FAQ part:
How do I know when someone comments on my site?
You can subscribe to the 'comment.create' and 'comment.remove' events
through FB.Event.subscribe.
so yes, you will need to use this method to be notified on comments.