feat: add Instagram, Facebook, TikTok and LinkedIn slots
Organic social channels per client in the agency hub, separate from paid Meta Ads. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
36
sql/social_integrations.sql
Normal file
36
sql/social_integrations.sql
Normal file
@@ -0,0 +1,36 @@
|
||||
-- Organic social connection slots per tenant
|
||||
-- Idempotent. (Distinct from meta_ads / paid.)
|
||||
|
||||
alter table public.integrations drop constraint if exists integrations_provider_check;
|
||||
alter table public.integrations
|
||||
add constraint integrations_provider_check
|
||||
check (provider in (
|
||||
'meta_ads',
|
||||
'google_ads',
|
||||
'ga4',
|
||||
'search_console',
|
||||
'tag_manager',
|
||||
'clientify',
|
||||
'klaviyo',
|
||||
'mailchimp',
|
||||
'google_drive',
|
||||
'wordpress',
|
||||
'prestashop',
|
||||
'shopify',
|
||||
'instagram',
|
||||
'facebook',
|
||||
'tiktok',
|
||||
'linkedin'
|
||||
));
|
||||
|
||||
insert into public.integrations (tenant_id, provider, status, label)
|
||||
select t.id, p.provider, 'disconnected', p.label
|
||||
from public.tenants t
|
||||
cross join (
|
||||
values
|
||||
('instagram', 'Instagram'),
|
||||
('facebook', 'Facebook Page'),
|
||||
('tiktok', 'TikTok'),
|
||||
('linkedin', 'LinkedIn')
|
||||
) as p(provider, label)
|
||||
on conflict (tenant_id, provider) do nothing;
|
||||
Reference in New Issue
Block a user