Google doesn't send Push-Notifications - push-notification

I'm using Google Calendar API in my application.
The problem that I faced is that Google doesn't send me Push-Notifications.
I setup my app here https://console.developers.google.com/
Verified domain: https://console.developers.google.com/apis/credentials/domainverification
Watched calendar: https://developers.google.com/calendar/v3/reference/calendarList/watch and got successful response.
However, having done all of this, no push-notifications are received by my web-hook. It seems that Google just doesn't send them. Maybe I missed some step? I use https URL.

The problem was that the URL that I used for PUSH-NOTIFICATIONS wasn't whitelisted and if it was requested from other network(e.g. Google), then the request couldn't be processed.
Therefore, if there is such a problem, consider checking your URL availability outside your network. It should be accessible from anywhere and by anyone.

Related

How can sniff Firebase Events?

I'm using Charles Proxy as Sniffer to check and verify the body/payload of my Firebase Events?
I see the POST request to firebaselogging-pa.googleapis.com/v1/firelog/legacy/batchlog in Batch, and in each event, inside the POST request, I found the sourceExtension attrib, that I think constains all the event data, but I cant to decode, I tryed with base64 and bytes, but I cant see the content of the property.
I know the documented way to check firebase events is thourght the web portal in debug view, but this question is about how to see the content in the request before it arrive to the google cloud.
I saw another related post in Stackoverflow, but without any answers:
See Firebase network traffic in debug purpose
Anyone know how to sniff Firebase events and decode correctly? thanks in advance.

Getting r_fullprofile access to the Linkedin API

I am currently using a linkedin API with r_lightprofile in my application.
Two months ago, I sent a request for access to r_fullprofile using the Partner Program form.
https://business.linkedin.com/marketing-solutions/contact-us
http://prntscr.com/opfnpd
I also sent a request to the Marketing Developer Platform, but the request is still pending (http://prntscr.com/opfvfx)
After all this, I got an email with a form to fill out information about the company.
But after filling out the form, I did not receive an answer that the company is suitable or not suitable for full access.
1) How long does it usually take to get access?
2) Does the linkedin API have support? Email, Live chat or something else?
3) Have I done everything for access? Maybe I missed something?
4) Does Linkedin send an email in case of failure?
It's been a long way for me too, I'll give you some random tips:
Make sure your app is connected to a LinkedIn company page and that the status is Verified. To do this, from the app dashboard, add to the Team members an administrator of the LinkedIn company page (as Admin member) and let him access the app dashboard. He should be able to see a Verify button to confirm the authenticity of the app.
The only support that was really helpful to me was Zendesk.

How to properly initiate an OAuth flow for Gmail Watch?

I'm trying to initiate Gmail Watch on behalf of my site's users and also get the messages according to what historyId I get on the corresponding PubSub Topic.
I have GCP + Firebase on the backend and Angular 7 in the frontend.
I face two problems here:
Doing this on the frontend seems the right way, with grantOfflineAccess, since it asks nicely on the consent screen for the required Modify scope. However, what I get back is an auth code, and I can't find out how to get access and refresh tokens from it, and use it in the backend Cloud Functions python part.
If I try this on the backend (which works), I have to initiate the flow from python, send the redirect to Angular and pop-up the consent url there. This already seems bad, since the consent screen does not say anything about what you're granting. Then I need a redirect url, which can't be a Cloud Functions url, because I can't whitelist it (can verify the domain), so it is now handled on the Angular side and sent back. Ie. the my oauth redirect is handled in the frontend, which also doesn't seem the right way.
Could you please advise on how to do this properly?
Thanks!

LinkedIn New API - Can't Get r_network Permission

I inherited a program that was written with the old LinkedIn API, and I'm trying to migrate it to the new API. When I try to get the r_basicprofile permission, my oauth token works. However, when I try r_network or rw_nus, I get a response
invalid scope -- your application has not been authorized for
r_network.
Yet, when I go to www.linkedin.com/developer/apps/xxxx/auth, the boxes for r_network and rw_nus are checked.
I.e., A request to
https://www.linkedin.com/uas/oauth2/authorization?response_type=code&client_id=xxxxxx&scope=r_basicprofile&state=yyyy&redirect_uri=http%3A%2F%2Fkalatublog.com%2Fwp-content%2Fmu-plugins%2Fimb-en%2Fhelpers%2Fsocial-connect%2Fapi%2Ffinalize.php%3Fapi%3Dlinkedin%26ch%zzzzz
works, but a request to
https://www.linkedin.com/uas/oauth2/authorization?response_type=code&client_id=xxxxxx&scope=r_network&state=yyyy&redirect_uri=http%3A%2F%2Fkalatublog.com%2Fwp-content%2Fmu-plugins%2Fimb-en%2Fhelpers%2Fsocial-connect%2Fapi%2Ffinalize.php%3Fapi%3Dlinkedin%26ch%zzzzz
gives that error. What am I doing wrong?
As of May 15,
After the grace period expires, several REST API endpoints will no longer be available for general use. The following endpoints are the only ones that will remain available for use:
Profile API — /v1/people/~ `
Share API — /v1/people/~/shares
Companies API — /v1/companies/{id}
If your application is currently using any other API services (e.g. Connections, Groups, People Search, Invitation, Job Search, etc.) you will have to apply to become a member of a relevant Partner Program that provides the necessary API access to continue to leverage any of the endpoints that are not listed above.
It looks like linkedin no longer wants to share anything with their API. Creating a new app indicates that the only possible options are r_basicprofile, r_emailaddress, rw_company_admin, and w_share:
TLDR: they have locked down the API and restricted the usage to an extremely limited set of access points.
I did some more digging. The linkedin website is misleading. On my app linkedin page, it says that I'm approved for rw_nus and r_network, but on this page
https://developer.linkedin.com/support/developer-program-transition
it says those are no longer approved.
So the app home page in linkedin incorrectly said I had those permissions.
Heres the link if you want to Apply for Linkedin
https://help.linkedin.com/app/ask/path/api-dvr

Google calendar API calls blocked by captcha

I have successfully written a tool to display upcoming calendar events on a website using Google's calendar API (v2). I am using the username/password method outlined at https://developers.google.com/google-apps/calendar/v2/developers_guide_dotnet#AuthClientLogin. Today an instance of this code would not return data or a decent error message. I finally logged into the web server and browsed directly to http://calendar.google.com and logged in using the credentials. I was challenged by Google's captcha and then my code worked.
How do I get around API calls being blocked by Google's captcha security? I don't want to have to re-code for magic cookies but I will if I have to. I have read some about generating tokens but I dont know if that is something I have to do once or every time the code is called.
If your app is a service that is getting used by many people, you might be running into API call bandwidth limitation. That is, google is limiting the number of API requests per time interval.
If this IS getting used by many people, you may have to upgrade to a paid account.

Resources