{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/qelka-com/json-schema/qelka-com-signup-check-result-schema.json",
  "title": "SignupCheckResult",
  "description": "Sign-up risk from every input sent, with each sub-result. Never cached.",
  "x-generated": "2026-11-27",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/qelka-com-openapi.yml#/components/schemas/SignupCheckResult",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "pattern": "^lkp_[0-9A-HJKMNP-TV-Z]{10,26}$",
      "description": "Unique identifier of this lookup."
    },
    "object": {
      "type": "string",
      "const": "signup_check"
    },
    "input": {
      "type": "string",
      "description": "First input sent, in the order email, phone, ip, name, user_agent."
    },
    "decision": {
      "type": "string",
      "enum": [
        "allow",
        "review",
        "block"
      ],
      "description": "block: score 70 or more. review: score 30 to 69. allow: below 30. A suggestion for your flow, never a fact about the person."
    },
    "score": {
      "type": "integer",
      "minimum": 0,
      "maximum": 100,
      "description": "Sum of the points of every reason, capped at 100. Higher is riskier."
    },
    "reasons": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "enum": [
              "email_disposable",
              "email_invalid",
              "email_domain_unroutable",
              "email_lookalike_domain",
              "email_new_domain",
              "email_young_domain",
              "email_typo",
              "email_role",
              "email_risky_tld",
              "email_many_digits",
              "email_free_provider",
              "phone_invalid",
              "phone_premium_rate",
              "phone_heavily_reported",
              "phone_voip",
              "phone_reported",
              "ip_tor",
              "ip_proxy",
              "ip_vpn",
              "ip_datacenter",
              "country_mismatch",
              "name_has_link",
              "name_has_digits",
              "name_repetitive",
              "name_too_short",
              "user_agent_automation",
              "user_agent_short"
            ]
          },
          "field": {
            "type": "string",
            "enum": [
              "email",
              "phone",
              "ip",
              "name",
              "user_agent",
              "country"
            ],
            "description": "Input the signal comes from."
          },
          "severity": {
            "type": "string",
            "enum": [
              "info",
              "low",
              "medium",
              "high",
              "critical"
            ],
            "description": "Weight class of the signal, from its points: critical 90 and more, high 40 to 89, medium 20 to 39, low 1 to 19, info 0."
          },
          "points": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "message": {
            "type": "string",
            "description": "Plain-English explanation of the signal."
          }
        },
        "required": [
          "code",
          "field",
          "severity",
          "points",
          "message"
        ],
        "additionalProperties": false
      },
      "description": "Every signal found, strongest first."
    },
    "checks": {
      "type": "object",
      "properties": {
        "email": {
          "type": "string",
          "enum": [
            "ok",
            "not_provided",
            "not_applicable",
            "unavailable"
          ],
          "description": "ok: the check ran. not_provided: its input was not sent. not_applicable: the check does not cover this input (FTC reports outside North America, RDAP for a TLD without a public service). unavailable: its data source did not answer; the call is then free."
        },
        "email_domain_age": {
          "type": "string",
          "enum": [
            "ok",
            "not_provided",
            "not_applicable",
            "unavailable"
          ],
          "description": "ok: the check ran. not_provided: its input was not sent. not_applicable: the check does not cover this input (FTC reports outside North America, RDAP for a TLD without a public service). unavailable: its data source did not answer; the call is then free."
        },
        "phone": {
          "type": "string",
          "enum": [
            "ok",
            "not_provided",
            "not_applicable",
            "unavailable"
          ],
          "description": "ok: the check ran. not_provided: its input was not sent. not_applicable: the check does not cover this input (FTC reports outside North America, RDAP for a TLD without a public service). unavailable: its data source did not answer; the call is then free."
        },
        "phone_reports": {
          "type": "string",
          "enum": [
            "ok",
            "not_provided",
            "not_applicable",
            "unavailable"
          ],
          "description": "ok: the check ran. not_provided: its input was not sent. not_applicable: the check does not cover this input (FTC reports outside North America, RDAP for a TLD without a public service). unavailable: its data source did not answer; the call is then free."
        },
        "ip": {
          "type": "string",
          "enum": [
            "ok",
            "not_provided",
            "not_applicable",
            "unavailable"
          ],
          "description": "ok: the check ran. not_provided: its input was not sent. not_applicable: the check does not cover this input (FTC reports outside North America, RDAP for a TLD without a public service). unavailable: its data source did not answer; the call is then free."
        },
        "name": {
          "type": "string",
          "enum": [
            "ok",
            "not_provided",
            "not_applicable",
            "unavailable"
          ],
          "description": "ok: the check ran. not_provided: its input was not sent. not_applicable: the check does not cover this input (FTC reports outside North America, RDAP for a TLD without a public service). unavailable: its data source did not answer; the call is then free."
        },
        "user_agent": {
          "type": "string",
          "enum": [
            "ok",
            "not_provided",
            "not_applicable",
            "unavailable"
          ],
          "description": "ok: the check ran. not_provided: its input was not sent. not_applicable: the check does not cover this input (FTC reports outside North America, RDAP for a TLD without a public service). unavailable: its data source did not answer; the call is then free."
        }
      },
      "required": [
        "email",
        "email_domain_age",
        "phone",
        "phone_reports",
        "ip",
        "name",
        "user_agent"
      ],
      "additionalProperties": false
    },
    "email": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "object": {
              "type": "string",
              "const": "email"
            },
            "input": {
              "type": "string"
            },
            "status": {
              "type": "string",
              "enum": [
                "deliverable",
                "undeliverable",
                "risky",
                "unknown"
              ]
            },
            "reason": {
              "type": "string",
              "enum": [
                "accepted_email",
                "invalid_syntax",
                "domain_not_found",
                "domain_no_mx",
                "domain_null_mx",
                "mailbox_not_found",
                "mailbox_full",
                "mailbox_disabled",
                "catch_all",
                "disposable",
                "smtp_not_checked",
                "smtp_unavailable",
                "smtp_timeout",
                "smtp_blocked",
                "greylisted",
                "provider_unverifiable",
                "dns_error"
              ]
            },
            "did_you_mean": {
              "type": [
                "string",
                "null"
              ]
            },
            "checks": {
              "type": "object",
              "properties": {
                "syntax": {
                  "type": "boolean"
                },
                "mx": {
                  "type": [
                    "boolean",
                    "null"
                  ]
                },
                "smtp": {
                  "type": [
                    "boolean",
                    "null"
                  ]
                },
                "catch_all": {
                  "type": [
                    "boolean",
                    "null"
                  ]
                },
                "disposable": {
                  "type": "boolean"
                },
                "role": {
                  "type": "boolean"
                },
                "free_provider": {
                  "type": "boolean"
                }
              },
              "required": [
                "syntax",
                "mx",
                "smtp",
                "catch_all",
                "disposable",
                "role",
                "free_provider"
              ],
              "additionalProperties": false
            },
            "domain": {
              "type": "object",
              "properties": {
                "name": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "spf": {
                  "type": [
                    "boolean",
                    "null"
                  ]
                },
                "dmarc": {
                  "type": [
                    "boolean",
                    "null"
                  ]
                }
              },
              "required": [
                "name",
                "spf",
                "dmarc"
              ],
              "additionalProperties": false
            },
            "score": {
              "type": "integer",
              "minimum": 0,
              "maximum": 100
            }
          },
          "required": [
            "object",
            "input",
            "status",
            "reason",
            "did_you_mean",
            "checks",
            "domain",
            "score"
          ],
          "additionalProperties": false
        },
        {
          "type": "null"
        }
      ],
      "description": "Result of the email check in fast mode (syntax, MX, disposable, role, free provider, no SMTP)."
    },
    "email_domain_age": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "domain": {
              "type": "string"
            },
            "status": {
              "type": "string",
              "enum": [
                "found",
                "not_found",
                "unsupported",
                "error"
              ],
              "description": "found: the registry answered with the registration. not_found: the registry says the domain is not registered. unsupported: the TLD has no public RDAP service. error: the registry did not answer."
            },
            "created_at": {
              "type": [
                "string",
                "null"
              ]
            },
            "age_days": {
              "anyOf": [
                {
                  "type": "integer",
                  "minimum": -9007199254740991,
                  "maximum": 9007199254740991
                },
                {
                  "type": "null"
                }
              ]
            },
            "registrar": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "required": [
            "domain",
            "status",
            "created_at",
            "age_days",
            "registrar"
          ],
          "additionalProperties": false
        },
        {
          "type": "null"
        }
      ],
      "description": "Registration of the email domain over RDAP. Null for free mailbox providers and when no email was sent."
    },
    "phone": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "object": {
              "type": "string",
              "const": "phone"
            },
            "input": {
              "type": "string"
            },
            "valid": {
              "type": "boolean"
            },
            "status": {
              "type": "string",
              "enum": [
                "valid",
                "invalid",
                "unknown"
              ]
            },
            "e164": {
              "type": [
                "string",
                "null"
              ]
            },
            "national": {
              "type": [
                "string",
                "null"
              ]
            },
            "country": {
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "code": {
                      "type": "string",
                      "minLength": 2,
                      "maxLength": 2
                    },
                    "name": {
                      "type": "string"
                    },
                    "calling_code": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "name",
                    "calling_code"
                  ],
                  "additionalProperties": false
                },
                {
                  "type": "null"
                }
              ]
            },
            "region": {
              "type": [
                "string",
                "null"
              ]
            },
            "timezones": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "line_type": {
              "type": "string",
              "enum": [
                "mobile",
                "landline",
                "fixed_line_or_mobile",
                "voip",
                "toll_free",
                "premium_rate",
                "shared_cost",
                "personal_number",
                "pager",
                "uan",
                "voicemail",
                "unknown"
              ]
            },
            "carrier": {
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "name": {
                      "description": "Carrier name.",
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "mcc": {
                      "description": "Mobile country code, live level only.",
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "mnc": {
                      "description": "Mobile network code, live level only.",
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "source": {
                      "type": "string",
                      "enum": [
                        "live",
                        "numbering_plan"
                      ],
                      "description": "`numbering_plan`: the carrier the range was originally assigned to; it cannot see ported or disconnected lines. `live`: the carrier currently serving the number."
                    }
                  },
                  "required": [
                    "name",
                    "mcc",
                    "mnc",
                    "source"
                  ],
                  "additionalProperties": false
                },
                {
                  "type": "null"
                }
              ]
            },
            "ported": {
              "description": "Live level only. Null at basic level, which cannot detect porting.",
              "type": [
                "boolean",
                "null"
              ]
            }
          },
          "required": [
            "object",
            "input",
            "valid",
            "status",
            "e164",
            "national",
            "country",
            "region",
            "timezones",
            "line_type",
            "carrier",
            "ported"
          ],
          "additionalProperties": false
        },
        {
          "type": "null"
        }
      ],
      "description": "Result of the phone check at basic level."
    },
    "phone_reports": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "object": {
              "type": "string",
              "const": "phone_reports"
            },
            "input": {
              "type": "string"
            },
            "status": {
              "type": "string",
              "enum": [
                "reported",
                "not_reported",
                "unsupported"
              ],
              "description": "reported when at least one consumer reported the number to the FTC in the window, not_reported otherwise. unsupported for numbers outside the North American Numbering Plan, which the FTC data does not cover."
            },
            "e164": {
              "type": [
                "string",
                "null"
              ]
            },
            "reports": {
              "type": "integer",
              "minimum": 0,
              "maximum": 9007199254740991,
              "description": "Consumer complaints to the FTC Do Not Call registry that name this number as the caller, over the window."
            },
            "first_reported": {
              "anyOf": [
                {
                  "type": "string",
                  "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                },
                {
                  "type": "null"
                }
              ]
            },
            "last_reported": {
              "anyOf": [
                {
                  "type": "string",
                  "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                },
                {
                  "type": "null"
                }
              ]
            },
            "days_reported": {
              "type": "integer",
              "minimum": 0,
              "maximum": 9007199254740991,
              "description": "Days with at least one complaint."
            },
            "robocall_share": {
              "anyOf": [
                {
                  "type": "number",
                  "minimum": 0,
                  "maximum": 1
                },
                {
                  "type": "null"
                }
              ],
              "description": "Share of complaints, among those that answered the question, saying the call was a recorded message or robocall. Null when none answered."
            },
            "subjects": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "subject": {
                    "type": "string",
                    "description": "Subject the consumer picked in the FTC complaint form, as published."
                  },
                  "reports": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "subject",
                  "reports"
                ],
                "additionalProperties": false
              },
              "description": "Most reported subjects, up to 5. Complaints without a subject are left out."
            },
            "states": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "state": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 2,
                    "description": "USPS code of the state the consumer reported from."
                  },
                  "reports": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "state",
                  "reports"
                ],
                "additionalProperties": false
              },
              "description": "States the consumers reported from, up to 5."
            },
            "timeline": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "day": {
                    "type": "string",
                    "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                  },
                  "reports": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "day",
                  "reports"
                ],
                "additionalProperties": false
              },
              "description": "Complaints per day, oldest first."
            },
            "window": {
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "from": {
                      "type": "string",
                      "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                    },
                    "to": {
                      "type": "string",
                      "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                    },
                    "days": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "from",
                    "to",
                    "days"
                  ],
                  "additionalProperties": false,
                  "description": "Complaint creation days covered by the data, in Eastern time. Null until the data is loaded."
                },
                {
                  "type": "null"
                }
              ]
            },
            "verified": {
              "type": "boolean",
              "const": false,
              "description": "Always false: the FTC does not verify the reports, and caller ID can be spoofed."
            }
          },
          "required": [
            "object",
            "input",
            "status",
            "e164",
            "reports",
            "first_reported",
            "last_reported",
            "days_reported",
            "robocall_share",
            "subjects",
            "states",
            "timeline",
            "window",
            "verified"
          ],
          "additionalProperties": false
        },
        {
          "type": "null"
        }
      ],
      "description": "FTC consumer reports of the phone number, North American numbers only."
    },
    "ip": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "object": {
              "type": "string",
              "const": "ip"
            },
            "input": {
              "type": "string"
            },
            "version": {
              "anyOf": [
                {
                  "type": "number",
                  "const": 4
                },
                {
                  "type": "number",
                  "const": 6
                }
              ]
            },
            "country": {
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "code": {
                      "type": "string",
                      "minLength": 2,
                      "maxLength": 2,
                      "description": "ISO 3166-1 alpha-2 code."
                    },
                    "name": {
                      "type": "string",
                      "description": "English short name."
                    }
                  },
                  "required": [
                    "code",
                    "name"
                  ],
                  "additionalProperties": false
                },
                {
                  "type": "null"
                }
              ]
            },
            "region": {
              "type": [
                "string",
                "null"
              ]
            },
            "city": {
              "type": [
                "string",
                "null"
              ]
            },
            "asn": {
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "number": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "org": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "hosting",
                        "isp",
                        "mobile",
                        "business",
                        "education",
                        "government",
                        "unknown"
                      ]
                    }
                  },
                  "required": [
                    "number",
                    "org",
                    "type"
                  ],
                  "additionalProperties": false
                },
                {
                  "type": "null"
                }
              ]
            },
            "flags": {
              "type": "object",
              "properties": {
                "tor": {
                  "type": "boolean"
                },
                "vpn": {
                  "type": "boolean"
                },
                "proxy": {
                  "type": "boolean"
                },
                "datacenter": {
                  "type": "boolean"
                }
              },
              "required": [
                "tor",
                "vpn",
                "proxy",
                "datacenter"
              ],
              "additionalProperties": false
            },
            "risk": {
              "type": "object",
              "properties": {
                "score": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 100
                },
                "level": {
                  "type": "string",
                  "enum": [
                    "low",
                    "medium",
                    "high"
                  ]
                }
              },
              "required": [
                "score",
                "level"
              ],
              "additionalProperties": false
            }
          },
          "required": [
            "object",
            "input",
            "version",
            "country",
            "region",
            "city",
            "asn",
            "flags",
            "risk"
          ],
          "additionalProperties": false
        },
        {
          "type": "null"
        }
      ],
      "description": "Result of the IP check."
    },
    "credits_used": {
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991,
      "description": "Credits debited for this call. Cached results cost the same; failed upstream calls cost 0."
    },
    "cached": {
      "type": "boolean",
      "description": "True when the result was served from the 7-day result cache. Send `fresh: true` to bypass it."
    }
  },
  "required": [
    "id",
    "object",
    "input",
    "decision",
    "score",
    "reasons",
    "checks",
    "email",
    "email_domain_age",
    "phone",
    "phone_reports",
    "ip",
    "credits_used",
    "cached"
  ],
  "additionalProperties": false
}