Amazon QLDB 2019-01-02
- Client: Aws\QLDB\QLDBClient
- Service ID: qldb
- Version: 2019-01-02
This page describes the parameters and results for the operations of the Amazon QLDB (2019-01-02), and shows how to use the Aws\QLDB\QLDBClient object to call the described operations. This documentation is specific to the 2019-01-02 API version of the service.
Operation Summary
Each of the following operations can be created from a client using
$client->getCommand('CommandName')
, where "CommandName" is the
name of one of the following operations. Note: a command is a value that
encapsulates an operation and the parameters used to create an HTTP request.
You can also create and send a command immediately using the magic methods
available on a client object: $client->commandName(/* parameters */)
.
You can send the command asynchronously (returning a promise) by appending the
word "Async" to the operation name: $client->commandNameAsync(/* parameters */)
.
- CancelJournalKinesisStream ( array $params = [] )
Ends a given Amazon QLDB journal stream.
- CreateLedger ( array $params = [] )
Creates a new ledger in your AWS account.
- DeleteLedger ( array $params = [] )
Deletes a ledger and all of its contents.
- DescribeJournalKinesisStream ( array $params = [] )
Returns detailed information about a given Amazon QLDB journal stream.
- DescribeJournalS3Export ( array $params = [] )
Returns information about a journal export job, including the ledger name, export ID, when it was created, current status, and its start and end time export parameters.
- DescribeLedger ( array $params = [] )
Returns information about a ledger, including its state and when it was created.
- ExportJournalToS3 ( array $params = [] )
Exports journal contents within a date and time range from a ledger into a specified Amazon Simple Storage Service (Amazon S3) bucket.
- GetBlock ( array $params = [] )
Returns a block object at a specified address in a journal.
- GetDigest ( array $params = [] )
Returns the digest of a ledger at the latest committed block in the journal.
- GetRevision ( array $params = [] )
Returns a revision data object for a specified document ID and block address.
- ListJournalKinesisStreamsForLedger ( array $params = [] )
Returns an array of all Amazon QLDB journal stream descriptors for a given ledger.
- ListJournalS3Exports ( array $params = [] )
Returns an array of journal export job descriptions for all ledgers that are associated with the current AWS account and Region.
- ListJournalS3ExportsForLedger ( array $params = [] )
Returns an array of journal export job descriptions for a specified ledger.
- ListLedgers ( array $params = [] )
Returns an array of ledger summaries that are associated with the current AWS account and Region.
- ListTagsForResource ( array $params = [] )
Returns all tags for a specified Amazon QLDB resource.
- StreamJournalToKinesis ( array $params = [] )
Creates a journal stream for a given Amazon QLDB ledger.
- TagResource ( array $params = [] )
Adds one or more tags to a specified Amazon QLDB resource.
- UntagResource ( array $params = [] )
Removes one or more tags from a specified Amazon QLDB resource.
- UpdateLedger ( array $params = [] )
Updates properties on a ledger.
Paginators
Paginators handle automatically iterating over paginated API results. Paginators are associated with specific API operations, and they accept the parameters that the corresponding API operation accepts. You can get a paginator from a client class using getPaginator($paginatorName, $operationParameters). This client supports the following paginators:
Operations
CancelJournalKinesisStream
$result = $client->cancelJournalKinesisStream
([/* ... */]); $promise = $client->cancelJournalKinesisStreamAsync
([/* ... */]);
Ends a given Amazon QLDB journal stream. Before a stream can be canceled, its current status must be ACTIVE
.
You can't restart a stream after you cancel it. Canceled QLDB stream resources are subject to a 7-day retention period, so they are automatically deleted after this limit expires.
Parameter Syntax
$result = $client->cancelJournalKinesisStream([ 'LedgerName' => '<string>', // REQUIRED 'StreamId' => '<string>', // REQUIRED ]);
Parameter Details
Members
Result Syntax
[ 'StreamId' => '<string>', ]
Result Details
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
CreateLedger
$result = $client->createLedger
([/* ... */]); $promise = $client->createLedgerAsync
([/* ... */]);
Creates a new ledger in your AWS account.
Parameter Syntax
$result = $client->createLedger([ 'DeletionProtection' => true || false, 'Name' => '<string>', // REQUIRED 'PermissionsMode' => 'ALLOW_ALL', // REQUIRED 'Tags' => ['<string>', ...], ]);
Parameter Details
Members
- DeletionProtection
-
- Type: boolean
The flag that prevents a ledger from being deleted by any user. If not provided on ledger creation, this feature is enabled (
true
) by default.If deletion protection is enabled, you must first disable it before you can delete the ledger using the QLDB API or the AWS Command Line Interface (AWS CLI). You can disable it by calling the
UpdateLedger
operation to set the flag tofalse
. The QLDB console disables deletion protection for you when you use it to delete a ledger. - Name
-
- Required: Yes
- Type: string
The name of the ledger that you want to create. The name must be unique among all of your ledgers in the current AWS Region.
Naming constraints for ledger names are defined in Quotas in Amazon QLDB in the Amazon QLDB Developer Guide.
- PermissionsMode
-
- Required: Yes
- Type: string
The permissions mode to assign to the ledger that you want to create.
- Tags
-
- Type: Associative array of custom strings keys (TagKey) to strings
The key-value pairs to add as tags to the ledger that you want to create. Tag keys are case sensitive. Tag values are case sensitive and can be null.
Result Syntax
[ 'Arn' => '<string>', 'CreationDateTime' => <DateTime>, 'DeletionProtection' => true || false, 'Name' => '<string>', 'State' => 'CREATING|ACTIVE|DELETING|DELETED', ]
Result Details
Members
- Arn
-
- Type: string
The Amazon Resource Name (ARN) for the ledger.
- CreationDateTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The date and time, in epoch time format, when the ledger was created. (Epoch time format is the number of seconds elapsed since 12:00:00 AM January 1, 1970 UTC.)
- DeletionProtection
-
- Type: boolean
The flag that prevents a ledger from being deleted by any user. If not provided on ledger creation, this feature is enabled (
true
) by default.If deletion protection is enabled, you must first disable it before you can delete the ledger using the QLDB API or the AWS Command Line Interface (AWS CLI). You can disable it by calling the
UpdateLedger
operation to set the flag tofalse
. The QLDB console disables deletion protection for you when you use it to delete a ledger. - Name
-
- Type: string
The name of the ledger.
- State
-
- Type: string
The current status of the ledger.
Errors
-
One or more parameters in the request aren't valid.
-
ResourceAlreadyExistsException:
The specified resource already exists.
-
You have reached the limit on the maximum number of resources allowed.
-
The specified resource can't be modified at this time.
DeleteLedger
$result = $client->deleteLedger
([/* ... */]); $promise = $client->deleteLedgerAsync
([/* ... */]);
Deletes a ledger and all of its contents. This action is irreversible.
If deletion protection is enabled, you must first disable it before you can delete the ledger using the QLDB API or the AWS Command Line Interface (AWS CLI). You can disable it by calling the UpdateLedger
operation to set the flag to false
. The QLDB console disables deletion protection for you when you use it to delete a ledger.
Parameter Syntax
$result = $client->deleteLedger([ 'Name' => '<string>', // REQUIRED ]);
Parameter Details
Result Syntax
[]
Result Details
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
The specified resource can't be modified at this time.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
DescribeJournalKinesisStream
$result = $client->describeJournalKinesisStream
([/* ... */]); $promise = $client->describeJournalKinesisStreamAsync
([/* ... */]);
Returns detailed information about a given Amazon QLDB journal stream. The output includes the Amazon Resource Name (ARN), stream name, current status, creation time, and the parameters of your original stream creation request.
Parameter Syntax
$result = $client->describeJournalKinesisStream([ 'LedgerName' => '<string>', // REQUIRED 'StreamId' => '<string>', // REQUIRED ]);
Parameter Details
Members
Result Syntax
[ 'Stream' => [ 'Arn' => '<string>', 'CreationTime' => <DateTime>, 'ErrorCause' => 'KINESIS_STREAM_NOT_FOUND|IAM_PERMISSION_REVOKED', 'ExclusiveEndTime' => <DateTime>, 'InclusiveStartTime' => <DateTime>, 'KinesisConfiguration' => [ 'AggregationEnabled' => true || false, 'StreamArn' => '<string>', ], 'LedgerName' => '<string>', 'RoleArn' => '<string>', 'Status' => 'ACTIVE|COMPLETED|CANCELED|FAILED|IMPAIRED', 'StreamId' => '<string>', 'StreamName' => '<string>', ], ]
Result Details
Members
- Stream
-
- Type: JournalKinesisStreamDescription structure
Information about the QLDB journal stream returned by a
DescribeJournalS3Export
request.
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
DescribeJournalS3Export
$result = $client->describeJournalS3Export
([/* ... */]); $promise = $client->describeJournalS3ExportAsync
([/* ... */]);
Returns information about a journal export job, including the ledger name, export ID, when it was created, current status, and its start and end time export parameters.
This action does not return any expired export jobs. For more information, see Export Job Expiration in the Amazon QLDB Developer Guide.
If the export job with the given ExportId
doesn't exist, then throws ResourceNotFoundException
.
If the ledger with the given Name
doesn't exist, then throws ResourceNotFoundException
.
Parameter Syntax
$result = $client->describeJournalS3Export([ 'ExportId' => '<string>', // REQUIRED 'Name' => '<string>', // REQUIRED ]);
Parameter Details
Members
Result Syntax
[ 'ExportDescription' => [ 'ExclusiveEndTime' => <DateTime>, 'ExportCreationTime' => <DateTime>, 'ExportId' => '<string>', 'InclusiveStartTime' => <DateTime>, 'LedgerName' => '<string>', 'RoleArn' => '<string>', 'S3ExportConfiguration' => [ 'Bucket' => '<string>', 'EncryptionConfiguration' => [ 'KmsKeyArn' => '<string>', 'ObjectEncryptionType' => 'SSE_KMS|SSE_S3|NO_ENCRYPTION', ], 'Prefix' => '<string>', ], 'Status' => 'IN_PROGRESS|COMPLETED|CANCELLED', ], ]
Result Details
Members
- ExportDescription
-
- Required: Yes
- Type: JournalS3ExportDescription structure
Information about the journal export job returned by a
DescribeJournalS3Export
request.
Errors
-
The specified resource doesn't exist.
DescribeLedger
$result = $client->describeLedger
([/* ... */]); $promise = $client->describeLedgerAsync
([/* ... */]);
Returns information about a ledger, including its state and when it was created.
Parameter Syntax
$result = $client->describeLedger([ 'Name' => '<string>', // REQUIRED ]);
Parameter Details
Result Syntax
[ 'Arn' => '<string>', 'CreationDateTime' => <DateTime>, 'DeletionProtection' => true || false, 'Name' => '<string>', 'State' => 'CREATING|ACTIVE|DELETING|DELETED', ]
Result Details
Members
- Arn
-
- Type: string
The Amazon Resource Name (ARN) for the ledger.
- CreationDateTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The date and time, in epoch time format, when the ledger was created. (Epoch time format is the number of seconds elapsed since 12:00:00 AM January 1, 1970 UTC.)
- DeletionProtection
-
- Type: boolean
The flag that prevents a ledger from being deleted by any user. If not provided on ledger creation, this feature is enabled (
true
) by default.If deletion protection is enabled, you must first disable it before you can delete the ledger using the QLDB API or the AWS Command Line Interface (AWS CLI). You can disable it by calling the
UpdateLedger
operation to set the flag tofalse
. The QLDB console disables deletion protection for you when you use it to delete a ledger. - Name
-
- Type: string
The name of the ledger.
- State
-
- Type: string
The current status of the ledger.
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
ExportJournalToS3
$result = $client->exportJournalToS3
([/* ... */]); $promise = $client->exportJournalToS3Async
([/* ... */]);
Exports journal contents within a date and time range from a ledger into a specified Amazon Simple Storage Service (Amazon S3) bucket. The data is written as files in Amazon Ion format.
If the ledger with the given Name
doesn't exist, then throws ResourceNotFoundException
.
If the ledger with the given Name
is in CREATING
status, then throws ResourcePreconditionNotMetException
.
You can initiate up to two concurrent journal export requests for each ledger. Beyond this limit, journal export requests throw LimitExceededException
.
Parameter Syntax
$result = $client->exportJournalToS3([ 'ExclusiveEndTime' => <integer || string || DateTime>, // REQUIRED 'InclusiveStartTime' => <integer || string || DateTime>, // REQUIRED 'Name' => '<string>', // REQUIRED 'RoleArn' => '<string>', // REQUIRED 'S3ExportConfiguration' => [ // REQUIRED 'Bucket' => '<string>', // REQUIRED 'EncryptionConfiguration' => [ // REQUIRED 'KmsKeyArn' => '<string>', 'ObjectEncryptionType' => 'SSE_KMS|SSE_S3|NO_ENCRYPTION', // REQUIRED ], 'Prefix' => '<string>', // REQUIRED ], ]);
Parameter Details
Members
- ExclusiveEndTime
-
- Required: Yes
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The exclusive end date and time for the range of journal contents that you want to export.
The
ExclusiveEndTime
must be inISO 8601
date and time format and in Universal Coordinated Time (UTC). For example:2019-06-13T21:36:34Z
The
ExclusiveEndTime
must be less than or equal to the current UTC date and time. - InclusiveStartTime
-
- Required: Yes
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The inclusive start date and time for the range of journal contents that you want to export.
The
InclusiveStartTime
must be inISO 8601
date and time format and in Universal Coordinated Time (UTC). For example:2019-06-13T21:36:34Z
The
InclusiveStartTime
must be beforeExclusiveEndTime
.If you provide an
InclusiveStartTime
that is before the ledger'sCreationDateTime
, Amazon QLDB defaults it to the ledger'sCreationDateTime
. - Name
-
- Required: Yes
- Type: string
The name of the ledger.
- RoleArn
-
- Required: Yes
- Type: string
The Amazon Resource Name (ARN) of the IAM role that grants QLDB permissions for a journal export job to do the following:
-
Write objects into your Amazon Simple Storage Service (Amazon S3) bucket.
-
(Optional) Use your customer master key (CMK) in AWS Key Management Service (AWS KMS) for server-side encryption of your exported data.
- S3ExportConfiguration
-
- Required: Yes
- Type: S3ExportConfiguration structure
The configuration settings of the Amazon S3 bucket destination for your export request.
Result Syntax
[ 'ExportId' => '<string>', ]
Result Details
Members
Errors
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
GetBlock
$result = $client->getBlock
([/* ... */]); $promise = $client->getBlockAsync
([/* ... */]);
Returns a block object at a specified address in a journal. Also returns a proof of the specified block for verification if DigestTipAddress
is provided.
For information about the data contents in a block, see Journal contents in the Amazon QLDB Developer Guide.
If the specified ledger doesn't exist or is in DELETING
status, then throws ResourceNotFoundException
.
If the specified ledger is in CREATING
status, then throws ResourcePreconditionNotMetException
.
If no block exists with the specified address, then throws InvalidParameterException
.
Parameter Syntax
$result = $client->getBlock([ 'BlockAddress' => [ // REQUIRED 'IonText' => '<string>', ], 'DigestTipAddress' => [ 'IonText' => '<string>', ], 'Name' => '<string>', // REQUIRED ]);
Parameter Details
Members
- BlockAddress
-
- Required: Yes
- Type: ValueHolder structure
The location of the block that you want to request. An address is an Amazon Ion structure that has two fields:
strandId
andsequenceNo
.For example:
{strandId:"BlFTjlSXze9BIh1KOszcE3",sequenceNo:14}
- DigestTipAddress
-
- Type: ValueHolder structure
The latest block location covered by the digest for which to request a proof. An address is an Amazon Ion structure that has two fields:
strandId
andsequenceNo
.For example:
{strandId:"BlFTjlSXze9BIh1KOszcE3",sequenceNo:49}
- Name
-
- Required: Yes
- Type: string
The name of the ledger.
Result Syntax
[ 'Block' => [ 'IonText' => '<string>', ], 'Proof' => [ 'IonText' => '<string>', ], ]
Result Details
Members
- Block
-
- Required: Yes
- Type: ValueHolder structure
The block data object in Amazon Ion format.
- Proof
-
- Type: ValueHolder structure
The proof object in Amazon Ion format returned by a
GetBlock
request. A proof contains the list of hash values required to recalculate the specified digest using a Merkle tree, starting with the specified block.
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
GetDigest
$result = $client->getDigest
([/* ... */]); $promise = $client->getDigestAsync
([/* ... */]);
Returns the digest of a ledger at the latest committed block in the journal. The response includes a 256-bit hash value and a block address.
Parameter Syntax
$result = $client->getDigest([ 'Name' => '<string>', // REQUIRED ]);
Parameter Details
Result Syntax
[ 'Digest' => <string || resource || Psr\Http\Message\StreamInterface>, 'DigestTipAddress' => [ 'IonText' => '<string>', ], ]
Result Details
Members
- Digest
-
- Required: Yes
- Type: blob (string|resource|Psr\Http\Message\StreamInterface)
The 256-bit hash value representing the digest returned by a
GetDigest
request. - DigestTipAddress
-
- Required: Yes
- Type: ValueHolder structure
The latest block location covered by the digest that you requested. An address is an Amazon Ion structure that has two fields:
strandId
andsequenceNo
.
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
GetRevision
$result = $client->getRevision
([/* ... */]); $promise = $client->getRevisionAsync
([/* ... */]);
Returns a revision data object for a specified document ID and block address. Also returns a proof of the specified revision for verification if DigestTipAddress
is provided.
Parameter Syntax
$result = $client->getRevision([ 'BlockAddress' => [ // REQUIRED 'IonText' => '<string>', ], 'DigestTipAddress' => [ 'IonText' => '<string>', ], 'DocumentId' => '<string>', // REQUIRED 'Name' => '<string>', // REQUIRED ]);
Parameter Details
Members
- BlockAddress
-
- Required: Yes
- Type: ValueHolder structure
The block location of the document revision to be verified. An address is an Amazon Ion structure that has two fields:
strandId
andsequenceNo
.For example:
{strandId:"BlFTjlSXze9BIh1KOszcE3",sequenceNo:14}
- DigestTipAddress
-
- Type: ValueHolder structure
The latest block location covered by the digest for which to request a proof. An address is an Amazon Ion structure that has two fields:
strandId
andsequenceNo
.For example:
{strandId:"BlFTjlSXze9BIh1KOszcE3",sequenceNo:49}
- DocumentId
-
- Required: Yes
- Type: string
The unique ID of the document to be verified.
- Name
-
- Required: Yes
- Type: string
The name of the ledger.
Result Syntax
[ 'Proof' => [ 'IonText' => '<string>', ], 'Revision' => [ 'IonText' => '<string>', ], ]
Result Details
Members
- Proof
-
- Type: ValueHolder structure
The proof object in Amazon Ion format returned by a
GetRevision
request. A proof contains the list of hash values that are required to recalculate the specified digest using a Merkle tree, starting with the specified document revision. - Revision
-
- Required: Yes
- Type: ValueHolder structure
The document revision data object in Amazon Ion format.
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
ListJournalKinesisStreamsForLedger
$result = $client->listJournalKinesisStreamsForLedger
([/* ... */]); $promise = $client->listJournalKinesisStreamsForLedgerAsync
([/* ... */]);
Returns an array of all Amazon QLDB journal stream descriptors for a given ledger. The output of each stream descriptor includes the same details that are returned by DescribeJournalKinesisStream
.
This action returns a maximum of MaxResults
items. It is paginated so that you can retrieve all the items by calling ListJournalKinesisStreamsForLedger
multiple times.
Parameter Syntax
$result = $client->listJournalKinesisStreamsForLedger([ 'LedgerName' => '<string>', // REQUIRED 'MaxResults' => <integer>, 'NextToken' => '<string>', ]);
Parameter Details
Members
- LedgerName
-
- Required: Yes
- Type: string
The name of the ledger.
- MaxResults
-
- Type: int
The maximum number of results to return in a single
ListJournalKinesisStreamsForLedger
request. (The actual number of results returned might be fewer.) - NextToken
-
- Type: string
A pagination token, indicating that you want to retrieve the next page of results. If you received a value for
NextToken
in the response from a previousListJournalKinesisStreamsForLedger
call, you should use that value as input here.
Result Syntax
[ 'NextToken' => '<string>', 'Streams' => [ [ 'Arn' => '<string>', 'CreationTime' => <DateTime>, 'ErrorCause' => 'KINESIS_STREAM_NOT_FOUND|IAM_PERMISSION_REVOKED', 'ExclusiveEndTime' => <DateTime>, 'InclusiveStartTime' => <DateTime>, 'KinesisConfiguration' => [ 'AggregationEnabled' => true || false, 'StreamArn' => '<string>', ], 'LedgerName' => '<string>', 'RoleArn' => '<string>', 'Status' => 'ACTIVE|COMPLETED|CANCELED|FAILED|IMPAIRED', 'StreamId' => '<string>', 'StreamName' => '<string>', ], // ... ], ]
Result Details
Members
- NextToken
-
- Type: string
-
If
NextToken
is empty, the last page of results has been processed and there are no more results to be retrieved. -
If
NextToken
is not empty, more results are available. To retrieve the next page of results, use the value ofNextToken
in a subsequentListJournalKinesisStreamsForLedger
call.
- Streams
-
- Type: Array of JournalKinesisStreamDescription structures
The array of QLDB journal stream descriptors that are associated with the given ledger.
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
ListJournalS3Exports
$result = $client->listJournalS3Exports
([/* ... */]); $promise = $client->listJournalS3ExportsAsync
([/* ... */]);
Returns an array of journal export job descriptions for all ledgers that are associated with the current AWS account and Region.
This action returns a maximum of MaxResults
items, and is paginated so that you can retrieve all the items by calling ListJournalS3Exports
multiple times.
This action does not return any expired export jobs. For more information, see Export Job Expiration in the Amazon QLDB Developer Guide.
Parameter Syntax
$result = $client->listJournalS3Exports([ 'MaxResults' => <integer>, 'NextToken' => '<string>', ]);
Parameter Details
Members
- MaxResults
-
- Type: int
The maximum number of results to return in a single
ListJournalS3Exports
request. (The actual number of results returned might be fewer.) - NextToken
-
- Type: string
A pagination token, indicating that you want to retrieve the next page of results. If you received a value for
NextToken
in the response from a previousListJournalS3Exports
call, then you should use that value as input here.
Result Syntax
[ 'JournalS3Exports' => [ [ 'ExclusiveEndTime' => <DateTime>, 'ExportCreationTime' => <DateTime>, 'ExportId' => '<string>', 'InclusiveStartTime' => <DateTime>, 'LedgerName' => '<string>', 'RoleArn' => '<string>', 'S3ExportConfiguration' => [ 'Bucket' => '<string>', 'EncryptionConfiguration' => [ 'KmsKeyArn' => '<string>', 'ObjectEncryptionType' => 'SSE_KMS|SSE_S3|NO_ENCRYPTION', ], 'Prefix' => '<string>', ], 'Status' => 'IN_PROGRESS|COMPLETED|CANCELLED', ], // ... ], 'NextToken' => '<string>', ]
Result Details
Members
- JournalS3Exports
-
- Type: Array of JournalS3ExportDescription structures
The array of journal export job descriptions for all ledgers that are associated with the current AWS account and Region.
- NextToken
-
- Type: string
-
If
NextToken
is empty, then the last page of results has been processed and there are no more results to be retrieved. -
If
NextToken
is not empty, then there are more results available. To retrieve the next page of results, use the value ofNextToken
in a subsequentListJournalS3Exports
call.
Errors
There are no errors described for this operation.
ListJournalS3ExportsForLedger
$result = $client->listJournalS3ExportsForLedger
([/* ... */]); $promise = $client->listJournalS3ExportsForLedgerAsync
([/* ... */]);
Returns an array of journal export job descriptions for a specified ledger.
This action returns a maximum of MaxResults
items, and is paginated so that you can retrieve all the items by calling ListJournalS3ExportsForLedger
multiple times.
This action does not return any expired export jobs. For more information, see Export Job Expiration in the Amazon QLDB Developer Guide.
Parameter Syntax
$result = $client->listJournalS3ExportsForLedger([ 'MaxResults' => <integer>, 'Name' => '<string>', // REQUIRED 'NextToken' => '<string>', ]);
Parameter Details
Members
- MaxResults
-
- Type: int
The maximum number of results to return in a single
ListJournalS3ExportsForLedger
request. (The actual number of results returned might be fewer.) - Name
-
- Required: Yes
- Type: string
The name of the ledger.
- NextToken
-
- Type: string
A pagination token, indicating that you want to retrieve the next page of results. If you received a value for
NextToken
in the response from a previousListJournalS3ExportsForLedger
call, then you should use that value as input here.
Result Syntax
[ 'JournalS3Exports' => [ [ 'ExclusiveEndTime' => <DateTime>, 'ExportCreationTime' => <DateTime>, 'ExportId' => '<string>', 'InclusiveStartTime' => <DateTime>, 'LedgerName' => '<string>', 'RoleArn' => '<string>', 'S3ExportConfiguration' => [ 'Bucket' => '<string>', 'EncryptionConfiguration' => [ 'KmsKeyArn' => '<string>', 'ObjectEncryptionType' => 'SSE_KMS|SSE_S3|NO_ENCRYPTION', ], 'Prefix' => '<string>', ], 'Status' => 'IN_PROGRESS|COMPLETED|CANCELLED', ], // ... ], 'NextToken' => '<string>', ]
Result Details
Members
- JournalS3Exports
-
- Type: Array of JournalS3ExportDescription structures
The array of journal export job descriptions that are associated with the specified ledger.
- NextToken
-
- Type: string
-
If
NextToken
is empty, then the last page of results has been processed and there are no more results to be retrieved. -
If
NextToken
is not empty, then there are more results available. To retrieve the next page of results, use the value ofNextToken
in a subsequentListJournalS3ExportsForLedger
call.
Errors
There are no errors described for this operation.
ListLedgers
$result = $client->listLedgers
([/* ... */]); $promise = $client->listLedgersAsync
([/* ... */]);
Returns an array of ledger summaries that are associated with the current AWS account and Region.
This action returns a maximum of 100 items and is paginated so that you can retrieve all the items by calling ListLedgers
multiple times.
Parameter Syntax
$result = $client->listLedgers([ 'MaxResults' => <integer>, 'NextToken' => '<string>', ]);
Parameter Details
Members
- MaxResults
-
- Type: int
The maximum number of results to return in a single
ListLedgers
request. (The actual number of results returned might be fewer.) - NextToken
-
- Type: string
A pagination token, indicating that you want to retrieve the next page of results. If you received a value for
NextToken
in the response from a previousListLedgers
call, then you should use that value as input here.
Result Syntax
[ 'Ledgers' => [ [ 'CreationDateTime' => <DateTime>, 'Name' => '<string>', 'State' => 'CREATING|ACTIVE|DELETING|DELETED', ], // ... ], 'NextToken' => '<string>', ]
Result Details
Members
- Ledgers
-
- Type: Array of LedgerSummary structures
The array of ledger summaries that are associated with the current AWS account and Region.
- NextToken
-
- Type: string
A pagination token, indicating whether there are more results available:
-
If
NextToken
is empty, then the last page of results has been processed and there are no more results to be retrieved. -
If
NextToken
is not empty, then there are more results available. To retrieve the next page of results, use the value ofNextToken
in a subsequentListLedgers
call.
Errors
There are no errors described for this operation.
ListTagsForResource
$result = $client->listTagsForResource
([/* ... */]); $promise = $client->listTagsForResourceAsync
([/* ... */]);
Returns all tags for a specified Amazon QLDB resource.
Parameter Syntax
$result = $client->listTagsForResource([ 'ResourceArn' => '<string>', // REQUIRED ]);
Parameter Details
Members
Result Syntax
[ 'Tags' => ['<string>', ...], ]
Result Details
Members
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
StreamJournalToKinesis
$result = $client->streamJournalToKinesis
([/* ... */]); $promise = $client->streamJournalToKinesisAsync
([/* ... */]);
Creates a journal stream for a given Amazon QLDB ledger. The stream captures every document revision that is committed to the ledger's journal and delivers the data to a specified Amazon Kinesis Data Streams resource.
Parameter Syntax
$result = $client->streamJournalToKinesis([ 'ExclusiveEndTime' => <integer || string || DateTime>, 'InclusiveStartTime' => <integer || string || DateTime>, // REQUIRED 'KinesisConfiguration' => [ // REQUIRED 'AggregationEnabled' => true || false, 'StreamArn' => '<string>', // REQUIRED ], 'LedgerName' => '<string>', // REQUIRED 'RoleArn' => '<string>', // REQUIRED 'StreamName' => '<string>', // REQUIRED 'Tags' => ['<string>', ...], ]);
Parameter Details
Members
- ExclusiveEndTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The exclusive date and time that specifies when the stream ends. If you don't define this parameter, the stream runs indefinitely until you cancel it.
The
ExclusiveEndTime
must be inISO 8601
date and time format and in Universal Coordinated Time (UTC). For example:2019-06-13T21:36:34Z
- InclusiveStartTime
-
- Required: Yes
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The inclusive start date and time from which to start streaming journal data. This parameter must be in
ISO 8601
date and time format and in Universal Coordinated Time (UTC). For example:2019-06-13T21:36:34Z
The
InclusiveStartTime
cannot be in the future and must be beforeExclusiveEndTime
.If you provide an
InclusiveStartTime
that is before the ledger'sCreationDateTime
, QLDB effectively defaults it to the ledger'sCreationDateTime
. - KinesisConfiguration
-
- Required: Yes
- Type: KinesisConfiguration structure
The configuration settings of the Kinesis Data Streams destination for your stream request.
- LedgerName
-
- Required: Yes
- Type: string
The name of the ledger.
- RoleArn
-
- Required: Yes
- Type: string
The Amazon Resource Name (ARN) of the IAM role that grants QLDB permissions for a journal stream to write data records to a Kinesis Data Streams resource.
- StreamName
-
- Required: Yes
- Type: string
The name that you want to assign to the QLDB journal stream. User-defined names can help identify and indicate the purpose of a stream.
Your stream name must be unique among other active streams for a given ledger. Stream names have the same naming constraints as ledger names, as defined in Quotas in Amazon QLDB in the Amazon QLDB Developer Guide.
- Tags
-
- Type: Associative array of custom strings keys (TagKey) to strings
The key-value pairs to add as tags to the stream that you want to create. Tag keys are case sensitive. Tag values are case sensitive and can be null.
Result Syntax
[ 'StreamId' => '<string>', ]
Result Details
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
-
ResourcePreconditionNotMetException:
The operation failed because a condition wasn't satisfied in advance.
TagResource
$result = $client->tagResource
([/* ... */]); $promise = $client->tagResourceAsync
([/* ... */]);
Adds one or more tags to a specified Amazon QLDB resource.
A resource can have up to 50 tags. If you try to create more than 50 tags for a resource, your request fails and returns an error.
Parameter Syntax
$result = $client->tagResource([ 'ResourceArn' => '<string>', // REQUIRED 'Tags' => ['<string>', ...], // REQUIRED ]);
Parameter Details
Members
- ResourceArn
-
- Required: Yes
- Type: string
The Amazon Resource Name (ARN) to which you want to add the tags. For example:
arn:aws:qldb:us-east-1:123456789012:ledger/exampleLedger
- Tags
-
- Required: Yes
- Type: Associative array of custom strings keys (TagKey) to strings
The key-value pairs to add as tags to the specified QLDB resource. Tag keys are case sensitive. If you specify a key that already exists for the resource, your request fails and returns an error. Tag values are case sensitive and can be null.
Result Syntax
[]
Result Details
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
UntagResource
$result = $client->untagResource
([/* ... */]); $promise = $client->untagResourceAsync
([/* ... */]);
Removes one or more tags from a specified Amazon QLDB resource. You can specify up to 50 tag keys to remove.
Parameter Syntax
$result = $client->untagResource([ 'ResourceArn' => '<string>', // REQUIRED 'TagKeys' => ['<string>', ...], // REQUIRED ]);
Parameter Details
Members
Result Syntax
[]
Result Details
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
UpdateLedger
$result = $client->updateLedger
([/* ... */]); $promise = $client->updateLedgerAsync
([/* ... */]);
Updates properties on a ledger.
Parameter Syntax
$result = $client->updateLedger([ 'DeletionProtection' => true || false, 'Name' => '<string>', // REQUIRED ]);
Parameter Details
Members
- DeletionProtection
-
- Type: boolean
The flag that prevents a ledger from being deleted by any user. If not provided on ledger creation, this feature is enabled (
true
) by default.If deletion protection is enabled, you must first disable it before you can delete the ledger using the QLDB API or the AWS Command Line Interface (AWS CLI). You can disable it by calling the
UpdateLedger
operation to set the flag tofalse
. The QLDB console disables deletion protection for you when you use it to delete a ledger. - Name
-
- Required: Yes
- Type: string
The name of the ledger.
Result Syntax
[ 'Arn' => '<string>', 'CreationDateTime' => <DateTime>, 'DeletionProtection' => true || false, 'Name' => '<string>', 'State' => 'CREATING|ACTIVE|DELETING|DELETED', ]
Result Details
Members
- Arn
-
- Type: string
The Amazon Resource Name (ARN) for the ledger.
- CreationDateTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The date and time, in epoch time format, when the ledger was created. (Epoch time format is the number of seconds elapsed since 12:00:00 AM January 1, 1970 UTC.)
- DeletionProtection
-
- Type: boolean
The flag that prevents a ledger from being deleted by any user. If not provided on ledger creation, this feature is enabled (
true
) by default.If deletion protection is enabled, you must first disable it before you can delete the ledger using the QLDB API or the AWS Command Line Interface (AWS CLI). You can disable it by calling the
UpdateLedger
operation to set the flag tofalse
. The QLDB console disables deletion protection for you when you use it to delete a ledger. - Name
-
- Type: string
The name of the ledger.
- State
-
- Type: string
The current status of the ledger.
Errors
-
One or more parameters in the request aren't valid.
-
The specified resource doesn't exist.
Shapes
InvalidParameterException
Description
One or more parameters in the request aren't valid.
Members
JournalKinesisStreamDescription
Description
The information about an Amazon QLDB journal stream, including the Amazon Resource Name (ARN), stream name, creation time, current status, and the parameters of your original stream creation request.
Members
- Arn
-
- Type: string
The Amazon Resource Name (ARN) of the QLDB journal stream.
- CreationTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The date and time, in epoch time format, when the QLDB journal stream was created. (Epoch time format is the number of seconds elapsed since 12:00:00 AM January 1, 1970 UTC.)
- ErrorCause
-
- Type: string
The error message that describes the reason that a stream has a status of
IMPAIRED
orFAILED
. This is not applicable to streams that have other status values. - ExclusiveEndTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The exclusive date and time that specifies when the stream ends. If this parameter is blank, the stream runs indefinitely until you cancel it.
- InclusiveStartTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The inclusive start date and time from which to start streaming journal data.
- KinesisConfiguration
-
- Required: Yes
- Type: KinesisConfiguration structure
The configuration settings of the Amazon Kinesis Data Streams destination for your QLDB journal stream.
- LedgerName
-
- Required: Yes
- Type: string
The name of the ledger.
- RoleArn
-
- Required: Yes
- Type: string
The Amazon Resource Name (ARN) of the IAM role that grants QLDB permissions for a journal stream to write data records to a Kinesis Data Streams resource.
- Status
-
- Required: Yes
- Type: string
The current state of the QLDB journal stream.
- StreamId
-
- Required: Yes
- Type: string
The unique ID that QLDB assigns to each QLDB journal stream.
- StreamName
-
- Required: Yes
- Type: string
The user-defined name of the QLDB journal stream.
JournalS3ExportDescription
Description
The information about a journal export job, including the ledger name, export ID, when it was created, current status, and its start and end time export parameters.
Members
- ExclusiveEndTime
-
- Required: Yes
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The exclusive end date and time for the range of journal contents that are specified in the original export request.
- ExportCreationTime
-
- Required: Yes
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The date and time, in epoch time format, when the export job was created. (Epoch time format is the number of seconds elapsed since 12:00:00 AM January 1, 1970 UTC.)
- ExportId
-
- Required: Yes
- Type: string
The unique ID of the journal export job.
- InclusiveStartTime
-
- Required: Yes
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The inclusive start date and time for the range of journal contents that are specified in the original export request.
- LedgerName
-
- Required: Yes
- Type: string
The name of the ledger.
- RoleArn
-
- Required: Yes
- Type: string
The Amazon Resource Name (ARN) of the IAM role that grants QLDB permissions for a journal export job to do the following:
-
Write objects into your Amazon Simple Storage Service (Amazon S3) bucket.
-
(Optional) Use your customer master key (CMK) in AWS Key Management Service (AWS KMS) for server-side encryption of your exported data.
- S3ExportConfiguration
-
- Required: Yes
- Type: S3ExportConfiguration structure
The Amazon Simple Storage Service (Amazon S3) bucket location in which a journal export job writes the journal contents.
- Status
-
- Required: Yes
- Type: string
The current state of the journal export job.
KinesisConfiguration
Description
The configuration settings of the Amazon Kinesis Data Streams destination for your Amazon QLDB journal stream.
Members
- AggregationEnabled
-
- Type: boolean
Enables QLDB to publish multiple data records in a single Kinesis Data Streams record. To learn more, see KPL Key Concepts in the Amazon Kinesis Data Streams Developer Guide.
- StreamArn
-
- Required: Yes
- Type: string
The Amazon Resource Name (ARN) of the Kinesis data stream resource.
LedgerSummary
Description
Information about a ledger, including its name, state, and when it was created.
Members
- CreationDateTime
-
- Type: timestamp (string|DateTime or anything parsable by strtotime)
The date and time, in epoch time format, when the ledger was created. (Epoch time format is the number of seconds elapsed since 12:00:00 AM January 1, 1970 UTC.)
- Name
-
- Type: string
The name of the ledger.
- State
-
- Type: string
The current status of the ledger.
LimitExceededException
Description
You have reached the limit on the maximum number of resources allowed.
Members
ResourceAlreadyExistsException
Description
The specified resource already exists.
Members
ResourceInUseException
Description
The specified resource can't be modified at this time.
Members
ResourceNotFoundException
Description
The specified resource doesn't exist.
Members
ResourcePreconditionNotMetException
Description
The operation failed because a condition wasn't satisfied in advance.
Members
S3EncryptionConfiguration
Description
The encryption settings that are used by a journal export job to write data in an Amazon Simple Storage Service (Amazon S3) bucket.
Members
- KmsKeyArn
-
- Type: string
The Amazon Resource Name (ARN) for a symmetric customer master key (CMK) in AWS Key Management Service (AWS KMS). Amazon QLDB does not support asymmetric CMKs.
You must provide a
KmsKeyArn
if you specifySSE_KMS
as theObjectEncryptionType
.KmsKeyArn
is not required if you specifySSE_S3
as theObjectEncryptionType
. - ObjectEncryptionType
-
- Required: Yes
- Type: string
The Amazon S3 object encryption type.
To learn more about server-side encryption options in Amazon S3, see Protecting Data Using Server-Side Encryption in the Amazon S3 Developer Guide.
S3ExportConfiguration
Description
The Amazon Simple Storage Service (Amazon S3) bucket location in which a journal export job writes the journal contents.
Members
- Bucket
-
- Required: Yes
- Type: string
The Amazon S3 bucket name in which a journal export job writes the journal contents.
The bucket name must comply with the Amazon S3 bucket naming conventions. For more information, see Bucket Restrictions and Limitations in the Amazon S3 Developer Guide.
- EncryptionConfiguration
-
- Required: Yes
- Type: S3EncryptionConfiguration structure
The encryption settings that are used by a journal export job to write data in an Amazon S3 bucket.
- Prefix
-
- Required: Yes
- Type: string
The prefix for the Amazon S3 bucket in which a journal export job writes the journal contents.
The prefix must comply with Amazon S3 key naming rules and restrictions. For more information, see Object Key and Metadata in the Amazon S3 Developer Guide.
The following are examples of valid
Prefix
values:-
JournalExports-ForMyLedger/Testing/
-
JournalExports
-
My:Tests/