Skip to content

Commit ddd022d

Browse files
APIBot: SDK update based on recent changes in Atlas API (#263)
1 parent 6e2cd9e commit ddd022d

File tree

104 files changed

+3300
-1543
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

104 files changed

+3300
-1543
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Note that `atlas-sdk-go` only supports the two most recent major versions of Go.
1111
### Adding Dependency
1212

1313
```terminal
14-
go get go.mongodb.org/atlas-sdk/v20231115004
14+
go get go.mongodb.org/atlas-sdk/v20231115005
1515
```
1616

1717
### Using in the code
@@ -20,7 +20,7 @@ Construct a new Atlas SDK client, then use the various services on the client to
2020
access different parts of the Atlas API. For example:
2121

2222
```go
23-
import "go.mongodb.org/atlas-sdk/v20231115004/admin"
23+
import "go.mongodb.org/atlas-sdk/v20231115005/admin"
2424

2525
func example() {
2626
ctx := context.Background()

admin/api_cloud_migration_service.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ type CloudMigrationServiceApi interface {
4141
4242
Migrate one cluster that Cloud or Ops Manager manages to MongoDB Atlas.
4343
44-
Please make sure to [validate](#tag/Cloud-Migration-Service/operation/validateOneMigration) your migration before initiating it.
44+
Please make sure to [validate](#tag/Cloud-Migration-Service/operation/validateMigration) your migration before initiating it.
4545
4646
You can use this API endpoint for push live migrations only. Your API Key must have the Organization Owner role to successfully call this resource.
4747
@@ -373,7 +373,7 @@ CreatePushMigration Migrate One Local Managed Cluster to MongoDB Atlas
373373
374374
Migrate one cluster that Cloud or Ops Manager manages to MongoDB Atlas.
375375
376-
Please make sure to [validate](#tag/Cloud-Migration-Service/operation/validateOneMigration) your migration before initiating it.
376+
Please make sure to [validate](#tag/Cloud-Migration-Service/operation/validateMigration) your migration before initiating it.
377377
378378
You can use this API endpoint for push live migrations only. Your API Key must have the Organization Owner role to successfully call this resource.
379379

admin/api_federated_authentication.go

Lines changed: 27 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -310,6 +310,8 @@ type FederatedAuthenticationApi interface {
310310
311311
**Note**: If the identityProviderId field is not provided, you will disconnect the organization and the identity provider.
312312
313+
**Note**: Currently connected data access identity providers missing from the dataAccessIdentityProviderIds field will be disconnected.
314+
313315
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
314316
@param federationSettingsId Unique 24-hexadecimal digit string that identifies your federation.
315317
@param orgId Unique 24-hexadecimal digit string that identifies the connected organization configuration to update.
@@ -339,7 +341,7 @@ type FederatedAuthenticationApi interface {
339341
@param identityProviderId Unique 20-hexadecimal digit string that identifies the identity provider.
340342
@return UpdateIdentityProviderApiRequest
341343
*/
342-
UpdateIdentityProvider(ctx context.Context, federationSettingsId string, identityProviderId string, identityProviderUpdate *IdentityProviderUpdate) UpdateIdentityProviderApiRequest
344+
UpdateIdentityProvider(ctx context.Context, federationSettingsId string, identityProviderId string, federationIdentityProviderUpdate *FederationIdentityProviderUpdate) UpdateIdentityProviderApiRequest
343345
/*
344346
UpdateIdentityProvider Update the identity provider.
345347
@@ -1966,6 +1968,8 @@ UpdateConnectedOrgConfig Update One Org Config Connected to One Federation
19661968
19671969
**Note**: If the identityProviderId field is not provided, you will disconnect the organization and the identity provider.
19681970
1971+
**Note**: Currently connected data access identity providers missing from the dataAccessIdentityProviderIds field will be disconnected.
1972+
19691973
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
19701974
@param federationSettingsId Unique 24-hexadecimal digit string that identifies your federation.
19711975
@param orgId Unique 24-hexadecimal digit string that identifies the connected organization configuration to update.
@@ -2073,26 +2077,26 @@ func (a *FederatedAuthenticationApiService) UpdateConnectedOrgConfigExecute(r Up
20732077
}
20742078

20752079
type UpdateIdentityProviderApiRequest struct {
2076-
ctx context.Context
2077-
ApiService FederatedAuthenticationApi
2078-
federationSettingsId string
2079-
identityProviderId string
2080-
identityProviderUpdate *IdentityProviderUpdate
2080+
ctx context.Context
2081+
ApiService FederatedAuthenticationApi
2082+
federationSettingsId string
2083+
identityProviderId string
2084+
federationIdentityProviderUpdate *FederationIdentityProviderUpdate
20812085
}
20822086

20832087
type UpdateIdentityProviderApiParams struct {
2084-
FederationSettingsId string
2085-
IdentityProviderId string
2086-
IdentityProviderUpdate *IdentityProviderUpdate
2088+
FederationSettingsId string
2089+
IdentityProviderId string
2090+
FederationIdentityProviderUpdate *FederationIdentityProviderUpdate
20872091
}
20882092

20892093
func (a *FederatedAuthenticationApiService) UpdateIdentityProviderWithParams(ctx context.Context, args *UpdateIdentityProviderApiParams) UpdateIdentityProviderApiRequest {
20902094
return UpdateIdentityProviderApiRequest{
2091-
ApiService: a,
2092-
ctx: ctx,
2093-
federationSettingsId: args.FederationSettingsId,
2094-
identityProviderId: args.IdentityProviderId,
2095-
identityProviderUpdate: args.IdentityProviderUpdate,
2095+
ApiService: a,
2096+
ctx: ctx,
2097+
federationSettingsId: args.FederationSettingsId,
2098+
identityProviderId: args.IdentityProviderId,
2099+
federationIdentityProviderUpdate: args.FederationIdentityProviderUpdate,
20962100
}
20972101
}
20982102

@@ -2110,13 +2114,13 @@ UpdateIdentityProvider Update the identity provider.
21102114
@param identityProviderId Unique 20-hexadecimal digit string that identifies the identity provider.
21112115
@return UpdateIdentityProviderApiRequest
21122116
*/
2113-
func (a *FederatedAuthenticationApiService) UpdateIdentityProvider(ctx context.Context, federationSettingsId string, identityProviderId string, identityProviderUpdate *IdentityProviderUpdate) UpdateIdentityProviderApiRequest {
2117+
func (a *FederatedAuthenticationApiService) UpdateIdentityProvider(ctx context.Context, federationSettingsId string, identityProviderId string, federationIdentityProviderUpdate *FederationIdentityProviderUpdate) UpdateIdentityProviderApiRequest {
21142118
return UpdateIdentityProviderApiRequest{
2115-
ApiService: a,
2116-
ctx: ctx,
2117-
federationSettingsId: federationSettingsId,
2118-
identityProviderId: identityProviderId,
2119-
identityProviderUpdate: identityProviderUpdate,
2119+
ApiService: a,
2120+
ctx: ctx,
2121+
federationSettingsId: federationSettingsId,
2122+
identityProviderId: identityProviderId,
2123+
federationIdentityProviderUpdate: federationIdentityProviderUpdate,
21202124
}
21212125
}
21222126

@@ -2143,8 +2147,8 @@ func (a *FederatedAuthenticationApiService) UpdateIdentityProviderExecute(r Upda
21432147
localVarHeaderParams := make(map[string]string)
21442148
localVarQueryParams := url.Values{}
21452149
localVarFormParams := url.Values{}
2146-
if r.identityProviderUpdate == nil {
2147-
return localVarReturnValue, nil, reportError("identityProviderUpdate is required and must be specified")
2150+
if r.federationIdentityProviderUpdate == nil {
2151+
return localVarReturnValue, nil, reportError("federationIdentityProviderUpdate is required and must be specified")
21482152
}
21492153

21502154
// to determine the Content-Type header
@@ -2165,7 +2169,7 @@ func (a *FederatedAuthenticationApiService) UpdateIdentityProviderExecute(r Upda
21652169
localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept
21662170
}
21672171
// body params
2168-
localVarPostBody = r.identityProviderUpdate
2172+
localVarPostBody = r.federationIdentityProviderUpdate
21692173
req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles)
21702174
if err != nil {
21712175
return localVarReturnValue, nil, err

admin/atlas_client.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package admin // import "go.mongodb.org/atlas-sdk/v20231115004/admin"
1+
package admin // import "go.mongodb.org/atlas-sdk/v20231115005/admin"
22

33
import (
44
"errors"
@@ -8,7 +8,7 @@ import (
88
"strings"
99

1010
"github.com/mongodb-forks/digest"
11-
"go.mongodb.org/atlas-sdk/v20231115004/internal/core"
11+
"go.mongodb.org/atlas-sdk/v20231115005/internal/core"
1212
)
1313

1414
const (

admin/model_backup_online_archive.go

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ type BackupOnlineArchive struct {
2222
CollectionType *string `json:"collectionType,omitempty"`
2323
Criteria *Criteria `json:"criteria,omitempty"`
2424
DataExpirationRule *DataExpirationRule `json:"dataExpirationRule,omitempty"`
25+
DataProcessRegion *DataProcessRegion `json:"dataProcessRegion,omitempty"`
2526
// Human-readable label that identifies the dataset that Atlas generates for this online archive.
2627
// Read only field.
2728
DataSetName *string `json:"dataSetName,omitempty"`
@@ -257,6 +258,39 @@ func (o *BackupOnlineArchive) SetDataExpirationRule(v DataExpirationRule) {
257258
o.DataExpirationRule = &v
258259
}
259260

261+
// GetDataProcessRegion returns the DataProcessRegion field value if set, zero value otherwise
262+
func (o *BackupOnlineArchive) GetDataProcessRegion() DataProcessRegion {
263+
if o == nil || IsNil(o.DataProcessRegion) {
264+
var ret DataProcessRegion
265+
return ret
266+
}
267+
return *o.DataProcessRegion
268+
}
269+
270+
// GetDataProcessRegionOk returns a tuple with the DataProcessRegion field value if set, nil otherwise
271+
// and a boolean to check if the value has been set.
272+
func (o *BackupOnlineArchive) GetDataProcessRegionOk() (*DataProcessRegion, bool) {
273+
if o == nil || IsNil(o.DataProcessRegion) {
274+
return nil, false
275+
}
276+
277+
return o.DataProcessRegion, true
278+
}
279+
280+
// HasDataProcessRegion returns a boolean if a field has been set.
281+
func (o *BackupOnlineArchive) HasDataProcessRegion() bool {
282+
if o != nil && !IsNil(o.DataProcessRegion) {
283+
return true
284+
}
285+
286+
return false
287+
}
288+
289+
// SetDataProcessRegion gets a reference to the given DataProcessRegion and assigns it to the DataProcessRegion field.
290+
func (o *BackupOnlineArchive) SetDataProcessRegion(v DataProcessRegion) {
291+
o.DataProcessRegion = &v
292+
}
293+
260294
// GetDataSetName returns the DataSetName field value if set, zero value otherwise
261295
func (o *BackupOnlineArchive) GetDataSetName() string {
262296
if o == nil || IsNil(o.DataSetName) {
@@ -503,6 +537,9 @@ func (o BackupOnlineArchive) ToMap() (map[string]interface{}, error) {
503537
if !IsNil(o.DataExpirationRule) {
504538
toSerialize["dataExpirationRule"] = o.DataExpirationRule
505539
}
540+
if !IsNil(o.DataProcessRegion) {
541+
toSerialize["dataProcessRegion"] = o.DataProcessRegion
542+
}
506543
if !IsNil(o.Paused) {
507544
toSerialize["paused"] = o.Paused
508545
}

admin/model_backup_online_archive_create.go

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,21 +15,25 @@ type BackupOnlineArchiveCreate struct {
1515
// Read only field.
1616
ClusterName *string `json:"clusterName,omitempty"`
1717
// Human-readable label that identifies the collection for which you created the online archive.
18+
// Write only field.
1819
CollName string `json:"collName"`
1920
// Classification of MongoDB database collection that you want to return. If you set this parameter to `TIMESERIES`, set `\"criteria.type\" : \"date\"` and `\"criteria.dateFormat\" : \"ISODATE\"`.
20-
CollectionType *string `json:"collectionType,omitempty"`
21-
Criteria Criteria `json:"criteria"`
22-
DataExpirationRule *DataExpirationRule `json:"dataExpirationRule,omitempty"`
23-
DataProcessRegion *DataProcessRegion `json:"dataProcessRegion,omitempty"`
21+
// Write only field.
22+
CollectionType *string `json:"collectionType,omitempty"`
23+
Criteria Criteria `json:"criteria"`
24+
DataExpirationRule *DataExpirationRule `json:"dataExpirationRule,omitempty"`
25+
DataProcessRegion *CreateDataProcessRegion `json:"dataProcessRegion,omitempty"`
2426
// Human-readable label that identifies the dataset that Atlas generates for this online archive.
2527
// Read only field.
2628
DataSetName *string `json:"dataSetName,omitempty"`
2729
// Human-readable label of the database that contains the collection that contains the online archive.
30+
// Write only field.
2831
DbName string `json:"dbName"`
2932
// Unique 24-hexadecimal digit string that identifies the project that contains the specified cluster. The specified cluster contains the collection for which to create the online archive.
3033
// Read only field.
3134
GroupId *string `json:"groupId,omitempty"`
3235
// List that contains document parameters to use to logically divide data within a collection. Partitions provide a coarse level of filtering of the underlying collection data. To divide your data, specify parameters that you frequently query. If you \"specified :criteria.type\": \"DATE\" in the CREATE ONE ONLINE ARCHIVE endpoint, then you can specify up to three parameters by which to query. One of these parameters must be the DATE value, which is required in this case. If you \"specified :criteria.type\": \"CUSTOM\" in the CREATE ONE ONLINE ARCHIVE endpoint, then you can specify up to two parameters by which to query. Queries that don't use \":criteria.type\": \"DATE\" or \":criteria.type\": \"CUSTOM\" parameters cause MongoDB to scan a full collection of all archived documents. This takes more time and increases your costs.
36+
// Write only field.
3337
PartitionFields *[]PartitionField `json:"partitionFields,omitempty"`
3438
// Flag that indicates whether this online archive exists in the paused state. A request to resume fails if the collection has another active online archive. To pause an active online archive or resume a paused online archive, you must include this parameter. To pause an active archive, set this to **true**. To resume a paused archive, set this to **false**.
3539
Paused *bool `json:"paused,omitempty"`
@@ -244,17 +248,17 @@ func (o *BackupOnlineArchiveCreate) SetDataExpirationRule(v DataExpirationRule)
244248
}
245249

246250
// GetDataProcessRegion returns the DataProcessRegion field value if set, zero value otherwise
247-
func (o *BackupOnlineArchiveCreate) GetDataProcessRegion() DataProcessRegion {
251+
func (o *BackupOnlineArchiveCreate) GetDataProcessRegion() CreateDataProcessRegion {
248252
if o == nil || IsNil(o.DataProcessRegion) {
249-
var ret DataProcessRegion
253+
var ret CreateDataProcessRegion
250254
return ret
251255
}
252256
return *o.DataProcessRegion
253257
}
254258

255259
// GetDataProcessRegionOk returns a tuple with the DataProcessRegion field value if set, nil otherwise
256260
// and a boolean to check if the value has been set.
257-
func (o *BackupOnlineArchiveCreate) GetDataProcessRegionOk() (*DataProcessRegion, bool) {
261+
func (o *BackupOnlineArchiveCreate) GetDataProcessRegionOk() (*CreateDataProcessRegion, bool) {
258262
if o == nil || IsNil(o.DataProcessRegion) {
259263
return nil, false
260264
}
@@ -271,8 +275,8 @@ func (o *BackupOnlineArchiveCreate) HasDataProcessRegion() bool {
271275
return false
272276
}
273277

274-
// SetDataProcessRegion gets a reference to the given DataProcessRegion and assigns it to the DataProcessRegion field.
275-
func (o *BackupOnlineArchiveCreate) SetDataProcessRegion(v DataProcessRegion) {
278+
// SetDataProcessRegion gets a reference to the given CreateDataProcessRegion and assigns it to the DataProcessRegion field.
279+
func (o *BackupOnlineArchiveCreate) SetDataProcessRegion(v CreateDataProcessRegion) {
276280
o.DataProcessRegion = &v
277281
}
278282

admin/model_cloud_region_config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ type CloudRegionConfig struct {
1313
Priority *int `json:"priority,omitempty"`
1414
// Cloud service provider on which MongoDB Cloud provisions the hosts. Set dedicated clusters to `AWS`, `GCP`, `AZURE` or `TENANT`.
1515
ProviderName *string `json:"providerName,omitempty"`
16-
// Physical location of your MongoDB cluster nodes. The region you choose can affect network latency for clients accessing your databases. When MongoDB Cloud deploys a dedicated cluster, it checks if a VPC or VPC connection exists for that provider and region. If not, MongoDB Cloud creates them as part of the deployment. It assigns the VPC a Classless Inter-Domain Routing (CIDR) block. To limit a new VPC peering connection to one Classless Inter-Domain Routing (CIDR) block and region, create the connection first. Deploy the cluster after the connection starts. GCP Clusters and Multi-region clusters require one VPC peering connection for each region. MongoDB nodes can use only the peering connection that resides in the same region as the nodes to communicate with the peered VPC.
16+
// Physical location of your MongoDB cluster nodes. The region you choose can affect network latency for clients accessing your databases. The region name is only returned in the response for single-region clusters. When MongoDB Cloud deploys a dedicated cluster, it checks if a VPC or VPC connection exists for that provider and region. If not, MongoDB Cloud creates them as part of the deployment. It assigns the VPC a Classless Inter-Domain Routing (CIDR) block. To limit a new VPC peering connection to one Classless Inter-Domain Routing (CIDR) block and region, create the connection first. Deploy the cluster after the connection starts. GCP Clusters and Multi-region clusters require one VPC peering connection for each region. MongoDB nodes can use only the peering connection that resides in the same region as the nodes to communicate with the peered VPC.
1717
RegionName *string `json:"regionName,omitempty"`
1818
AnalyticsAutoScaling *AdvancedAutoScalingSettings `json:"analyticsAutoScaling,omitempty"`
1919
AnalyticsSpecs *DedicatedHardwareSpec `json:"analyticsSpecs,omitempty"`

admin/model_cluster_search_index.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ type ClusterSearchIndex struct {
3131
SearchAnalyzer *string `json:"searchAnalyzer,omitempty"`
3232
// Rule sets that map words to their synonyms in this index.
3333
Synonyms *[]SearchSynonymMappingDefinition `json:"synonyms,omitempty"`
34-
Fields *[]map[string]interface{} `json:"fields,omitempty"`
34+
// Settings that configure the fields, one per object, to index. You must define at least one \"vector\" type field. You can optionally define \"filter\" type fields also.
35+
Fields *[]map[string]interface{} `json:"fields,omitempty"`
3536
}
3637

3738
// NewClusterSearchIndex instantiates a new ClusterSearchIndex object

admin/model_connected_org_config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ type ConnectedOrgConfig struct {
1414
DomainAllowList *[]string `json:"domainAllowList,omitempty"`
1515
// Value that indicates whether domain restriction is enabled for this connected org.
1616
DomainRestrictionEnabled bool `json:"domainRestrictionEnabled"`
17-
// Unique 20-hexadecimal digit string that identifies the identity provider that this connected org config is associated with.
17+
// Unique 20-hexadecimal digit string that identifies the UI access identity provider that this connected org config is associated with.
1818
IdentityProviderId string `json:"identityProviderId"`
1919
// Unique 24-hexadecimal digit string that identifies the connected organization configuration.
2020
// Read only field.

0 commit comments

Comments
 (0)