Workflow · Calculate · Opening soon
Affiliate commissions
Export your Shopify orders and your affiliate commission rates, then load both files into the workflow. It matches each order to a rate using the referral code, keeps paid orders, and calculates commission from the order subtotal.
Someone typed
“calculate affiliate commissions by affiliate and month from orders with their referral codes and commission rates”
The agent read it as
Calculate affiliate commissions by affiliate and month from Shopify orders with their referral codes and Affiliate commission rates, using the order subtotal.
What the agent built
4 steps, each one an ordinary Mammoth step you can open and change.
File
Shopify orders
CSV export · 24 rows
File
Affiliate commission rates
CSV export · 8 rows
Step
Make rate code key
Step 1
Step
Keep paid orders
Step 2
Join
Add affiliate rates
23 of 23 paired
Step
Total commissions by month
Step 4
Result
Affiliate Commission Totals
18 rows
Schedule
Runs when you say
Proposed
- FileShopify ordersCSV export · 24 rows
- FileAffiliate commission ratesCSV export · 8 rows
- StepKeep paid ordersStep 2
- StepMake rate code keyStep 1
- JoinAdd affiliate rates23 of 23 paired
- StepTotal commissions by monthStep 4
- ResultAffiliate Commission Totals18 rows
- ScheduleRuns when you sayProposed
On the sample files, every step runs and the result has 18 rows.
- Download Shopify orders sample (24 rows)Shopify admin: Orders > Export > All orders CSV
- Download Affiliate commission rates sample (8 rows)Internal spreadsheet: Commissions > Affiliate Rates
What you get back
The result of that run, the rows to look at first.
Affiliate Commission TotalsSample data18 rows
| Affiliate | Month | Commission | Order subtotal | Commission rate |
|---|---|---|---|---|
| Sunrise Studio | 2026-10-01 | 6 | 75 | 8% |
| Northstar Collective | 2026-10-01 | 17.16 | 132 | 13% |
| Harbor House Media | 2026-10-01 | 21 | 210 | 10% |
| Verve Loop | 2026-10-01 | 16.20 | 180 | 9% |
| Evergreen Audience | 2026-10-01 | 6.16 | 88 | 7% |
| Harbor House Media | 2026-11-01 | 24.40 | 244 | 10% |
| Sunrise Studio | 2026-11-01 | 22.16 | 277 | 8% |
| Ridge Path Creators | 2026-11-01 | 49.20 | 410 | 12% |
| Evergreen Audience | 2026-11-01 | 12.74 | 182 | 7% |
| Coastline Partners | 2026-11-01 | 34.10 | 310 | 11% |
| Sunrise Studio | 2026-09-01 | 9.60 | 120 | 8% |
| Harbor House Media | 2026-09-01 | 8.40 | 84 | 10% |
How it works
How to use the Affiliate Commission Totals workflow
- 1Get early accessWe invite people in small batches, job by job. You'll land on this workflow, already built and working on sample files.
- 2Swap in your exportsUpload your own files as they come out of your tools. The agent checks the workflow on your rows.
- 3Change it in words, then turn it onSay what to change and see the new result before anything saves. Then choose when it runs.
Affiliate Commission Totals: questions
How do you calculate affiliate commissions by affiliate and month?
Export your Shopify orders and your affiliate commission rates, then load both files into the workflow. It matches each order to a rate using the referral code, keeps paid orders, and calculates commission from the order subtotal. Then it groups the results by affiliate and month.
What export should you use from Shopify?
Use the orders export from Shopify. It needs the order fields that include the referral code, paid status, order date, and order subtotal.
What happens to rows that do not match a rate?
Rows that do not match a rate stay out of the matched commission result unless you decide otherwise in the rules. You can review them separately and update the rate table or matching rule.
How do you change the rules?
You change the rules in plain words. For example, you can say which orders to keep, which column to match on, how to calculate commission, and how to group the totals.
Get early access to this workflow
It opens already built and working on sample files. Swap in your own exports to see your result.
Workflows like this
Schedules, commissions, costing and margins, worked out the same way from every new export.
- Pivot table from raw dataTurn a raw sales export into a pivot table of revenue by region and month.See the workflow Built by the agent
- Real estate commission splitWork out real estate commission on each closed sale and split it between the listing agent, buying agent and brokerage.See the workflow Built by the agent
- Loan amortization from statementsBuild a monthly loan amortization schedule from an Excel export, with interest, principal, and remaining balance for each loan.See the workflow Built by the agent
- Accrued expenses scheduleBuild an accrued expenses schedule from QuickBooks exports. Match purchase orders to vendor bills, calculate unbilled amounts, and flag items that need accrual.See the workflow Built by the agent
- RFM segmentsEvery customer scored 1-5 on recency, frequency and spend, with a segmentSee the workflow Template
- Sales velocityEach rep's open deals, win rate, deal size, sales cycle and velocity, and the team'sSee the workflow Template