EnableDirectoryDataAccessCommand

Enables access to directory data via the Directory Service Data API for the specified directory.

Example Syntax

Use a bare-bones client and the command you need to make an API call.

import { DirectoryServiceClient, EnableDirectoryDataAccessCommand } from "@aws-sdk/client-directory-service"; // ES Modules import
// const { DirectoryServiceClient, EnableDirectoryDataAccessCommand } = require("@aws-sdk/client-directory-service"); // CommonJS import
const client = new DirectoryServiceClient(config);
const input = { // EnableDirectoryDataAccessRequest
  DirectoryId: "STRING_VALUE", // required
};
const command = new EnableDirectoryDataAccessCommand(input);
const response = await client.send(command);
// {};

EnableDirectoryDataAccessCommand Input

Parameter
Type
Description
DirectoryId
Required
string | undefined

The directory identifier.

EnableDirectoryDataAccessCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.

Throws

Name
Fault
Details
AccessDeniedException
client

You do not have sufficient access to perform this action.

ClientException
client

A client exception has occurred.

DirectoryDoesNotExistException
client

The specified directory does not exist in the system.

DirectoryInDesiredStateException
client

The directory is already updated to desired update type settings.

DirectoryUnavailableException
client

The specified directory is unavailable.

ServiceException
server

An exception has occurred in Directory Service.

UnsupportedOperationException
client

The operation is not supported.

DirectoryServiceServiceException
Base exception class for all service exceptions from DirectoryService service.