# Log every captured Razorpay payment to Sheets and Slack

> The moment Razorpay captures a payment, we add a row to your revenue spreadsheet and post a short confirmation to your team's Slack channel.

- Workflow type: code
- Services: Razorpay, Google Sheets, Slack
- Categories: Finance, Operations
- Published: 2026-08-09

## What it does

- Adds one row to your revenue spreadsheet the moment Razorpay captures a payment, holding the payment and order reference, the amount, the currency, the payment method, the customer email and phone number, your own notes, and the capture time.
- Converts amounts from paise into rupees and turns the capture time into a date you can actually read, so the sheet is ready for reporting instead of needing cleanup.
- Posts a one-line confirmation to your Slack channel naming the amount, the payment method and the customer, so the team sees revenue land without opening a dashboard.
- Keeps the spreadsheet row and the Slack message independent, so a Slack outage never costs you the ledger entry.

## What you'll need

- A Razorpay account, with permission to add a webhook in the dashboard so Razorpay can notify us the moment a payment is captured
- A Google account and a spreadsheet you want to use as your revenue tracker
- A Slack workspace and the channel where confirmations should be posted

## Prompt

Every time a Razorpay payment is captured, log it and tell the team, with no judgement calls in the loop. Trigger this on a Razorpay webhook for the payment captured event, so the workflow runs the moment the money is confirmed.

First, append one row to my Google Sheets revenue tracker using Append Values. The row should hold the payment id, the order id, the amount in rupees, the currency, the payment method, the customer email, the customer contact number, the notes field, and the capture time as a readable date.

Then post a one-line confirmation to my Slack channel using Send a Message, naming the amount, the payment method and the customer. Keep it to a single line that a revenue channel can scan without opening anything.

Two fields in the Razorpay payload need converting before anything is written or posted. Amounts arrive as integers in paise, so divide by 100 to get rupees, and apply that to both the sheet row and the Slack message. Capture times arrive as Unix epoch seconds, so format them as a human readable date and time rather than writing the raw number.

Razorpay ids are prefixed by type, pay_ for payments and order_ for orders, so write them through unchanged as text. The notes field is a free form object of up to 15 key value string pairs, so flatten it into something readable for a single cell rather than dropping it. Razorpay does not always collect an email or a contact number, so when either is missing write an empty cell and carry on rather than failing the run.

Keep the sheet append and the Slack post independent of each other. Append the ledger row first, then post to Slack, and make sure a failure posting to Slack never rolls back, blocks or retries the spreadsheet row. A Slack hiccup should never cost me the ledger entry.

## How to customize

- Change which columns land in the sheet, or add your own such as a team name or invoice number taken from the notes you attach to payments in Razorpay
- Point the confirmation at a different Slack channel, or reword it to include the order reference or a link to the payment
- Only announce payments above a value you choose, so small transactions log quietly to the sheet without pinging the channel

## FAQ

### Does this catch every payment, or only card payments?

Every payment Razorpay captures, whatever the method. Cards, UPI, netbanking and wallet payments all flow through the same way, and the method is written into its own column so you can compare how customers actually pay.

### Why do the amounts in Razorpay look a hundred times too big?

Razorpay reports amounts in paise rather than rupees, so a 500 rupee payment shows up as 50000. This workflow divides by 100 before anything is written, so your sheet and your Slack message both show the real rupee value.

### What happens if Slack is down when a payment comes in?

You still get the spreadsheet row. The ledger entry and the Slack confirmation are deliberately kept independent of each other, so a problem with Slack never costs you the record of the payment.

### Can I test this before pointing it at real money?

Yes. Razorpay has a test mode with its own keys, so you can connect it in test mode, run a test payment through, and confirm the row and the message look right before switching over to live payments.

### Can this run on a schedule instead of instantly?

Yes. If adding a webhook in Razorpay is not an option for you, ask for a version that checks for new captured payments every hour and logs any it has not seen yet. You lose the instant confirmation but keep the ledger.

Use this prompt in General Input: https://www.generalinput.com/prompts/log-every-captured-razorpay-payment-to-sheets-and-slack