{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cloudfront/json-schema/cloudfront-create-function-result-schema.json",
  "title": "CreateFunctionResult",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cloudfront-functions-api-openapi.yml#/components/schemas/CreateFunctionResult",
  "type": "object",
  "properties": {
    "FunctionSummary": {
      "$ref": "#/$defs/FunctionSummary"
    },
    "Location": {
      "type": "string",
      "description": "The URL of the CloudFront function. Use the URL to manage the function with the CloudFront API."
    },
    "ETag": {
      "type": "string",
      "description": "The version identifier for the current version of the CloudFront function."
    }
  },
  "$defs": {
    "FunctionConfig": {
      "type": "object",
      "properties": {
        "Comment": {
          "type": "string",
          "description": "A comment to describe the function."
        },
        "Runtime": {
          "type": "string",
          "enum": [
            "cloudfront-js-1.0",
            "cloudfront-js-2.0"
          ],
          "description": "The function's runtime environment version."
        },
        "KeyValueStoreAssociations": {
          "$ref": "#/$defs/KeyValueStoreAssociations"
        }
      },
      "required": [
        "Comment",
        "Runtime"
      ]
    },
    "FunctionMetadata": {
      "type": "object",
      "properties": {
        "FunctionARN": {
          "type": "string",
          "description": "The Amazon Resource Name (ARN) of the function. The ARN uniquely identifies the function."
        },
        "Stage": {
          "type": "string",
          "enum": [
            "DEVELOPMENT",
            "LIVE"
          ],
          "description": "The stage that the function is in, either DEVELOPMENT or LIVE. When a function is in the DEVELOPMENT stage, you can test the function with TestFunction, and update it with UpdateFunction. When a function is in the LIVE stage, you can attach the function to a distribution's cache behavior, using the function's ARN."
        },
        "CreatedTime": {
          "type": "string",
          "format": "date-time",
          "description": "The date and time when the function was created."
        },
        "LastModifiedTime": {
          "type": "string",
          "format": "date-time",
          "description": "The date and time when the function was most recently updated."
        }
      },
      "required": [
        "FunctionARN",
        "LastModifiedTime"
      ]
    },
    "FunctionSummary": {
      "type": "object",
      "properties": {
        "Name": {
          "type": "string",
          "description": "The name of the CloudFront function."
        },
        "Status": {
          "type": "string",
          "description": "The status of the CloudFront function."
        },
        "FunctionConfig": {
          "$ref": "#/$defs/FunctionConfig"
        },
        "FunctionMetadata": {
          "$ref": "#/$defs/FunctionMetadata"
        }
      },
      "required": [
        "Name",
        "FunctionConfig",
        "FunctionMetadata"
      ]
    },
    "KeyValueStoreAssociation": {
      "type": "object",
      "properties": {
        "KeyValueStoreARN": {
          "type": "string",
          "description": "The Amazon Resource Name (ARN) of the key value store association."
        }
      },
      "required": [
        "KeyValueStoreARN"
      ]
    },
    "KeyValueStoreAssociations": {
      "type": "object",
      "properties": {
        "Quantity": {
          "type": "integer",
          "description": "The quantity of key value store associations."
        },
        "Items": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/KeyValueStoreAssociation"
          },
          "description": "The items of the key value store association."
        }
      },
      "required": [
        "Quantity"
      ]
    }
  }
}