2021/12/08 - AWS IoT - 4 updated api methods
Changes This release allows customer to enable caching of custom authorizer on HTTP protocol for clients that use persistent or Keep-Alive connection in order to reduce the number of Lambda invocations.
{'enableCachingForHttp': 'boolean'}
Creates an authorizer.
Requires permission to access the CreateAuthorizer action.
See also: AWS API Documentation
Request Syntax
client.create_authorizer( authorizerName='string', authorizerFunctionArn='string', tokenKeyName='string', tokenSigningPublicKeys={ 'string': 'string' }, status='ACTIVE'|'INACTIVE', tags=[ { 'Key': 'string', 'Value': 'string' }, ], signingDisabled=True|False, enableCachingForHttp=True|False )
string
[REQUIRED]
The authorizer name.
string
[REQUIRED]
The ARN of the authorizer's Lambda function.
string
The name of the token key used to extract the token from the HTTP headers.
dict
The public keys used to verify the digital signature returned by your custom authentication service.
(string) --
(string) --
string
The status of the create authorizer request.
list
Metadata which can be used to manage the custom authorizer.
(dict) --
A set of key/value pairs that are used to manage the resource.
Key (string) -- [REQUIRED]
The tag's key.
Value (string) --
The tag's value.
boolean
Specifies whether IoT validates the token signature in an authorization request.
boolean
When true, the result from the authorizer’s Lambda function is cached for clients that use persistent HTTP connections. The results are cached for the time specified by the Lambda function in refreshAfterInSeconds. This value does not affect authorization of clients that use MQTT connections.
The default value is false.
dict
Response Syntax
{ 'authorizerName': 'string', 'authorizerArn': 'string' }
Response Structure
(dict) --
authorizerName (string) --
The authorizer's name.
authorizerArn (string) --
The authorizer ARN.
{'authorizerDescription': {'enableCachingForHttp': 'boolean'}}
Describes an authorizer.
Requires permission to access the DescribeAuthorizer action.
See also: AWS API Documentation
Request Syntax
client.describe_authorizer( authorizerName='string' )
string
[REQUIRED]
The name of the authorizer to describe.
dict
Response Syntax
{ 'authorizerDescription': { 'authorizerName': 'string', 'authorizerArn': 'string', 'authorizerFunctionArn': 'string', 'tokenKeyName': 'string', 'tokenSigningPublicKeys': { 'string': 'string' }, 'status': 'ACTIVE'|'INACTIVE', 'creationDate': datetime(2015, 1, 1), 'lastModifiedDate': datetime(2015, 1, 1), 'signingDisabled': True|False, 'enableCachingForHttp': True|False } }
Response Structure
(dict) --
authorizerDescription (dict) --
The authorizer description.
authorizerName (string) --
The authorizer name.
authorizerArn (string) --
The authorizer ARN.
authorizerFunctionArn (string) --
The authorizer's Lambda function ARN.
tokenKeyName (string) --
The key used to extract the token from the HTTP headers.
tokenSigningPublicKeys (dict) --
The public keys used to validate the token signature returned by your custom authentication service.
(string) --
(string) --
status (string) --
The status of the authorizer.
creationDate (datetime) --
The UNIX timestamp of when the authorizer was created.
lastModifiedDate (datetime) --
The UNIX timestamp of when the authorizer was last updated.
signingDisabled (boolean) --
Specifies whether IoT validates the token signature in an authorization request.
enableCachingForHttp (boolean) --
When true, the result from the authorizer’s Lambda function is cached for the time specified in refreshAfterInSeconds. The cached result is used while the device reuses the same HTTP connection.
{'authorizerDescription': {'enableCachingForHttp': 'boolean'}}
Describes the default authorizer.
Requires permission to access the DescribeDefaultAuthorizer action.
See also: AWS API Documentation
Request Syntax
client.describe_default_authorizer()
dict
Response Syntax
{ 'authorizerDescription': { 'authorizerName': 'string', 'authorizerArn': 'string', 'authorizerFunctionArn': 'string', 'tokenKeyName': 'string', 'tokenSigningPublicKeys': { 'string': 'string' }, 'status': 'ACTIVE'|'INACTIVE', 'creationDate': datetime(2015, 1, 1), 'lastModifiedDate': datetime(2015, 1, 1), 'signingDisabled': True|False, 'enableCachingForHttp': True|False } }
Response Structure
(dict) --
authorizerDescription (dict) --
The default authorizer's description.
authorizerName (string) --
The authorizer name.
authorizerArn (string) --
The authorizer ARN.
authorizerFunctionArn (string) --
The authorizer's Lambda function ARN.
tokenKeyName (string) --
The key used to extract the token from the HTTP headers.
tokenSigningPublicKeys (dict) --
The public keys used to validate the token signature returned by your custom authentication service.
(string) --
(string) --
status (string) --
The status of the authorizer.
creationDate (datetime) --
The UNIX timestamp of when the authorizer was created.
lastModifiedDate (datetime) --
The UNIX timestamp of when the authorizer was last updated.
signingDisabled (boolean) --
Specifies whether IoT validates the token signature in an authorization request.
enableCachingForHttp (boolean) --
When true, the result from the authorizer’s Lambda function is cached for the time specified in refreshAfterInSeconds. The cached result is used while the device reuses the same HTTP connection.
{'enableCachingForHttp': 'boolean'}
Updates an authorizer.
Requires permission to access the UpdateAuthorizer action.
See also: AWS API Documentation
Request Syntax
client.update_authorizer( authorizerName='string', authorizerFunctionArn='string', tokenKeyName='string', tokenSigningPublicKeys={ 'string': 'string' }, status='ACTIVE'|'INACTIVE', enableCachingForHttp=True|False )
string
[REQUIRED]
The authorizer name.
string
The ARN of the authorizer's Lambda function.
string
The key used to extract the token from the HTTP headers.
dict
The public keys used to verify the token signature.
(string) --
(string) --
string
The status of the update authorizer request.
boolean
When true, the result from the authorizer’s Lambda function is cached for the time specified in refreshAfterInSeconds. The cached result is used while the device reuses the same HTTP connection.
dict
Response Syntax
{ 'authorizerName': 'string', 'authorizerArn': 'string' }
Response Structure
(dict) --
authorizerName (string) --
The authorizer name.
authorizerArn (string) --
The authorizer ARN.