API:GetCurrentRealm

Command
name = GetCurrentRealm

Description
Get current server.

Note: Sometimes (patch depending) this includes decorations like colors codes.

Example
Prints name of current server into chat frame /script DEFAULT_CHAT_FRAME:AddMessage(GetCurrentRealm)

See
API:GetCurrentServerList