Transform API data with Workflow scripts
Customize your API requests and responses using Workflow scripts
Maxim Workflows provide powerful scripting capabilities to modify requests and responses. These scripts help you transform data, add authentication, and handle complex response structures.
Pre-request Script
The prescript
function runs before sending requests to your API. Use it to modify request parameters, add headers, or transform data.
Post-response Script
The postscriptV2
function processes API responses before displaying them. Use it to transform response data or extract specific fields:
Simulation Scripts
Use these scripts to set up and clean up multi-turn conversation tests:
Supported models
You don't need to use require
or import
to use these modules in scripts. These are directly available in the script environment.
axios
: Axios is a popular HTTP client library for JavaScript. It provides a simple API for making HTTP requests and supports various features like request and response interceptors, request cancellation, and automatic JSON parsing.
Evaluate simulated sessions for agents
Learn how to evaluate your AI agent's performance using automated simulated conversations. Get insights into how well your agent handles different scenarios and user interactions.
Automate workflow evaluation via CI/CD
Trigger test runs in CI/CD pipelines to evaluate workflows automatically.