2025/11/10 - Braket - 2 updated api methods
Changes Adds ExperimentalCapabilities field to CreateQuantumTask request and GetQuantumTask response objects. Enables use of experimental software capabilities when creating quantum tasks.
{'experimentalCapabilities': {'enabled': 'ALL | NONE'}}
Creates a quantum task.
See also: AWS API Documentation
Request Syntax
client.create_quantum_task(
clientToken='string',
deviceArn='string',
deviceParameters='string',
shots=123,
outputS3Bucket='string',
outputS3KeyPrefix='string',
action='string',
tags={
'string': 'string'
},
jobToken='string',
associations=[
{
'arn': 'string',
'type': 'RESERVATION_TIME_WINDOW_ARN'
},
],
experimentalCapabilities={
'enabled': 'ALL'|'NONE'
}
)
string
[REQUIRED]
The client token associated with the request.
This field is autopopulated if not provided.
string
[REQUIRED]
The ARN of the device to run the quantum task on.
string
The parameters for the device to run the quantum task on.
integer
[REQUIRED]
The number of shots to use for the quantum task.
string
[REQUIRED]
The S3 bucket to store quantum task result files in.
string
[REQUIRED]
The key prefix for the location in the S3 bucket to store quantum task results in.
string
[REQUIRED]
The action associated with the quantum task.
dict
Tags to be added to the quantum task you're creating.
(string) --
(string) --
string
The token for an Amazon Braket hybrid job that associates it with the quantum task.
list
The list of Amazon Braket resources associated with the quantum task.
(dict) --
The Amazon Braket resource and the association type.
arn (string) -- [REQUIRED]
The Amazon Braket resource arn.
type (string) -- [REQUIRED]
The association type for the specified Amazon Braket resource arn.
dict
Enable experimental capabilities for the quantum task.
enabled (string) --
Enabled experimental capabilities.
dict
Response Syntax
{
'quantumTaskArn': 'string'
}
Response Structure
(dict) --
quantumTaskArn (string) --
The ARN of the quantum task created by the request.
{'experimentalCapabilities': {'enabled': 'ALL | NONE'}}
Retrieves the specified quantum task.
See also: AWS API Documentation
Request Syntax
client.get_quantum_task(
quantumTaskArn='string',
additionalAttributeNames=[
'QueueInfo',
]
)
string
[REQUIRED]
The ARN of the quantum task to retrieve.
list
A list of attributes to return additional information for. Only the QueueInfo additional attribute name is currently supported.
(string) --
dict
Response Syntax
{
'quantumTaskArn': 'string',
'status': 'CREATED'|'QUEUED'|'RUNNING'|'COMPLETED'|'FAILED'|'CANCELLING'|'CANCELLED',
'failureReason': 'string',
'deviceArn': 'string',
'deviceParameters': 'string',
'shots': 123,
'outputS3Bucket': 'string',
'outputS3Directory': 'string',
'createdAt': datetime(2015, 1, 1),
'endedAt': datetime(2015, 1, 1),
'tags': {
'string': 'string'
},
'jobArn': 'string',
'queueInfo': {
'queue': 'QUANTUM_TASKS_QUEUE'|'JOBS_QUEUE',
'position': 'string',
'queuePriority': 'Normal'|'Priority',
'message': 'string'
},
'associations': [
{
'arn': 'string',
'type': 'RESERVATION_TIME_WINDOW_ARN'
},
],
'numSuccessfulShots': 123,
'actionMetadata': {
'actionType': 'string',
'programCount': 123,
'executableCount': 123
},
'experimentalCapabilities': {
'enabled': 'ALL'|'NONE'
}
}
Response Structure
(dict) --
quantumTaskArn (string) --
The ARN of the quantum task.
status (string) --
The status of the quantum task.
failureReason (string) --
The reason that a quantum task failed.
deviceArn (string) --
The ARN of the device the quantum task was run on.
deviceParameters (string) --
The parameters for the device on which the quantum task ran.
shots (integer) --
The number of shots used in the quantum task.
outputS3Bucket (string) --
The S3 bucket where quantum task results are stored.
outputS3Directory (string) --
The folder in the S3 bucket where quantum task results are stored.
createdAt (datetime) --
The time at which the quantum task was created.
endedAt (datetime) --
The time at which the quantum task ended.
tags (dict) --
The tags that belong to this quantum task.
(string) --
(string) --
jobArn (string) --
The ARN of the Amazon Braket job associated with the quantum task.
queueInfo (dict) --
Queue information for the requested quantum task. Only returned if QueueInfo is specified in the additionalAttributeNames" field in the GetQuantumTask API request.
queue (string) --
The name of the queue.
position (string) --
Current position of the quantum task in the quantum tasks queue.
queuePriority (string) --
Optional. Specifies the priority of the queue. Quantum tasks in a priority queue are processed before the quantum tasks in a normal queue.
message (string) --
Optional. Provides more information about the queue position. For example, if the quantum task is complete and no longer in the queue, the message field contains that information.
associations (list) --
The list of Amazon Braket resources associated with the quantum task.
(dict) --
The Amazon Braket resource and the association type.
arn (string) --
The Amazon Braket resource arn.
type (string) --
The association type for the specified Amazon Braket resource arn.
numSuccessfulShots (integer) --
The number of successful shots for the quantum task. This is available after a successfully completed quantum task.
actionMetadata (dict) --
Metadata about the action performed by the quantum task, including information about the type of action and program counts.
actionType (string) --
The type of action associated with the quantum task.
programCount (integer) --
The number of programs in a program set. This is only available for a program set.
executableCount (integer) --
The number of executables in a program set. This is only available for a program set.
experimentalCapabilities (dict) --
Enabled experimental capabilities for the quantum task, if any.
enabled (string) --
Enabled experimental capabilities.