# Payment Failed

Kindly be aware that if a user attempts payment multiple times, all corresponding entries will be activated within this webhook. To prevent multiple communications on your end, please ensure appropriate checks are in place.

Payment failures can occur in two scenarios: 1) When a user initiates a payment but does not complete it, the payment\_status field in the webhook will indicate 'initiated' 2) If a user attempts to complete the payment but it fails due to any reason, the payment\_status field in the webhook will show 'failed'.

## For all offerings

```
curl --location `${WEBHOOK_URL}` \
--header 'apikey: ${YOUR_API_KEY}' \
--header 'Content-Type: application/json' \
--data-raw '{
   "Name": "Abhishek", 
    "Amount": 2, // In INR
    "offer_code": "Republic30", 
    "offer_id": "65aa4e1327f9931ac61d9fef",
    "offer_discount": null, 
    "Email": "app@rigi.club",
    "Phone": "+91123456789",
    "Product": "How To Crack Your First Five Clients",
    "Link of Product": "https://rpy.club/jcp/example-1",
    "Time": "Jan 19, 2024 10:36 AM",
    "ref_id": "order_NQRMSFjAj4kCm6",
    "event_type": "payment_failed",
    "payment_status" : "initiated", // or "failed"
  }'
```

## For Cart Payment

```
curl --location `${WEBHOOK_URL}` \
--header 'apikey: ${YOUR_API_KEY}' \
--header 'Content-Type: application/json' \
--data-raw ' {
    "Name": "SHIVA",
    "Amount": 52038,
    "offering_type": "Cart",
    "Phone": "+91123456799",
    "Email": "app@rigi.club",
    "event_type": "payment_failed",
    "Time": "Dec 26, 2024 6:36 PM",
    "extra_details":{"type":"mag","linktok":"11939"},
    "Products": [
      {
        "name": "Offering 1",
        "offer_code": "ABCD",
        "offer_id": {
          "$oid": "65aa4e1327f9931ac61d9fef"
        },
        "offer_discount": 10,
        "amount": 52038,
        "group_id": "65aa4e1327f9931ac61d9fef"
      }
    ]
  }'
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.rigi.club/webhooks/payment-failed.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
