def gen_endpoint(endpoint_name, endpoint_config_name):
    """
    Generate the endpoint resource
    """
    endpoint = {
        "SagemakerEndpoint": {
            "Type": "AWS::SageMaker::Endpoint",
            "DependsOn": "SagemakerEndpointConfig",
            "Properties": {
                "EndpointConfigName": {
                    "Fn::GetAtt": ["SagemakerEndpointConfig", "EndpointConfigName"]
                },
                "EndpointName": endpoint_name,
                "RetainAllVariantProperties": False,
            },
        },
    }

    return endpoint