func NewProvider(ctx context.Context, accessKey, secretKey, region, sessionToken string) (provider.Provider, error) {
	log.Get().Log("func", "reader.New", "msg", "configuring aws Reader")
	awsr, err := reader.New(ctx, accessKey, secretKey, region, sessionToken, nil)
	if err != nil {
		return nil, fmt.Errorf("could not initialize 'reader' because: %s", err)
	}
	cfg := tfaws.Config{
		AccessKey: accessKey,
		SecretKey: secretKey,
		Region:    region,
		Token:     sessionToken,
	}
	log.Get().Log("func", "aws.NewProvider", "msg", "configuring TF Client")
	awsClient, err := cfg.Client()
	if err != nil {
		return nil, fmt.Errorf("could not initialize 'terraform/aws.Config.Client()' because: %s", err)
	}
	tfp := tfaws.Provider()
	tfp.SetMeta(awsClient)
	return &aws{
		awsr:        awsr,
		tfAWSClient: awsClient,
		tfProvider:  tfp,
		cache:       cache.New(),
		configuration: map[string]interface{}{
			"region": region,
		},
	}, nil
}
NewProvider returns an AWS Provider
package aws
import (
	"context"
	"fmt"
	"github.com/aws/aws-sdk-go/aws/awserr"
	"github.com/cycloidio/terracognita/aws/reader"
	"github.com/cycloidio/terracognita/cache"
	"github.com/cycloidio/terracognita/errcode"
	"github.com/cycloidio/terracognita/filter"
	"github.com/cycloidio/terracognita/log"
	"github.com/cycloidio/terracognita/provider"
	"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
	"github.com/pkg/errors"
	tfaws "github.com/terraform-providers/terraform-provider-aws/aws"
)
var skippableCodes = map[string]struct{}{
	"InvalidAction":         struct{}{},
	"AccessDeniedException": struct{}{},
	"RequestError":          struct{}{},
}
type aws struct {
	awsr reader.Reader
	tfAWSClient interface{}
	tfProvider  *schema.Provider
	configuration map[string]interface{}
	cache cache.Cache
}