Meldiron / appwrite-webhook-proxy

A simple HTTP server behaving as proxy between webhooks and Appwrite Functions.
30 stars 2 forks source link

doesn't write an order into appwrite #3

Open j2l opened 2 years ago

j2l commented 2 years ago

First of all thank you for this proxy!

There are so many parts, I'll try to make it as clear as possible. I set everything according to your article. Everything is running on docker locally. Database Orders is populated with attributes and indexes through your script. I can directly reach this webhook-proxy server with postman at http://0.0.0.0:8079/v1/webhook-proxy

When ordering, Stripe CLI (local proxy for webhooks) is connected with Stripe and send events to the proxy:

2022-04-04 18:39:45   --> payment_intent.created [evt_3KkswPJ5qmHdQM1Gk2Wf3f]
2022-04-04 18:39:45  <--  [201] POST http://0.0.0.0:8079/v1/webhook-proxy [evt_3KkswPJ5qmdQM1Gk2Wf3f]
2022-04-04 18:40:17   --> customer.created [evt_1KkswuJ5qmHdQMyEWl6uxk]
2022-04-04 18:40:17  <--  [201] POST http://0.0.0.0:8079/v1/webhook-proxy [evt_1KkswuJ5qmdQMyEWl6uxk]
2022-04-04 18:40:17   --> payment_intent.succeeded [evt_3KkswPJ5qmHdQM1qfTZeVs]
2022-04-04 18:40:17  <--  [201] POST http://0.0.0.0:8079/v1/webhook-proxy [evt_3KkswPJ5qmdQM1qfTZeVs]
2022-04-04 18:40:17   --> charge.succeeded [evt_3KkswPJ5qmHdQM1yvzVRhL]
2022-04-04 18:40:17  <--  [201] POST http://0.0.0.0:8079/v1/webhook-proxy [evt_3KkswPJ5qmQM1yvzVRhL]
2022-04-04 18:40:17   --> checkout.session.completed [evt_1KkswvJ5qmHdQMUKRvGB9k]
2022-04-04 18:40:17  <--  [201] POST http://0.0.0.0:8079/v1/webhook-proxy [evt_1KkswvJ5qmQMUKRvGB9k]

(evt_ serials are modified)

But no Order (Orders/Document) is added to the backend. The webhook-proxy logs (std output, no file found) doesn't show anything.

Any idea? Would it be possible to add logs on this server to understand what it tries to do?