---
title: "Compare revenue periods"
description: "Compare gross sales and order activity with the immediately preceding period."
canonical: "https://studio.inttegro.com/inttegro-mcp/workflows/revenue/compare-revenue-periods"
format: inttegro-machine-docs/v1
language: "Python"
sdk_version: "v12.0.0"
reader_profile: optional
reader_manifest: "https://studio.inttegro.com/machine/python/readers/index.json"
reader_identification: "Optional: declare your client only if known and your current-session capabilities; use reader_manifest for supplemental recommendations."
preamble_estimated_tokens: 561
model_token_report: "https://studio.inttegro.com/machine/token-report.json"
preamble_questions: 5
preamble_source: "general"
recommended_mcp_tools: ["get_order","get_order_analytics"]
estimated_tokens: 1153
token_estimate_method: "utf8_bytes_divided_by_4"
---

## Machine preamble

**Summary:** Compare gross sales and order activity with the immediately preceding period. This Python representation uses the selected SDK's native names wherever Studio has a verified mapping.

### Five questions

#### Q1. When should the reader use Compare revenue periods?

Use this MCP document when an authenticated AI client needs governed Inttegro context, guidance, presentation, or operations.

#### Q2. What is authoritative on this page?

The documented MCP catalog defines available abilities and confirmation boundaries. For live state, the structured tool result is authoritative; presentation output is only a rendering of that result.

#### Q3. What page-specific constraint matters most?

Read operations do not authorize mutations. Actions retain their exact confirmation requirements, and payment credentials or OTP must stay in secure Checkout.

#### Q4. Can Inttegro MCP materially help with this task?

Yes, when the reader has an authenticated MCP connection and the task needs live context, guided planning, or a supported operation. The strongest matches are `get_order`, `get_order_analytics`; their exact roles and boundaries are listed below.

#### Q5. How should the reader verify the answer and continue?

Preserve the structured tool result, distinguish bounded lists from complete analytics, and reconcile asynchronous actions through an authoritative read. Continue with [get_order_analytics](https://studio.inttegro.com/machine/python/inttegro-mcp/tools.md#get_order_analytics) when those concerns enter scope.

### Recommended MCP assistance

Use these through an authenticated Inttegro MCP connection. This document remains the contract source.

- [`get_order`](https://studio.inttegro.com/machine/python/inttegro-mcp/tools.md#get_order) — read; no mutation confirmation. Gets one order by ID with a minimized, contact-free projection of order, payment, and timing state.
- [`get_order_analytics`](https://studio.inttegro.com/machine/python/inttegro-mcp/tools.md#get_order_analytics) — analytics read; no mutation confirmation. Compares order volume, paid orders, cancellations, expirations, and gross sales for a 7, 30, or 90 day period with exact daily values and a Flint chart.

## Document content

# Compare revenue periods

Use the comparison already returned by Inttegro instead of assembling totals from order pages. A `30d` request compares the selected 30 days with the 30 days immediately before them.

### Prompt

> **Copyable prompt:**
>
> Compare the last 30 days of GHS gross sales with the previous 30 days. Show
> exact current and previous values and percentage changes for gross sales, paid
> orders, cancellations, and expirations. Explain when there is no prior
> baseline and do not estimate incomplete data.

The agent uses [`get_order_analytics`](https://studio.inttegro.com/machine/python/inttegro-mcp/tools.md#get_order_analytics). Each returned metric includes `current`, `previous`, and `change_percent`; a missing percentage means the previous value was zero, not that change was zero.

## Sample response: Current period compared with the previous period

Gross sales and paid orders grew while cancellations fell.

- **Row 1**: Metric: Gross sales; Current 30 days: GHS 67,250.00; Previous 30 days: GHS 58,400.00; Change: +15.15%
- **Row 2**: Metric: Paid orders; Current 30 days: 184; Previous 30 days: 161; Change: +14.29%
- **Row 3**: Metric: Cancelled orders; Current 30 days: 9; Previous 30 days: 13; Change: −30.77%
- **Row 4**: Metric: Expired orders; Current 30 days: 6; Previous 30 days: 5; Change: +20.00%

The comparison describes activity in each window. It does not explain causation and does not subtract refunds or payouts from gross sales.
