add_attachments_to_set
¶
add_attachments_to_set(
attachments: Attachments,
*,
config_overrides: Optional[SupportClientConfig] = None,
attachment_set_id: Optional[AttachmentSetId] = None,
dry_run: Optional[NullableBooleanType] = None,
) -> AddAttachmentsToSetResponse
Adds one or more attachments to an attachment set.
An attachment set is a temporary container for attachments that you add to a case or case communication. The set is available for 1 hour after it's created. The expiryTime returned in the response is when the set expires.
-
You must have an Amazon Web Services Business Support+, Amazon Web Services Enterprise Support, or Amazon Web Services Unified Operations plan to use the Amazon Web Services Support API. If you're in an Amazon Web Services Region that doesn't offer one of these Amazon Web Services Support plans, or if you haven't transitioned to one of these plans, you can use the Amazon Web Services Support API with a Business, Enterprise On-Ramp, or Enterprise Support plan.
-
If you call the Amazon Web Services Support API from an account that doesn't have an Amazon Web Services Business Support+, Amazon Web Services Enterprise Support, or Amazon Web Services Unified Operations plan, the
SubscriptionRequiredExceptionerror message appears. For information about changing your support plan, see Amazon Web Services Support.
Parameters:
-
attachment_set_id(Optional[AttachmentSetId], default:None) –The ID of the attachment set. If an
attachmentSetIdis not specified, a new attachment set is created, and the ID of the set is returned in the response. If anattachmentSetIdis specified, the attachments are added to the specified set, if it exists. -
attachments(Attachments) –One or more attachments to add to the set. You can add up to three attachments per set. The size limit is 5 MB per attachment.
In the
Attachmentobject, use thedataparameter to specify the contents of the attachment file. In the previous request syntax, the value fordataappear asblob, which is represented as a base64-encoded string. The value forfileNameis the name of the attachment, such astroubleshoot-screenshot.png. -
dry_run(Optional[NullableBooleanType], default:None) –Specifies whether to validate the request without actually adding the attachments. When set to
true, the request is validated but no attachments are stored, and the operation returns aDryRunOperationException. When omitted or set tofalse, the request runs normally.
Raises:
-
AttachmentLimitExceeded–The limit for the number of attachment sets created in a short period of time has been exceeded.
-
AttachmentSetExpired–The expiration time of the attachment set has passed. The set expires 1 hour after it is created.
-
AttachmentSetIdNotFound–An attachment set with the specified ID could not be found.
-
AttachmentSetSizeLimitExceeded–A limit for the size of an attachment set has been exceeded. The limits are three attachments and 5 MB per attachment.
-
DryRunOperationException–The request was valid, but the operation wasn't performed because
dryRunwas set totrue. -
InternalServerError–An internal server error occurred.
-
UnknownServiceError–The service returned an error code this client does not model.