describe_cases
(**kwargs)¶Returns a list of cases that you specify by passing one or more case IDs. You can use the afterTime
and beforeTime
parameters to filter the cases by date. You can set values for the includeResolvedCases
and includeCommunications
parameters to specify how much information to return.
The response returns the following in JSON format:
nextToken
values, which specify where to paginate the returned records represented by the CaseDetails
objects.Case data is available for 12 months after creation. If a case was created more than 12 months ago, a request might return an error.
Note
SubscriptionRequiredException
error message appears. For information about changing your support plan, see Amazon Web Services Support.See also: AWS API Documentation
Request Syntax
response = client.describe_cases(
caseIdList=[
'string',
],
displayId='string',
afterTime='string',
beforeTime='string',
includeResolvedCases=True|False,
nextToken='string',
maxResults=123,
language='string',
includeCommunications=True|False
)
A list of ID numbers of the support cases you want returned. The maximum number of cases is 100.
DescribeCases
response. By default, resolved cases aren't included.language
parameter if you want support in that language.DescribeCases
response. By default, communications are included.dict
Response Syntax
{
'cases': [
{
'caseId': 'string',
'displayId': 'string',
'subject': 'string',
'status': 'string',
'serviceCode': 'string',
'categoryCode': 'string',
'severityCode': 'string',
'submittedBy': 'string',
'timeCreated': 'string',
'recentCommunications': {
'communications': [
{
'caseId': 'string',
'body': 'string',
'submittedBy': 'string',
'timeCreated': 'string',
'attachmentSet': [
{
'attachmentId': 'string',
'fileName': 'string'
},
]
},
],
'nextToken': 'string'
},
'ccEmailAddresses': [
'string',
],
'language': 'string'
},
],
'nextToken': 'string'
}
Response Structure
(dict) --
Returns an array of CaseDetails objects and a nextToken
that defines a point for pagination in the result set.
cases (list) --
The details for the cases that match the request.
(dict) --
A JSON-formatted object that contains the metadata for a support case. It is contained in the response from a DescribeCases request. CaseDetails contains the following fields:
CategoryCode
values returned by a call to DescribeServices.language
parameter if you want support in that language.attachments
, body
, caseId
, submittedBy
, and timeCreated
.low
, normal
, high
, urgent
, and critical
.opened
pending-customer-action
reopened
resolved
unassigned
work-in-progress
caseId (string) --
The support case ID requested or returned in the call. The case ID is an alphanumeric string formatted as shown in this example: case-12345678910-2013-c4c1d2bf33c5cf47
displayId (string) --
The ID displayed for the case in the Amazon Web Services Support Center. This is a numeric string.
subject (string) --
The subject line for the case in the Amazon Web Services Support Center.
status (string) --
The status of the case.
Valid values:
opened
pending-customer-action
reopened
resolved
unassigned
work-in-progress
serviceCode (string) --
The code for the Amazon Web Services service. You can get a list of codes and the corresponding service names by calling DescribeServices.
categoryCode (string) --
The category of problem for the support case.
severityCode (string) --
The code for the severity level returned by the call to DescribeSeverityLevels.
submittedBy (string) --
The email address of the account that submitted the case.
timeCreated (string) --
The time that the case was created in the Amazon Web Services Support Center.
recentCommunications (dict) --
The five most recent communications between you and Amazon Web Services Support Center, including the IDs of any attachments to the communications. Also includes a nextToken
that you can use to retrieve earlier communications.
communications (list) --
The five most recent communications associated with the case.
(dict) --
A communication associated with a support case. The communication consists of the case ID, the message body, attachment information, the submitter of the communication, and the date and time of the communication.
caseId (string) --
The support case ID requested or returned in the call. The case ID is an alphanumeric string formatted as shown in this example: case-12345678910-2013-c4c1d2bf33c5cf47
body (string) --
The text of the communication between the customer and Amazon Web Services Support.
submittedBy (string) --
The identity of the account that submitted, or responded to, the support case. Customer entries include the role or IAM user as well as the email address. For example, "AdminRole (Role) <janedoe@example.com>. Entries from the Amazon Web Services Support team display "Amazon Web Services," and don't show an email address.
timeCreated (string) --
The time the communication was created.
attachmentSet (list) --
Information about the attachments to the case communication.
(dict) --
The file name and ID of an attachment to a case communication. You can use the ID to retrieve the attachment with the DescribeAttachment operation.
attachmentId (string) --
The ID of the attachment.
fileName (string) --
The file name of the attachment.
nextToken (string) --
A resumption point for pagination.
ccEmailAddresses (list) --
The email addresses that receive copies of communication about the case.
language (string) --
The language in which Amazon Web Services Support handles the case. Amazon Web Services Support currently supports English ("en") and Japanese ("ja"). You must specify the ISO 639-1 code for the language
parameter if you want support in that language.
nextToken (string) --
A resumption point for pagination.
Exceptions
Support.Client.exceptions.InternalServerError
Support.Client.exceptions.CaseIdNotFound