{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/hostinger/main/json-schema/hostinger-agency-hosting-v1-websites-website-resource-schema.json",
  "title": "AgencyHosting.V1.Websites.WebsiteResource",
  "x-generated": "2026-10-26",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/hostinger-agency-hosting-websites-api-openapi.yml#/components/schemas/AgencyHosting.V1.Websites.WebsiteResource",
  "properties": {
    "uid": {
      "description": "Website UID",
      "type": "string"
    },
    "ipv4": {
      "description": "IPv4 address",
      "type": "string"
    },
    "flavor": {
      "description": "Setup flavor",
      "type": "string"
    },
    "type": {
      "description": "Website type",
      "type": [
        "string",
        "null"
      ]
    },
    "description": {
      "description": "Description",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "Website state",
      "type": "string",
      "enum": [
        "active",
        "suspended"
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "domains": {
      "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteDomainDetailsCollection"
    },
    "preview_domain": {
      "oneOf": [
        {
          "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsitePreviewDomainResource"
        }
      ]
    },
    "settings": {
      "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteSettingsResource"
    },
    "wordpress": {
      "oneOf": [
        {
          "$ref": "#/$defs/AgencyHosting.V1.Websites.WordPressInstallResource"
        }
      ]
    },
    "remote_access": {
      "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteRemoteAccessResource"
    },
    "server": {
      "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteServerResource"
    },
    "order": {
      "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteOrderResource"
    },
    "user": {
      "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteUserResource"
    },
    "staging_root": {
      "oneOf": [
        {
          "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteStagingRootResource"
        }
      ]
    }
  },
  "type": "object",
  "$defs": {
    "AgencyHosting.V1.Websites.CustomSslCertResource": {
      "properties": {
        "is_expired": {
          "description": "Is the SSL certificate expired",
          "type": "boolean"
        },
        "expires_at": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.SslCertResource": {
      "properties": {
        "names": {
          "description": "SSL cert names",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "expires_at": {
          "type": "string",
          "format": "date-time"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteDomainDetailsCollection": {
      "description": "Array of [`AgencyHosting.V1.Websites.WebsiteDomainDetailsResource`](#model/agencyhostingv1websiteswebsitedomaindetailsresource)",
      "type": "array",
      "items": {
        "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteDomainDetailsResource"
      }
    },
    "AgencyHosting.V1.Websites.WebsiteDomainDetailsResource": {
      "properties": {
        "fqdn": {
          "description": "Domain name",
          "type": "string"
        },
        "parent_fqdn": {
          "description": "Parent domain name if the domain is a subdomain",
          "type": [
            "string",
            "null"
          ]
        },
        "ipv6": {
          "description": "IPv6 address",
          "type": [
            "string",
            "null"
          ]
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "nameservers": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "ssl_cert": {
          "oneOf": [
            {
              "$ref": "#/$defs/AgencyHosting.V1.Websites.SslCertResource"
            }
          ]
        },
        "custom_ssl_cert": {
          "oneOf": [
            {
              "$ref": "#/$defs/AgencyHosting.V1.Websites.CustomSslCertResource"
            }
          ]
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteOrderPlanResource": {
      "properties": {
        "name": {
          "description": "Plan name",
          "type": [
            "string",
            "null"
          ]
        },
        "parameters": {
          "description": "Plan parameters",
          "properties": {
            "disk_quota_bytes": {
              "description": "Disk quota in bytes",
              "type": "integer"
            },
            "inode_quota": {
              "description": "Inode quota",
              "type": "integer"
            },
            "cpu_cores": {
              "description": "CPU cores",
              "type": "integer"
            },
            "memory_quota_bytes": {
              "description": "Memory quota in bytes",
              "type": "integer"
            },
            "disk_iops_quota": {
              "description": "Disk IOPs quota",
              "type": "integer"
            },
            "process_quota": {
              "description": "Process quota",
              "type": "integer"
            },
            "website_quota": {
              "description": "Website quota",
              "type": "integer"
            },
            "max_databases_per_website": {
              "description": "Maximum number of databases per website",
              "type": "integer"
            },
            "is_cdn_available": {
              "description": "Is CDN available",
              "type": "boolean"
            }
          },
          "type": "object"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteOrderResource": {
      "properties": {
        "id": {
          "description": "Order ID",
          "type": "integer"
        },
        "status": {
          "description": "Order status",
          "type": [
            "string",
            "null"
          ]
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "plan": {
          "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteOrderPlanResource"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsitePhpSettingsResource": {
      "properties": {
        "version": {
          "description": "PHP version",
          "type": "string"
        },
        "workers": {
          "description": "Number of PHP workers",
          "type": "integer"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsitePreviewDomainResource": {
      "properties": {
        "fqdn": {
          "description": "Preview domain name",
          "type": "string"
        },
        "created_at": {
          "description": "Creation date",
          "type": "string",
          "format": "date-time"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteRemoteAccessResource": {
      "properties": {
        "mode": {
          "description": "Remote access mode",
          "type": "string"
        },
        "ssh": {
          "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteSshDetailsResource"
        },
        "sftp": {
          "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsiteSftpDetailsResource"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteServerResource": {
      "properties": {
        "hostname": {
          "description": "Server hostname",
          "type": "string"
        },
        "country_code": {
          "description": "Country code",
          "type": "string"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteSettingsResource": {
      "properties": {
        "php": {
          "oneOf": [
            {
              "$ref": "#/$defs/AgencyHosting.V1.Websites.WebsitePhpSettingsResource"
            }
          ],
          "description": "PHP settings"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteSftpDetailsResource": {
      "properties": {
        "username": {
          "description": "SFTP username",
          "type": "string"
        },
        "host": {
          "description": "SFTP host",
          "type": "string"
        },
        "port": {
          "description": "SFTP port",
          "type": "integer"
        },
        "is_enabled": {
          "description": "Is SFTP access enabled",
          "type": "boolean"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteSshDetailsResource": {
      "properties": {
        "username": {
          "description": "SSH username",
          "type": "string"
        },
        "host": {
          "description": "SSH host",
          "type": "string"
        },
        "port": {
          "description": "SSH port",
          "type": "integer"
        },
        "is_enabled": {
          "description": "Is SSH access enabled",
          "type": "boolean"
        },
        "is_password_enabled": {
          "description": "Is SSH password access enabled",
          "type": "boolean"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteStagingRootResource": {
      "properties": {
        "uid": {
          "description": "UID of the website this is a staging environment of",
          "type": "string"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WebsiteUserResource": {
      "properties": {
        "username": {
          "description": "System username",
          "type": "string"
        },
        "state": {
          "description": "User state",
          "type": "string"
        }
      },
      "type": "object"
    },
    "AgencyHosting.V1.Websites.WordPressInstallResource": {
      "properties": {
        "domain": {
          "description": "WordPress domain",
          "type": "string"
        },
        "title": {
          "description": "WordPress title",
          "type": "string"
        },
        "language": {
          "description": "WordPress language",
          "type": "string"
        },
        "is_config_locked": {
          "description": "WordPress configuration lock status",
          "type": "boolean"
        },
        "created_at": {
          "description": "Creation date",
          "type": "string",
          "format": "date-time"
        }
      },
      "type": "object"
    }
  }
}