I have set up a basic install of XMPPHP and to test it I tried sending a message from one of my gtalk (GoogleTalk) accounts to another gTalk account. The receiving account did not show the message, or the normal "user * has sent you a message: accept/block"
I then sent my receiving account a chat message from within the Google interface, and it prompted me (as expected) to add my account to the list of approved chat people.
Once my sending account was on the "approved" list, i was able successfully to send messages with xmpphp with no problem.
My question: Using xmpphp, how do i send an INVITATION to chat? I can send messages fine once the recipient accepts my incoming chats, but the first message sent does not trigger the chat program to prompt me to accept the messages.
As a follow-up...is there a way to find out if the recipient has accepted the request? ANy way to know that the messages are being delivered (or not)?
I had the same problem and the solution is to send a "subscribe" request before the message.
So just call
$conn->subscribe('someguy#someserver.net');
before
$conn->message('someguy#someserver.net', 'This is a test message!');
Related
I am trying to send a message through WhatsApp using WhatsApp Business API, but it doesn't work.I created a new whatsapp application on the Facebook developers page. I entered my own phone instead of the test phone from the "Getting started" page. I'm trying to send a message with the sample api found on the "Getting started" page. I press the 'Send Message' button. I get the response "Message sent successfully". I can see that messages are sent in the statistics section on Facebook Business (https://business.facebook.com/wa/manage/insights/). However, messages do not come to the specified phone number.The messages I sent are not being delivered. "The first 1000 messages initiated by the business are free." specified as. So I should be able to send messages without a message problem. I have not made any payments as of now. It also asks me to add the receiving phone when I want to try the "Test number". The recipient sends a verification code when adding their phone. However, the verification code is not coming to the phone. Where am i doing wrong?
here are my results
Platforms like upwork have a feature where when you get a message through those platforms, you also get an email.
Instead of logging Upwork to reply, the user can simply reply to the incoming email, and the message is then automatically sent by upworks backend to the original person who sent the message.
How exactly is this done in a way that Upwork knows the inbox to send the message to, and is able to receive a message via email.
It seems Upwork handles incoming emails by detecting any project ID in the email message - it can be an ID in the subject or in the email body and etc. So, the email can be recognized easily and processed. Also additional information can be checked on the incoming email - the sender (whom the original emails was sent out), the recipient and etc. Actually, it is up to your needs how algorithm should be working.
I will name my firstborn after whoever answers my question!
My bot uses the Handover Protocol to transfer users from the bot (primary receiver) to the page's inbox (secondary receiver) after they tap on a 'chat with human' button, the problem is that I'm not getting any facebook notifications when the user starts messaging a human (page inbox).
Right now I'm having the bot email me anytime it transfers a user to a human but this fix obviously doesn't scale, ideally I would want facebook to send me notifications on my phone just like it does by default to pages that receive messages and don't have any bots installed.
I know I can see the messages sent to a human by using the 'standby' webhook but those are developer-side server logs, what I want are normal facebook notifications sent to the page owner and the people in the page's Roles so they reply to those messages instead of me (the developer) being the only one being notified through emails I have to send myself.
1.You have to go to Your Page--> Settings--> Notifications--> Select this option
from Messages- "Get a notification each time your Page receives a message".
2.Download "Facebook Pages Manager" App to get all your page related notification
on your phone.
I am working on xmpp framework. I have done most of initial things. I created stream, Connected it and get authenticate. Now I am sending buddy request to another user from my app. App shows presence is sent. When I get roster it shows a entry there. But on other system I am not getting any precence or anything. I tried to send a message message is also not received by other client.
Than I used one id in ichat and send friend request to that id. Wow I am able to see friend request on ichat. I accept request from ichat :( No notification on my app.
If I send message to ichat. Message shown in iChat. but when I send message to my app from ichat.. My app is not getting any delegate called or nothing.
I don't know why this is happening.
I am using a non ARC xmpp framework.
Please guys Please help me. I am badly stucked in it :(
Thanks in Advance.
Have you consider to send presence after get authenticate?
If you are authenticate but not sending preence than server will consider you offline and all messages sent to you will be stored on server with delay.
Send your presence and see the magic. :)
I am not an iPhone developer so i can not explain programming.
In XMPP, Presence subscription has two handshakes. Like When first user send request to second user , it will ask for presence subscription to second user. When second user accept , then first user is subscribed for second user's presence. So he can get all the presence of second user. It's called "to" subscription type for first user. Now second user ask for presence subscription to first user and first accepts request then this "to" subscription type changed to "both" subscription type. Now both user can get presence of each other. otherwise only first user can get presence of second user.
And for messages, there must be a some prob with listener.
In Google Talk, how to send a message to person that is not in my friend list?
I work on an application that notify customers of a bank about change of their accounts. When I send a message to a person not in my list, no error is created, but the message isn't delivered to the recipient.
Because of design issues it is not suitable to send an invitation to customers and store information about their responses to it.
You can message a user directly using XMPP without an active presence subscription (the requirement for an item to appear in your roster), but most clients (Google Talk clients included AFAIK) will discard the message upon reception, if the from header does not match a bare JID in their roster.