openapi: 3.0.1 info: description: "The MongoDB Atlas Administration API allows developers to manage all components in MongoDB Atlas.\n\nThe Atlas Administration API supports OAuth2 Service Accounts and HTTP Digest-based API keys. Service accounts are the recommended authentication method and API keys are considered a legacy option.\n\nTo authenticate with a Service Account, first exchange its client ID and secret for an access token using the OAuth 2.0 Client Credentials flow. Atlas provides a token endpoint at `POST https://cloud.mongodb.com/api/oauth/token`, which returns a Bearer token that is reusable and valid for 1 hour (3600 seconds).\n\nFor example, to [return a list of your organizations](https://www.mongodb.com/docs/api/doc/atlas-admin-api-v2/operation/operation-listorgs) with [cURL](https://en.wikipedia.org/wiki/CURL), first generate an access token and then use that token to call the same Atlas Administration API endpoint shown in the current example:\n\n```\nACCESS_TOKEN=$(curl -fsS --request POST https://cloud.mongodb.com/api/oauth/token \\\n --header \"Authorization: Basic $(printf '%s' \"${CLIENT_ID}:${CLIENT_SECRET}\" | base64 | tr -d '\\n')\" \\\n --header \"Content-Type: application/x-www-form-urlencoded\" \\\n --header \"Accept: application/json\" \\\n --data \"grant_type=client_credentials\" | jq -r '.access_token')\n\ncurl --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/orgs?pretty=true\"\n```\n\nIf your organization requires an IP access list for the Atlas Administration API, the token can be created from any IP address, but the API call that uses the token must originate from an allowed IP.\n\nTo learn more, see [Get Started with the Atlas Administration API](https://www.mongodb.com/docs/atlas/configure-api-access/). For support, see [MongoDB Support](https://www.mongodb.com/support/get-started).\n\nYou can also explore the various endpoints available through the Atlas Administration API in MongoDB's [Postman workspace](https://www.postman.com/mongodb-devrel/workspace/mongodb-atlas-administration-apis/) (requires a Postman account)." license: name: CC BY-NC-SA 3.0 US url: https://creativecommons.org/licenses/by-nc-sa/3.0/us/ termsOfService: https://www.mongodb.com/mongodb-management-service-terms-and-conditions title: MongoDB Atlas Administration Access Tracking MongoDB Cloud Users API version: '2.0' x-xgen-sha: 3d70e065843c008b9871ea7836c98c9de6f202f9 servers: - url: https://cloud.mongodb.com security: - ServiceAccounts: [] - DigestAuth: [] tags: - description: Returns, adds, and edits MongoDB Cloud users. name: MongoDB Cloud Users paths: /api/atlas/v2/groups/{groupId}/users: get: description: 'Returns details about the pending and active MongoDB Cloud users associated with the specified project. To use this resource, the requesting Service Account or API Key must have the Project Read Only role. **Note**: This resource cannot be used to view details about users invited via the deprecated Invite One MongoDB Cloud User to Join One Project endpoint. **Note**: To return both pending and active users, use v2-{2025-02-19} or later. If using a deprecated version, only active users will be returned. Deprecated versions: v2-{2023-01-01}' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: listGroupUsers parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/groupId' - $ref: '#/components/parameters/includeCount' - $ref: '#/components/parameters/itemsPerPage' - $ref: '#/components/parameters/pageNum' - $ref: '#/components/parameters/pretty' - description: 'Flag that indicates whether the returned list should include users who belong to a team with a role in this project. You might not have assigned the individual users a role in this project. If `"flattenTeams" : false`, this resource returns only users with a role in the project. If `"flattenTeams" : true`, this resource returns both users with roles in the project and users who belong to teams with roles in the project.' in: query name: flattenTeams schema: default: false type: boolean - description: 'Flag that indicates whether the returned list should include users with implicit access to the project, the Organization Owner or Organization Read Only role. You might not have assigned the individual users a role in this project. If `"includeOrgUsers": false`, this resource returns only users with a role in the project. If `"includeOrgUsers": true`, this resource returns both users with roles in the project and users who have implicit access to the project through their organization role.' in: query name: includeOrgUsers schema: default: false type: boolean - description: Flag that indicates whether to filter the returned list by users organization membership status. If you exclude this parameter, this resource returns both pending and active users. Not supported in deprecated versions. in: query name: orgMembershipStatus schema: example: ACTIVE type: string - description: Email address to filter users by. Not supported in deprecated versions. in: query name: username schema: format: email type: string responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/PaginatedGroupUserView' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Return All MongoDB Cloud Users in One Project tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers listGroupUsers --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.ListGroupUsersApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tListGroupUsersWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users?pretty=true\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users?pretty=true\"" x-rolesRequirements: - Project Read Only x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/listGroupUsers post: description: "Adds one MongoDB Cloud user to one project. To use this resource, the requesting Service Account or API Key must have the Project Owner role or Project Access Manager role. \n- If the user has a pending invitation to join the project's organization, MongoDB Cloud modifies it and grants project access. \n- If the user doesn't have an invitation to join the organization, MongoDB Cloud sends a new invitation that grants the user organization and project access. \n- If the user is already active in the project's organization, MongoDB Cloud grants access to the project. \n" operationId: addGroupUsers parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/groupId' - $ref: '#/components/parameters/pretty' requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/GroupUserRequest' description: The active or pending MongoDB Cloud user that you want to add to the specified project. required: true responses: '201': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/GroupUserResponse' x-xgen-version: '2025-02-19' description: Created headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Add One MongoDB Cloud User to One Project tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers addGroupUsers --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.AddGroupUsersApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tAddGroupUsersWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users\" \\\n -d '{ }'" x-rolesRequirements: - Project Access Manager x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/addGroupUsers x-xgen-method-verb-override: customMethod: 'True' verb: add /api/atlas/v2/groups/{groupId}/users/{userId}: delete: description: 'Removes one MongoDB Cloud user from the specified project. You can remove an active user or a user that has not yet accepted the invitation to join the organization. To use this resource, the requesting Service Account or API Key must have the Project Owner role or Project Access Manager role. **Note**: This resource cannot be used to remove pending users invited via the deprecated Invite One MongoDB Cloud User to Join One Project endpoint. **Note**: To remove pending or active users, use v2-{2025-02-19} or later. If using a deprecated version, only active users can be removed. Deprecated versions: v2-{2023-01-01}' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: removeGroupUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/groupId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the project. If you need to lookup a user's `userId` or verify a user's status in the organization, use the [Return All MongoDB Cloud Users in One Project](#tag/MongoDB-Cloud-Users/operation/listProjectUsers) resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string responses: '204': content: application/vnd.atlas.2025-02-19+json: x-xgen-version: '2025-02-19' description: This endpoint does not return a response body. headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Remove One MongoDB Cloud User from One Project tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers removeGroupUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.RemoveGroupUserApiParams{}\n\thttpResp, err := client.MongoDBCloudUsersApi.\n\t\tRemoveGroupUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X DELETE \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X DELETE \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}\"" x-rolesRequirements: - Project Access Manager x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/removeGroupUser x-xgen-method-verb-override: customMethod: 'True' verb: remove get: description: 'Returns information about the specified MongoDB Cloud user within the context of the specified project. To use this resource, the requesting Service Account or API Key must have the Project Read Only role. **Note**: You can only use this resource to fetch information about MongoDB Cloud human users. To return information about an API Key, use the [Return One Organization API Key](#tag/Programmatic-API-Keys/operation/getApiKey) endpoint. **Note**: This resource does not return information about pending users invited via the deprecated [Invite One MongoDB Cloud User to Join One Project](#tag/Projects/operation/createProjectInvitation) endpoint.' operationId: getGroupUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/groupId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the project. If you need to lookup a user's `userId` or verify a user's status in the organization, use the Return All MongoDB Cloud Users in One Project resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/GroupUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Return One MongoDB Cloud User in One Project tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers getGroupUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.GetGroupUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tGetGroupUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}?pretty=true\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}?pretty=true\"" x-rolesRequirements: - Project Read Only x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/getGroupUser /api/atlas/v2/groups/{groupId}/users/{userId}:addRole: post: description: 'Adds one project-level role to the MongoDB Cloud user. You can add a role to an active user or a user that has been invited to join the project. To use this resource, the requesting Service Account or API Key must have the Project Owner role or Project Access Manager role. **Note**: This resource cannot be used to add a role to users invited using the deprecated Invite One MongoDB Cloud User to Join One Project endpoint.' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: addGroupUserRole parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/groupId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the project. If you need to lookup a user's `userId` or verify a user's status in the organization, use the Return All MongoDB Cloud Users in One Project resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/AddOrRemoveGroupRole' description: Project-level role to assign to the MongoDB Cloud user. required: true responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/GroupUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Add One Project Role to One MongoDB Cloud User tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers addGroupUserRole --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.AddGroupUserRoleApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tAddGroupUserRoleWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}:addRole\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}:addRole\" \\\n -d '{ }'" x-rolesRequirements: - Project Access Manager x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/addGroupUserRole /api/atlas/v2/groups/{groupId}/users/{userId}:removeRole: post: description: 'Removes one project-level role from the MongoDB Cloud user. You can remove a role from an active user or a user that has been invited to join the project. To replace a user''s only role, add the new role before removing the old role. A user must have at least one role at all times. To use this resource, the requesting Service Account or API Key must have the Project Owner role or Project Access Manager role. **Note**: This resource cannot be used to remove a role from users invited using the deprecated Invite One MongoDB Cloud User to Join One Project endpoint.' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: removeGroupUserRole parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/groupId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the project. If you need to lookup a user's `userId` or verify a user's status in the organization, use the Return All MongoDB Cloud Users in One Project resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/AddOrRemoveGroupRole' description: Project-level role to remove from the MongoDB Cloud user. required: true responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/GroupUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Remove One Project Role from One MongoDB Cloud User tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers removeGroupUserRole --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.RemoveGroupUserRoleApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tRemoveGroupUserRoleWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}:removeRole\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/users/{userId}:removeRole\" \\\n -d '{ }'" x-rolesRequirements: - Project Access Manager x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/removeGroupUserRole /api/atlas/v2/orgs/{orgId}/teams/{teamId}/users: get: description: 'Returns details about the pending and active MongoDB Cloud users associated with the specified team in the organization. Teams enable you to grant project access roles to MongoDB Cloud users. To use this resource, the requesting Service Account or API Key must have the Organization Member role. **Note**: This resource cannot be used to view details about users invited via the deprecated [Invite One MongoDB Cloud User to Join One Project](#tag/Projects/operation/createProjectInvitation) endpoint. **Note**: To return both pending and active users, use v2-{2025-02-19} or later. If using a deprecated version, only active users will be returned. Deprecated versions: v2-{2023-01-01}' externalDocs: description: Manage Organization Teams url: https://docs.atlas.mongodb.com/access/manage-teams-in-orgs/#std-label-manage-teams operationId: listOrgTeamUsers parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/itemsPerPage' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pageNum' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the team whose application users you want to return. in: path name: teamId required: true schema: pattern: ^([a-f0-9]{24})$ type: string - description: Email address to filter users by. Not supported in deprecated versions. in: query name: username schema: format: email type: string - description: Organization membership status to filter users by. If you exclude this parameter, this resource returns both pending and active users. Not supported in deprecated versions. in: query name: orgMembershipStatus schema: example: ACTIVE type: string - description: Unique 24-hexadecimal digit string to filter users by. Not supported in deprecated versions. in: query name: userId schema: pattern: ^([a-f0-9]{24})$ type: string responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/PaginatedOrgUserView' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Return All MongoDB Cloud Users Assigned to One Team tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers listTeamUsers --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.ListOrgTeamUsersApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tListOrgTeamUsersWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/teams/{teamId}/users?pretty=true\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/teams/{teamId}/users?pretty=true\"" x-rolesRequirements: - Organization Member x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/listOrgTeamUsers x-xgen-operation-id-override: listTeamUsers /api/atlas/v2/orgs/{orgId}/teams/{teamId}:addUser: post: description: 'Adds one MongoDB Cloud user to one team. You can add an active user or a user that has not yet accepted the invitation to join the organization. To use this resource, the requesting Service Account or API Key must have the Organization Owner role. **Note**: This resource cannot be used to add a user invited via the deprecated Invite One MongoDB Cloud User to Join One Project endpoint.' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project endpoint' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/updateProjectInvitation operationId: addOrgTeamUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the team to add the MongoDB Cloud user to. in: path name: teamId required: true schema: pattern: ^([a-f0-9]{24})$ type: string requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/AddOrRemoveUserFromTeam' description: The active or pending MongoDB Cloud user that you want to add to the specified team. required: true responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Add One MongoDB Cloud User to One Team tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers addOrgTeamUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.AddOrgTeamUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tAddOrgTeamUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/teams/{teamId}:addUser\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/teams/{teamId}:addUser\" \\\n -d '{ }'" x-rolesRequirements: - Organization Owner x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/addOrgTeamUser /api/atlas/v2/orgs/{orgId}/teams/{teamId}:removeUser: post: description: 'Removes one MongoDB Cloud user from one team. You can remove an active user or a user that has not yet accepted the invitation to join the organization. To use this resource, the requesting Service Account or API Key must have the Organization Owner role. **Note**: This resource cannot be used to remove a user invited via the deprecated Invite One MongoDB Cloud User to Join One Project endpoint.' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: removeOrgTeamUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the team to remove the MongoDB user from. in: path name: teamId required: true schema: pattern: ^([a-f0-9]{24})$ type: string requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/AddOrRemoveUserFromTeam' description: The id of the active or pending MongoDB Cloud user that you want to remove from the specified team. required: true responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Remove One MongoDB Cloud User from One Team tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers removeOrgTeamUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.RemoveOrgTeamUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tRemoveOrgTeamUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/teams/{teamId}:removeUser\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/teams/{teamId}:removeUser\" \\\n -d '{ }'" x-rolesRequirements: - Organization Owner x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/removeOrgTeamUser /api/atlas/v2/orgs/{orgId}/users: get: description: 'Returns details about the pending and active MongoDB Cloud users associated with the specified organization. To use this resource, the requesting Service Account or API Key must have the Organization Member role. **Note**: This resource cannot be used to view details about users invited via the deprecated Invite One MongoDB Cloud User to Join One Project endpoint. **Note**: To return both pending and active users, use v2-{2025-02-19} or later. If using a deprecated version, only active users will be returned. Deprecated versions: v2-{2023-01-01}' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: listOrgUsers parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - $ref: '#/components/parameters/includeCount' - $ref: '#/components/parameters/itemsPerPage' - $ref: '#/components/parameters/pageNum' - description: Email address to filter users by. Not supported in deprecated versions. in: query name: username schema: format: email type: string - description: Organization membership status to filter users by. If you exclude this parameter, this resource returns both pending and active users. Not supported in deprecated versions. in: query name: orgMembershipStatus schema: example: ACTIVE type: string responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/PaginatedOrgUserView' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Return All MongoDB Cloud Users in One Organization tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers listOrgUsers --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.ListOrgUsersApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tListOrgUsersWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users?pretty=true\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users?pretty=true\"" x-rolesRequirements: - Organization Member x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/listOrgUsers post: description: 'Invites one new or existing MongoDB Cloud user to join the organization. The invitation to join the organization will be sent to the username provided and must be accepted within 30 days. To use this resource, the requesting Service Account or API Key must have the Organization Owner role. **Note**: If the user does not have an existing MongoDB Cloud account, they will be prompted to finish setting up an account upon accepting the invitation. If the user already has an account, they will still receive an invitation to access the organization.' operationId: createOrgUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserRequest' description: Represents the MongoDB Cloud user to be created within the organization. required: true responses: '201': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserResponse' x-xgen-version: '2025-02-19' description: Created headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Add One MongoDB Cloud User to One Organization tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers createOrgUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.CreateOrgUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tCreateOrgUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users\" \\\n -d '{ }'" x-rolesRequirements: - Organization Owner x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/createOrgUser /api/atlas/v2/orgs/{orgId}/users/{userId}: delete: description: 'Removes one MongoDB Cloud user in the specified organization. You can remove an active user or a user that has not yet accepted the invitation to join the organization. To use this resource, the requesting Service Account or API Key must have the Organization Owner role. **Note**: This resource cannot be used to remove pending users invited via the deprecated Invite One MongoDB Cloud User to Join One Project endpoint. **Note**: To remove pending or active users, use v2-{2025-02-19} or later. If using a deprecated version, only active users can be removed. Deprecated versions: v2-{2023-01-01}' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: removeOrgUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the organization. If you need to lookup a user's `userId` or verify a user's status in the organization, use the [Return All MongoDB Cloud Users in One Organization](#tag/MongoDB-Cloud-Users/operation/listOrganizationUsers) resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string responses: '204': content: application/vnd.atlas.2025-02-19+json: x-xgen-version: '2025-02-19' description: This endpoint does not return a response body. headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Remove One MongoDB Cloud User from One Organization tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers removeOrgUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.RemoveOrgUserApiParams{}\n\thttpResp, err := client.MongoDBCloudUsersApi.\n\t\tRemoveOrgUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X DELETE \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X DELETE \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}\"" x-rolesRequirements: - Organization Owner x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/removeOrgUser x-xgen-method-verb-override: customMethod: 'True' verb: remove get: description: 'Returns information about the specified MongoDB Cloud user within the context of the specified organization. To use this resource, the requesting Service Account or API Key must have the Organization Member role. **Note**: This resource can only be used to fetch information about MongoDB Cloud human users. To return information about an API Key, use the [Return One Organization API Key](#tag/Programmatic-API-Keys/operation/getApiKey) endpoint. **Note**: This resource does not return information about pending users invited via the deprecated [Invite One MongoDB Cloud User to Join One Project](#tag/Projects/operation/createProjectInvitation) endpoint.' operationId: getOrgUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the organization. If you need to lookup a user's `userId` or verify a user's status in the organization, use the Return All MongoDB Cloud Users in One Organization resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Return One MongoDB Cloud User in One Organization tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers getOrgUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.GetOrgUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tGetOrgUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}?pretty=true\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}?pretty=true\"" x-rolesRequirements: - Organization Member x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/getOrgUser patch: description: 'Updates one MongoDB Cloud user in the specified organization. You can update an active user or a user that has not yet accepted the invitation to join the organization. To use this resource, the requesting Service Account or API Key must have the Organization Owner role. **Note**: Only include the fields you wish to update in the request body. Supplying a field with an empty value will reset that field on the user. **Note**: This resource cannot be used to update pending users invited via the deprecated Invite One MongoDB Cloud User to Join One Project endpoint.' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: updateOrgUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the organization. If you need to lookup a user's `userId` or verify a user's status in the organization, use the Return All MongoDB Cloud Users in One Organization resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserUpdateRequest' description: Represents the roles and teams to assign the MongoDB Cloud user. required: true responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Update One MongoDB Cloud User in One Organization tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers updateOrgUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.UpdateOrgUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tUpdateOrgUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X PATCH \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X PATCH \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}\" \\\n -d '{ }'" x-rolesRequirements: - Organization Owner x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/updateOrgUser /api/atlas/v2/orgs/{orgId}/users/{userId}:addRole: post: description: 'Adds one organization-level role to the MongoDB Cloud user. You can add a role to an active user or a user that has not yet accepted the invitation to join the organization. To use this resource, the requesting Service Account or API Key must have the Organization Owner role. **Note**: This operation is atomic. **Note**: This resource cannot be used to add a role to users invited using the deprecated Invite One MongoDB Cloud User to Join One Project endpoint.' externalDocs: description: 'Deprecated: Invite One MongoDB Cloud User to Join One Project' url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: addOrgUserRole parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the organization. If you need to lookup a user's `userId` or verify a user's status in the organization, use the Return All MongoDB Cloud Users in One Organization resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/AddOrRemoveOrgRole' description: Organization-level role to assign to the MongoDB Cloud user. required: true responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Add One Organization Role to One MongoDB Cloud User tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers addOrgRole --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.AddOrgUserRoleApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tAddOrgUserRoleWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}:addRole\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}:addRole\" \\\n -d '{ }'" x-rolesRequirements: - Organization Owner x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/addOrgUserRole x-xgen-operation-id-override: addOrgRole /api/atlas/v2/orgs/{orgId}/users/{userId}:removeRole: post: description: 'Removes one organization-level role from the MongoDB Cloud user. You can remove a role from an active user or a user that has not yet accepted the invitation to join the organization. To replace a user''s only role, add the new role before removing the old role. A user must have at least one role at all times. To use this resource, the requesting Service Account or API Key must have the Organization Owner role. **Note**: This operation is atomic. **Note**: This resource cannot be used to remove a role from users invited using the deprecated Invite One MongoDB Cloud User to Join One Project endpoint.' externalDocs: description: Invite One MongoDB Cloud User to Join One Project url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Projects/operation/createProjectInvitation operationId: removeOrgUserRole parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/orgId' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies the pending or active user in the organization. If you need to lookup a user's `userId` or verify a user's status in the organization, use the Return All MongoDB Cloud Users in One Organization resource and filter by `username`. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string requestBody: content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/AddOrRemoveOrgRole' description: Organization-level role to remove from the MongoDB Cloud user. required: true responses: '200': content: application/vnd.atlas.2025-02-19+json: schema: $ref: '#/components/schemas/OrgUserResponse' x-xgen-version: '2025-02-19' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Remove One Organization Role from One MongoDB Cloud User tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers removeOrgRole --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.RemoveOrgUserRoleApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tRemoveOrgUserRoleWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}:removeRole\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/orgs/{orgId}/users/{userId}:removeRole\" \\\n -d '{ }'" x-rolesRequirements: - Organization Owner x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/removeOrgUserRole x-xgen-operation-id-override: removeOrgRole /api/atlas/v2/users: post: deprecated: true description: "Creates one MongoDB Cloud user account. A MongoDB Cloud user account grants access to only the MongoDB Cloud application. To grant database access, create a database user. MongoDB Cloud sends an email to the users you specify, inviting them to join the project. Invited users don't have access to the project until they accept the invitation. Invitations expire after 30 days.\n\n MongoDB Cloud limits MongoDB Cloud user membership to a maximum of 250 MongoDB Cloud users per team. MongoDB Cloud limits MongoDB Cloud user membership to 500 MongoDB Cloud users per project and 500 MongoDB Cloud users per organization, which includes the combined membership of all projects in the organization. MongoDB Cloud raises an error if an operation exceeds these limits. For example, if you have an organization with five projects, and each project has 100 MongoDB Cloud users, and each MongoDB Cloud user belongs to only one project, you can't add any MongoDB Cloud users to this organization without first removing existing MongoDB Cloud users from the organization.\n\n To use this resource, the requesting Service Account or API Key can have any role." operationId: createUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/pretty' requestBody: content: application/vnd.atlas.2023-01-01+json: schema: $ref: '#/components/schemas/CloudAppUser' description: MongoDB Cloud user account to create. required: true responses: '200': content: application/vnd.atlas.2023-01-01+json: schema: $ref: '#/components/schemas/CloudAppUser' x-xgen-version: '2023-01-01' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Create One MongoDB Cloud User tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers createUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.CreateUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tCreateUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/users\" \\\n -d '{ }'" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n --header \"Content-Type: application/json\" \\\n -X POST \"https://cloud.mongodb.com/api/atlas/v2/users\" \\\n -d '{ }'" x-sunset: '2027-07-01' x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/createUser /api/atlas/v2/users/byName/{userName}: get: deprecated: true description: Returns the details for one MongoDB Cloud user account with the specified username. You can't use this endpoint to return information about an API Key. To return information about an API Key, use the Return One Organization API Key endpoint. To use this resource, the requesting Service Account or API Key can have any role. externalDocs: description: Return One Organization API Key url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Programmatic-API-Keys/operation/getApiKey operationId: getUserByName parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/pretty' - description: Email address that belongs to the MongoDB Cloud user account. You cannot modify this address after creating the user. in: path name: userName required: true schema: pattern: ^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$ type: string responses: '200': content: application/vnd.atlas.2023-01-01+json: schema: $ref: '#/components/schemas/CloudAppUser' x-xgen-version: '2023-01-01' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Return One MongoDB Cloud User by Username tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers getUserByName --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.GetUserByNameApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tGetUserByNameWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/users/byName/{userName}?pretty=true\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/users/byName/{userName}?pretty=true\"" x-sunset: '2027-07-01' x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/getUserByName /api/atlas/v2/users/{userId}: get: deprecated: true description: Returns the details for one MongoDB Cloud user account with the specified unique identifier for the user. You can't use this endpoint to return information on an API Key. To return information about an API Key, use the Return One Organization API Key endpoint. You can always retrieve your own user account. If you are the owner of a MongoDB Cloud organization or project, you can also retrieve the user profile for any user with membership in that organization or project. To use this resource, the requesting Service Account or API Key can have any role. externalDocs: description: Return One Organization API Key url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/Programmatic-API-Keys/operation/getApiKey operationId: getUser parameters: - $ref: '#/components/parameters/envelope' - $ref: '#/components/parameters/pretty' - description: Unique 24-hexadecimal digit string that identifies this user. in: path name: userId required: true schema: pattern: ^([a-f0-9]{24})$ type: string responses: '200': content: application/vnd.atlas.2023-01-01+json: schema: $ref: '#/components/schemas/CloudAppUser' x-xgen-version: '2023-01-01' description: OK headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '429': $ref: '#/components/responses/tooManyRequests' '500': $ref: '#/components/responses/internalServerError' summary: Return One MongoDB Cloud User by ID tags: - MongoDB Cloud Users x-codeSamples: - lang: cURL label: Atlas CLI source: atlas api mongoDbCloudUsers getUser --help - lang: go label: Go source: "import (\n\t\"os\"\n\t\"context\"\n\t\"log\"\n\tsdk \"go.mongodb.org/atlas-sdk/v20250312001/admin\"\n)\n\nfunc main() {\n\tctx := context.Background()\n\tclientID := os.Getenv(\"MONGODB_ATLAS_CLIENT_ID\")\n\tclientSecret := os.Getenv(\"MONGODB_ATLAS_CLIENT_SECRET\")\n\n\t// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth\n\tclient, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))\n\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: %v\", err)\n\t}\n\n\tparams = &sdk.GetUserApiParams{}\n\tsdkResp, httpResp, err := client.MongoDBCloudUsersApi.\n\t\tGetUserWithParams(ctx, params).\n\t\tExecute()\n}\n" - lang: cURL label: curl (Service Accounts) source: "curl --include --header \"Authorization: Bearer ${ACCESS_TOKEN}\" \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/users/{userId}?pretty=true\"" - lang: cURL label: curl (Digest) source: "curl --user \"${PUBLIC_KEY}:${PRIVATE_KEY}\" \\\n --digest --include \\\n --header \"Accept: application/vnd.atlas.2025-03-12+json\" \\\n -X GET \"https://cloud.mongodb.com/api/atlas/v2/users/{userId}?pretty=true\"" x-sunset: '2027-07-01' x-xgen-docs-url: https://mongodb.com/docs/atlas/reference/api-resources-spec/v2/#tag/MongoDB-Cloud-Users/operation/getUser components: schemas: GroupPendingUserResponse: allOf: - $ref: '#/components/schemas/GroupUserResponse' - properties: invitationCreatedAt: description: Date and time when MongoDB Cloud sent the invitation. MongoDB Cloud represents this timestamp in ISO 8601 format in UTC. format: date-time readOnly: true type: string invitationExpiresAt: description: Date and time when the invitation from MongoDB Cloud expires. MongoDB Cloud represents this timestamp in ISO 8601 format in UTC. format: date-time readOnly: true type: string inviterUsername: description: Username of the MongoDB Cloud user who sent the invitation to join the organization. format: email readOnly: true type: string type: object required: - id - invitationCreatedAt - invitationExpiresAt - inviterUsername - orgMembershipStatus - roles - username type: object OrgUserUpdateRequest: properties: roles: $ref: '#/components/schemas/OrgUserRolesRequest' teamIds: description: List of unique 24-hexadecimal digit strings that identifies the teams to assign the MongoDB Cloud user. items: example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ type: string type: array uniqueItems: true writeOnly: true type: object OrgUserRequest: properties: roles: $ref: '#/components/schemas/OrgUserRolesRequest' teamIds: description: List of unique 24-hexadecimal digit strings that identifies the teams to which this MongoDB Cloud user belongs. items: type: string type: array uniqueItems: true writeOnly: true username: description: Email address that represents the username of the MongoDB Cloud user. format: email type: string writeOnly: true required: - roles - username type: object AddOrRemoveUserFromTeam: properties: id: description: Unique 24-hexadecimal digit string that identifies the MongoDB Cloud user. example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ type: string writeOnly: true required: - id type: object Link: properties: href: description: Uniform Resource Locator (URL) that points another API resource to which this response has some relationship. This URL often begins with `https://cloud.mongodb.com/api/atlas`. example: https://cloud.mongodb.com/api/atlas type: string rel: description: Uniform Resource Locator (URL) that defines the semantic relationship between this resource and another API resource. This URL often begins with `https://cloud.mongodb.com/api/atlas`. example: self type: string type: object OrgPendingUserResponse: allOf: - $ref: '#/components/schemas/OrgUserResponse' - properties: invitationCreatedAt: description: Date and time when MongoDB Cloud sent the invitation. MongoDB Cloud represents this timestamp in ISO 8601 format in UTC. format: date-time readOnly: true type: string invitationExpiresAt: description: Date and time when the invitation from MongoDB Cloud expires. MongoDB Cloud represents this timestamp in ISO 8601 format in UTC. format: date-time readOnly: true type: string inviterUsername: description: Username of the MongoDB Cloud user who sent the invitation to join the organization. format: email readOnly: true type: string type: object required: - id - invitationCreatedAt - invitationExpiresAt - inviterUsername - orgMembershipStatus - roles - username type: object ApiError: properties: badRequestDetail: $ref: '#/components/schemas/BadRequestDetail' detail: description: Describes the specific conditions or reasons that cause each type of error. type: string error: description: HTTP status code returned with this error. externalDocs: url: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status format: int32 readOnly: true type: integer errorCode: description: Application error code returned with this error. readOnly: true type: string parameters: description: Parameters used to give more information about the error. items: type: object readOnly: true type: array reason: description: Application error message returned with this error. readOnly: true type: string required: - error - errorCode type: object PaginatedGroupUserView: properties: links: description: List of one or more Uniform Resource Locators (URLs) that point to API sub-resources, related API resources, or both. RFC 5988 outlines these relationships. externalDocs: description: Web Linking Specification (RFC 5988) url: https://datatracker.ietf.org/doc/html/rfc5988 items: $ref: '#/components/schemas/Link' readOnly: true type: array results: description: List of returned documents that MongoDB Cloud provides when completing this request. items: $ref: '#/components/schemas/GroupUserResponse' readOnly: true type: array totalCount: description: Total number of documents available. MongoDB Cloud omits this value if `includeCount` is set to `false`. The total number is an estimate and may not be exact. format: int32 minimum: 0 readOnly: true type: integer required: - results type: object GroupUserResponse: discriminator: mapping: ACTIVE: '#/components/schemas/GroupActiveUserResponse' PENDING: '#/components/schemas/GroupPendingUserResponse' propertyName: orgMembershipStatus oneOf: - $ref: '#/components/schemas/GroupPendingUserResponse' - $ref: '#/components/schemas/GroupActiveUserResponse' properties: id: description: Unique 24-hexadecimal digit string that identifies the MongoDB Cloud user. example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ readOnly: true type: string orgMembershipStatus: description: String enum that indicates whether the MongoDB Cloud user has a pending invitation to join the organization or they are already active in the organization. enum: - PENDING - ACTIVE readOnly: true type: string roles: description: One or more project-level roles assigned to the MongoDB Cloud user. externalDocs: description: MongoDB Cloud User Roles url: https://www.mongodb.com/docs/atlas/reference/user-roles/ items: type: string readOnly: true type: array uniqueItems: true username: description: Email address that represents the username of the MongoDB Cloud user. format: email readOnly: true type: string required: - id - orgMembershipStatus - roles - username type: object BadRequestDetail: description: Bad request detail. properties: fields: description: Describes all violations in a client request. items: $ref: '#/components/schemas/FieldViolation' type: array readOnly: true type: object GroupUserRequest: properties: roles: description: One or more project-level roles to assign the MongoDB Cloud user. externalDocs: description: MongoDB Cloud User Roles url: https://www.mongodb.com/docs/atlas/reference/user-roles/ items: type: string minItems: 1 type: array uniqueItems: true writeOnly: true username: description: Email address that represents the username of the MongoDB Cloud user. format: email type: string writeOnly: true required: - roles - username type: object OrgUserResponse: discriminator: mapping: ACTIVE: '#/components/schemas/OrgActiveUserResponse' PENDING: '#/components/schemas/OrgPendingUserResponse' propertyName: orgMembershipStatus oneOf: - $ref: '#/components/schemas/OrgPendingUserResponse' - $ref: '#/components/schemas/OrgActiveUserResponse' properties: id: description: Unique 24-hexadecimal digit string that identifies the MongoDB Cloud user. example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ readOnly: true type: string orgMembershipStatus: description: String enum that indicates whether the MongoDB Cloud user has a pending invitation to join the organization or they are already active in the organization. enum: - PENDING - ACTIVE readOnly: true type: string roles: $ref: '#/components/schemas/OrgUserRolesResponse' teamIds: description: List of unique 24-hexadecimal digit strings that identifies the teams to which this MongoDB Cloud user belongs. items: example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ type: string readOnly: true type: array uniqueItems: true username: description: Email address that represents the username of the MongoDB Cloud user. format: email readOnly: true type: string required: - id - orgMembershipStatus - roles - username type: object CloudAccessRoleAssignment: description: MongoDB Cloud user's roles and the corresponding organization or project to which that role applies. Each role can apply to one organization or one project but not both. properties: groupId: description: Unique 24-hexadecimal digit string that identifies the project to which this role belongs. You can set a value for this parameter or `orgId` but not both in the same request. example: 32b6e34b3d91647abb20e7b8 maxLength: 24 minLength: 24 pattern: ^([a-f0-9]{24})$ type: string orgId: description: Unique 24-hexadecimal digit string that identifies the organization to which this role belongs. You can set a value for this parameter or `groupId` but not both in the same request. example: 32b6e34b3d91647abb20e7b8 maxLength: 24 minLength: 24 pattern: ^([a-f0-9]{24})$ type: string roleName: description: Human-readable label that identifies the collection of privileges that MongoDB Cloud grants a specific API key, MongoDB Cloud user, or MongoDB Cloud team. These roles include organization- and project-level roles. externalDocs: description: MongoDB Cloud User Roles url: https://www.mongodb.com/docs/atlas/reference/user-roles/ type: string title: Role Assignment type: object GroupActiveUserResponse: allOf: - $ref: '#/components/schemas/GroupUserResponse' - properties: country: description: Two-character alphabetical string that identifies the MongoDB Cloud user's geographic location. This parameter uses the ISO 3166-1a2 code format. example: US pattern: ^([A-Z]{2})$ readOnly: true type: string createdAt: description: Date and time when MongoDB Cloud created the current account. This value is in the ISO 8601 timestamp format in UTC. format: date-time readOnly: true type: string firstName: description: First or given name that belongs to the MongoDB Cloud user. example: John readOnly: true type: string lastAuth: description: Date and time when the current account last authenticated. This value is in the ISO 8601 timestamp format in UTC. format: date-time readOnly: true type: string lastName: description: Last name, family name, or surname that belongs to the MongoDB Cloud user. example: Doe readOnly: true type: string mobileNumber: description: Mobile phone number that belongs to the MongoDB Cloud user. pattern: (?:(?:\\+?1\\s*(?:[.-]\\s*)?)?(?:(\\s*([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9])\\s*)|([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9]))\\s*(?:[.-]\\s*)?)([2-9]1[02-9]|[2-9][02-9]1|[2-9][02-9]{2})\\s*(?:[.-]\\s*)?([0-9]{4})$ readOnly: true type: string type: object required: - createdAt - firstName - id - lastName - orgMembershipStatus - roles - username type: object CloudAppUser: properties: country: description: Two alphabet characters that identifies MongoDB Cloud user's geographic location. This parameter uses the ISO 3166-1a2 code format. pattern: ^([A-Z]{2})$ type: string createdAt: description: Date and time when the current account is created. This value is in the ISO 8601 timestamp format in UTC. format: date-time readOnly: true type: string emailAddress: deprecated: true description: Email address that belongs to the MongoDB Cloud user. format: email readOnly: true type: string firstName: description: First or given name that belongs to the MongoDB Cloud user. type: string id: description: Unique 24-hexadecimal digit string that identifies the MongoDB Cloud user. example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ readOnly: true type: string lastAuth: description: Date and time when the current account last authenticated. This value is in the ISO 8601 timestamp format in UTC. format: date-time readOnly: true type: string lastName: description: Last name, family name, or surname that belongs to the MongoDB Cloud user. type: string links: description: List of one or more Uniform Resource Locators (URLs) that point to API sub-resources, related API resources, or both. RFC 5988 outlines these relationships. externalDocs: description: Web Linking Specification (RFC 5988) url: https://datatracker.ietf.org/doc/html/rfc5988 items: $ref: '#/components/schemas/Link' readOnly: true type: array mobileNumber: description: Mobile phone number that belongs to the MongoDB Cloud user. pattern: (?:(?:\\+?1\\s*(?:[.-]\\s*)?)?(?:(\\s*([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9])\\s*)|([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9]))\\s*(?:[.-]\\s*)?)([2-9]1[02-9]|[2-9][02-9]1|[2-9][02-9]{2})\\s*(?:[.-]\\s*)?([0-9]{4})$ type: string password: description: Password applied with the username to log in to MongoDB Cloud. MongoDB Cloud does not return this parameter except in response to creating a new MongoDB Cloud user. Only the MongoDB Cloud user can update their password after it has been set from the MongoDB Cloud console. format: password minLength: 8 type: string roles: description: List of objects that display the MongoDB Cloud user's roles and the corresponding organization or project to which that role applies. A role can apply to one organization or one project but not both. items: $ref: '#/components/schemas/CloudAccessRoleAssignment' type: array teamIds: description: List of unique 24-hexadecimal digit strings that identifies the teams to which this MongoDB Cloud user belongs. items: description: Unique 24-hexadecimal digit string that identifies the team to which this MongoDB Cloud user belongs. example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ type: string readOnly: true type: array uniqueItems: true username: description: Email address that represents the username of the MongoDB Cloud user. format: email type: string required: - country - emailAddress - firstName - lastName - mobileNumber - password - roles - username type: object FieldViolation: properties: description: description: A description of why the request element is bad. type: string field: description: A path that leads to a field in the request body. type: string required: - description - field type: object GroupRoleAssignment: properties: groupId: description: Unique 24-hexadecimal digit string that identifies the project to which these roles belong. example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ type: string groupRoles: description: One or more project-level roles assigned to the MongoDB Cloud user. externalDocs: description: MongoDB Cloud User Roles url: https://www.mongodb.com/docs/atlas/reference/user-roles/ items: type: string type: array uniqueItems: true type: object PaginatedOrgUserView: properties: links: description: List of one or more Uniform Resource Locators (URLs) that point to API sub-resources, related API resources, or both. RFC 5988 outlines these relationships. externalDocs: description: Web Linking Specification (RFC 5988) url: https://datatracker.ietf.org/doc/html/rfc5988 items: $ref: '#/components/schemas/Link' readOnly: true type: array results: description: List of returned documents that MongoDB Cloud provides when completing this request. items: $ref: '#/components/schemas/OrgUserResponse' readOnly: true type: array totalCount: description: Total number of documents available. MongoDB Cloud omits this value if `includeCount` is set to `false`. The total number is an estimate and may not be exact. format: int32 minimum: 0 readOnly: true type: integer required: - results type: object OrgUserRolesRequest: description: Organization and project level roles to assign the MongoDB Cloud user within one organization. properties: groupRoleAssignments: description: List of project level role assignments to assign the MongoDB Cloud user. items: $ref: '#/components/schemas/GroupRoleAssignment' type: array orgRoles: description: One or more organization level roles to assign the MongoDB Cloud user. items: description: Organization-level role. enum: - ORG_OWNER - ORG_GROUP_CREATOR - ORG_BILLING_ADMIN - ORG_BILLING_READ_ONLY - ORG_STREAM_PROCESSING_ADMIN - ORG_READ_ONLY - ORG_MEMBER type: string minItems: 1 type: array uniqueItems: true required: - orgRoles type: object writeOnly: true AddOrRemoveOrgRole: properties: orgRole: description: Organization-level role. enum: - ORG_OWNER - ORG_GROUP_CREATOR - ORG_BILLING_ADMIN - ORG_BILLING_READ_ONLY - ORG_STREAM_PROCESSING_ADMIN - ORG_READ_ONLY - ORG_MEMBER type: string required: - orgRole type: object AddOrRemoveGroupRole: properties: groupRole: description: Project-level role to assign to or remove from the MongoDB Cloud user. externalDocs: description: MongoDB Cloud User Roles url: https://www.mongodb.com/docs/atlas/reference/user-roles/ type: string required: - groupRole type: object OrgActiveUserResponse: allOf: - $ref: '#/components/schemas/OrgUserResponse' - properties: country: description: Two-character alphabetical string that identifies the MongoDB Cloud user's geographic location. This parameter uses the ISO 3166-1a2 code format. example: US pattern: ^([A-Z]{2})$ readOnly: true type: string createdAt: description: Date and time when MongoDB Cloud created the current account. This value is in the ISO 8601 timestamp format in UTC. format: date-time readOnly: true type: string firstName: description: First or given name that belongs to the MongoDB Cloud user. example: John readOnly: true type: string lastAuth: description: Date and time when the current account last authenticated. This value is in the ISO 8601 timestamp format in UTC. format: date-time readOnly: true type: string lastName: description: Last name, family name, or surname that belongs to the MongoDB Cloud user. example: Doe readOnly: true type: string mobileNumber: description: Mobile phone number that belongs to the MongoDB Cloud user. pattern: (?:(?:\\+?1\\s*(?:[.-]\\s*)?)?(?:(\\s*([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9])\\s*)|([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9]))\\s*(?:[.-]\\s*)?)([2-9]1[02-9]|[2-9][02-9]1|[2-9][02-9]{2})\\s*(?:[.-]\\s*)?([0-9]{4})$ readOnly: true type: string type: object required: - createdAt - firstName - id - lastName - orgMembershipStatus - roles - username type: object OrgUserRolesResponse: description: Organization- and project-level roles assigned to one MongoDB Cloud user within one organization. properties: groupRoleAssignments: description: List of project-level role assignments assigned to the MongoDB Cloud user. items: $ref: '#/components/schemas/GroupRoleAssignment' type: array orgRoles: description: One or more organization-level roles assigned to the MongoDB Cloud user. items: description: Organization-level role. enum: - ORG_OWNER - ORG_GROUP_CREATOR - ORG_BILLING_ADMIN - ORG_BILLING_READ_ONLY - ORG_STREAM_PROCESSING_ADMIN - ORG_READ_ONLY - ORG_MEMBER type: string type: array uniqueItems: true readOnly: true type: object responses: internalServerError: content: application/json: example: detail: (This is just an example, the exception may not be related to this endpoint) error: 500 errorCode: UNEXPECTED_ERROR reason: Internal Server Error schema: $ref: '#/components/schemas/ApiError' description: Internal Server Error. forbidden: content: application/json: example: detail: (This is just an example, the exception may not be related to this endpoint) error: 403 errorCode: CANNOT_CHANGE_GROUP_NAME reason: Forbidden schema: $ref: '#/components/schemas/ApiError' description: Forbidden. tooManyRequests: content: application/json: example: detail: (This is just an example, the exception may not be related to this endpoint) error: 429 errorCode: RATE_LIMITED reason: Too Many Requests schema: $ref: '#/components/schemas/ApiError' description: Too Many Requests. headers: RateLimit-Limit: $ref: '#/components/headers/HeaderRateLimitLimit' RateLimit-Remaining: $ref: '#/components/headers/HeaderRateLimitRemaining' Retry-After: $ref: '#/components/headers/HeaderRetryAfter' unauthorized: content: application/json: example: detail: (This is just an example, the exception may not be related to this endpoint) error: 401 errorCode: NOT_ORG_GROUP_CREATOR reason: Unauthorized schema: $ref: '#/components/schemas/ApiError' description: Unauthorized. conflict: content: application/json: example: detail: '(This is just an example, the exception may not be related to this endpoint) Cannot delete organization link while there is active migration in following project ids: 60c4fd418ebe251047c50554' error: 409 errorCode: CANNOT_DELETE_ORG_ACTIVE_LIVE_MIGRATION_ATLAS_ORG_LINK reason: Conflict schema: $ref: '#/components/schemas/ApiError' description: Conflict. badRequest: content: application/json: example: detail: (This is just an example, the exception may not be related to this endpoint) No provider AWS exists. error: 400 errorCode: VALIDATION_ERROR reason: Bad Request schema: $ref: '#/components/schemas/ApiError' description: Bad Request. notFound: content: application/json: example: detail: (This is just an example, the exception may not be related to this endpoint) Cannot find resource AWS error: 404 errorCode: RESOURCE_NOT_FOUND reason: Not Found schema: $ref: '#/components/schemas/ApiError' description: Not Found. headers: HeaderRateLimitRemaining: description: The number of requests remaining in the current rate limit window before the limit is reached. schema: type: integer HeaderRetryAfter: description: The minimum time you should wait, in seconds, before retrying the API request. This header might be returned for 429 or 503 error responses. schema: type: integer HeaderRateLimitLimit: description: The maximum number of requests that a user can make within a specific time window. schema: type: integer parameters: envelope: description: Flag that indicates whether Application wraps the response in an `envelope` JSON object. Some API clients cannot access the HTTP response headers or status code. To remediate this, set envelope=true in the query. Endpoints that return a list of results use the results object as an envelope. Application adds the status parameter to the response body. in: query name: envelope schema: default: false type: boolean itemsPerPage: description: Number of items that the response returns per page. in: query name: itemsPerPage schema: default: 100 maximum: 500 minimum: 1 type: integer groupId: description: 'Unique 24-hexadecimal digit string that identifies your project. Use the [/groups](#tag/Projects/operation/listProjects) endpoint to retrieve all projects to which the authenticated user has access. **NOTE**: Groups and projects are synonymous terms. Your group id is the same as your project id. For existing groups, your group/project id remains the same. The resource and corresponding endpoints use the term groups.' in: path name: groupId required: true schema: example: 32b6e34b3d91647abb20e7b8 pattern: ^([a-f0-9]{24})$ type: string pretty: description: Flag that indicates whether the response body should be in the prettyprint format. in: query name: pretty schema: default: false externalDocs: description: Prettyprint url: https://en.wikipedia.org/wiki/Prettyprint type: boolean pageNum: description: Number of the page that displays the current set of the total objects that the response returns. in: query name: pageNum schema: default: 1 minimum: 1 type: integer orgId: description: Unique 24-hexadecimal digit string that identifies the organization that contains your projects. Use the [`/orgs`](#tag/Organizations/operation/listOrganizations) endpoint to retrieve all organizations to which the authenticated user has access. in: path name: orgId required: true schema: example: 4888442a3354817a7320eb61 pattern: ^([a-f0-9]{24})$ type: string includeCount: description: Flag that indicates whether the response returns the total number of items (`totalCount`) in the response. in: query name: includeCount schema: default: true type: boolean securitySchemes: DigestAuth: scheme: digest type: http ServiceAccounts: description: Learn more about [Service Accounts](https://www.mongodb.com/docs/atlas/api/service-accounts-overview). flows: clientCredentials: scopes: {} tokenUrl: https://cloud.mongodb.com/api/oauth/token type: oauth2 x-externalLinks: - label: Back to Atlas Docs url: https://www.mongodb.com/docs/atlas/ - label: API Changelog url: https://www.mongodb.com/docs/atlas/reference/api-resources-spec/changelog/ x-topics: - content: The MongoDB Atlas Administration API is rate limited. To learn more about rate limiting, see the [Atlas Documentation on Rate Limiting](http://dochub.mongodb.org/core/atlas-api-rate-limit) title: Rate Limiting