I want to develop a bot which will update the status of a facebook account using php.
Please guide me on this
#Porkchop is correct, you will probably need the Facebook Connect API. To update a users status on Facebook, you should look at the Status.set API call.
For coding a googletalk bot in php there are some articles that should get you started:
Twitter PHP Jabber Bot Tutorial
Jabber Simple - A PHP library
But also consider using IMified, which does a lot of the work of creating and running chat bots for you.
If all you are interested in is a simple way to update your Facebook status from you Google Talk status, you probably don't need to go to all that work - just install the 'Google Talk Status Synchronizer' facebook application.
You could hire somebody to do it for cheap by outsourcing it, i mean thats what i do when i dont know code.
Since you are coding in PHP, I recommend using Jaxl (Jabber XMPP Library).
It supports bot authentication using X-FACEBOOK-PLATFORM and updating facebook status should be a one line task using the library. http://github.com/abhinavsingh/JAXL
Related
i am currently working on a Project with Firebase and i am trying to Implement the Firebase Cloud messaging service. I manage to make it work with a combination of PHP and Javascript (Javascript sends a Requiest to the server, where php makes a call to the Firebase API to send out a Notification).
The problem here is, that the code i use is for the old version, so its not using the HTTP v1.
When i looked at the docs on how to upgrade to the new version, i found out you need a short-lived OAuth 2.0 access token.
Thing is, the docs only show how you can get it via node.js, java, python, c# and go.
So my question is, is there a way to get the short-lived OAuth 2.0 access token with php or do i have to use something like node.js for it?
I'm not sure I fully understand your requirements, but if you want to send FCM notification from a PHP backend, I'd suggest checking out this (unofficial) Admin SDK for PHP (Disclaimer: I'm the creator of that library)
In its current state, you would need a Firebase Service Account (with Admin access) to be able to send notifications with it, but I'm currently working on a feature that will allow you to retrieve an OAuth access token for a given user (https://github.com/kreait/firebase-php/pull/390) in case you really need this.
I'd like to invite you to join https://discord.gg/nbgVfty (the Discord-Community around the PHP Admin SDK) to discuss your use case and process further.
Even if the SDK is not for you, looking through the code might could give you some ideas...
An alternative could be to use the Google PHP Api Client Services library, in which you can find a FirebaseCloudMessaging service.
I hope this helps!
My client would like a twitter feed that just shows her most recent tweet on her Shopify site. She needs it to be more customizable than the current standard widget provided by Twitter is.
There is a Shopify app that someone built for a monthly fee that does this, but I'd like to build it on my own.
I have already built a stand-alone solution with the Twitter API and twitterOAuth PHP library. Since I can't run the PHP on Shopify, I figured I need to build an app.
Just wanted to see if I'm on the right track or if there is a better way to do this. Thanks in advance.
If you can handle Twitter oAuth, then clearly you can handle Shopify oAuth. As per what we can barely call standards, it turns out using oAuth is pretty much the same between all these services. So Shopify oAuth is going to pose no trouble for you. Hence it is relatively easy for you to create an App in PHP in the cloud, that scrapes Twitter, and provides said scraped Tweet to Shopify.
My customer asked me to develop a web app which include function chat with facebook but as I know, the Facebook Chat API and XMPP things has been deprecated since 04/30/2015.
But the function chat with facebook on Skype still working. Are there have any other approaches beside Facebook Chat API? I would like to hear an clear answer to explain for my customer.
No, there is no alternative to the Chat API. It has been removed and there is no way to implement chat in your App anymore. Skype may have a special deal with Facebook, or they are not upgraded to v2.0 yet - it´s a process that is still going on afaik.
I want to start developing a tool that runs daily via cron for getting daily analytical data from one channel, or video, etc.. through the "Youtube Analytics API". And not what is the best way to approach it.
I have read the documentation of Google and and I have several questions:
I created the project in the console (https://code.google.com/apis/console/) but I doubt what kind of application I have to choose when I create a Client ID (Web Application, Service Account or Installed aplplication).
What PHP library use?
It's a very new API and not much information.
In the Google GData site there is a warning about that "Most newer Google APIs Google Data APIs are not Google Data APIs." and in the google-api-php-client, no examples of this API.
What is the best method for authentication in a cron?
As you can see I am very confuse, can someone help me, please?
Thank you.
1) It will be an installed application unless you will run it in a web server.
2) Use the official library, add the ytanalytics php library. Samples: https://github.com/youtube/yt-samples-php
3) You can do so by getting a refresh token from OAuth2 Playground and setting it in your youtube object.
Here it explains a little more.
And a step by step video.
I'm wondering how Boxcar works, anybody knows? I know how to do the push notification from server to iPhone, but I have no clue of how to create the server to get the #reply and dm from twitter in real time. Any suggestion on what I should look into to create the server? Should I use Twitter's streaming API or User Streams API?
Any sample code, in PHP preferably, will be great :) Thanks!
Currently the only way to get mentions and DMs in realtime for more then a single user is the Site Stream API. You can use the Phirehose library with the OAuth/userstream patch to connect. Unfortunately Site Streams is currently in closed beta and you may not be able to get access for a little while.
Otherwise you pretty much have to poll the REST API frequently to simulate realtime.