Webhooks from Azure to Django. Validation problems - django

I am super stuck trying to validate (I think) the Azure end of my webhook. I have an Event Grid System Topic that is successfully updating (POST) to a dummy webhook site.
The problem is when I try to use this webhook in a view
I receive this error in Azure. If anyone has any ideas of what I am doing wrong it would be great because I have gone through 50+ stack overflow questions trying to figure it out.

Related

Django with Stripe webhooks not working with Stripe CLI, but Postman works localhost

I'm trying to implement webhooks in Django with Stripe, but I'm facing an issue where the webhook is not getting triggered after a successful purchase using the Stripe CLI. However, the webhook works perfectly fine when tested using Postman.
I've tried multiple libraries and packages, including downloading repositories for webhooks integrated with Django and Stripe, but the problem still persists. I've double-checked all the URLs and made sure that every step has been taken correctly. I'm not including any code here as I've tried many different approaches and downloaded git repos just to test the webhooks, but the problem remains the same.
I'm using Windows 11 with VSCode, Stripe CLI, Django Rest Framework, and I've even tried turning off the firewalls, but to no avail. On the other hand, when I tested the Stripe CLI with a NodeJS app, the webhook fired as it should.
Can anyone help me troubleshoot this issue and make the webhook work with Django and Stripe CLI?
The solution to the problem was to install the Stripe VSCode extension. This made the webhook work with Django and Stripe CLI.

Is AWS SNS required for Firebase Cloud Messaging?

I have a production server running an application and also a mobile app for the same, I want to use FCM as my push notification service , but what I'm seeing from the google website and most stack overflow answers is somewhat conflicting. Stack has a lot of answers on how to get FCM running on SNS, I want to know is it possible to simply use FCM (as its free) or would I need SNS , if not why bother setting up SNS for FCM? Keep in mind I only want to use FCM through an API for a django server and not through the firebase console.
The Firebase documentation is clear on how to get started, and nowhere does it state that SNS is required. Just follow the documentation for your client app platform.
If you want to send messages from your AWS backend, you can just use the Firebase Admin SDK for your chosen backend OS. It will also not require SNS.
If you are having a specific problem with FCM, you should ask a new question explaining what you've done so far that doesn't work the way you expect, along with your code and links to the documentation you're working with.

Youtube API Integromat testing app - connection getting disabled

I don't have much idea about API but I managed setup Youtube API so that I am able to use Integromat workflow between Youtube and Airtable.
It works fine.
The issue I have is the connection between my Youtube API at Integroat is getting disconnected after a few days / weeks and have to re-verify(reconnect) to Google account again.
The Youtube app was setup properly (as instructed by Integromat) and as I said it works..... it's grabbing URLs of new Youtube videos on my Youtube channel and it is pushing those URLs into Airtable.
Now have even added mysef now as the user of the app. Wasn't listed as the user there (1 out of 100). Could that be the reason?
The Youtube API is setup as a test-app. Is that the reason for the disconnects at Integromat?
Do Ineed to request Google to have the app verified? Or can I continue with the app being a test app? (Because it says it hasn't been verified).
I don't know much about what I am doing but it sees working fine for me so I guess I managed to set it up OK except for the one issue with connection loss.
Pic:
The 2nd and 3rd item on the 2nd picture is for the Youtube API connection... and that is where I am being asked every now and then by Integromat to reconnnect the connection.. then I need to login and Google wanrs me my application wasn't approved so I pick continue etc...
The issue I have is the connection between my Youtube API at Integroat is getting disconnected after a few days / weeks and have to re-verify(reconnect) to Google account again.
This is because your authorization has an expire time. Access tokens by default work for one hour. If you want your application to refresh its access then you need to request offline access and store the refresh token and then use that to refresh your access whenever you need it.
On unverified apps refresh tokens will expire after a very short time this is because your application is considered to still be in development. YOu should apply for verification when you are ready to go to production. until that time you will need to login again regularly but as you are in development this sholdnt be to much of a problem.

Facebook API page feed didn't send information to my webhook?

I'm admin of my test app, and my test page.
Now I'm doing a function get page's feed realtime by webhook, just only on development mode.
When I click test button on App's Dashboard, It has been sent to my webhook. But when I comment or like ... the post, facebook doesn't send even though I subscribed feed webhook.
With Messages, it has been sent successfully, but Feed doesn't.
I ask facebook support, so they said that:
"Applications will only be able to receive test webhooks sent from the
app dashboard while they are in development. No production data,
including that of app admins, developers, and testers, will be
delivered unless the app is live. In order to receive feed webhooks,
your app needs to be live and has to go through app review for
necessary permissions."
I understand that I can not get data from facebook even though it is under development mode.
So how can I get data returned by facebook to develop, test... apps in development mode.
Thanks so much.
It is not possible to run this service without an app review, since it is not possible to add the 'mange_pages' permission to a (test-)user within a development app. At the same time it is not possible to turn a testapp into live-mode. As the same is true vice versa the only solution is the app review to get information from a specific (test-)page.
For live testing i suggest to create a testuser and subscribe for information about the "user" to test your webhook.
You can check with GET graph.facebook.com/app-id/subscriptions, if your app is successfully subscribed to "page information". Graph API Documentation
As you already mentioned you can also send "page information" test calls to your endpoint.
UPDATE 18th Nov 2018
If you go to Webhook -> pages in your App Dashboard on https://developers.facebook.com you are able to notice, that Webhooks in dev mode do not work.
I've submitted a Bug report to Facebook for this issue, as there is no proper solution.
You can check it at : https://developers.facebook.com/support/bugs/1570460936387604/
I also don't get the fact that you can't test webhooks in dev mode, and you can't do the app review because you can't develop your app and show them for review.
Just a chicken and egg issue.

How to cancel google apps subscription through API?

From Google Apps Reseller API: Manage Subscriptions
To immediately cancel a non Google Apps subscription, use the following DELETE HTTP request with a deletionType of 'transfer_to_direct'
So, how to cancel google apps subscription ?
I have filed an internal bug to have the documentation updated and will see that this is corrected promptly. I apologize for the confusion the docs have caused you.
To clarify 'transfer_to_direct' is the best way to immediately cancel a Google Apps subscription and transfer the customer to a direct relationship with Google. Customers are given a short window of 'free' service.
TL;DR: 'transfer_to_direct' can be used for Google Apps subscriptions