Belelros, the function you want is GetSpellLink, which will return a spell link string from its spell ID number, which you can then set in a text string, or send to someone in a chat message. For example, the following function will output the spell link to your default chat frame for a given spell ID:
Code:
function ShowSpellLink(spellID)
local spellLink = GetSpellLink(spellID or 0) or "<no spellLink found>";
DEFAULT_CHAT_FRAME:AddMessage(spellLink);
end