API created task not notified to Slack

When I create a new task using the API, notifications do not seem to be sent to Slack. If I create a task via the web interface, I get the Slack notification. Is there a way to get the Slack notification to work when when the task is created via the API?