marginmath

v0.1.0
io.github.CloudCorpRecords/marginmath Checked 13 hours ago Published 6 days ago

Ecommerce margin calculators: break-even ROAS, profit scenarios, UTM links, weekly reports.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

calculate_break_even_roas Calculate break-even ROAS

Calculate break-even and target-profit ROAS and maximum CPA from user-supplied revenue, costs, percentage fees and refund reserve. Ask for missing inputs even if asked not to ask questions. Unknown fields must be null, never guessed zeros or a default currency. If any input is unknown, returns needs_input with questions and no estimate. Only explicit user-supplied zeros are valid. Does not read an ad account or change a budget.

ParameterTypeDescription
currency *User-supplied ISO 4217 currency code. Use null if unknown; never assume USD.
paymentFeeRate *User-supplied payment fee percentage: 3 means 3%. Use null if unknown; do not substitute 0.
price *User-supplied revenue per order after discounts and excluding collected taxes. Use null if unknown.
productCost *User-supplied product cost per order. Use null if unknown; use 0 only when the user explicitly supplied zero.
refundRate *User-supplied refund reserve percentage. Use null if unknown; do not substitute 0.
shippingCost *User-supplied net shipping and fulfillment cost per order. Use null if unknown; do not substitute 0.
targetProfit *User-supplied desired profit per order, or 0 when the user requests break-even only. Use null if unknown.

compare_profit_scenarios Compare profit scenarios

Compare two to five user-supplied pricing or cost scenarios in one currency. Unknown inputs must be null, never guessed zeros or a default currency. If any scenario is incomplete, returns needs_input with labeled questions and no numeric comparison; ask for those inputs. Complete scenarios return contribution, maximum CPA and ROAS. Does not predict sales or change pricing or advertising.

ParameterTypeDescription
scenarios *arrayArray of two to five user-supplied pricing or cost scenarios to compare, in one currency

build_campaign_utm Build a campaign UTM link

Format one HTTP(S) campaign URL with source, medium and campaign, plus optional content and term. Trims and lowercases UTM values and replaces whitespace with underscores. Returns naming warnings. Never visits the URL, sends a message, saves a campaign or changes tracking settings.

ParameterTypeDescription
campaign *stringUTM campaign name (utm_campaign)
medium *stringUTM medium (utm_medium), such as email, cpc or social
source *stringUTM source (utm_source), such as a site or newsletter name
url *stringDestination URL. This tool formats it locally and never fetches it.
contentstringUTM content tag (utm_content) distinguishing variants of the same ad or link
termstringUTM term (utm_term), the paid-search keyword tag

search_ecommerce_resources Search Ecomwith resources

Search Ecomwith published tutorial metadata, internal tool descriptions and public answer summaries in English or Chinese. Returns up to ten source links with content access labels. Does not search the wider web, fetch websites or return paid lesson bodies, drafts or customer data.

ParameterTypeDescription
query *stringSearch text to match against the ecommerce resources
limitintegerMaximum number of results to return
localestringLocale for the response: en or zh

list_public_weekly_reports List public ecommerce weekly reports

List up to ten Ecomwith published or corrected ecommerce reports with public summaries and dates. Does not return drafts, withdrawn issues, member-only sections, subscriber data or unpublished research. These are dated editorial reports, not a live news feed.

ParameterTypeDescription
limitintegerMaximum number of results to return
localestringLocale for the response: en or zh

get_public_weekly_report Read a public ecommerce weekly report

Read guest excerpts and cited source links for one published or corrected Ecomwith weekly report, using a slug returned by list_public_weekly_reports. Retain publication and correction dates and each cited source verificationStatus label; do not upgrade weaker evidence. Rechecks publication state each call. A withdrawn, unpublished, missing or unavailable-language report is not returned. No member content or private research notes are accessible.

ParameterTypeDescription
slug *stringSlug identifying the weekly report to read
localestringLocale for the response: en or zh