{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/google-cloud-compute-engine/json-schema/google-cloud-compute-engine-public-delegated-prefix-schema.json",
  "title": "PublicDelegatedPrefix",
  "description": "A PublicDelegatedPrefix resource represents an IP block within a\nPublicAdvertisedPrefix that is configured within a single cloud scope\n(global or region). IPs in the block can be allocated to resources within\nthat scope. Public delegated prefixes may be further broken up into\nsmaller IP blocks in the same scope as the parent block.",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/google-cloud-compute-engine-global-public-delegated-prefixes-api-openapi.yml#/components/schemas/PublicDelegatedPrefix",
  "properties": {
    "id": {
      "description": "Output only. [Output Only] The unique identifier for the resource type. The server\ngenerates this identifier.",
      "format": "uint64",
      "readOnly": true,
      "type": "string"
    },
    "region": {
      "readOnly": true,
      "description": "Output only. [Output Only] URL of the region where the public delegated prefix resides.\nThis field applies only to the region resource. You must specify this\nfield as part of the HTTP request URL. It is not settable as a field in\nthe request body.",
      "type": "string"
    },
    "creationTimestamp": {
      "description": "Output only. [Output Only] Creation timestamp inRFC3339\ntext format.",
      "readOnly": true,
      "type": "string"
    },
    "byoipApiVersion": {
      "description": "Output only. [Output Only] The version of BYOIP API.",
      "type": "string",
      "readOnly": true,
      "enum": [
        "V1",
        "V2"
      ]
    },
    "enableEnhancedIpv4Allocation": {
      "description": "Output only. [Output Only] Whether this PDP supports enhanced IPv4 allocations.\nApplicable for IPv4 PDPs only.",
      "readOnly": true,
      "type": "boolean"
    },
    "description": {
      "description": "An optional description of this resource. Provide this property when you\ncreate the resource.",
      "type": "string"
    },
    "kind": {
      "readOnly": true,
      "type": "string",
      "description": "Output only. [Output Only] Type of the resource. Alwayscompute#publicDelegatedPrefix for public delegated prefixes.",
      "default": "compute#publicDelegatedPrefix"
    },
    "selfLink": {
      "readOnly": true,
      "description": "Output only. [Output Only] Server-defined URL for the resource.",
      "type": "string"
    },
    "isLiveMigration": {
      "type": "boolean",
      "description": "If true, the prefix will be live migrated."
    },
    "parentPrefix": {
      "type": "string",
      "description": "The URL of parent prefix. Either PublicAdvertisedPrefix or\nPublicDelegatedPrefix."
    },
    "allocatablePrefixLength": {
      "type": "integer",
      "description": "The allocatable prefix length supported by this public delegated prefix.\nThis field is optional and cannot be set for prefixes in DELEGATION mode.\nIt cannot be set for IPv4 prefixes either, and it always defaults to 32.",
      "format": "int32"
    },
    "ipv6AccessType": {
      "description": "Output only. [Output Only] The internet access type for IPv6 Public Delegated Prefixes.\nInherited from parent prefix.",
      "enum": [
        "EXTERNAL",
        "INTERNAL"
      ],
      "readOnly": true,
      "type": "string"
    },
    "fingerprint": {
      "description": "Fingerprint of this resource. A hash of the contents stored in this object.\nThis field is used in optimistic locking. This field will be ignored when\ninserting a new PublicDelegatedPrefix. An up-to-date\nfingerprint must be provided in order to update thePublicDelegatedPrefix, otherwise the request will fail with\nerror 412 conditionNotMet.\n\nTo see the latest fingerprint, make a get() request to\nretrieve a PublicDelegatedPrefix.",
      "format": "byte",
      "type": "string"
    },
    "name": {
      "type": "string",
      "description": "Name of the resource. Provided by the client when the resource is created.\nThe name must be 1-63 characters long, and comply withRFC1035.\nSpecifically, the name must be 1-63 characters long and match the regular\nexpression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first\ncharacter must be a lowercase letter, and all following characters must\nbe a dash, lowercase letter, or digit, except the last character, which\ncannot be a dash.",
      "pattern": "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?"
    },
    "mode": {
      "description": "The public delegated prefix mode for IPv6 only.",
      "enum": [
        "DELEGATION",
        "EXTERNAL_IPV6_FORWARDING_RULE_CREATION",
        "EXTERNAL_IPV6_SUBNETWORK_CREATION",
        "INTERNAL_IPV6_SUBNETWORK_CREATION"
      ],
      "type": "string"
    },
    "status": {
      "description": "[Output Only] The status of the public delegated prefix, which can be one\nof following values:\n   \n   \n     - `INITIALIZING` The public delegated prefix is being initialized and\n     addresses cannot be created yet.\n     - `READY_TO_ANNOUNCE` The public delegated prefix is a live migration\n     prefix and is active.\n     - `ANNOUNCED` The public delegated prefix is announced and ready to\n     use.\n     - `DELETING` The public delegated prefix is being deprovsioned.\n     - `ACTIVE` The public delegated prefix is ready to use.",
      "enum": [
        "ACTIVE",
        "ANNOUNCED",
        "ANNOUNCED_TO_GOOGLE",
        "ANNOUNCED_TO_INTERNET",
        "DELETING",
        "INITIALIZING",
        "READY_TO_ANNOUNCE"
      ],
      "type": "string"
    },
    "ipCidrRange": {
      "description": "The IP address range, in CIDR format, represented by this public\ndelegated prefix.",
      "type": "string"
    },
    "publicDelegatedSubPrefixs": {
      "description": "The list of sub public delegated prefixes that exist for this public\ndelegated prefix.",
      "items": {
        "$ref": "#/$defs/PublicDelegatedPrefixPublicDelegatedSubPrefix"
      },
      "type": "array"
    }
  },
  "type": "object",
  "$defs": {
    "PublicDelegatedPrefixPublicDelegatedSubPrefix": {
      "properties": {
        "ipv6AccessType": {
          "type": "string",
          "description": "Output only. [Output Only] The internet access type for IPv6 Public Delegated Sub\nPrefixes. Inherited from parent prefix.",
          "readOnly": true,
          "enum": [
            "EXTERNAL",
            "INTERNAL"
          ]
        },
        "allocatablePrefixLength": {
          "description": "The allocatable prefix length supported by this PublicDelegatedSubPrefix.",
          "format": "int32",
          "type": "integer"
        },
        "isAddress": {
          "description": "Whether the sub prefix is delegated to create Address resources in the\ndelegatee project.",
          "type": "boolean"
        },
        "status": {
          "type": "string",
          "description": "Output only. [Output Only] The status of the sub public delegated prefix.",
          "enum": [
            "ACTIVE",
            "INACTIVE"
          ],
          "readOnly": true
        },
        "delegateeProject": {
          "description": "Name of the project scoping this PublicDelegatedSubPrefix.",
          "type": "string"
        },
        "description": {
          "type": "string",
          "description": "An optional description of this resource. Provide this property when you\ncreate the resource."
        },
        "region": {
          "description": "Output only. [Output Only] The region of the sub public delegated prefix if it is\nregional. If absent, the sub prefix is global.",
          "type": "string",
          "readOnly": true
        },
        "ipCidrRange": {
          "type": "string",
          "description": "The IP address range, in CIDR format, represented by this sub public\ndelegated prefix."
        },
        "name": {
          "type": "string",
          "description": "The name of the sub public delegated prefix."
        },
        "enableEnhancedIpv4Allocation": {
          "type": "boolean",
          "readOnly": true,
          "description": "Output only. [Output Only] Whether this PDP supports enhanced IPv4 allocations.\nApplicable for IPv4 PDPs only."
        },
        "mode": {
          "enum": [
            "DELEGATION",
            "EXTERNAL_IPV6_FORWARDING_RULE_CREATION",
            "EXTERNAL_IPV6_SUBNETWORK_CREATION",
            "INTERNAL_IPV6_SUBNETWORK_CREATION"
          ],
          "description": "The PublicDelegatedSubPrefix mode for IPv6 only.",
          "type": "string"
        }
      },
      "type": "object",
      "description": "Represents a sub PublicDelegatedPrefix."
    }
  }
}