The `oci-databasetools` package is the official Oracle Cloud Infrastructure (OCI) NodeJS client for the Database Tools Service. It enables developers to programmatically manage resources within this service, such as database connections, private endpoints, and related configurations. As part of the broader OCI TypeScript SDK, it ships with comprehensive TypeScript type definitions, enhancing developer experience. Currently at version 2.130.0, the package follows a rapid release cadence, often receiving updates weekly or bi-weekly to incorporate new OCI service features and API enhancements. Its key differentiators include direct integration with OCI's authentication mechanisms, adherence to OCI API specifications, and guaranteed compatibility with the latest service functionalities, providing a robust and reliable interface for OCI automation compared to generic HTTP clients.
npm install oci-databasetoolsVerified import paths — ran on the pinned version, not inferred.
This quickstart initializes the OCI Database Tools client using default authentication, then lists active database tools connections within a specified compartment. It demonstrates basic client instantiation, request creation, and error handling.
Ensure your `~/.oci/config` file is correctly configured with your user OCID, tenancy OCID, fingerprint, and private key path. Alternatively, set environment variables like `OCI_TENANCY`, `OCI_USER`, `OCI_FINGERPRINT`, `OCI_KEY_FILE`, and `OCI_REGION`.
Double-check all OCIDs used in your requests for correctness. Use the OCI Console or `oci-cli` to verify resource OCIDs before incorporating them into your code.
Set the `OCI_REGION` environment variable or explicitly provide the region when creating the authentication provider: `const provider = new common.DefaultAuthenticationDetailsProvider({ region: 'us-ashburn-1' });`Verify `~/.oci/config` file contents, permissions (private key must be `0400`), and environment variables (e.g., `OCI_CONFIG_FILE`, `OCI_PROFILE`). Ensure the public key is uploaded to the OCI user API Keys.
Check the exact OCID(s) in your request parameters against the OCI Console or `oci-cli` to confirm they are valid and refer to existing resources in the correct region and tenancy.
Consult the OCI API documentation for the specific operation to ensure all required fields are present and their values adhere to the specified constraints (e.g., data types, enum values, length limits).