{
    "version": "1.1",
    "parameters": {
        "UseDualStack": {
            "builtIn": "AWS::UseDualStack",
            "required": true,
            "default": false,
            "documentation": "When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.",
            "type": "boolean"
        },
        "UseFIPS": {
            "builtIn": "AWS::UseFIPS",
            "required": true,
            "default": false,
            "documentation": "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.",
            "type": "boolean"
        },
        "Endpoint": {
            "builtIn": "SDK::Endpoint",
            "required": false,
            "documentation": "Override the endpoint used to send this request",
            "type": "string"
        },
        "Region": {
            "builtIn": "AWS::Region",
            "required": false,
            "documentation": "The AWS region used to dispatch the request.",
            "type": "string"
        }
    },
    "conditions": [
        {
            "fn": "isSet",
            "argv": [
                {
                    "ref": "Endpoint"
                }
            ]
        },
        {
            "fn": "isSet",
            "argv": [
                {
                    "ref": "Region"
                }
            ]
        },
        {
            "fn": "aws.partition",
            "argv": [
                {
                    "ref": "Region"
                }
            ],
            "assign": "PartitionResult"
        },
        {
            "fn": "booleanEquals",
            "argv": [
                {
                    "ref": "UseFIPS"
                },
                true
            ]
        },
        {
            "fn": "booleanEquals",
            "argv": [
                {
                    "fn": "getAttr",
                    "argv": [
                        {
                            "ref": "PartitionResult"
                        },
                        "supportsFIPS"
                    ]
                },
                true
            ]
        },
        {
            "fn": "booleanEquals",
            "argv": [
                {
                    "ref": "UseDualStack"
                },
                true
            ]
        },
        {
            "fn": "stringEquals",
            "argv": [
                {
                    "fn": "getAttr",
                    "argv": [
                        {
                            "ref": "PartitionResult"
                        },
                        "name"
                    ]
                },
                "aws-iso-b"
            ]
        },
        {
            "fn": "stringEquals",
            "argv": [
                {
                    "fn": "getAttr",
                    "argv": [
                        {
                            "ref": "PartitionResult"
                        },
                        "name"
                    ]
                },
                "aws-iso-e"
            ]
        },
        {
            "fn": "stringEquals",
            "argv": [
                {
                    "fn": "getAttr",
                    "argv": [
                        {
                            "ref": "PartitionResult"
                        },
                        "name"
                    ]
                },
                "aws"
            ]
        },
        {
            "fn": "stringEquals",
            "argv": [
                {
                    "fn": "getAttr",
                    "argv": [
                        {
                            "ref": "PartitionResult"
                        },
                        "name"
                    ]
                },
                "aws-iso-f"
            ]
        },
        {
            "fn": "stringEquals",
            "argv": [
                {
                    "fn": "getAttr",
                    "argv": [
                        {
                            "ref": "PartitionResult"
                        },
                        "name"
                    ]
                },
                "aws-eusc"
            ]
        },
        {
            "fn": "booleanEquals",
            "argv": [
                {
                    "fn": "getAttr",
                    "argv": [
                        {
                            "ref": "PartitionResult"
                        },
                        "supportsDualStack"
                    ]
                },
                true
            ]
        }
    ],
    "results": [
        {
            "conditions": [],
            "error": "Invalid Configuration: FIPS and custom endpoint are not supported",
            "type": "error"
        },
        {
            "conditions": [],
            "error": "Invalid Configuration: Dualstack and custom endpoint are not supported",
            "type": "error"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": {
                    "ref": "Endpoint"
                },
                "properties": {},
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets.us-east-1.api.aws",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "us-east-1"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets.global.sc2s.sgov.gov",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "us-isob-east-1"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets.global.cloud.adc-e.uk",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "eu-isoe-west-1"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets.global.csp.hci.ic.gov",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "us-isof-south-1"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets.eusc-de-east-1.api.amazonwebservices.eu",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "eusc-de-east-1"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets-fips.{PartitionResult#dualStackDnsSuffix}",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "{PartitionResult#implicitGlobalRegion}"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "error": "FIPS and DualStack are enabled, but this partition does not support one or both",
            "type": "error"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets-fips.{PartitionResult#dnsSuffix}",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "{PartitionResult#implicitGlobalRegion}"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "error": "FIPS is enabled but this partition does not support FIPS",
            "type": "error"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets.{PartitionResult#dualStackDnsSuffix}",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "{PartitionResult#implicitGlobalRegion}"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "error": "DualStack is enabled but this partition does not support DualStack",
            "type": "error"
        },
        {
            "conditions": [],
            "endpoint": {
                "url": "https://budgets.{PartitionResult#dnsSuffix}",
                "properties": {
                    "authSchemes": [
                        {
                            "name": "sigv4",
                            "signingRegion": "{PartitionResult#implicitGlobalRegion}"
                        }
                    ]
                },
                "headers": {}
            },
            "type": "endpoint"
        },
        {
            "conditions": [],
            "error": "Invalid Configuration: Missing Region",
            "type": "error"
        }
    ],
    "root": 2,
    "nodeCount": 19,
    "nodes": "/////wAAAAH/////AAAAAAAAABIAAAADAAAAAQAAAAQF9eEQAAAAAgAAAAUF9eEQAAAAAwAAAA4AAAAGAAAABQAAAAsAAAAHAAAABgX14QUAAAAIAAAABwX14QYAAAAJAAAACQX14QcAAAAKAAAACgX14QgF9eEPAAAACAX14QQAAAAMAAAACgX14QgAAAANAAAACwX14Q0F9eEOAAAABAAAABAAAAAPAAAABQX14QoF9eEMAAAABQAAABEF9eELAAAACwX14QkF9eEKAAAAAwX14QEAAAATAAAABQX14QIF9eED"
}