The latest Facebook iOS SDK (3.2) includes native methods for sending AppRequests to a user's friends via the FBWebDialogs class. Does it have any way to filter the recipients' list to friends that use iOS devices? Does Facebook keep any sort of database with these relationships?
Answering my own question - you can add 'devices' to the 'fields' parameter when querying the user's friends, create your own custom friend picker for app requests which parses users based on their devices, and send the list you build as a parameter to apprequests.
Related
I'm creating a headless WooCommerce application and I need to create a booking for a bookable product via an API request in Node.
Woo bookings shows this on their docs - essentially it says don't use - then I raised a ticket with the Store API team here - the answer appears to suggest we add the data ourselves, that's not good as we're then running a custom version of Woo.
Does anyone know how I can make a booking in WooCommerce via an API endpoint? It must have SOME kind of API or the frontend wouldn't work?!? It's handy to have because it means the customer runs what they've always run and get all the nice stuff like reminder texts and emails for their customers.
I have a mobile app where people store their contacts. I want to be able to sync these contacts with the phone so if anyone calls my users they would have the name in the address book and show it when getting the call.
I was thinking about implementing carddav or similar protocol, so my users could add this account to their phone and sync with it (it would be read only). I thought it was easy with just returning an xml for a certain endpoint with basic auth, but I'm not finding examples.
Other idea was that I run a carddav server and both my backend and the user could connect to it. My backend would fill it for the user and my user could sync with it from his phone.
I would prefer the first, implementing my own endpoint. Would it be enough if I just reverse engineer the carddav endpoints and build up the xml results on my own? Any guides or very easy implementations? Of course I won't need the full specification implemented for this. My preferred environment is nodejs but if it's an easy implementation of course I could bring it over from other languages.
I would like to find out how, using Node.js, Express, Typeorm I can send notifications at random times to users to add a post etc.
I would like to create something of the BeReal sort. Notifications should be sent according to the user's selected time zone at random times.
If you want to send automated notifications, I'd recommend using
node-cron. However, for your case, I'd propose to add a timeZone
indicative information in the database to link the user with the
timeZone(you can find it in HTTP Requests, update it after each
login).
For the actual sending of the notifications, I think you should use
some third party service like Google Firebase for mobile
notifications, and web-push for web applications.
In our website, we need to achieve a seemingly simple task: Enable the user to send a specific text to all or some of his/her Gmail contacts (including contact selection).
We don't actually need the contact data itself. We prefer some kind of "Gmail Plugin" (if there is one) that asks the user to login and does all the work. Alas, we couldn't find any.
We did find several different Google APIs related to this task. Some of them seem to give us contacts data. Others seem to handle sending email:
There is "Contacts API" under
https://developers.google.com/google-apps/contacts/v3/...
There is "Contacts Service" under
https://developers.google.com/apps-script/reference/contacts/...
There is "Gmail Service" under
https://developers.google.com/apps-script/reference/gmail/...
There is "Gmail Platform Integration" under
https://developers.google.com/gmail/...
Each of the above looks different and there seems to be much overlapping between them.
So what is the recommended method to achieve our original task? Is there a plugin that does it all? If not - should we use separate APIs for getting the contacts data and sending the emails, or are there Google APIs that combine both sub-tasks? In case those are separate tasks - is it possible to email via Gmail, or are there other recommended services for the email sending part?
To directly answer your question: you must use the first API you pointed, Contacts API under https://developers.google.com/google-apps/contacts/v3/.
Basically, you want to use the Google Contacts API with OAuth2 authentication in your website: user will be prompted by Google to allow your website to read user contacts.
First, read a bit about OAuth2 authentication flows here: http://alexbilbie.com/2013/02/a-guide-to-oauth-2-grants/
Second step: register your app on Google Console and get your key/pass for the Contacts API (you'll need contacts.readonly permission): https://console.developers.google.com
Then, as you'll use the OAuth2 for Web Servers, check this Google documentation: https://developers.google.com/accounts/docs/OAuth2WebServer
Alternatively, you can use third part libraries to easily import contacts to your website. There are free libraries, like PHP OpenInviter.org, Ruby OmniAuth gem, and paid alternatives, like CloudSponge.com (multi-language).
Disclaimer: I work for CloudSponge.com.
You could achieve this as you say with Google APIs and a Chrome Extension for example.
The user can add a Chrome Extension from the Chrome Webstore. The Extension will provide the user with a user interface to allow them to compose their message and send to the selected contacts.
The users contacts can be retrieved with the Google Contacts API.
The message can be sent to the selected contacts with the Gmail API.
There is a lot of documentation and examples for all of the above which together will give you what you want.
Depending on how much use this is going to get, you could use a contextual gadget which is browser agnostic - but visible in all emails in Gmail.
This is wrong the idea is to post the text to buffer a and submit pointer to array on buffet a and copy it to class b pointer a 0 than release the array and buffer so new allocation can be done
Can we send SMS programatically by selecting group from the address book using J2me?
yes... it is possible to have access to the users phonebook (if supported on the device(most modern devices do allow it)) via PIM(JSR 75).
And sending SMS's from j2me is also possible(again if the user allows this).
It turns out you can only send a single message to a single recipient at a time using JSR-205.
If you want to send the same message to many recipients, you have to loop around
javax.wireless.messaging.Message.setAddress();
javax.wireless.messaging.MessageConnection.send();
There is no way to add a javax.microedition.pim.ContactList to a Message or to a MessageConnection because there can't be any API dependancy between JSR-205 and JSR-75.
The latest JavaME SDK contains example code that shows how to read contact data in a MIDlet.