For documentation about obtaining apiKey and apiSecret go to https://docs.atlas.mongodb.com/configure-api-access.
export MONGODB_ATLAS_PUBLIC_KEY=somekey
export MONGODB_ATLAS_PRIVATE_KEY=some-secret-key-for-gosdkapi
go run ./aws_cluster/aws.go
SDK provides mocks using Testify and Mockery. One of the SDK examples covers usage of the mockery within tests.
go test ./mock/cluster_test.go
Example provides automatic retries for all HTTP 500, 429 HTTP status errors.
go run ./retry/retry.go