tzero
Ttzero
API Reference
POSTRun the Anti-REA audit controller/gradio_api/call/_run_anti_rea_audit_controllerPOSTCalculate estimated return on investment/gradio_api/call/calculate_roi_controllerPOSTGenerate an MCP client configuration/gradio_api/call/generate_mcp_config_controllerPOSTCompress source code/gradio_api/call/process_code_compressionPOSTRun the Auto Vault controller/gradio_api/call/run_auto_vault_controllerPOSTRun the Code Healer controller/gradio_api/call/run_code_healer_controllerPOSTCheck a proposed code change/gradio_api/call/run_hallucination_guard_controllerPOSTAnalyze code impact/gradio_api/call/run_impact_analysis_controller
GETStream the result of a submitted job/gradio_api/call/{api_name}/{event_id}
llms.txtPowered by Octri
POST/gradio_api/call/calculate_roi_controller

Calculate estimated return on investment

Calculates estimated return on investment using the values supplied in data. Provide five values in order: team size, prompts per day, average prompt size, estimated savings percentage, and model name. Use GET /gradio_api/call/{api_name}/{event_id} with the returned event_id to read the result stream.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

1 body field

The ordered values for the ROI calculation.

dataarrayrequired

Values in endpoint input order.

1 status code
200Returns an event_id you can use to retrieve the job's result stream.
event_idstringrequired

Identifier used to retrieve the result stream.

Error handling

data is required and must contain exactly five values in this order: four numbers for team size, prompts per day, average prompt size, and estimated savings percentage, followed by a string for the model name.

import { TZeroGradio } from "tzero-sdk";

const client = new TZeroGradio({
  baseUrl: "https://toprakke4-tzero-token-reducer.hf.space",
  auth: { bearer: process.env.API_TOKEN! },
});

const result = await client.call.submitRoiCalculation({ data: [] });
Response
{
  "event_id": "550e8400-e29b-41d4-a716-446655440000"
}
PreviousStream the result of a submitted…NextGenerate an MCP client configura…