SERVICEDISCOVERY

CreateHttpNamespace

valid {
    input.Body.Name == STRING
    input.Body.CreatorRequestId == STRING
    input.Body.Description == STRING
    input.Body.Tags[_].Key == STRING
    input.Body.Tags[_].Value == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

CreatePrivateDnsNamespace

valid {
    input.Body.Name == STRING
    input.Body.CreatorRequestId == STRING
    input.Body.Description == STRING
    input.Body.Vpc == STRING
    input.Body.Tags[_].Key == STRING
    input.Body.Tags[_].Value == STRING
    input.Body.Properties.DnsProperties.SOA.TTL == LONG
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

CreatePublicDnsNamespace

valid {
    input.Body.Name == STRING
    input.Body.CreatorRequestId == STRING
    input.Body.Description == STRING
    input.Body.Tags[_].Key == STRING
    input.Body.Tags[_].Value == STRING
    input.Body.Properties.DnsProperties.SOA.TTL == LONG
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

CreateService

enum_HealthCheckType := [ "HTTP", "HTTPS", "TCP" ]
enum_RecordType := [ "SRV", "A", "AAAA", "CNAME" ]
enum_RoutingPolicy := [ "MULTIVALUE", "WEIGHTED" ]
enum_ServiceTypeOption := [ "HTTP" ]

valid {
    input.Body.Name == STRING
    input.Body.NamespaceId == STRING
    input.Body.CreatorRequestId == STRING
    input.Body.Description == STRING
    input.Body.DnsConfig.NamespaceId == STRING
    input.Body.DnsConfig.RoutingPolicy == enum_RoutingPolicy[_]
    input.Body.DnsConfig.DnsRecords[_].Type == enum_RecordType[_]
    input.Body.DnsConfig.DnsRecords[_].TTL == LONG
    input.Body.HealthCheckConfig.Type == enum_HealthCheckType[_]
    input.Body.HealthCheckConfig.ResourcePath == STRING
    input.Body.HealthCheckConfig.FailureThreshold == INTEGER
    input.Body.HealthCheckCustomConfig.FailureThreshold == INTEGER
    input.Body.Tags[_].Key == STRING
    input.Body.Tags[_].Value == STRING
    input.Body.Type == enum_ServiceTypeOption[_]
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

DeleteNamespace

valid {
    input.Body.Id == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

DeleteService

valid {
    input.Body.Id == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

DeregisterInstance

valid {
    input.Body.ServiceId == STRING
    input.Body.InstanceId == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

DiscoverInstances

enum_HealthStatusFilter := [ "HEALTHY", "UNHEALTHY", "ALL", "HEALTHY_OR_ELSE_ALL" ]

valid {
    input.Body.NamespaceName == STRING
    input.Body.ServiceName == STRING
    input.Body.MaxResults == INTEGER
    input.Body.QueryParameters.STRING == STRING
    input.Body.OptionalParameters.STRING == STRING
    input.Body.HealthStatus == enum_HealthStatusFilter[_]
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

DiscoverInstancesRevision

valid {
    input.Body.NamespaceName == STRING
    input.Body.ServiceName == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

GetInstance

valid {
    input.Body.ServiceId == STRING
    input.Body.InstanceId == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

GetInstancesHealthStatus

valid {
    input.Body.ServiceId == STRING
    input.Body.Instances[_] == STRING
    input.Body.MaxResults == INTEGER
    input.Body.NextToken == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

GetNamespace

valid {
    input.Body.Id == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

GetOperation

valid {
    input.Body.OperationId == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

GetService

valid {
    input.Body.Id == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

ListInstances

valid {
    input.Body.ServiceId == STRING
    input.Body.NextToken == STRING
    input.Body.MaxResults == INTEGER
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

ListNamespaces

enum_FilterCondition := [ "EQ", "IN", "BETWEEN", "BEGINS_WITH" ]
enum_NamespaceFilterName := [ "TYPE", "NAME", "HTTP_NAME" ]

valid {
    input.Body.NextToken == STRING
    input.Body.MaxResults == INTEGER
    input.Body.Filters[_].Name == enum_NamespaceFilterName[_]
    input.Body.Filters[_].Values[_] == STRING
    input.Body.Filters[_].Condition == enum_FilterCondition[_]
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

ListOperations

enum_FilterCondition := [ "EQ", "IN", "BETWEEN", "BEGINS_WITH" ]
enum_OperationFilterName := [ "NAMESPACE_ID", "SERVICE_ID", "STATUS", "TYPE", "UPDATE_DATE" ]

valid {
    input.Body.NextToken == STRING
    input.Body.MaxResults == INTEGER
    input.Body.Filters[_].Name == enum_OperationFilterName[_]
    input.Body.Filters[_].Values[_] == STRING
    input.Body.Filters[_].Condition == enum_FilterCondition[_]
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

ListServices

enum_FilterCondition := [ "EQ", "IN", "BETWEEN", "BEGINS_WITH" ]
enum_ServiceFilterName := [ "NAMESPACE_ID" ]

valid {
    input.Body.NextToken == STRING
    input.Body.MaxResults == INTEGER
    input.Body.Filters[_].Name == enum_ServiceFilterName[_]
    input.Body.Filters[_].Values[_] == STRING
    input.Body.Filters[_].Condition == enum_FilterCondition[_]
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

ListTagsForResource

valid {
    input.Body.ResourceARN == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

RegisterInstance

valid {
    input.Body.ServiceId == STRING
    input.Body.InstanceId == STRING
    input.Body.CreatorRequestId == STRING
    input.Body.Attributes.STRING == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

TagResource

valid {
    input.Body.ResourceARN == STRING
    input.Body.Tags[_].Key == STRING
    input.Body.Tags[_].Value == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

UntagResource

valid {
    input.Body.ResourceARN == STRING
    input.Body.TagKeys[_] == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

UpdateHttpNamespace

valid {
    input.Body.Id == STRING
    input.Body.UpdaterRequestId == STRING
    input.Body.Namespace.Description == STRING
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

UpdateInstanceCustomHealthStatus

enum_CustomHealthStatus := [ "HEALTHY", "UNHEALTHY" ]

valid {
    input.Body.ServiceId == STRING
    input.Body.InstanceId == STRING
    input.Body.Status == enum_CustomHealthStatus[_]
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

UpdatePrivateDnsNamespace

valid {
    input.Body.Id == STRING
    input.Body.UpdaterRequestId == STRING
    input.Body.Namespace.Description == STRING
    input.Body.Namespace.Properties.DnsProperties.SOA.TTL == LONG
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

UpdatePublicDnsNamespace

valid {
    input.Body.Id == STRING
    input.Body.UpdaterRequestId == STRING
    input.Body.Namespace.Description == STRING
    input.Body.Namespace.Properties.DnsProperties.SOA.TTL == LONG
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}

UpdateService

enum_HealthCheckType := [ "HTTP", "HTTPS", "TCP" ]
enum_RecordType := [ "SRV", "A", "AAAA", "CNAME" ]

valid {
    input.Body.Id == STRING
    input.Body.Service.Description == STRING
    input.Body.Service.DnsConfig.DnsRecords[_].Type == enum_RecordType[_]
    input.Body.Service.DnsConfig.DnsRecords[_].TTL == LONG
    input.Body.Service.HealthCheckConfig.Type == enum_HealthCheckType[_]
    input.Body.Service.HealthCheckConfig.ResourcePath == STRING
    input.Body.Service.HealthCheckConfig.FailureThreshold == INTEGER
    input.ProviderMetadata.Account == STRING
    input.ProviderMetadata.AccessKeyId == STRING
    input.ProviderMetadata.Region == STRING
}