> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://zuora.ferndocs.com/docs/platform/extensibility/mediation/meter-components/processors/mediation-code-editors/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://zuora.ferndocs.com/_mcp/server.
# Mediation code editors
> Zuora's mediation engine supports custom code for three meter components, the Advanced Transformer, Aggregator, and Accumulator processors. Each operator is designed for a distinct purpose within the event processing pipeline.
Zuora's mediation engine supports custom code for three meter components, the Advanced Transformer, Aggregator, and Accumulator processors. Each operator is designed for a distinct purpose within the event processing pipeline.
For the Accumulator and Aggregator processors, the code editor option is available under **Advanced Accumulation** and **Advanced Aggregation**.
|
Type
|
Usage
|
|
Advanced Transformer code editor
|
* You need to transform or validate individual records.
* Operations are stateless and lightweight.
* You want to enrich or convert data on the fly.
|
|
Advanced Accumulator code editor
|
* You need time-based summaries or grouped aggregates.
* Calculating totals, averages, or counts.
* Processing batch or windowed data streams.
|
|
Advanced Aggregator code editor
|
* You require persistent state management.
* Logic involves thresholds or custom release rules.
* Event emission depends on business triggers rather than time.
|
> Zuora's mediation engine supports custom code for three meter components, the Advanced Transformer, Aggregator, and Accumulator processors. Each operator is designed for a distinct purpose within the event processing pipeline.
## Docs
- [Advanced Transformer code editor](https://zuora.ferndocs.com/docs/platform/extensibility/mediation/meter-components/processors/mediation-code-editors/advanced-transformer-code-editor.md): The Advanced Transformer is used for per-event transformations. It processes individual events independently, performing 1 to 1, many or none It is stateless unless state handling is explicitly implemented.
- [Advanced Accumulator code editor](https://zuora.ferndocs.com/docs/platform/extensibility/mediation/meter-components/processors/mediation-code-editors/advanced-accumulator-code-editor.md): The Advanced Accumulator code editor processes multiple events together, typically within time-based windows or grouped contexts. It is best suited for aggregation, summation, and grouped analytics.
- [Advanced Aggregator code editor](https://zuora.ferndocs.com/docs/platform/extensibility/mediation/meter-components/processors/mediation-code-editors/advanced-aggregator-code-editor.md): The Advanced Aggregator code editor provides stateful, memory-based processing across multiple events. It enables custom release conditions, allowing flexible accumulation of data until business-defined triggers are met.
- [Mediation code editor guide](https://zuora.ferndocs.com/docs/platform/extensibility/mediation/meter-components/processors/mediation-code-editors/mediation-code-editor-guide.md): The Mediation code editor guide offers a comprehensive overview of using GraalVM 23.0.1, GraalJS, and GraalPy to execute custom logic in meters. It includes examples of transformers, accumulators, and aggregators, along with guidelines for handling dates and currency in JavaScript and Python.