{"api":{"id":"api_b7b64905243c5c9bb7e4d02d","slug":"mta-sts-policy-reader","name":"MTA-STS Policy API","description":"Reads the MTA-STS mail transport policy that each domain publishes: whether one exists, its version, mode (enforce, testing or none), the allowed mail server patterns and the cache lifetime. Many domains per call.","kind":"ready_made","visibility":"public","domain":"mta-sts.gmail.com","source_url":"https://mta-sts.gmail.com/.well-known/mta-sts.txt","category":"developer","record_type":"generic","active_version":"1.0","units_per_1k":500,"health":"unknown","auto_repair":false,"last_checked_at":null,"last_run_at":null,"fields_count":6,"created_at":"2026-12-06T04:45:48.378Z","updated_at":"2026-12-06T04:45:48.378Z","runnable":true},"version":"1.0","contract_hash":"3b0c015b15262d42160510e02fec75298c04d31d4e782c2eedc35036022542c7","fields":[{"name":"domain","type":"string","description":"The domain that was checked, in lower case.","required":true,"coverage":1,"example":"gmail.com"},{"name":"has_policy","type":"boolean","description":"True when the domain publishes a policy file.","required":false,"coverage":1,"example":true},{"name":"version","type":"string","description":"Policy version, normally STSv1.","required":false,"coverage":1,"example":"STSv1"},{"name":"mode","type":"string","description":"enforce, testing or none.","required":false,"coverage":1,"example":"enforce"},{"name":"mx_patterns","type":"array","description":"Mail server host names or wildcard patterns the policy allows.","required":false,"coverage":1,"example":["smtp.google.com","gmail-smtp-in.l.google.com"]},{"name":"max_age_seconds","type":"integer","description":"How long senders may cache the policy, in seconds.","required":false,"coverage":1,"example":86400}],"inputs":[{"name":"domains","type":"array","description":"Domains to check, such as gmail.com. A leading mta-sts. or https:// is ignored.","example":["gmail.com","outlook.com"],"required":true}],"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","additionalProperties":true,"properties":{"domain":{"description":"The domain that was checked, in lower case.","type":"string"},"has_policy":{"description":"True when the domain publishes a policy file.","type":"boolean"},"max_age_seconds":{"description":"How long senders may cache the policy, in seconds.","type":"integer"},"mode":{"description":"enforce, testing or none.","type":"string"},"mx_patterns":{"description":"Mail server host names or wildcard patterns the policy allows.","type":"array"},"version":{"description":"Policy version, normally STSv1.","type":"string"}},"required":["domain"],"title":"MTA-STS Policy API","type":"object"},"samples":[{"domain":"gmail.com","has_policy":true,"version":"STSv1","mode":"enforce","mx_patterns":["smtp.google.com","gmail-smtp-in.l.google.com","*.gmail-smtp-in.l.google.com"],"max_age_seconds":86400},{"domain":"outlook.com","has_policy":true,"version":"STSv1","mode":"enforce","mx_patterns":["*.olc.protection.outlook.com"],"max_age_seconds":604800},{"domain":"google.com","has_policy":true,"version":"STSv1","mode":"enforce","mx_patterns":["smtp.google.com","aspmx.l.google.com","*.aspmx.l.google.com"],"max_age_seconds":86400}],"validation":{"checked_at":"2026-12-06T04:45:48.335Z","field_coverage":{"domain":1,"has_policy":1,"max_age_seconds":1,"mode":1,"mx_patterns":1,"version":1},"fresh_read":false,"identity_unique":true,"issues":["Imported from a hand-built source. Field names and types come from its published schema; no live read was made for this check."],"level":"preview","pages_checked":0,"passed":true,"records_checked":3},"changelog":[{"version":"1.0","change_kind":"initial","note":"Imported from the ready-made source catalog.","created_at":"2026-12-06T04:45:48.378Z","activated_at":"2026-12-06T04:45:48.378Z","active":true,"contract_hash":"3b0c015b15262d42160510e02fec75298c04d31d4e782c2eedc35036022542c7","fields_count":6}]}