2017/09/21 - Amazon Elastic Compute Cloud - 5 new 1 updated api methods
Changes Add EC2 APIs to copy Amazon FPGA Images (AFIs) within the same region and across multiple regions, delete AFIs, and modify AFI attributes. AFI attributes include name, description and granting/denying other AWS accounts to load the AFI.
Resets the specified attribute of the specified Amazon FPGA Image (AFI) to its default value. You can only reset the load permission attribute.
See also: AWS API Documentation
Request Syntax
client.reset_fpga_image_attribute( DryRun=True|False, FpgaImageId='string', Attribute='loadPermission' )
boolean
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation . Otherwise, it is UnauthorizedOperation .
string
[REQUIRED]
The ID of the AFI.
string
The attribute.
dict
Response Syntax
{ 'Return': True|False }
Response Structure
(dict) --
Return (boolean) --
Is true if the request succeeds, and an error otherwise.
Copies the specified Amazon FPGA Image (AFI) to the current region.
See also: AWS API Documentation
Request Syntax
client.copy_fpga_image( DryRun=True|False, SourceFpgaImageId='string', Description='string', Name='string', SourceRegion='string', ClientToken='string' )
boolean
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation . Otherwise, it is UnauthorizedOperation .
string
[REQUIRED]
The ID of the source AFI.
string
The description for the new AFI.
string
The name for the new AFI. The default is the name of the source AFI.
string
[REQUIRED]
The region that contains the source AFI.
string
Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see Ensuring Idempotency .
dict
Response Syntax
{ 'FpgaImageId': 'string' }
Response Structure
(dict) --
FpgaImageId (string) --
The ID of the new AFI.
Describes the specified attribute of the specified Amazon FPGA Image (AFI).
See also: AWS API Documentation
Request Syntax
client.describe_fpga_image_attribute( DryRun=True|False, FpgaImageId='string', Attribute='description'|'name'|'loadPermission'|'productCodes' )
boolean
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation . Otherwise, it is UnauthorizedOperation .
string
[REQUIRED]
The ID of the AFI.
string
[REQUIRED]
The AFI attribute.
dict
Response Syntax
{ 'FpgaImageAttribute': { 'FpgaImageId': 'string', 'Name': 'string', 'Description': 'string', 'LoadPermissions': [ { 'UserId': 'string', 'Group': 'all' }, ], 'ProductCodes': [ { 'ProductCodeId': 'string', 'ProductCodeType': 'devpay'|'marketplace' }, ] } }
Response Structure
(dict) --
FpgaImageAttribute (dict) --
Information about the attribute.
FpgaImageId (string) --
The ID of the AFI.
Name (string) --
The name of the AFI.
Description (string) --
The description of the AFI.
LoadPermissions (list) --
One or more load permissions.
(dict) --
Describes a load permission.
UserId (string) --
The AWS account ID.
Group (string) --
The name of the group.
ProductCodes (list) --
One or more product codes.
(dict) --
Describes a product code.
ProductCodeId (string) --
The product code.
ProductCodeType (string) --
The type of product code.
Modifies the specified attribute of the specified Amazon FPGA Image (AFI).
See also: AWS API Documentation
Request Syntax
client.modify_fpga_image_attribute( DryRun=True|False, FpgaImageId='string', Attribute='description'|'name'|'loadPermission'|'productCodes', OperationType='add'|'remove', UserIds=[ 'string', ], UserGroups=[ 'string', ], ProductCodes=[ 'string', ], LoadPermission={ 'Add': [ { 'Group': 'all', 'UserId': 'string' }, ], 'Remove': [ { 'Group': 'all', 'UserId': 'string' }, ] }, Description='string', Name='string' )
boolean
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation . Otherwise, it is UnauthorizedOperation .
string
[REQUIRED]
The ID of the AFI.
string
The name of the attribute.
string
The operation type.
list
One or more AWS account IDs. This parameter is valid only when modifying the loadPermission attribute.
(string) --
list
One or more user groups. This parameter is valid only when modifying the loadPermission attribute.
(string) --
list
One or more product codes. After you add a product code to an AFI, it can't be removed. This parameter is valid only when modifying the productCodes attribute.
(string) --
dict
The load permission for the AFI.
Add (list) --
The load permissions to add.
(dict) --
Describes a load permission.
Group (string) --
The name of the group.
UserId (string) --
The AWS account ID.
Remove (list) --
The load permissions to remove.
(dict) --
Describes a load permission.
Group (string) --
The name of the group.
UserId (string) --
The AWS account ID.
string
A description for the AFI.
string
A name for the AFI.
dict
Response Syntax
{ 'FpgaImageAttribute': { 'FpgaImageId': 'string', 'Name': 'string', 'Description': 'string', 'LoadPermissions': [ { 'UserId': 'string', 'Group': 'all' }, ], 'ProductCodes': [ { 'ProductCodeId': 'string', 'ProductCodeType': 'devpay'|'marketplace' }, ] } }
Response Structure
(dict) --
FpgaImageAttribute (dict) --
Information about the attribute.
FpgaImageId (string) --
The ID of the AFI.
Name (string) --
The name of the AFI.
Description (string) --
The description of the AFI.
LoadPermissions (list) --
One or more load permissions.
(dict) --
Describes a load permission.
UserId (string) --
The AWS account ID.
Group (string) --
The name of the group.
ProductCodes (list) --
One or more product codes.
(dict) --
Describes a product code.
ProductCodeId (string) --
The product code.
ProductCodeType (string) --
The type of product code.
Deletes the specified Amazon FPGA Image (AFI).
See also: AWS API Documentation
Request Syntax
client.delete_fpga_image( DryRun=True|False, FpgaImageId='string' )
boolean
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation . Otherwise, it is UnauthorizedOperation .
string
[REQUIRED]
The ID of the AFI.
dict
Response Syntax
{ 'Return': True|False }
Response Structure
(dict) --
Return (boolean) --
Is true if the request succeeds, and an error otherwise.
{'FpgaImages': {'Public': 'boolean'}}
Describes one or more available Amazon FPGA Images (AFIs). These include public AFIs, private AFIs that you own, and AFIs owned by other AWS accounts for which you have load permissions.
See also: AWS API Documentation
Request Syntax
client.describe_fpga_images( DryRun=True|False, FpgaImageIds=[ 'string', ], Owners=[ 'string', ], Filters=[ { 'Name': 'string', 'Values': [ 'string', ] }, ], NextToken='string', MaxResults=123 )
boolean
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation . Otherwise, it is UnauthorizedOperation .
list
One or more AFI IDs.
(string) --
list
Filters the AFI by owner. Specify an AWS account ID, self (owner is the sender of the request), or an AWS owner alias (valid values are amazon | aws-marketplace ).
(string) --
list
One or more filters.
create-time - The creation time of the AFI.
fpga-image-id - The FPGA image identifier (AFI ID).
fpga-image-global-id - The global FPGA image identifier (AGFI ID).
name - The name of the AFI.
owner-id - The AWS account ID of the AFI owner.
product-code - The product code.
shell-version - The version of the AWS Shell that was used to create the bitstream.
state - The state of the AFI (pending | failed | available | unavailable ).
tag :key =*value* - The key/value combination of a tag assigned to the resource. Specify the key of the tag in the filter name and the value of the tag in the filter value. For example, for the tag Purpose=X, specify tag:Purpose for the filter name and X for the filter value.
tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag :key =*value* filter.
tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.
update-time - The time of the most recent update.
(dict) --
A filter name and value pair that is used to return a more specific list of results. Filters can be used to match a set of resources by various criteria, such as tags, attributes, or IDs.
Name (string) --
The name of the filter. Filter names are case-sensitive.
Values (list) --
One or more filter values. Filter values are case-sensitive.
(string) --
string
The token to retrieve the next page of results.
integer
The maximum number of results to return in a single call.
dict
Response Syntax
{ 'FpgaImages': [ { 'FpgaImageId': 'string', 'FpgaImageGlobalId': 'string', 'Name': 'string', 'Description': 'string', 'ShellVersion': 'string', 'PciId': { 'DeviceId': 'string', 'VendorId': 'string', 'SubsystemId': 'string', 'SubsystemVendorId': 'string' }, 'State': { 'Code': 'pending'|'failed'|'available'|'unavailable', 'Message': 'string' }, 'CreateTime': datetime(2015, 1, 1), 'UpdateTime': datetime(2015, 1, 1), 'OwnerId': 'string', 'OwnerAlias': 'string', 'ProductCodes': [ { 'ProductCodeId': 'string', 'ProductCodeType': 'devpay'|'marketplace' }, ], 'Tags': [ { 'Key': 'string', 'Value': 'string' }, ], 'Public': True|False }, ], 'NextToken': 'string' }
Response Structure
(dict) --
FpgaImages (list) --
Information about one or more FPGA images.
(dict) --
Describes an Amazon FPGA image (AFI).
FpgaImageId (string) --
The FPGA image identifier (AFI ID).
FpgaImageGlobalId (string) --
The global FPGA image identifier (AGFI ID).
Name (string) --
The name of the AFI.
Description (string) --
The description of the AFI.
ShellVersion (string) --
The version of the AWS Shell that was used to create the bitstream.
PciId (dict) --
Information about the PCI bus.
DeviceId (string) --
The ID of the device.
VendorId (string) --
The ID of the vendor.
SubsystemId (string) --
The ID of the subsystem.
SubsystemVendorId (string) --
The ID of the vendor for the subsystem.
State (dict) --
Information about the state of the AFI.
Code (string) --
The state. The following are the possible values:
pending - AFI bitstream generation is in progress.
available - The AFI is available for use.
failed - AFI bitstream generation failed.
unavailable - The AFI is no longer available for use.
Message (string) --
If the state is failed , this is the error message.
CreateTime (datetime) --
The date and time the AFI was created.
UpdateTime (datetime) --
The time of the most recent update to the AFI.
OwnerId (string) --
The AWS account ID of the AFI owner.
OwnerAlias (string) --
The alias of the AFI owner. Possible values include self , amazon , and aws-marketplace .
ProductCodes (list) --
The product codes for the AFI.
(dict) --
Describes a product code.
ProductCodeId (string) --
The product code.
ProductCodeType (string) --
The type of product code.
Tags (list) --
Any tags assigned to the AFI.
(dict) --
Describes a tag.
Key (string) --
The key of the tag.
Constraints: Tag keys are case-sensitive and accept a maximum of 127 Unicode characters. May not begin with aws:
Value (string) --
The value of the tag.
Constraints: Tag values are case-sensitive and accept a maximum of 255 Unicode characters.
Public (boolean) --
Indicates whether the AFI is public.
NextToken (string) --
The token to use to retrieve the next page of results. This value is null when there are no more results to return.