// Code generated by smithy-go-codegen DO NOT EDIT.

//go:build request_snapshot

package appsync

import (
	"bytes"
	"context"
	"errors"
	"fmt"
	"github.com/aws/aws-sdk-go-v2/service/appsync/types"
	smithyendpoints "github.com/aws/smithy-go/endpoints"
	"github.com/aws/smithy-go/middleware"
	"github.com/aws/smithy-go/ptr"
	smithyhttp "github.com/aws/smithy-go/transport/http"
	"io"
	"io/fs"
	"net/url"
	"os"
	"slices"
	"strings"
	"testing"
)

const serdeSSPrefix = "request_snapshot"

// errSerdeSnapshotOK is returned by the capture middleware to abort the request
// pipeline once the serialized request has been captured, so no network call is
// made. It is a control signal, not a failure.
var errSerdeSnapshotOK = errors.New("serde snapshot: request captured")

func serdeCreatePath(path string) (*os.File, error) {
	if err := os.MkdirAll(serdeSSPrefix, 0700); err != nil && !errors.Is(err, fs.ErrExist) {
		return nil, err
	}
	return os.Create(path)
}

func serdeSSPath(op string) string {
	return fmt.Sprintf("%s/%s.request.snap", serdeSSPrefix, op)
}

type captureSerdeRequestMiddleware struct {
	body     *bytes.Buffer
	method   *string
	rawPath  *string
	rawQuery *string
	header   *map[string][]string
}

func (*captureSerdeRequestMiddleware) ID() string { return "captureSerdeRequest" }

func (m *captureSerdeRequestMiddleware) HandleFinalize(
	ctx context.Context, input middleware.FinalizeInput, next middleware.FinalizeHandler,
) (
	middleware.FinalizeOutput, middleware.Metadata, error,
) {
	req, ok := input.Request.(*smithyhttp.Request)
	if !ok {
		return middleware.FinalizeOutput{}, middleware.Metadata{}, fmt.Errorf("unexpected transport type %T", input.Request)
	}

	built := req.Build(ctx)
	*m.method = built.Method
	*m.rawPath = built.URL.RawPath
	if *m.rawPath == "" {
		*m.rawPath = built.URL.Path
	}
	*m.rawQuery = built.URL.RawQuery
	*m.header = built.Header

	if built.Body != nil {
		if _, err := io.Copy(m.body, built.Body); err != nil {
			return middleware.FinalizeOutput{}, middleware.Metadata{}, err
		}
	}

	return middleware.FinalizeOutput{}, middleware.Metadata{}, errSerdeSnapshotOK
}

func serdeFormatRequest(method, rawPath, rawQuery string, header map[string][]string, body []byte) string {
	skipHeaders := map[string]bool{
		"Authorization":         true,
		"User-Agent":            true,
		"X-Amz-Date":            true,
		"X-Amz-Security-Token":  true,
		"Amz-Sdk-Invocation-Id": true,
		"Amz-Sdk-Request":       true,
	}

	var sb strings.Builder
	sb.WriteString(method)
	sb.WriteString(" ")
	sb.WriteString(rawPath)
	if rawQuery != "" {
		sb.WriteString("?")
		sb.WriteString(rawQuery)
	}
	sb.WriteString("\n\n")

	keys := make([]string, 0, len(header))
	for k := range header {
		if skipHeaders[k] {
			continue
		}
		keys = append(keys, k)
	}
	slices.Sort(keys)
	for _, k := range keys {
		for _, v := range header[k] {
			sb.WriteString(k)
			sb.WriteString(": ")
			sb.WriteString(v)
			sb.WriteString("\n")
		}
	}
	sb.WriteString("\n")
	if len(body) > 0 {
		sb.Write(body)
	}
	return sb.String()
}

func serdeUpdateSnapshot(method, rawPath, rawQuery string, header map[string][]string, body []byte, operation string) error {
	content := serdeFormatRequest(method, rawPath, rawQuery, header, body)
	// Leave the snapshot untouched if it's semantically equal to the new one.
	// Some protocols (rpcv2Cbor) serialize map/struct fields in a nondeterministic
	// byte order, so a blind rewrite would churn the file on every run.
	if existing, err := os.ReadFile(serdeSSPath(operation)); err == nil {
		prefix := serdeFormatRequest(method, rawPath, rawQuery, header, nil)
		if strings.HasPrefix(string(existing), prefix) &&
			serdeBodyEqual(body, []byte(string(existing)[len(prefix):])) {
			return nil
		}
	}
	f, err := serdeCreatePath(serdeSSPath(operation))
	if err != nil {
		return err
	}
	defer f.Close()
	if _, err := f.Write([]byte(content)); err != nil {
		return err
	}
	return nil
}

func serdeTestSnapshot(method, rawPath, rawQuery string, header map[string][]string, body []byte, operation string) error {
	f, err := os.Open(serdeSSPath(operation))
	if errors.Is(err, fs.ErrNotExist) {
		return nil
	}
	if err != nil {
		return err
	}
	defer f.Close()
	expected, err := io.ReadAll(f)
	if err != nil {
		return err
	}
	prefix := serdeFormatRequest(method, rawPath, rawQuery, header, nil)
	if !strings.HasPrefix(string(expected), prefix) ||
		!serdeBodyEqual(body, []byte(string(expected)[len(prefix):])) {
		content := serdeFormatRequest(method, rawPath, rawQuery, header, body)
		return fmt.Errorf("serde snapshot mismatch for %s:\nGOT:\n%s:\nEXPECTED:\n%s", operation, content, string(expected))
	}
	return nil
}

type serdeEndpointResolver struct{}

func (*serdeEndpointResolver) ResolveEndpoint(ctx context.Context, params EndpointParameters) (smithyendpoints.Endpoint, error) {
	return smithyendpoints.Endpoint{URI: url.URL{Scheme: "https", Host: "test.example.com"}}, nil
}

func serdeNewClient() *Client {
	return New(Options{
		Region:             "us-east-1",
		EndpointResolverV2: &serdeEndpointResolver{},
	})
}
func serdeBodyEqual(got, expected []byte) bool {
	return bytes.Equal(got, expected)
}
func TestCheckRequestSnapshot_AssociateApi(t *testing.T) {
	input := &AssociateApiInput{
		DomainName: ptr.String("__DomainName__"),
		ApiId:      ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.AssociateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "AssociateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_AssociateMergedGraphqlApi(t *testing.T) {
	input := &AssociateMergedGraphqlApiInput{
		SourceApiIdentifier: ptr.String("__SourceApiIdentifier__"),
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		Description:         ptr.String("__Description__"),
		SourceApiAssociationConfig: &types.SourceApiAssociationConfig{
			MergeType: types.MergeType("MANUAL_MERGE"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.AssociateMergedGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "AssociateMergedGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_AssociateSourceGraphqlApi(t *testing.T) {
	input := &AssociateSourceGraphqlApiInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		SourceApiIdentifier: ptr.String("__SourceApiIdentifier__"),
		Description:         ptr.String("__Description__"),
		SourceApiAssociationConfig: &types.SourceApiAssociationConfig{
			MergeType: types.MergeType("MANUAL_MERGE"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.AssociateSourceGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "AssociateSourceGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateApi(t *testing.T) {
	input := &CreateApiInput{
		Name:         ptr.String("__Name__"),
		OwnerContact: ptr.String("__OwnerContact__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
		EventConfig: &types.EventConfig{
			AuthProviders: []types.AuthProvider{
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
			},
			ConnectionAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultPublishAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultSubscribeAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			LogConfig: &types.EventLogConfig{
				LogLevel:              types.EventLogLevel("NONE"),
				CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateApiCache(t *testing.T) {
	input := &CreateApiCacheInput{
		ApiId:                    ptr.String("__ApiId__"),
		Ttl:                      1,
		TransitEncryptionEnabled: true,
		AtRestEncryptionEnabled:  true,
		ApiCachingBehavior:       types.ApiCachingBehavior("FULL_REQUEST_CACHING"),
		Type:                     types.ApiCacheType("T2_SMALL"),
		HealthMetricsConfig:      types.CacheHealthMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateApiKey(t *testing.T) {
	input := &CreateApiKeyInput{
		ApiId:       ptr.String("__ApiId__"),
		Description: ptr.String("__Description__"),
		Expires:     1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateApiKey(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateApiKey"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateChannelNamespace(t *testing.T) {
	input := &CreateChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
		SubscribeAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		PublishAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		CodeHandlers: ptr.String("__CodeHandlers__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
		HandlerConfigs: &types.HandlerConfigs{
			OnPublish: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
			OnSubscribe: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateDataSource(t *testing.T) {
	input := &CreateDataSourceInput{
		ApiId:          ptr.String("__ApiId__"),
		Name:           ptr.String("__Name__"),
		Description:    ptr.String("__Description__"),
		Type:           types.DataSourceType("AWS_LAMBDA"),
		ServiceRoleArn: ptr.String("__ServiceRoleArn__"),
		DynamodbConfig: &types.DynamodbDataSourceConfig{
			TableName:            ptr.String("__TableName__"),
			AwsRegion:            ptr.String("__AwsRegion__"),
			UseCallerCredentials: true,
			DeltaSyncConfig: &types.DeltaSyncConfig{
				BaseTableTTL:       1,
				DeltaSyncTableName: ptr.String("__DeltaSyncTableName__"),
				DeltaSyncTableTTL:  1,
			},
			Versioned: true,
		},
		LambdaConfig: &types.LambdaDataSourceConfig{
			LambdaFunctionArn: ptr.String("__LambdaFunctionArn__"),
		},
		ElasticsearchConfig: &types.ElasticsearchDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		OpenSearchServiceConfig: &types.OpenSearchServiceDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		HttpConfig: &types.HttpDataSourceConfig{
			Endpoint: ptr.String("__Endpoint__"),
			AuthorizationConfig: &types.AuthorizationConfig{
				AuthorizationType: types.AuthorizationType("AWS_IAM"),
				AwsIamConfig: &types.AwsIamConfig{
					SigningRegion:      ptr.String("__SigningRegion__"),
					SigningServiceName: ptr.String("__SigningServiceName__"),
				},
			},
		},
		RelationalDatabaseConfig: &types.RelationalDatabaseDataSourceConfig{
			RelationalDatabaseSourceType: types.RelationalDatabaseSourceType("RDS_HTTP_ENDPOINT"),
			RdsHttpEndpointConfig: &types.RdsHttpEndpointConfig{
				AwsRegion:           ptr.String("__AwsRegion__"),
				DbClusterIdentifier: ptr.String("__DbClusterIdentifier__"),
				DatabaseName:        ptr.String("__DatabaseName__"),
				Schema:              ptr.String("__Schema__"),
				AwsSecretStoreArn:   ptr.String("__AwsSecretStoreArn__"),
			},
		},
		EventBridgeConfig: &types.EventBridgeDataSourceConfig{
			EventBusArn: ptr.String("__EventBusArn__"),
		},
		MetricsConfig: types.DataSourceLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateDomainName(t *testing.T) {
	input := &CreateDomainNameInput{
		DomainName:     ptr.String("__DomainName__"),
		CertificateArn: ptr.String("__CertificateArn__"),
		Description:    ptr.String("__Description__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateFunction(t *testing.T) {
	input := &CreateFunctionInput{
		ApiId:                   ptr.String("__ApiId__"),
		Name:                    ptr.String("__Name__"),
		Description:             ptr.String("__Description__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		FunctionVersion:         ptr.String("__FunctionVersion__"),
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code: ptr.String("__Code__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateGraphqlApi(t *testing.T) {
	input := &CreateGraphqlApiInput{
		Name: ptr.String("__Name__"),
		LogConfig: &types.LogConfig{
			FieldLogLevel:         types.FieldLogLevel("NONE"),
			CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			ExcludeVerboseContent: true,
		},
		AuthenticationType: types.AuthenticationType("API_KEY"),
		UserPoolConfig: &types.UserPoolConfig{
			UserPoolId:       ptr.String("__UserPoolId__"),
			AwsRegion:        ptr.String("__AwsRegion__"),
			DefaultAction:    types.DefaultAction("ALLOW"),
			AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
		},
		OpenIDConnectConfig: &types.OpenIDConnectConfig{
			Issuer:   ptr.String("__Issuer__"),
			ClientId: ptr.String("__ClientId__"),
			IatTTL:   1,
			AuthTTL:  1,
		},
		Tags: map[string]string{
			"key0": "__Value__",
		},
		AdditionalAuthenticationProviders: []types.AdditionalAuthenticationProvider{
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
		},
		XrayEnabled: true,
		LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
			AuthorizerResultTtlInSeconds: 1,
			AuthorizerUri:                ptr.String("__AuthorizerUri__"),
			IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
		},
		ApiType:                   types.GraphQLApiType("GRAPHQL"),
		MergedApiExecutionRoleArn: ptr.String("__MergedApiExecutionRoleArn__"),
		Visibility:                types.GraphQLApiVisibility("GLOBAL"),
		OwnerContact:              ptr.String("__OwnerContact__"),
		IntrospectionConfig:       types.GraphQLApiIntrospectionConfig("ENABLED"),
		QueryDepthLimit:           1,
		ResolverCountLimit:        1,
		EnhancedMetricsConfig: &types.EnhancedMetricsConfig{
			ResolverLevelMetricsBehavior:   types.ResolverLevelMetricsBehavior("FULL_REQUEST_RESOLVER_METRICS"),
			DataSourceLevelMetricsBehavior: types.DataSourceLevelMetricsBehavior("FULL_REQUEST_DATA_SOURCE_METRICS"),
			OperationLevelMetricsConfig:    types.OperationLevelMetricsConfig("ENABLED"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateResolver(t *testing.T) {
	input := &CreateResolverInput{
		ApiId:                   ptr.String("__ApiId__"),
		TypeName:                ptr.String("__TypeName__"),
		FieldName:               ptr.String("__FieldName__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		Kind:                    types.ResolverKind("UNIT"),
		PipelineConfig: &types.PipelineConfig{
			Functions: []string{
				"__Member__",
				"__Member__",
			},
		},
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		CachingConfig: &types.CachingConfig{
			Ttl: 1,
			CachingKeys: []string{
				"__Member__",
				"__Member__",
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code:          ptr.String("__Code__"),
		MetricsConfig: types.ResolverLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_CreateType(t *testing.T) {
	input := &CreateTypeInput{
		ApiId:      ptr.String("__ApiId__"),
		Definition: ptr.String("__Definition__"),
		Format:     types.TypeDefinitionFormat("SDL"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateType"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteApi(t *testing.T) {
	input := &DeleteApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteApiCache(t *testing.T) {
	input := &DeleteApiCacheInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteApiKey(t *testing.T) {
	input := &DeleteApiKeyInput{
		ApiId: ptr.String("__ApiId__"),
		Id:    ptr.String("__Id__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteApiKey(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteApiKey"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteChannelNamespace(t *testing.T) {
	input := &DeleteChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteDataSource(t *testing.T) {
	input := &DeleteDataSourceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteDomainName(t *testing.T) {
	input := &DeleteDomainNameInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteFunction(t *testing.T) {
	input := &DeleteFunctionInput{
		ApiId:      ptr.String("__ApiId__"),
		FunctionId: ptr.String("__FunctionId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteGraphqlApi(t *testing.T) {
	input := &DeleteGraphqlApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteResolver(t *testing.T) {
	input := &DeleteResolverInput{
		ApiId:     ptr.String("__ApiId__"),
		TypeName:  ptr.String("__TypeName__"),
		FieldName: ptr.String("__FieldName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DeleteType(t *testing.T) {
	input := &DeleteTypeInput{
		ApiId:    ptr.String("__ApiId__"),
		TypeName: ptr.String("__TypeName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteType"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DisassociateApi(t *testing.T) {
	input := &DisassociateApiInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DisassociateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DisassociateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DisassociateMergedGraphqlApi(t *testing.T) {
	input := &DisassociateMergedGraphqlApiInput{
		SourceApiIdentifier: ptr.String("__SourceApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DisassociateMergedGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DisassociateMergedGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_DisassociateSourceGraphqlApi(t *testing.T) {
	input := &DisassociateSourceGraphqlApiInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DisassociateSourceGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DisassociateSourceGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_EvaluateCode(t *testing.T) {
	input := &EvaluateCodeInput{
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code:     ptr.String("__Code__"),
		Context:  ptr.String("__Context__"),
		Function: ptr.String("__Function__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.EvaluateCode(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "EvaluateCode"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_EvaluateMappingTemplate(t *testing.T) {
	input := &EvaluateMappingTemplateInput{
		Template: ptr.String("__Template__"),
		Context:  ptr.String("__Context__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.EvaluateMappingTemplate(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "EvaluateMappingTemplate"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_FlushApiCache(t *testing.T) {
	input := &FlushApiCacheInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.FlushApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "FlushApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetApi(t *testing.T) {
	input := &GetApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetApiAssociation(t *testing.T) {
	input := &GetApiAssociationInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetApiAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetApiAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetApiCache(t *testing.T) {
	input := &GetApiCacheInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetChannelNamespace(t *testing.T) {
	input := &GetChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetDataSource(t *testing.T) {
	input := &GetDataSourceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetDataSourceIntrospection(t *testing.T) {
	input := &GetDataSourceIntrospectionInput{
		IntrospectionId:  ptr.String("__IntrospectionId__"),
		IncludeModelsSDL: true,
		NextToken:        ptr.String("__NextToken__"),
		MaxResults:       1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetDataSourceIntrospection(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetDataSourceIntrospection"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetDomainName(t *testing.T) {
	input := &GetDomainNameInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetFunction(t *testing.T) {
	input := &GetFunctionInput{
		ApiId:      ptr.String("__ApiId__"),
		FunctionId: ptr.String("__FunctionId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetGraphqlApi(t *testing.T) {
	input := &GetGraphqlApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetGraphqlApiEnvironmentVariables(t *testing.T) {
	input := &GetGraphqlApiEnvironmentVariablesInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetGraphqlApiEnvironmentVariables(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetGraphqlApiEnvironmentVariables"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetIntrospectionSchema(t *testing.T) {
	input := &GetIntrospectionSchemaInput{
		ApiId:             ptr.String("__ApiId__"),
		Format:            types.OutputType("SDL"),
		IncludeDirectives: ptr.Bool(true),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetIntrospectionSchema(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetIntrospectionSchema"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetResolver(t *testing.T) {
	input := &GetResolverInput{
		ApiId:     ptr.String("__ApiId__"),
		TypeName:  ptr.String("__TypeName__"),
		FieldName: ptr.String("__FieldName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetSchemaCreationStatus(t *testing.T) {
	input := &GetSchemaCreationStatusInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetSchemaCreationStatus(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetSchemaCreationStatus"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetSourceApiAssociation(t *testing.T) {
	input := &GetSourceApiAssociationInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetSourceApiAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetSourceApiAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_GetType(t *testing.T) {
	input := &GetTypeInput{
		ApiId:    ptr.String("__ApiId__"),
		TypeName: ptr.String("__TypeName__"),
		Format:   types.TypeDefinitionFormat("SDL"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetType"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListApiKeys(t *testing.T) {
	input := &ListApiKeysInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListApiKeys(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListApiKeys"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListApis(t *testing.T) {
	input := &ListApisInput{
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListApis(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListApis"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListChannelNamespaces(t *testing.T) {
	input := &ListChannelNamespacesInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListChannelNamespaces(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListChannelNamespaces"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListDataSources(t *testing.T) {
	input := &ListDataSourcesInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListDataSources(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListDataSources"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListDomainNames(t *testing.T) {
	input := &ListDomainNamesInput{
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListDomainNames(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListDomainNames"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListFunctions(t *testing.T) {
	input := &ListFunctionsInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListFunctions(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListFunctions"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListGraphqlApis(t *testing.T) {
	input := &ListGraphqlApisInput{
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
		ApiType:    types.GraphQLApiType("GRAPHQL"),
		Owner:      types.Ownership("CURRENT_ACCOUNT"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListGraphqlApis(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListGraphqlApis"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListResolvers(t *testing.T) {
	input := &ListResolversInput{
		ApiId:      ptr.String("__ApiId__"),
		TypeName:   ptr.String("__TypeName__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListResolvers(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListResolvers"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListResolversByFunction(t *testing.T) {
	input := &ListResolversByFunctionInput{
		ApiId:      ptr.String("__ApiId__"),
		FunctionId: ptr.String("__FunctionId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListResolversByFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListResolversByFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListSourceApiAssociations(t *testing.T) {
	input := &ListSourceApiAssociationsInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListSourceApiAssociations(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListSourceApiAssociations"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListTagsForResource(t *testing.T) {
	input := &ListTagsForResourceInput{
		ResourceArn: ptr.String("__ResourceArn__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListTagsForResource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListTagsForResource"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListTypes(t *testing.T) {
	input := &ListTypesInput{
		ApiId:      ptr.String("__ApiId__"),
		Format:     types.TypeDefinitionFormat("SDL"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListTypes(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListTypes"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_ListTypesByAssociation(t *testing.T) {
	input := &ListTypesByAssociationInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
		Format:              types.TypeDefinitionFormat("SDL"),
		NextToken:           ptr.String("__NextToken__"),
		MaxResults:          1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListTypesByAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListTypesByAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_PutGraphqlApiEnvironmentVariables(t *testing.T) {
	input := &PutGraphqlApiEnvironmentVariablesInput{
		ApiId: ptr.String("__ApiId__"),
		EnvironmentVariables: map[string]string{
			"key0": "__Value__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.PutGraphqlApiEnvironmentVariables(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "PutGraphqlApiEnvironmentVariables"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_StartDataSourceIntrospection(t *testing.T) {
	input := &StartDataSourceIntrospectionInput{
		RdsDataApiConfig: &types.RdsDataApiConfig{
			ResourceArn:  ptr.String("__ResourceArn__"),
			SecretArn:    ptr.String("__SecretArn__"),
			DatabaseName: ptr.String("__DatabaseName__"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.StartDataSourceIntrospection(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "StartDataSourceIntrospection"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_StartSchemaCreation(t *testing.T) {
	input := &StartSchemaCreationInput{
		ApiId:      ptr.String("__ApiId__"),
		Definition: []byte("blob"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.StartSchemaCreation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "StartSchemaCreation"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_StartSchemaMerge(t *testing.T) {
	input := &StartSchemaMergeInput{
		AssociationId:       ptr.String("__AssociationId__"),
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.StartSchemaMerge(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "StartSchemaMerge"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_TagResource(t *testing.T) {
	input := &TagResourceInput{
		ResourceArn: ptr.String("__ResourceArn__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.TagResource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "TagResource"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UntagResource(t *testing.T) {
	input := &UntagResourceInput{
		ResourceArn: ptr.String("__ResourceArn__"),
		TagKeys: []string{
			"__Member__",
			"__Member__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UntagResource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UntagResource"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateApi(t *testing.T) {
	input := &UpdateApiInput{
		ApiId:        ptr.String("__ApiId__"),
		Name:         ptr.String("__Name__"),
		OwnerContact: ptr.String("__OwnerContact__"),
		EventConfig: &types.EventConfig{
			AuthProviders: []types.AuthProvider{
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
			},
			ConnectionAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultPublishAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultSubscribeAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			LogConfig: &types.EventLogConfig{
				LogLevel:              types.EventLogLevel("NONE"),
				CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateApiCache(t *testing.T) {
	input := &UpdateApiCacheInput{
		ApiId:               ptr.String("__ApiId__"),
		Ttl:                 1,
		ApiCachingBehavior:  types.ApiCachingBehavior("FULL_REQUEST_CACHING"),
		Type:                types.ApiCacheType("T2_SMALL"),
		HealthMetricsConfig: types.CacheHealthMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateApiKey(t *testing.T) {
	input := &UpdateApiKeyInput{
		ApiId:       ptr.String("__ApiId__"),
		Id:          ptr.String("__Id__"),
		Description: ptr.String("__Description__"),
		Expires:     1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateApiKey(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateApiKey"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateChannelNamespace(t *testing.T) {
	input := &UpdateChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
		SubscribeAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		PublishAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		CodeHandlers: ptr.String("__CodeHandlers__"),
		HandlerConfigs: &types.HandlerConfigs{
			OnPublish: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
			OnSubscribe: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateDataSource(t *testing.T) {
	input := &UpdateDataSourceInput{
		ApiId:          ptr.String("__ApiId__"),
		Name:           ptr.String("__Name__"),
		Description:    ptr.String("__Description__"),
		Type:           types.DataSourceType("AWS_LAMBDA"),
		ServiceRoleArn: ptr.String("__ServiceRoleArn__"),
		DynamodbConfig: &types.DynamodbDataSourceConfig{
			TableName:            ptr.String("__TableName__"),
			AwsRegion:            ptr.String("__AwsRegion__"),
			UseCallerCredentials: true,
			DeltaSyncConfig: &types.DeltaSyncConfig{
				BaseTableTTL:       1,
				DeltaSyncTableName: ptr.String("__DeltaSyncTableName__"),
				DeltaSyncTableTTL:  1,
			},
			Versioned: true,
		},
		LambdaConfig: &types.LambdaDataSourceConfig{
			LambdaFunctionArn: ptr.String("__LambdaFunctionArn__"),
		},
		ElasticsearchConfig: &types.ElasticsearchDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		OpenSearchServiceConfig: &types.OpenSearchServiceDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		HttpConfig: &types.HttpDataSourceConfig{
			Endpoint: ptr.String("__Endpoint__"),
			AuthorizationConfig: &types.AuthorizationConfig{
				AuthorizationType: types.AuthorizationType("AWS_IAM"),
				AwsIamConfig: &types.AwsIamConfig{
					SigningRegion:      ptr.String("__SigningRegion__"),
					SigningServiceName: ptr.String("__SigningServiceName__"),
				},
			},
		},
		RelationalDatabaseConfig: &types.RelationalDatabaseDataSourceConfig{
			RelationalDatabaseSourceType: types.RelationalDatabaseSourceType("RDS_HTTP_ENDPOINT"),
			RdsHttpEndpointConfig: &types.RdsHttpEndpointConfig{
				AwsRegion:           ptr.String("__AwsRegion__"),
				DbClusterIdentifier: ptr.String("__DbClusterIdentifier__"),
				DatabaseName:        ptr.String("__DatabaseName__"),
				Schema:              ptr.String("__Schema__"),
				AwsSecretStoreArn:   ptr.String("__AwsSecretStoreArn__"),
			},
		},
		EventBridgeConfig: &types.EventBridgeDataSourceConfig{
			EventBusArn: ptr.String("__EventBusArn__"),
		},
		MetricsConfig: types.DataSourceLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateDomainName(t *testing.T) {
	input := &UpdateDomainNameInput{
		DomainName:  ptr.String("__DomainName__"),
		Description: ptr.String("__Description__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateFunction(t *testing.T) {
	input := &UpdateFunctionInput{
		ApiId:                   ptr.String("__ApiId__"),
		Name:                    ptr.String("__Name__"),
		Description:             ptr.String("__Description__"),
		FunctionId:              ptr.String("__FunctionId__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		FunctionVersion:         ptr.String("__FunctionVersion__"),
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code: ptr.String("__Code__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateGraphqlApi(t *testing.T) {
	input := &UpdateGraphqlApiInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
		LogConfig: &types.LogConfig{
			FieldLogLevel:         types.FieldLogLevel("NONE"),
			CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			ExcludeVerboseContent: true,
		},
		AuthenticationType: types.AuthenticationType("API_KEY"),
		UserPoolConfig: &types.UserPoolConfig{
			UserPoolId:       ptr.String("__UserPoolId__"),
			AwsRegion:        ptr.String("__AwsRegion__"),
			DefaultAction:    types.DefaultAction("ALLOW"),
			AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
		},
		OpenIDConnectConfig: &types.OpenIDConnectConfig{
			Issuer:   ptr.String("__Issuer__"),
			ClientId: ptr.String("__ClientId__"),
			IatTTL:   1,
			AuthTTL:  1,
		},
		AdditionalAuthenticationProviders: []types.AdditionalAuthenticationProvider{
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
		},
		XrayEnabled: true,
		LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
			AuthorizerResultTtlInSeconds: 1,
			AuthorizerUri:                ptr.String("__AuthorizerUri__"),
			IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
		},
		MergedApiExecutionRoleArn: ptr.String("__MergedApiExecutionRoleArn__"),
		OwnerContact:              ptr.String("__OwnerContact__"),
		IntrospectionConfig:       types.GraphQLApiIntrospectionConfig("ENABLED"),
		QueryDepthLimit:           1,
		ResolverCountLimit:        1,
		EnhancedMetricsConfig: &types.EnhancedMetricsConfig{
			ResolverLevelMetricsBehavior:   types.ResolverLevelMetricsBehavior("FULL_REQUEST_RESOLVER_METRICS"),
			DataSourceLevelMetricsBehavior: types.DataSourceLevelMetricsBehavior("FULL_REQUEST_DATA_SOURCE_METRICS"),
			OperationLevelMetricsConfig:    types.OperationLevelMetricsConfig("ENABLED"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateResolver(t *testing.T) {
	input := &UpdateResolverInput{
		ApiId:                   ptr.String("__ApiId__"),
		TypeName:                ptr.String("__TypeName__"),
		FieldName:               ptr.String("__FieldName__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		Kind:                    types.ResolverKind("UNIT"),
		PipelineConfig: &types.PipelineConfig{
			Functions: []string{
				"__Member__",
				"__Member__",
			},
		},
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		CachingConfig: &types.CachingConfig{
			Ttl: 1,
			CachingKeys: []string{
				"__Member__",
				"__Member__",
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code:          ptr.String("__Code__"),
		MetricsConfig: types.ResolverLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateSourceApiAssociation(t *testing.T) {
	input := &UpdateSourceApiAssociationInput{
		AssociationId:       ptr.String("__AssociationId__"),
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		Description:         ptr.String("__Description__"),
		SourceApiAssociationConfig: &types.SourceApiAssociationConfig{
			MergeType: types.MergeType("MANUAL_MERGE"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateSourceApiAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateSourceApiAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestCheckRequestSnapshot_UpdateType(t *testing.T) {
	input := &UpdateTypeInput{
		ApiId:      ptr.String("__ApiId__"),
		TypeName:   ptr.String("__TypeName__"),
		Definition: ptr.String("__Definition__"),
		Format:     types.TypeDefinitionFormat("SDL"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeTestSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateType"); err != nil {
		t.Fatal(err)
	}
}
func TestUpdateRequestSnapshot_AssociateApi(t *testing.T) {
	input := &AssociateApiInput{
		DomainName: ptr.String("__DomainName__"),
		ApiId:      ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.AssociateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "AssociateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_AssociateMergedGraphqlApi(t *testing.T) {
	input := &AssociateMergedGraphqlApiInput{
		SourceApiIdentifier: ptr.String("__SourceApiIdentifier__"),
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		Description:         ptr.String("__Description__"),
		SourceApiAssociationConfig: &types.SourceApiAssociationConfig{
			MergeType: types.MergeType("MANUAL_MERGE"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.AssociateMergedGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "AssociateMergedGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_AssociateSourceGraphqlApi(t *testing.T) {
	input := &AssociateSourceGraphqlApiInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		SourceApiIdentifier: ptr.String("__SourceApiIdentifier__"),
		Description:         ptr.String("__Description__"),
		SourceApiAssociationConfig: &types.SourceApiAssociationConfig{
			MergeType: types.MergeType("MANUAL_MERGE"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.AssociateSourceGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "AssociateSourceGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateApi(t *testing.T) {
	input := &CreateApiInput{
		Name:         ptr.String("__Name__"),
		OwnerContact: ptr.String("__OwnerContact__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
		EventConfig: &types.EventConfig{
			AuthProviders: []types.AuthProvider{
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
			},
			ConnectionAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultPublishAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultSubscribeAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			LogConfig: &types.EventLogConfig{
				LogLevel:              types.EventLogLevel("NONE"),
				CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateApiCache(t *testing.T) {
	input := &CreateApiCacheInput{
		ApiId:                    ptr.String("__ApiId__"),
		Ttl:                      1,
		TransitEncryptionEnabled: true,
		AtRestEncryptionEnabled:  true,
		ApiCachingBehavior:       types.ApiCachingBehavior("FULL_REQUEST_CACHING"),
		Type:                     types.ApiCacheType("T2_SMALL"),
		HealthMetricsConfig:      types.CacheHealthMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateApiKey(t *testing.T) {
	input := &CreateApiKeyInput{
		ApiId:       ptr.String("__ApiId__"),
		Description: ptr.String("__Description__"),
		Expires:     1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateApiKey(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateApiKey"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateChannelNamespace(t *testing.T) {
	input := &CreateChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
		SubscribeAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		PublishAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		CodeHandlers: ptr.String("__CodeHandlers__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
		HandlerConfigs: &types.HandlerConfigs{
			OnPublish: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
			OnSubscribe: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateDataSource(t *testing.T) {
	input := &CreateDataSourceInput{
		ApiId:          ptr.String("__ApiId__"),
		Name:           ptr.String("__Name__"),
		Description:    ptr.String("__Description__"),
		Type:           types.DataSourceType("AWS_LAMBDA"),
		ServiceRoleArn: ptr.String("__ServiceRoleArn__"),
		DynamodbConfig: &types.DynamodbDataSourceConfig{
			TableName:            ptr.String("__TableName__"),
			AwsRegion:            ptr.String("__AwsRegion__"),
			UseCallerCredentials: true,
			DeltaSyncConfig: &types.DeltaSyncConfig{
				BaseTableTTL:       1,
				DeltaSyncTableName: ptr.String("__DeltaSyncTableName__"),
				DeltaSyncTableTTL:  1,
			},
			Versioned: true,
		},
		LambdaConfig: &types.LambdaDataSourceConfig{
			LambdaFunctionArn: ptr.String("__LambdaFunctionArn__"),
		},
		ElasticsearchConfig: &types.ElasticsearchDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		OpenSearchServiceConfig: &types.OpenSearchServiceDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		HttpConfig: &types.HttpDataSourceConfig{
			Endpoint: ptr.String("__Endpoint__"),
			AuthorizationConfig: &types.AuthorizationConfig{
				AuthorizationType: types.AuthorizationType("AWS_IAM"),
				AwsIamConfig: &types.AwsIamConfig{
					SigningRegion:      ptr.String("__SigningRegion__"),
					SigningServiceName: ptr.String("__SigningServiceName__"),
				},
			},
		},
		RelationalDatabaseConfig: &types.RelationalDatabaseDataSourceConfig{
			RelationalDatabaseSourceType: types.RelationalDatabaseSourceType("RDS_HTTP_ENDPOINT"),
			RdsHttpEndpointConfig: &types.RdsHttpEndpointConfig{
				AwsRegion:           ptr.String("__AwsRegion__"),
				DbClusterIdentifier: ptr.String("__DbClusterIdentifier__"),
				DatabaseName:        ptr.String("__DatabaseName__"),
				Schema:              ptr.String("__Schema__"),
				AwsSecretStoreArn:   ptr.String("__AwsSecretStoreArn__"),
			},
		},
		EventBridgeConfig: &types.EventBridgeDataSourceConfig{
			EventBusArn: ptr.String("__EventBusArn__"),
		},
		MetricsConfig: types.DataSourceLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateDomainName(t *testing.T) {
	input := &CreateDomainNameInput{
		DomainName:     ptr.String("__DomainName__"),
		CertificateArn: ptr.String("__CertificateArn__"),
		Description:    ptr.String("__Description__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateFunction(t *testing.T) {
	input := &CreateFunctionInput{
		ApiId:                   ptr.String("__ApiId__"),
		Name:                    ptr.String("__Name__"),
		Description:             ptr.String("__Description__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		FunctionVersion:         ptr.String("__FunctionVersion__"),
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code: ptr.String("__Code__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateGraphqlApi(t *testing.T) {
	input := &CreateGraphqlApiInput{
		Name: ptr.String("__Name__"),
		LogConfig: &types.LogConfig{
			FieldLogLevel:         types.FieldLogLevel("NONE"),
			CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			ExcludeVerboseContent: true,
		},
		AuthenticationType: types.AuthenticationType("API_KEY"),
		UserPoolConfig: &types.UserPoolConfig{
			UserPoolId:       ptr.String("__UserPoolId__"),
			AwsRegion:        ptr.String("__AwsRegion__"),
			DefaultAction:    types.DefaultAction("ALLOW"),
			AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
		},
		OpenIDConnectConfig: &types.OpenIDConnectConfig{
			Issuer:   ptr.String("__Issuer__"),
			ClientId: ptr.String("__ClientId__"),
			IatTTL:   1,
			AuthTTL:  1,
		},
		Tags: map[string]string{
			"key0": "__Value__",
		},
		AdditionalAuthenticationProviders: []types.AdditionalAuthenticationProvider{
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
		},
		XrayEnabled: true,
		LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
			AuthorizerResultTtlInSeconds: 1,
			AuthorizerUri:                ptr.String("__AuthorizerUri__"),
			IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
		},
		ApiType:                   types.GraphQLApiType("GRAPHQL"),
		MergedApiExecutionRoleArn: ptr.String("__MergedApiExecutionRoleArn__"),
		Visibility:                types.GraphQLApiVisibility("GLOBAL"),
		OwnerContact:              ptr.String("__OwnerContact__"),
		IntrospectionConfig:       types.GraphQLApiIntrospectionConfig("ENABLED"),
		QueryDepthLimit:           1,
		ResolverCountLimit:        1,
		EnhancedMetricsConfig: &types.EnhancedMetricsConfig{
			ResolverLevelMetricsBehavior:   types.ResolverLevelMetricsBehavior("FULL_REQUEST_RESOLVER_METRICS"),
			DataSourceLevelMetricsBehavior: types.DataSourceLevelMetricsBehavior("FULL_REQUEST_DATA_SOURCE_METRICS"),
			OperationLevelMetricsConfig:    types.OperationLevelMetricsConfig("ENABLED"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateResolver(t *testing.T) {
	input := &CreateResolverInput{
		ApiId:                   ptr.String("__ApiId__"),
		TypeName:                ptr.String("__TypeName__"),
		FieldName:               ptr.String("__FieldName__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		Kind:                    types.ResolverKind("UNIT"),
		PipelineConfig: &types.PipelineConfig{
			Functions: []string{
				"__Member__",
				"__Member__",
			},
		},
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		CachingConfig: &types.CachingConfig{
			Ttl: 1,
			CachingKeys: []string{
				"__Member__",
				"__Member__",
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code:          ptr.String("__Code__"),
		MetricsConfig: types.ResolverLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_CreateType(t *testing.T) {
	input := &CreateTypeInput{
		ApiId:      ptr.String("__ApiId__"),
		Definition: ptr.String("__Definition__"),
		Format:     types.TypeDefinitionFormat("SDL"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.CreateType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "CreateType"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteApi(t *testing.T) {
	input := &DeleteApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteApiCache(t *testing.T) {
	input := &DeleteApiCacheInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteApiKey(t *testing.T) {
	input := &DeleteApiKeyInput{
		ApiId: ptr.String("__ApiId__"),
		Id:    ptr.String("__Id__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteApiKey(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteApiKey"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteChannelNamespace(t *testing.T) {
	input := &DeleteChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteDataSource(t *testing.T) {
	input := &DeleteDataSourceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteDomainName(t *testing.T) {
	input := &DeleteDomainNameInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteFunction(t *testing.T) {
	input := &DeleteFunctionInput{
		ApiId:      ptr.String("__ApiId__"),
		FunctionId: ptr.String("__FunctionId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteGraphqlApi(t *testing.T) {
	input := &DeleteGraphqlApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteResolver(t *testing.T) {
	input := &DeleteResolverInput{
		ApiId:     ptr.String("__ApiId__"),
		TypeName:  ptr.String("__TypeName__"),
		FieldName: ptr.String("__FieldName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DeleteType(t *testing.T) {
	input := &DeleteTypeInput{
		ApiId:    ptr.String("__ApiId__"),
		TypeName: ptr.String("__TypeName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DeleteType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DeleteType"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DisassociateApi(t *testing.T) {
	input := &DisassociateApiInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DisassociateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DisassociateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DisassociateMergedGraphqlApi(t *testing.T) {
	input := &DisassociateMergedGraphqlApiInput{
		SourceApiIdentifier: ptr.String("__SourceApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DisassociateMergedGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DisassociateMergedGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_DisassociateSourceGraphqlApi(t *testing.T) {
	input := &DisassociateSourceGraphqlApiInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.DisassociateSourceGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "DisassociateSourceGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_EvaluateCode(t *testing.T) {
	input := &EvaluateCodeInput{
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code:     ptr.String("__Code__"),
		Context:  ptr.String("__Context__"),
		Function: ptr.String("__Function__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.EvaluateCode(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "EvaluateCode"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_EvaluateMappingTemplate(t *testing.T) {
	input := &EvaluateMappingTemplateInput{
		Template: ptr.String("__Template__"),
		Context:  ptr.String("__Context__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.EvaluateMappingTemplate(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "EvaluateMappingTemplate"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_FlushApiCache(t *testing.T) {
	input := &FlushApiCacheInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.FlushApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "FlushApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetApi(t *testing.T) {
	input := &GetApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetApiAssociation(t *testing.T) {
	input := &GetApiAssociationInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetApiAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetApiAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetApiCache(t *testing.T) {
	input := &GetApiCacheInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetChannelNamespace(t *testing.T) {
	input := &GetChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetDataSource(t *testing.T) {
	input := &GetDataSourceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetDataSourceIntrospection(t *testing.T) {
	input := &GetDataSourceIntrospectionInput{
		IntrospectionId:  ptr.String("__IntrospectionId__"),
		IncludeModelsSDL: true,
		NextToken:        ptr.String("__NextToken__"),
		MaxResults:       1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetDataSourceIntrospection(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetDataSourceIntrospection"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetDomainName(t *testing.T) {
	input := &GetDomainNameInput{
		DomainName: ptr.String("__DomainName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetFunction(t *testing.T) {
	input := &GetFunctionInput{
		ApiId:      ptr.String("__ApiId__"),
		FunctionId: ptr.String("__FunctionId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetGraphqlApi(t *testing.T) {
	input := &GetGraphqlApiInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetGraphqlApiEnvironmentVariables(t *testing.T) {
	input := &GetGraphqlApiEnvironmentVariablesInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetGraphqlApiEnvironmentVariables(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetGraphqlApiEnvironmentVariables"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetIntrospectionSchema(t *testing.T) {
	input := &GetIntrospectionSchemaInput{
		ApiId:             ptr.String("__ApiId__"),
		Format:            types.OutputType("SDL"),
		IncludeDirectives: ptr.Bool(true),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetIntrospectionSchema(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetIntrospectionSchema"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetResolver(t *testing.T) {
	input := &GetResolverInput{
		ApiId:     ptr.String("__ApiId__"),
		TypeName:  ptr.String("__TypeName__"),
		FieldName: ptr.String("__FieldName__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetSchemaCreationStatus(t *testing.T) {
	input := &GetSchemaCreationStatusInput{
		ApiId: ptr.String("__ApiId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetSchemaCreationStatus(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetSchemaCreationStatus"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetSourceApiAssociation(t *testing.T) {
	input := &GetSourceApiAssociationInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetSourceApiAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetSourceApiAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_GetType(t *testing.T) {
	input := &GetTypeInput{
		ApiId:    ptr.String("__ApiId__"),
		TypeName: ptr.String("__TypeName__"),
		Format:   types.TypeDefinitionFormat("SDL"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.GetType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "GetType"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListApiKeys(t *testing.T) {
	input := &ListApiKeysInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListApiKeys(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListApiKeys"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListApis(t *testing.T) {
	input := &ListApisInput{
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListApis(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListApis"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListChannelNamespaces(t *testing.T) {
	input := &ListChannelNamespacesInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListChannelNamespaces(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListChannelNamespaces"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListDataSources(t *testing.T) {
	input := &ListDataSourcesInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListDataSources(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListDataSources"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListDomainNames(t *testing.T) {
	input := &ListDomainNamesInput{
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListDomainNames(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListDomainNames"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListFunctions(t *testing.T) {
	input := &ListFunctionsInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListFunctions(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListFunctions"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListGraphqlApis(t *testing.T) {
	input := &ListGraphqlApisInput{
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
		ApiType:    types.GraphQLApiType("GRAPHQL"),
		Owner:      types.Ownership("CURRENT_ACCOUNT"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListGraphqlApis(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListGraphqlApis"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListResolvers(t *testing.T) {
	input := &ListResolversInput{
		ApiId:      ptr.String("__ApiId__"),
		TypeName:   ptr.String("__TypeName__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListResolvers(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListResolvers"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListResolversByFunction(t *testing.T) {
	input := &ListResolversByFunctionInput{
		ApiId:      ptr.String("__ApiId__"),
		FunctionId: ptr.String("__FunctionId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListResolversByFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListResolversByFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListSourceApiAssociations(t *testing.T) {
	input := &ListSourceApiAssociationsInput{
		ApiId:      ptr.String("__ApiId__"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListSourceApiAssociations(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListSourceApiAssociations"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListTagsForResource(t *testing.T) {
	input := &ListTagsForResourceInput{
		ResourceArn: ptr.String("__ResourceArn__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListTagsForResource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListTagsForResource"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListTypes(t *testing.T) {
	input := &ListTypesInput{
		ApiId:      ptr.String("__ApiId__"),
		Format:     types.TypeDefinitionFormat("SDL"),
		NextToken:  ptr.String("__NextToken__"),
		MaxResults: 1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListTypes(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListTypes"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_ListTypesByAssociation(t *testing.T) {
	input := &ListTypesByAssociationInput{
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		AssociationId:       ptr.String("__AssociationId__"),
		Format:              types.TypeDefinitionFormat("SDL"),
		NextToken:           ptr.String("__NextToken__"),
		MaxResults:          1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.ListTypesByAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "ListTypesByAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_PutGraphqlApiEnvironmentVariables(t *testing.T) {
	input := &PutGraphqlApiEnvironmentVariablesInput{
		ApiId: ptr.String("__ApiId__"),
		EnvironmentVariables: map[string]string{
			"key0": "__Value__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.PutGraphqlApiEnvironmentVariables(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "PutGraphqlApiEnvironmentVariables"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_StartDataSourceIntrospection(t *testing.T) {
	input := &StartDataSourceIntrospectionInput{
		RdsDataApiConfig: &types.RdsDataApiConfig{
			ResourceArn:  ptr.String("__ResourceArn__"),
			SecretArn:    ptr.String("__SecretArn__"),
			DatabaseName: ptr.String("__DatabaseName__"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.StartDataSourceIntrospection(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "StartDataSourceIntrospection"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_StartSchemaCreation(t *testing.T) {
	input := &StartSchemaCreationInput{
		ApiId:      ptr.String("__ApiId__"),
		Definition: []byte("blob"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.StartSchemaCreation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "StartSchemaCreation"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_StartSchemaMerge(t *testing.T) {
	input := &StartSchemaMergeInput{
		AssociationId:       ptr.String("__AssociationId__"),
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.StartSchemaMerge(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "StartSchemaMerge"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_TagResource(t *testing.T) {
	input := &TagResourceInput{
		ResourceArn: ptr.String("__ResourceArn__"),
		Tags: map[string]string{
			"key0": "__Value__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.TagResource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "TagResource"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UntagResource(t *testing.T) {
	input := &UntagResourceInput{
		ResourceArn: ptr.String("__ResourceArn__"),
		TagKeys: []string{
			"__Member__",
			"__Member__",
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UntagResource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UntagResource"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateApi(t *testing.T) {
	input := &UpdateApiInput{
		ApiId:        ptr.String("__ApiId__"),
		Name:         ptr.String("__Name__"),
		OwnerContact: ptr.String("__OwnerContact__"),
		EventConfig: &types.EventConfig{
			AuthProviders: []types.AuthProvider{
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
					CognitoConfig: &types.CognitoConfig{
						UserPoolId:       ptr.String("__UserPoolId__"),
						AwsRegion:        ptr.String("__AwsRegion__"),
						AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
					},
					OpenIDConnectConfig: &types.OpenIDConnectConfig{
						Issuer:   ptr.String("__Issuer__"),
						ClientId: ptr.String("__ClientId__"),
						IatTTL:   1,
						AuthTTL:  1,
					},
					LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
						AuthorizerResultTtlInSeconds: 1,
						AuthorizerUri:                ptr.String("__AuthorizerUri__"),
						IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
					},
				},
			},
			ConnectionAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultPublishAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			DefaultSubscribeAuthModes: []types.AuthMode{
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
				{
					AuthType: types.AuthenticationType("API_KEY"),
				},
			},
			LogConfig: &types.EventLogConfig{
				LogLevel:              types.EventLogLevel("NONE"),
				CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateApiCache(t *testing.T) {
	input := &UpdateApiCacheInput{
		ApiId:               ptr.String("__ApiId__"),
		Ttl:                 1,
		ApiCachingBehavior:  types.ApiCachingBehavior("FULL_REQUEST_CACHING"),
		Type:                types.ApiCacheType("T2_SMALL"),
		HealthMetricsConfig: types.CacheHealthMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateApiCache(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateApiCache"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateApiKey(t *testing.T) {
	input := &UpdateApiKeyInput{
		ApiId:       ptr.String("__ApiId__"),
		Id:          ptr.String("__Id__"),
		Description: ptr.String("__Description__"),
		Expires:     1,
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateApiKey(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateApiKey"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateChannelNamespace(t *testing.T) {
	input := &UpdateChannelNamespaceInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
		SubscribeAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		PublishAuthModes: []types.AuthMode{
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
			{
				AuthType: types.AuthenticationType("API_KEY"),
			},
		},
		CodeHandlers: ptr.String("__CodeHandlers__"),
		HandlerConfigs: &types.HandlerConfigs{
			OnPublish: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
			OnSubscribe: &types.HandlerConfig{
				Behavior: types.HandlerBehavior("CODE"),
				Integration: &types.Integration{
					DataSourceName: ptr.String("__DataSourceName__"),
					LambdaConfig: &types.LambdaConfig{
						InvokeType: types.InvokeType("REQUEST_RESPONSE"),
					},
				},
			},
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateChannelNamespace(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateChannelNamespace"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateDataSource(t *testing.T) {
	input := &UpdateDataSourceInput{
		ApiId:          ptr.String("__ApiId__"),
		Name:           ptr.String("__Name__"),
		Description:    ptr.String("__Description__"),
		Type:           types.DataSourceType("AWS_LAMBDA"),
		ServiceRoleArn: ptr.String("__ServiceRoleArn__"),
		DynamodbConfig: &types.DynamodbDataSourceConfig{
			TableName:            ptr.String("__TableName__"),
			AwsRegion:            ptr.String("__AwsRegion__"),
			UseCallerCredentials: true,
			DeltaSyncConfig: &types.DeltaSyncConfig{
				BaseTableTTL:       1,
				DeltaSyncTableName: ptr.String("__DeltaSyncTableName__"),
				DeltaSyncTableTTL:  1,
			},
			Versioned: true,
		},
		LambdaConfig: &types.LambdaDataSourceConfig{
			LambdaFunctionArn: ptr.String("__LambdaFunctionArn__"),
		},
		ElasticsearchConfig: &types.ElasticsearchDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		OpenSearchServiceConfig: &types.OpenSearchServiceDataSourceConfig{
			Endpoint:  ptr.String("__Endpoint__"),
			AwsRegion: ptr.String("__AwsRegion__"),
		},
		HttpConfig: &types.HttpDataSourceConfig{
			Endpoint: ptr.String("__Endpoint__"),
			AuthorizationConfig: &types.AuthorizationConfig{
				AuthorizationType: types.AuthorizationType("AWS_IAM"),
				AwsIamConfig: &types.AwsIamConfig{
					SigningRegion:      ptr.String("__SigningRegion__"),
					SigningServiceName: ptr.String("__SigningServiceName__"),
				},
			},
		},
		RelationalDatabaseConfig: &types.RelationalDatabaseDataSourceConfig{
			RelationalDatabaseSourceType: types.RelationalDatabaseSourceType("RDS_HTTP_ENDPOINT"),
			RdsHttpEndpointConfig: &types.RdsHttpEndpointConfig{
				AwsRegion:           ptr.String("__AwsRegion__"),
				DbClusterIdentifier: ptr.String("__DbClusterIdentifier__"),
				DatabaseName:        ptr.String("__DatabaseName__"),
				Schema:              ptr.String("__Schema__"),
				AwsSecretStoreArn:   ptr.String("__AwsSecretStoreArn__"),
			},
		},
		EventBridgeConfig: &types.EventBridgeDataSourceConfig{
			EventBusArn: ptr.String("__EventBusArn__"),
		},
		MetricsConfig: types.DataSourceLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateDataSource(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateDataSource"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateDomainName(t *testing.T) {
	input := &UpdateDomainNameInput{
		DomainName:  ptr.String("__DomainName__"),
		Description: ptr.String("__Description__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateDomainName(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateDomainName"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateFunction(t *testing.T) {
	input := &UpdateFunctionInput{
		ApiId:                   ptr.String("__ApiId__"),
		Name:                    ptr.String("__Name__"),
		Description:             ptr.String("__Description__"),
		FunctionId:              ptr.String("__FunctionId__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		FunctionVersion:         ptr.String("__FunctionVersion__"),
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code: ptr.String("__Code__"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateFunction(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateFunction"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateGraphqlApi(t *testing.T) {
	input := &UpdateGraphqlApiInput{
		ApiId: ptr.String("__ApiId__"),
		Name:  ptr.String("__Name__"),
		LogConfig: &types.LogConfig{
			FieldLogLevel:         types.FieldLogLevel("NONE"),
			CloudWatchLogsRoleArn: ptr.String("__CloudWatchLogsRoleArn__"),
			ExcludeVerboseContent: true,
		},
		AuthenticationType: types.AuthenticationType("API_KEY"),
		UserPoolConfig: &types.UserPoolConfig{
			UserPoolId:       ptr.String("__UserPoolId__"),
			AwsRegion:        ptr.String("__AwsRegion__"),
			DefaultAction:    types.DefaultAction("ALLOW"),
			AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
		},
		OpenIDConnectConfig: &types.OpenIDConnectConfig{
			Issuer:   ptr.String("__Issuer__"),
			ClientId: ptr.String("__ClientId__"),
			IatTTL:   1,
			AuthTTL:  1,
		},
		AdditionalAuthenticationProviders: []types.AdditionalAuthenticationProvider{
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
			{
				AuthenticationType: types.AuthenticationType("API_KEY"),
				OpenIDConnectConfig: &types.OpenIDConnectConfig{
					Issuer:   ptr.String("__Issuer__"),
					ClientId: ptr.String("__ClientId__"),
					IatTTL:   1,
					AuthTTL:  1,
				},
				UserPoolConfig: &types.CognitoUserPoolConfig{
					UserPoolId:       ptr.String("__UserPoolId__"),
					AwsRegion:        ptr.String("__AwsRegion__"),
					AppIdClientRegex: ptr.String("__AppIdClientRegex__"),
				},
				LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
					AuthorizerResultTtlInSeconds: 1,
					AuthorizerUri:                ptr.String("__AuthorizerUri__"),
					IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
				},
			},
		},
		XrayEnabled: true,
		LambdaAuthorizerConfig: &types.LambdaAuthorizerConfig{
			AuthorizerResultTtlInSeconds: 1,
			AuthorizerUri:                ptr.String("__AuthorizerUri__"),
			IdentityValidationExpression: ptr.String("__IdentityValidationExpression__"),
		},
		MergedApiExecutionRoleArn: ptr.String("__MergedApiExecutionRoleArn__"),
		OwnerContact:              ptr.String("__OwnerContact__"),
		IntrospectionConfig:       types.GraphQLApiIntrospectionConfig("ENABLED"),
		QueryDepthLimit:           1,
		ResolverCountLimit:        1,
		EnhancedMetricsConfig: &types.EnhancedMetricsConfig{
			ResolverLevelMetricsBehavior:   types.ResolverLevelMetricsBehavior("FULL_REQUEST_RESOLVER_METRICS"),
			DataSourceLevelMetricsBehavior: types.DataSourceLevelMetricsBehavior("FULL_REQUEST_DATA_SOURCE_METRICS"),
			OperationLevelMetricsConfig:    types.OperationLevelMetricsConfig("ENABLED"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateGraphqlApi(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateGraphqlApi"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateResolver(t *testing.T) {
	input := &UpdateResolverInput{
		ApiId:                   ptr.String("__ApiId__"),
		TypeName:                ptr.String("__TypeName__"),
		FieldName:               ptr.String("__FieldName__"),
		DataSourceName:          ptr.String("__DataSourceName__"),
		RequestMappingTemplate:  ptr.String("__RequestMappingTemplate__"),
		ResponseMappingTemplate: ptr.String("__ResponseMappingTemplate__"),
		Kind:                    types.ResolverKind("UNIT"),
		PipelineConfig: &types.PipelineConfig{
			Functions: []string{
				"__Member__",
				"__Member__",
			},
		},
		SyncConfig: &types.SyncConfig{
			ConflictHandler:   types.ConflictHandlerType("OPTIMISTIC_CONCURRENCY"),
			ConflictDetection: types.ConflictDetectionType("VERSION"),
			LambdaConflictHandlerConfig: &types.LambdaConflictHandlerConfig{
				LambdaConflictHandlerArn: ptr.String("__LambdaConflictHandlerArn__"),
			},
		},
		CachingConfig: &types.CachingConfig{
			Ttl: 1,
			CachingKeys: []string{
				"__Member__",
				"__Member__",
			},
		},
		MaxBatchSize: 1,
		Runtime: &types.AppSyncRuntime{
			Name:           types.RuntimeName("APPSYNC_JS"),
			RuntimeVersion: ptr.String("__RuntimeVersion__"),
		},
		Code:          ptr.String("__Code__"),
		MetricsConfig: types.ResolverLevelMetricsConfig("ENABLED"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateResolver(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateResolver"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateSourceApiAssociation(t *testing.T) {
	input := &UpdateSourceApiAssociationInput{
		AssociationId:       ptr.String("__AssociationId__"),
		MergedApiIdentifier: ptr.String("__MergedApiIdentifier__"),
		Description:         ptr.String("__Description__"),
		SourceApiAssociationConfig: &types.SourceApiAssociationConfig{
			MergeType: types.MergeType("MANUAL_MERGE"),
		},
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateSourceApiAssociation(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateSourceApiAssociation"); err != nil {
		t.Fatal(err)
	}
}

func TestUpdateRequestSnapshot_UpdateType(t *testing.T) {
	input := &UpdateTypeInput{
		ApiId:      ptr.String("__ApiId__"),
		TypeName:   ptr.String("__TypeName__"),
		Definition: ptr.String("__Definition__"),
		Format:     types.TypeDefinitionFormat("SDL"),
	}
	body := &bytes.Buffer{}
	method := ""
	rawPath := ""
	rawQuery := ""
	header := map[string][]string{}
	svc := serdeNewClient()
	_, err := svc.UpdateType(context.Background(), input, func(o *Options) {
		o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error {
			stack.Initialize.Remove("OperationInputValidation")
			stack.Serialize.Remove("RequestCompression")
			return stack.Finalize.Add(&captureSerdeRequestMiddleware{
				body: body, method: &method, rawPath: &rawPath, rawQuery: &rawQuery, header: &header,
			}, middleware.Before)
		})
	})
	if err != nil && !errors.Is(err, errSerdeSnapshotOK) {
		t.Fatal(err)
	}
	if err := serdeUpdateSnapshot(method, rawPath, rawQuery, header, body.Bytes(), "UpdateType"); err != nil {
		t.Fatal(err)
	}
}
