Live Loop returns analytics with product-level drill-down

By General Input

Pick any date range up to 120 days and see return volume, refund versus exchange mix, and the products behind every number, recalculated each time you open it.

Integrations

  • Loop Returns
  • Google Sheets
  • Slack

Type

App

Categories

  • Operations
  • Product

Build me an app I can open any time to analyze my Loop Returns data, instead of waiting on Loop's own reports. Loop's reporting can take six to eight hours to populate and struggles to load on large date ranges, so the whole point of this app is that it computes straight from the returns API on demand and lets me drill into the returns behind any number.

The main screen is a returns analytics view for a date range I pick. Give me a date picker that defaults to the last 30 days and enforces a maximum range of 120 days, because Loop's Detailed Returns List caps the from-to window at 120 days. Always send explicit from and to values, since Loop defaults to only the previous 24 hours when no range is passed.

To load a range, page through Detailed Returns List with paginate=true and a pageSize near the maximum of 750, following nextPageUrl until it comes back null. Loop allows 300 requests per minute per API key, so cache the computed result for each date range and reuse it as I sort, filter, and drill down, rather than refetching on every interaction. Loop's responses are additive only, so tolerate fields you do not recognize.

Alongside the selected range, fetch the immediately preceding window of the same length in a second pass, so every headline number and every table row can show a period-over-period comparison with the change expressed both in absolute terms and as a percentage.

At the top of the screen, show headline numbers for the selected range: total return volume, the mix of refunds versus exchanges versus store credit, and total refunded. Each one carries its comparison against the prior period.

Below that, show three breakdown tables: by product, by variant, and by return reason. Each row shows return count, total refunded, the refund versus exchange versus store credit split, and the change against the prior period. Let me sort each table and search within it.

Every row drills in. Clicking a product, variant, or reason row opens the individual returns that make up that row, and clicking a single return shows its full detail from Get Return Details plus its notes from Get Return Notes, so I can read what the customer selected and what my team wrote.

Two buttons act on whatever is currently on screen. Export to Sheets creates a new spreadsheet with Create Spreadsheet and writes the headline numbers and all three breakdown tables into it with Append Values, then shows me the link so I can pass it to the merchandising team. Post to Slack sends a snapshot of the headline numbers and the biggest movers to a channel I choose, using Send a Message.

Each product row has a Diagnose this product button that starts a background agent scoped to just that product. The agent reads that product's returns in the selected range along with their reasons and notes (Get Return Details, Get Return Notes) and the product and variant context from Loop (Get Product, List Product Variants, Get Product Variant), then writes a short diagnosis of why the product is coming back and one recommended fix. Save that output in the app against the product and display it next to the product row along with the date it was generated, so it persists after the run finishes and I can regenerate it later. Show a running state on the row while the agent works.

Loop returns money as an integer amount in minor units plus a currency code. Format every amount as real money with the correct currency symbol everywhere in the UI, and never show raw cent values.

Related prompts

Explore more prompts
Call overdue Xero customers with an AI collections agentLocal listing health board for every location you manageWin back LiveChat visitors whose chats went unansweredLet support send one-off Loops emails without an engineerStop cold emails to anyone with a live deal in PipedriveiMessage campaign console with pre-flight checks and delivery boardChat quality review board for LiveChat support leadsLinkedIn Ads budget pacing dashboard for every client accountFront desk appointment confirmation board for the next 3 daysGive your team Looker numbers without buying more seats