This function retrieves the the Sender Policy Framework (SPF) records for one or more domains.
uapi --output=jsonpretty \ --user=username \ EmailAuth \ validate_current_spfs \ domain='example.com'
{- "apiversion": 3,
- "func": "validate_current_spfs",
- "module": "EmailAuth",
- "result": {
- "data": [
- {
- "domain": "example.com",
- "error": "(XID rm8h9f) DNS returned SERVFAIL (code 2)\nin response to the systems query for example2.coms\nTXT records.",
- "expected": "ip6:0:0:0:0:0:ffff:c0a8:101",
- "ip_address": "0:0:0:0:0:ffff:c0a8:101",
- "ip_version": 6,
- "records": [
- {
- "current": "v=spf1 +a +mx ip6:0:0:0:0:0:ffff:c0a8:101 ~all",
- "reason": "'example.com: Sender\nis not authorized by default to use ''example.com''\nin ''helo'' identity, however domain is not\ncurrently prepared for false failures (mechanism\n''~all'' matched)'",
- "state": "PASS"
}
], - "state": "VALID"
}
], - "errors": null,
- "messages": null,
- "metadata": { },
- "status": 1,
- "warnings": null
}
}