Obter a política de abatimento por fuga
RegistosGET /leak-allowance-policy
Returns the rules the tenant uses to grant credits for water lost to leaks: whether the allowance is enabled, the credit share and minimum excess in basis points, the history and cooldown months, whether proof of repair is required, and the repair window in days. A tenant that never saved a policy gets the defaults: disabled, 50% credit, 6 months of history, 12-month cooldown, 50% minimum excess, proof required and a 90-day window. Needs the business:leak-allowances:read scope.
Devolve
200 OK
Permissões business:leak-allowances:read · Funções: admin, analyst, customer_service, finance, operations, owner, viewer
curl -X GET "$BUSINESS_API/leak-allowance-policy" \
-H "Authorization: Bearer sk_test_..."
# Sem comando CLI equivalente; use cURL ou HTTP directo.
const res = await fetch("$BUSINESS_API/leak-allowance-policy", {
method: "GET",
headers: {
Authorization: "Bearer sk_test_..."
}
});
const data = await res.json();
import requests
res = requests.get(
"$BUSINESS_API/leak-allowance-policy",
headers={
"Authorization": "Bearer sk_test_..."
}
)
data = res.json()
req, _ := http.NewRequest("GET", "$BUSINESS_API/leak-allowance-policy", nil)
req.Header.Set("Authorization", "Bearer sk_test_...")
resp, err := http.DefaultClient.Do(req)
OK