Overview
- Category
- Engineering
- API mode
execute- Processing
- client-side
- Privacy
- no-data-stored
Public descriptor
The descriptor is available without an API key and supplies this tool’s metadata, schemas, modes, and examples.
GET /api/v1/tools/electricity-calculator
Execute availability
This tool has an execute route defined by its descriptor. Server-side execution is currently unavailable, so requests return api_not_launched.
POST /api/v1/tools/electricity-calculator/execute
Authentication is not issued during the preview. A bearer API key is planned for execution after launch.
Input schema
object object; additional properties are not accepted.
watts· number · required- Enter the appliance or device power draw in watts.
hours· number · required- Enter elapsed or operating hours; use a decimal for partial hours when appropriate.
rate_per_kwh· number · required- Enter the electricity price per kilowatt-hour from your utility bill.
{
"type": "object",
"properties": {
"watts": {
"type": "number",
"description": "Enter the appliance or device power draw in watts."
},
"hours": {
"type": "number",
"description": "Enter elapsed or operating hours; use a decimal for partial hours when appropriate."
},
"rate_per_kwh": {
"type": "number",
"description": "Enter the electricity price per kilowatt-hour from your utility bill."
}
},
"required": [
"watts",
"hours",
"rate_per_kwh"
],
"additionalProperties": false
}
Output schema
On a successful execution, schema values appear in data.result.values.
kilowatt_hours· number- Browser-calculated kilowatt hours.
estimated_cost· number- Estimated electricity cost for one day.
monthly_kwh· number- Estimated energy use over 30 days.
monthly_cost· number- Estimated electricity cost over 30 days.
yearly_cost· number- Estimated electricity cost over 365 days.
{
"type": "object",
"properties": {
"kilowatt_hours": {
"type": "number",
"description": "Browser-calculated kilowatt hours."
},
"estimated_cost": {
"type": "number",
"description": "Estimated electricity cost for one day."
},
"monthly_kwh": {
"type": "number",
"description": "Estimated energy use over 30 days."
},
"monthly_cost": {
"type": "number",
"description": "Estimated electricity cost over 30 days."
},
"yearly_cost": {
"type": "number",
"description": "Estimated electricity cost over 365 days."
}
},
"additionalProperties": false
}
100-watt device used five hours daily
The request body follows the published input schema. The response below shows the success-envelope shape returned after execution is available.
curl -X POST "https://utilitypages.org/api/v1/tools/electricity-calculator/execute" \
-H "Content-Type: application/json" \
-d '{
"watts": 100,
"hours": 5,
"rate_per_kwh": 0.1499999999999999944488848768742172978818416595458984375
}'
{
"ok": true,
"data": {
"slug": "electricity-calculator",
"result": {
"values": {
"kilowatt_hours": 0.5,
"estimated_cost": 0.07499999999999999722444243843710864894092082977294921875,
"monthly_kwh": 15,
"monthly_cost": 2.25,
"yearly_cost": 27.379999999999999005240169935859739780426025390625
},
"display": {
"display": "0.5"
},
"warnings": [],
"assumptions": [],
"steps": []
}
},
"meta": [],
"request_id": "req_example_123"
}
Errors
api_not_launched· 503- Returned by the current launch gate for every execute request.
invalid_json· 400- Returned when an enabled execute request does not contain valid JSON.
validation_failed· 422- Returned when a request does not satisfy the input schema.
browser_interaction_required· 422- Returned for browser capability tools instead of inventing a server-side result.
tool_not_found· 404- Returned when a requested descriptor slug does not exist.
execution_failed· 503- Returned when an enabled server-side execution cannot complete.