-- Add LINK token to tokens table for ChainID 138
-- Uses deployed MockLinkToken address on ChainID 138

INSERT INTO tokens (chain_id, address, type, name, symbol, decimals, verified, description, logo_url, website_url)
VALUES (
    138,
    '0xb7721dD53A8c629d9f1Ba31a5819AFe250002b03',
    'ERC20',
    'Chainlink Token',
    'LINK',
    18,
    true,
    'Official Chainlink LINK token from Ethereum Mainnet. Used for CCIP fees and Chainlink services.',
    'https://raw.githubusercontent.com/chainlink/chainlink-docs/main/docs/images/chainlink-logo.svg',
    'https://chain.link/'
)
ON CONFLICT (chain_id, address) DO UPDATE SET
    name = EXCLUDED.name,
    symbol = EXCLUDED.symbol,
    decimals = EXCLUDED.decimals,
    verified = EXCLUDED.verified,
    description = EXCLUDED.description,
    logo_url = EXCLUDED.logo_url,
    website_url = EXCLUDED.website_url,
    updated_at = NOW();

