SSM.Client.
create_ops_item
(**kwargs)¶Creates a new OpsItem. You must have permission in Identity and Access Management (IAM) to create a new OpsItem. For more information, see Getting started with OpsCenter in the Amazon Web Services Systems Manager User Guide .
Operations engineers and IT professionals use Amazon Web Services Systems Manager OpsCenter to view, investigate, and remediate operational issues impacting the performance and health of their Amazon Web Services resources. For more information, see Amazon Web Services Systems Manager OpsCenter in the Amazon Web Services Systems Manager User Guide .
See also: AWS API Documentation
Request Syntax
response = client.create_ops_item(
Description='string',
OpsItemType='string',
OperationalData={
'string': {
'Value': 'string',
'Type': 'SearchableString'|'String'
}
},
Notifications=[
{
'Arn': 'string'
},
],
Priority=123,
RelatedOpsItems=[
{
'OpsItemId': 'string'
},
],
Source='string',
Title='string',
Tags=[
{
'Key': 'string',
'Value': 'string'
},
],
Category='string',
Severity='string',
ActualStartTime=datetime(2015, 1, 1),
ActualEndTime=datetime(2015, 1, 1),
PlannedStartTime=datetime(2015, 1, 1),
PlannedEndTime=datetime(2015, 1, 1),
AccountId='string'
)
[REQUIRED]
Information about the OpsItem.
The type of OpsItem to create. Systems Manager supports the following types of OpsItems:
/aws/issue
This type of OpsItem is used for default OpsItems created by OpsCenter./aws/changerequest
This type of OpsItem is used by Change Manager for reviewing and approving or rejecting change requests./aws/insights
This type of OpsItem is used by OpsCenter for aggregating and reporting on duplicate OpsItems.Operational data is custom data that provides useful reference details about the OpsItem. For example, you can specify log files, error strings, license keys, troubleshooting tips, or other relevant data. You enter operational data as key-value pairs. The key has a maximum length of 128 characters. The value has a maximum size of 20 KB.
Warning
Operational data keys can't begin with the following: amazon
, aws
, amzn
, ssm
, /amazon
, /aws
, /amzn
, /ssm
.
You can choose to make the data searchable by other users in the account or you can restrict search access. Searchable data means that all users with access to the OpsItem Overview page (as provided by the DescribeOpsItems API operation) can view and search on the specified data. Operational data that isn't searchable is only viewable by users who have access to the OpsItem (as provided by the GetOpsItem API operation).
Use the /aws/resources
key in OperationalData to specify a related resource in the request. Use the /aws/automations
key in OperationalData to associate an Automation runbook with the OpsItem. To view Amazon Web Services CLI example commands that use these keys, see Creating OpsItems manually in the Amazon Web Services Systems Manager User Guide .
An object that defines the value of the key and its type in the OperationalData map.
The value of the OperationalData key.
The type of key-value pair. Valid types include SearchableString
and String
.
The Amazon Resource Name (ARN) of an SNS topic where notifications are sent when this OpsItem is edited or changed.
A notification about the OpsItem.
The Amazon Resource Name (ARN) of an Amazon Simple Notification Service (Amazon SNS) topic where notifications are sent when this OpsItem is edited or changed.
One or more OpsItems that share something in common with the current OpsItems. For example, related OpsItems can include OpsItems with similar error messages, impacted resources, or statuses for the impacted resource.
An OpsItems that shares something in common with the current OpsItem. For example, related OpsItems can include OpsItems with similar error messages, impacted resources, or statuses for the impacted resource.
The ID of an OpsItem related to the current OpsItem.
[REQUIRED]
The origin of the OpsItem, such as Amazon EC2 or Systems Manager.
Note
The source name can't contain the following strings: aws
, amazon
, and amzn
.
[REQUIRED]
A short heading that describes the nature of the OpsItem and the impacted resource.
Optional metadata that you assign to a resource. You can restrict access to OpsItems by using an inline IAM policy that specifies tags. For more information, see Getting started with OpsCenter in the Amazon Web Services Systems Manager User Guide .
Tags use a key-value pair. For example:
Key=Department,Value=Finance
Warning
To add tags to a new OpsItem, a user must have IAM permissions for both the ssm:CreateOpsItems
operation and the ssm:AddTagsToResource
operation. To add tags to an existing OpsItem, use the AddTagsToResource operation.
Metadata that you assign to your Amazon Web Services resources. Tags enable you to categorize your resources in different ways, for example, by purpose, owner, or environment. In Amazon Web Services Systems Manager, you can apply tags to Systems Manager documents (SSM documents), managed nodes, maintenance windows, parameters, patch baselines, OpsItems, and OpsMetadata.
The name of the tag.
The value of the tag.
/aws/changerequest
./aws/changerequest
./aws/changerequest
./aws/changerequest
.dict
Response Syntax
{
'OpsItemId': 'string',
'OpsItemArn': 'string'
}
Response Structure
(dict) --
OpsItemId (string) --
The ID of the OpsItem.
OpsItemArn (string) --
The OpsItem Amazon Resource Name (ARN).
Exceptions
SSM.Client.exceptions.InternalServerError
SSM.Client.exceptions.OpsItemAlreadyExistsException
SSM.Client.exceptions.OpsItemLimitExceededException
SSM.Client.exceptions.OpsItemInvalidParameterException
SSM.Client.exceptions.OpsItemAccessDeniedException