An Aggregate is a powerful, stateful function that performs a calculation over a specified time window. This is the key to detecting sophisticated fraud patterns that occur over multiple transactions.Aggregates are highly optimised; the engine pre-calculates them to ensure low-latency evaluation.Structure & Examples:The time window is defined using the ISO 8601 duration format (e.g., PT1H for 1 hour, P7D for 7 days).count: Counts the number of transactions. Use Case: Detect rapid, repeated transactions.
// Block if more than 5 transactions are made from the same source in 1 hour.when count(transaction_id, "PT1H", source == $current.source) > 5
sum: Calculates the sum of a numerical field. Use Case: Detect structuring or high-volume activity.
// Flag if the total amount sent from an account in 24 hours exceeds $50,000.when sum(amount, "P1D", source == $current.source) > 50000
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"FinWatch","description":"A domain-specific language (DSL) for creating real-time transaction monitoring rules.","colors":{"primary":"#16A34A","light":"#07C983","dark":"#15803D"},"logo":{"light":"https://mintcdn.com/boxlesslabs/FhpkHFzcfexoCXOr/images/LogoBLACK.svg?fit=max\u0026auto=format\u0026n=FhpkHFzcfexoCXOr\u0026q=85\u0026s=d72794b97b9469b815c1ec25d7f9aa41","dark":"https://mintcdn.com/boxlesslabs/0JF6z69u57hmqsWm/images/logo_green(1).png?fit=max\u0026auto=format\u0026n=0JF6z69u57hmqsWm\u0026q=85\u0026s=531373acedba0eb783b669f6d558dfd8"},"favicon":{"light":"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026auto=format\u0026n=4FuH-i7uWBoUfanF\u0026q=85\u0026s=a9c53dbf3423acc0e5dff62da3c24f59","dark":"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026auto=format\u0026n=4FuH-i7uWBoUfanF\u0026q=85\u0026s=a9c53dbf3423acc0e5dff62da3c24f59"},"navbar":{"links":[{"href":"mailto:hi@mintlify.com","label":"Support"}],"primary":{"type":"button","label":"Dashboard","href":"https://dashboard.mintlify.com"}},"footer":{"socials":{"x":"https://x.com/mintlify","github":"https://github.com/mintlify","linkedin":"https://linkedin.com/company/mintlify"}},"seo":{"indexing":"all"},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"boxlesslabs","hasAudioNarration":false,"actualSubdomain":"boxlesslabs","customDomains":["docs.finwatch.finance"],"gitSource":{"type":"github","owner":"mintlify-community","repo":"docs-boxlesslabs-1bfea810","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{},"buildId":"6ae954847c27206474c743c2:success","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"default","tag":"Guides","count":13},{"language":"default","tag":"Watchscripts","count":12},{"language":"default","tag":"API reference","count":12},{"language":"default","tag":"Endpoint examples","count":11},{"language":"default","tag":"FinWatch Core","count":9},{"language":"default","tag":"Concepts","count":5},{"language":"default","tag":"Reference","count":5},{"language":"default","tag":"Built-ins","count":5},{"language":"default","tag":"git-ops","count":4},{"language":"default","tag":"Instructions","count":4}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"aggregates","slug":"/aggregates","pageMetadata":{"title":"Aggregates","description":null,"href":"/aggregates"},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,em:`em`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,..._provideComponents(),...props.components},{CodeBlock}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`An\\xA0`,_jsx(_components.strong,{children:`Aggregate`}),`\\xA0is a powerful, stateful function that performs a calculation over a specified time window. This is the key\\xA0to detecting sophisticated fraud patterns that occur over multiple transactions.`]}),`\n`,_jsx(_components.p,{children:`Aggregates are highly optimised; the engine pre-calculates them\\xA0to ensure low-latency evaluation.`}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Structure \u0026 Examples:`})}),`\n`,_jsxs(_components.p,{children:[`The time window is defined using the ISO 8601 duration format (e.g.,\\xA0`,_jsx(_components.code,{children:`PT1H`}),`\\xA0for 1 hour,\\xA0`,_jsx(_components.code,{children:`P7D`}),`\\xA0for 7 days).`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`count`}),_jsx(_components.strong,{children:`:`}),`\\xA0Counts the number of transactions.\\xA0`,_jsx(_components.em,{children:`Use Case: Detect rapid, repeated transactions.`})]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`4`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`//`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` Block`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` if`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` more`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` than`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 5`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` transactions`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` are`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` made`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` from`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` the`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` same`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` source`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` in`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 1`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` hour.`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`when`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:` count(transaction_id,`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"PT1H\",`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` source`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` ==`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $current`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`.source`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` 5`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`\\xA0`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`sum`}),`:\\xA0Calculates the sum of a\\xA0numerical field.\\xA0Use Case: Detect structuring or high-volume activity.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`3`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`3`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`//`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` Flag`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` if`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` the`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` total`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` amount`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` sent`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` from`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` an`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` account`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` in`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 24`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` hours`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` exceeds`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $50`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`,000.`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`when`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:` sum(amount,`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"P1D\",`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` source`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` ==`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $current`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`.source`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` 50000`})]}),`\n`]})})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Aggregates","description":null,"href":"/aggregates"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"subdomain":"boxlesslabs","siteName":"FinWatch","title":"Aggregates - FinWatch","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-06-27T19:09:06.588Z","originalFileLocation":"aggregates.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"application-name\" content=\"FinWatch\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/svg+xml\" sizes=\"180x180\" href=\"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026amp;auto=format\u0026amp;n=4FuH-i7uWBoUfanF\u0026amp;q=85\u0026amp;s=a9c53dbf3423acc0e5dff62da3c24f59\">\u003clink data-mint-head rel=\"icon\" type=\"image/svg+xml\" sizes=\"32x32\" href=\"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026amp;auto=format\u0026amp;n=4FuH-i7uWBoUfanF\u0026amp;q=85\u0026amp;s=a9c53dbf3423acc0e5dff62da3c24f59\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/svg+xml\" sizes=\"16x16\" href=\"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026amp;auto=format\u0026amp;n=4FuH-i7uWBoUfanF\u0026amp;q=85\u0026amp;s=a9c53dbf3423acc0e5dff62da3c24f59\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/svg+xml\" href=\"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026amp;auto=format\u0026amp;n=4FuH-i7uWBoUfanF\u0026amp;q=85\u0026amp;s=a9c53dbf3423acc0e5dff62da3c24f59\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/svg+xml\" sizes=\"32x32\" href=\"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026amp;auto=format\u0026amp;n=4FuH-i7uWBoUfanF\u0026amp;q=85\u0026amp;s=a9c53dbf3423acc0e5dff62da3c24f59\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/svg+xml\" sizes=\"16x16\" href=\"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026amp;auto=format\u0026amp;n=4FuH-i7uWBoUfanF\u0026amp;q=85\u0026amp;s=a9c53dbf3423acc0e5dff62da3c24f59\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/svg+xml\" href=\"https://mintcdn.com/boxlesslabs/4FuH-i7uWBoUfanF/favicon.svg?fit=max\u0026amp;auto=format\u0026amp;n=4FuH-i7uWBoUfanF\u0026amp;q=85\u0026amp;s=a9c53dbf3423acc0e5dff62da3c24f59\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Aggregates - FinWatch\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"FinWatch\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.finwatch.finance/aggregates\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://boxlesslabs.mintlify.site/_mintlify/api/og/v2?division=Concepts\u0026amp;title=Aggregates\u0026amp;theme=216dd2631f2c1c1b422dd134\u0026amp;signature=30d9dff887860aaca797664f941a15d194be7526b4c07f3cb8ab37ae6c00871c\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Aggregates - FinWatch\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://boxlesslabs.mintlify.site/_mintlify/api/og/v2?division=Concepts\u0026amp;title=Aggregates\u0026amp;theme=216dd2631f2c1c1b422dd134\u0026amp;signature=30d9dff887860aaca797664f941a15d194be7526b4c07f3cb8ab37ae6c00871c\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"https://mintlify.s3.us-west-1.amazonaws.com/boxlesslabs/_generated/favicon/browserconfig.xml?v=3\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"FinWatch\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#16A34A\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.finwatch.finance/aggregates\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/aggregates.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.finwatch.finance/#organization\",\"name\":\"FinWatch\",\"url\":\"https://docs.finwatch.finance\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/boxlesslabs/FhpkHFzcfexoCXOr/images/LogoBLACK.svg?fit=max\u0026auto=format\u0026n=FhpkHFzcfexoCXOr\u0026q=85\u0026s=d72794b97b9469b815c1ec25d7f9aa41\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.finwatch.finance#website\",\"name\":\"FinWatch\",\"url\":\"https://docs.finwatch.finance\",\"publisher\":{\"@id\":\"https://docs.finwatch.finance/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.finwatch.finance/aggregates#webpage\",\"url\":\"https://docs.finwatch.finance/aggregates\",\"name\":\"Aggregates\",\"dateModified\":\"2026-06-27T19:09:06.588Z\",\"isPartOf\":{\"@id\":\"https://docs.finwatch.finance#website\"},\"breadcrumb\":{\"@id\":\"https://docs.finwatch.finance/aggregates#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.finwatch.finance/aggregates#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Concepts\",\"item\":\"https://docs.finwatch.finance/rules\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Aggregates\",\"item\":\"https://docs.finwatch.finance/aggregates\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.finwatch.finance/aggregates#article\",\"headline\":\"Aggregates\",\"name\":\"Aggregates\",\"url\":\"https://docs.finwatch.finance/aggregates\",\"mainEntityOfPage\":{\"@id\":\"https://docs.finwatch.finance/aggregates#webpage\"},\"dateModified\":\"2026-06-27T19:09:06.588Z\",\"publisher\":{\"@id\":\"https://docs.finwatch.finance/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.finwatch.finance#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"FinWatch\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"FinWatch\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/aggregates.md","siteName":"FinWatch","nav":{"global":null,"tabs":[{"tab":"FinWatch Core","groups":[{"group":"Getting started","pages":[{"title":"Overview","href":"/introduction"},{"title":"The FinWatch Philosophy","href":"/the-fin-watch-philosophy"},{"title":"Why FinWatch?","href":"/why-fin-watch"},{"title":"Usecases","href":"/usecases"}]},{"group":"Concepts","pages":[{"title":"Rules","href":"/rules"},{"title":"Conditions","href":"/conditions"},{"title":"Actions","description":null,"href":"/actions"},{"title":"Aggregates","href":"/aggregates"},{"title":"Lists","description":null,"href":"/lists"}]}]},{"tab":"Watchscripts","pages":[{"title":"Watchscripts","href":"/overview"}]},{"tab":"Guides","pages":[{"title":"Guides","href":"/quick-start"}]},{"tab":"API reference","pages":[{"title":"API reference","href":"/api-reference/introduction"}]}]},"basePath":"","title":"Aggregates - FinWatch","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":[],"chunks":[]}