Trim api key.