Docs Menu
Docs Home
/ /
MongoDB Command Line Interface
/ / /

mongocli atlas privateendpoint watch

On this page

  • Syntax
  • Arguments
  • Options
  • Output
  • Example

The privateendpoint watch command monitors one private endpoint connection in the specified project until it becomes available, at which time it displays a confirmation message.

mongocli atlas privateendpoint(s)|privateEndpoint(s) watch <private-endpoint-id>
[ --profile|-P <profile-name> ]
[ --projectId <project-ID> ]

Note

Use -h or --help to view the command-line help for this command.

Argument
Type
Description
Required?
<private-endpoint-id>
string
Unique identifier of the private endpoint connection that you want to watch.
yes
Option
Type
Description
Required?
--profile, -P
string
Name of the profile where the public and private keys for the project are saved. If omitted, uses the default profile. To learn more about creating a profile, see Configure the MongoDB CLI.
no
--projectId
string

Unique identifier of the project. If omitted, uses the project ID in the profile or environment variable.

no

The privateendpoint watch command continuously polls Atlas for the status of one private endpoint connection until it reaches an available status.

Note

The MongoDB CLI considers WAITING_FOR_USER to be an available status.

For more information on private endpoint connection statuses, see the Atlas documentation.

If the command succeeds, it returns the following output in the default format. If the command returns errors, see Troubleshooting for recommended solutions.

Private endpoint changes completed.

The following command watches one private endpoint connection for a project using the default profile, which contains credentials and the project ID. The output is returned in the default format.

mongocli atlas privateendpoint watch 5f4fc14da2b47835a58c63a2

The previous command prints the following to the terminal.

Private endpoint changes completed.

Back

Create One Private Endpoint Connection