Purpose
This KB documents the internal process for enabling and managing the Conversation Auto-Close setting in Aerialink Conversations. This setting automatically closes inactive conversations after a defined period of time.
Overview
- Auto-close is an account-level setting (Company level).
- The configuration is applied directly in the Conversations database.
- Auto-close is enforced via a scheduled database job using a stored procedure.
Required Information
Before making the change, confirm:
- Company ID
- Company Name
- Requested auto-close duration (in hours)
Example:
- Company ID: 2443
- Company Name: Kent OH
- Auto-close duration: 12 hours
Database Configuration Steps
Step 1: Verify Current Setting
select id, name, auto_close_hours from companies where id = '2443';
Step 2: Update Auto-Close Duration
Set the auto_close_hours value to the requested number of hours.
update companies set auto_close_hours = 12 where id = '2443';
- A value greater than 0 enables auto-close
- A value of 0 or NULL disables auto-close
Auto-Close Processing Logic
Auto-close is executed by the scheduled stored procedure:
CREATE PROCEDURE auto_close_conversations()
BEGIN
UPDATE conversations_production.conversations conv
INNER JOIN conversations_production.companies comp
ON conv.company_id = comp.id
SET
conv.status = 'closed',
conv.updated_at = NOW(),
conv.is_last_updated_by_phone = 0
WHERE
comp.auto_close_hours > 0
AND conv.status != 'closed'
AND conv.updated_at < DATE_ADD(NOW(), INTERVAL (comp.auto_close_hours * -1) HOUR);
SELECT ROW_COUNT();
END;
Logic Summary
- The procedure checks all companies where
auto_close_hours > 0 - Conversations are closed if:
- Status is not already
closed - Last update exceeds the configured inactivity window
- Status is not already
Operational Notes
- Tier-1/Tier-2 Support should not perform this change
- Requires Engineering / DB access (e.g., JR / Srikanth)
Example Implementation (Reference)
- Customer: Land O’Lakes
- Company Name: Kent OH
- Company ID: 2443
- Auto-close hours: 12
- Status: Successfully configured and confirmed
NOTE : It is not configurable via UI, since we are anyhow sunset the conversations product.
Comments
0 comments
Please sign in to leave a comment.