I get the following error when trying to send an SNS notification. What am I doing wrong here?
Config:
# aws notification
aws:
notify:
- service: sns
aws_access_key_id: < access_key_id >
aws_secret_access_key: < access_key_secret >
region_name: us-east-1
Error:
2019-12-12 21:25:47 INFO (MainThread) [homeassistant.components.discovery] Unknown service discovered: spotify_connect {'host': '192.168.1.30', 'port': 36713, 'hostname': 'b68393bb25cbda2-0.local.', 'properties': {'CPath': '/zc/0', 'VERSION': '1.0', 'Stack': 'SP'}}
2019-12-12 21:27:20 INFO (MainThread) [homeassistant.components.automation] Executing Basement Leak Alert
2019-12-12 21:27:20 INFO (MainThread) [homeassistant.helpers.script] Script Basement Leak Alert: Running script
2019-12-12 21:27:20 INFO (MainThread) [homeassistant.helpers.script] Script Basement Leak Alert: Executing step call service
2019-12-12 21:27:21 ERROR (MainThread) [homeassistant.components.automation] Error while executing automation automation.basement_leak_alert. Unknown error for call_service at pos 1:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/automation/__init__.py", line 443, in action
await script_obj.async_run(variables, context)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 190, in async_run
await self._handle_action(action, variables, context)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 273, in _handle_action
await self._actions[_determine_action(action)](action, variables, context)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 355, in _async_call_service
context=context,
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 97, in async_call_from_config
domain, service_name, service_data, blocking=blocking, context=context
File "/usr/src/homeassistant/homeassistant/core.py", line 1235, in async_call
await asyncio.shield(self._execute_service(handler, service_call))
File "/usr/src/homeassistant/homeassistant/core.py", line 1260, in _execute_service
await handler.func(service_call)
File "/usr/src/homeassistant/homeassistant/components/notify/__init__.py", line 120, in async_notify_message
await notify_service.async_send_message(**kwargs)
File "/usr/src/homeassistant/homeassistant/components/aws/notify.py", line 197, in async_send_message
await asyncio.gather(*tasks)
File "/usr/local/lib/python3.7/site-packages/aiobotocore/client.py", line 92, in _make_api_call
operation_model, request_dict, request_context)
File "/usr/local/lib/python3.7/site-packages/aiobotocore/client.py", line 113, in _make_request
request_dict)
File "/usr/local/lib/python3.7/site-packages/aiobotocore/endpoint.py", line 226, in _send_request
request = self.create_request(request_dict, operation_model)
File "/usr/local/lib/python3.7/site-packages/botocore/endpoint.py", line 116, in create_request
operation_name=operation_model.name)
File "/usr/local/lib/python3.7/site-packages/botocore/hooks.py", line 356, in emit
return self._emitter.emit(aliased_event_name, **kwargs)
File "/usr/local/lib/python3.7/site-packages/botocore/hooks.py", line 228, in emit
return self._emit(event_name, kwargs)
File "/usr/local/lib/python3.7/site-packages/botocore/hooks.py", line 211, in _emit
response = handler(**kwargs)
File "/usr/local/lib/python3.7/site-packages/botocore/signers.py", line 90, in handler
return self.sign(operation_name, request)
File "/usr/local/lib/python3.7/site-packages/botocore/signers.py", line 157, in sign
auth.add_auth(request)
File "/usr/local/lib/python3.7/site-packages/botocore/auth.py", line 357, in add_auth
raise NoCredentialsError
botocore.exceptions.NoCredentialsError: Unable to locate credentials