The following is an example of a TestEventPattern request and response.
Sample Request
POST / HTTP/1.1
Host: events.<region>.<domain>
x-amz-Date: <Date>
Authorization: AWS4-HMAC-SHA256 Credential=<Credential>,
SignedHeaders=content-type;date;host;user-agent;x-amz-date;x-amz-target;x-amzn-requestid, Signature=<Signature>
User-Agent: <UserAgentString>
Content-Type: application/x-amz-json-1.1 Content-Length: <PayloadSizeBytes>
Connection: Keep-Alive
X-Amz-Target: AWSEvents.TestEventPattern {
"EventPattern": "{\"source\": [\"com.mycompany.myapp\"]}",
"Event": "{\"id\": \"e00c66cb-fe7a-4fcc-81ad-58eb60f5d96b\", \"detail-type\":
\"myDetailType\", \"source\": \"com.mycompany.myapp\", \"account\": \"123456789012\", \"time\": \"2016-01-10T01:29:23Z\", \"region\": \"us-east-1\", \"resources\":
[\"resource1\", \"resource2\"], \"detail\": {\"key1\": \"value1\", \"key2\":
\"value2\"}}"
}}
See Also
Sample Response
HTTP/1.1 200 OK
x-amzn-RequestId: <RequestId>
Content-Type: application/x-amz-json-1.1 Content-Length: <PayloadSizeBytes>
Date: <Date>
{ "Result": true }
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following:
• AWS Command Line Interface
• AWS SDK for .NET
• AWS SDK for C++
• AWS SDK for Go
• AWS SDK for Java V2
• AWS SDK for JavaScript
• AWS SDK for PHP V3
• AWS SDK for Python
• AWS SDK for Ruby V3
UntagResource
UntagResource
Removes one or more tags from the specified EventBridge resource. In Amazon EventBridge (CloudWatch Events), rules and event buses can be tagged.
Request Syntax
{
"ResourceARN": "string", "TagKeys": [ "string" ] }
Request Parameters
For information about the parameters that are common to all actions, see Common Parameters (p. 247).
The request accepts the following data in JSON format.
ResourceARN (p. 157)
The ARN of the EventBridge resource from which you are removing tags.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 1600.
Required: Yes TagKeys (p. 157)
The list of tag keys to remove from the resource.
Type: Array of strings
Length Constraints: Minimum length of 1. Maximum length of 128.
Required: Yes
Response Elements
If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body.
Errors
For information about the errors that are common to all actions, see Common Errors (p. 249).
ConcurrentModificationException
There is concurrent modification on a rule, target, archive, or replay.
HTTP Status Code: 400 InternalException
This exception occurs due to unexpected causes.
Examples
HTTP Status Code: 500 ManagedRuleException
This rule was created by an AWS service on behalf of your account. It is managed by that service.
If you see this error in response to DeleteRule or RemoveTargets, you can use the Force
parameter in those calls to delete the rule or remove targets from the rule. You cannot modify these managed rules by using DisableRule, EnableRule, PutTargets, PutRule, TagResource, or UntagResource.
HTTP Status Code: 400 ResourceNotFoundException
An entity that you specified does not exist.
HTTP Status Code: 400
Examples
Removes two tags from an EventBridge rule
The following is an example of an UntagResource request.
Sample Request
POST / HTTP/1.1
Host: events.<region>.<domain>
x-amz-Date: <Date>
Authorization: AWS4-HMAC-SHA256 Credential=<Credential>,
SignedHeaders=content-type;date;host;user-agent;x-amz-date;x-amz-target;x-amzn-requestid, Signature=<Signature>
{ "ResourceARN": "arn:aws:events:us-west-1:123456789012:rule/test", "TagKeys": [ "CostCenter", "Team" ]
}
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following:
• AWS Command Line Interface
• AWS SDK for .NET
• AWS SDK for C++
• AWS SDK for Go
• AWS SDK for Java V2
• AWS SDK for JavaScript
• AWS SDK for PHP V3
• AWS SDK for Python
• AWS SDK for Ruby V3
See Also
UpdateApiDestination
UpdateApiDestination
Updates an API destination.
Request Syntax
{
"ConnectionArn": "string", "Description": "string", "HttpMethod": "string",
"InvocationEndpoint": "string",
"InvocationRateLimitPerSecond": number, "Name": "string"
}
Request Parameters
For information about the parameters that are common to all actions, see Common Parameters (p. 247).
The request accepts the following data in JSON format.
ConnectionArn (p. 160)
The ARN of the connection to use for the API destination.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 1600.
Pattern: ^arn:aws([a-z]|\-)*:events:([a-z]|\d|\-)*:([0-9]{12})?:connection\/
[\.\-_A-Za-z0-9]+\/[\-A-Za-z0-9]+$
Required: No Description (p. 160)
The name of the API destination to update.
Type: String
Length Constraints: Maximum length of 512.
Pattern: .*
Required: No HttpMethod (p. 160)
The method to use for the API destination.
Type: String
Valid Values: POST | GET | HEAD | OPTIONS | PUT | PATCH | DELETE Required: No
InvocationEndpoint (p. 160)
The URL to the endpoint to use for the API destination.
Response Syntax
Type: String
Length Constraints: Minimum length of 1. Maximum length of 2048.
Pattern: ^((%[0-9A-Fa-f]{2}|[-()_.!~*';/?:@\x26=+$,A-Za-z0-9])+)([).!';/?:,])?
$
Required: No
InvocationRateLimitPerSecond (p. 160)
The maximum number of invocations per second to send to the API destination.
Type: Integer
Valid Range: Minimum value of 1.
Required: No Name (p. 160)
The name of the API destination to update.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 64.
Pattern: [\.\-_A-Za-z0-9]+
Required: Yes
Response Syntax
{
"ApiDestinationArn": "string", "ApiDestinationState": "string", "CreationTime": number,
"LastModifiedTime": number }
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
ApiDestinationArn (p. 161)
The ARN of the API destination that was updated.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 1600.
Pattern: ^arn:aws([a-z]|\-)*:events:([a-z]|\d|\-)*:([0-9]{12})?:api-destination\/[\.\-_A-Za-z0-9]+\/[\-A-Za-z0-9]+$
ApiDestinationState (p. 161)
The state of the API destination that was updated.
Errors
Type: String
Valid Values: ACTIVE | INACTIVE CreationTime (p. 161)
A time stamp for the time that the API destination was created.
Type: Timestamp LastModifiedTime (p. 161)
A time stamp for the time that the API destination was last modified.
Type: Timestamp
Errors
For information about the errors that are common to all actions, see Common Errors (p. 249).
ConcurrentModificationException
There is concurrent modification on a rule, target, archive, or replay.
HTTP Status Code: 400 InternalException
This exception occurs due to unexpected causes.
HTTP Status Code: 500 LimitExceededException
The request failed because it attempted to create resource beyond the allowed service quota.
HTTP Status Code: 400 ResourceNotFoundException
An entity that you specified does not exist.
HTTP Status Code: 400
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following:
• AWS Command Line Interface
• AWS SDK for .NET
• AWS SDK for C++
• AWS SDK for Go
• AWS SDK for Java V2
• AWS SDK for JavaScript
• AWS SDK for PHP V3
• AWS SDK for Python
• AWS SDK for Ruby V3
UpdateArchive
UpdateArchive
Updates the specified archive.
Request Syntax
{ "ArchiveName": "string", "Description": "string", "EventPattern": "string", "RetentionDays": number }
Request Parameters
For information about the parameters that are common to all actions, see Common Parameters (p. 247).
The request accepts the following data in JSON format.
ArchiveName (p. 163)
The name of the archive to update.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 48.
Pattern: [\.\-_A-Za-z0-9]+
Required: Yes Description (p. 163)
The description for the archive.
Type: String
Length Constraints: Maximum length of 512.
Pattern: .*
Required: No EventPattern (p. 163)
The event pattern to use to filter events sent to the archive.
Type: String Required: No RetentionDays (p. 163)
The number of days to retain events in the archive.
Type: Integer
Valid Range: Minimum value of 0.
Required: No
Response Syntax
Response Syntax
{ "ArchiveArn": "string", "CreationTime": number, "State": "string", "StateReason": "string"
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
ArchiveArn (p. 164) The ARN of the archive.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 1600.
Pattern: ^arn:aws([a-z]|\-)*:events:([a-z]|\d|\-)*:([0-9]{12})?:.+\/.+$
CreationTime (p. 164)
The time at which the archive was updated.
Type: Timestamp State (p. 164)
The state of the archive.
Type: String
Valid Values: ENABLED | DISABLED | CREATING | UPDATING | CREATE_FAILED | UPDATE_FAILED
StateReason (p. 164)
The reason that the archive is in the current state.
Type: String
Length Constraints: Maximum length of 512.
Pattern: .*
Errors
For information about the errors that are common to all actions, see Common Errors (p. 249).
ConcurrentModificationException
There is concurrent modification on a rule, target, archive, or replay.
HTTP Status Code: 400
See Also
InternalException
This exception occurs due to unexpected causes.
HTTP Status Code: 500 InvalidEventPatternException
The event pattern is not valid.
HTTP Status Code: 400 LimitExceededException
The request failed because it attempted to create resource beyond the allowed service quota.
HTTP Status Code: 400 ResourceNotFoundException
An entity that you specified does not exist.
HTTP Status Code: 400
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following:
• AWS Command Line Interface
• AWS SDK for .NET
• AWS SDK for C++
• AWS SDK for Go
• AWS SDK for Java V2
• AWS SDK for JavaScript
• AWS SDK for PHP V3
• AWS SDK for Python
• AWS SDK for Ruby V3
UpdateConnection
UpdateConnection
Updates settings for a connection.
Request Syntax
{ "AuthorizationType": "string", "AuthParameters": {
"ApiKeyAuthParameters": {
"InvocationHttpParameters": { "BodyParameters": [
"AuthorizationEndpoint": "string", "ClientParameters": {
Request Parameters
{
"IsValueSecret": boolean, "Key": "string",
"Value": "string"
} ] } } },
"Description": "string", "Name": "string"
}
Request Parameters
For information about the parameters that are common to all actions, see Common Parameters (p. 247).
The request accepts the following data in JSON format.
AuthorizationType (p. 166)
The type of authorization to use for the connection.
Type: String
Valid Values: BASIC | OAUTH_CLIENT_CREDENTIALS | API_KEY Required: No
AuthParameters (p. 166)
The authorization parameters to use for the connection.
Type: UpdateConnectionAuthRequestParameters (p. 241) object Required: No
Description (p. 166)
A description for the connection.
Type: String
Length Constraints: Maximum length of 512.
Pattern: .*
Required: No Name (p. 166)
The name of the connection to update.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 64.
Pattern: [\.\-_A-Za-z0-9]+
Required: Yes
Response Syntax
Response Syntax
{ "ConnectionArn": "string", "ConnectionState": "string", "CreationTime": number, "LastAuthorizedTime": number, "LastModifiedTime": number }
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
ConnectionArn (p. 168)
The ARN of the connection that was updated.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 1600.
Pattern: ^arn:aws([a-z]|\-)*:events:([a-z]|\d|\-)*:([0-9]{12})?:connection\/
[\.\-_A-Za-z0-9]+\/[\-A-Za-z0-9]+$
ConnectionState (p. 168)
The state of the connection that was updated.
Type: String
Valid Values: CREATING | UPDATING | DELETING | AUTHORIZED | DEAUTHORIZED | AUTHORIZING | DEAUTHORIZING
CreationTime (p. 168)
A time stamp for the time that the connection was created.
Type: Timestamp LastAuthorizedTime (p. 168)
A time stamp for the time that the connection was last authorized.
Type: Timestamp LastModifiedTime (p. 168)
A time stamp for the time that the connection was last modified.
Type: Timestamp
Errors
For information about the errors that are common to all actions, see Common Errors (p. 249).
ConcurrentModificationException
There is concurrent modification on a rule, target, archive, or replay.
See Also
HTTP Status Code: 400 InternalException
This exception occurs due to unexpected causes.
HTTP Status Code: 500 LimitExceededException
The request failed because it attempted to create resource beyond the allowed service quota.
HTTP Status Code: 400 ResourceNotFoundException
An entity that you specified does not exist.
HTTP Status Code: 400
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following:
• AWS Command Line Interface
• AWS SDK for .NET
• AWS SDK for C++
• AWS SDK for Go
• AWS SDK for Java V2
• AWS SDK for JavaScript
• AWS SDK for PHP V3
• AWS SDK for Python
• AWS SDK for Ruby V3