Your first post indicates you have refugee status.
What country are you from and what country are you currently in? Do you have a passport? An invitation from your friend is irrelevant. You will need either a TRV or an eTA to get to Canada. Both will require you to disclose your status in the country you currently reside in. If you can obtain a travel document, you can claim at the airport. Whether it is accepted or not will depend on compelling. Evidence of your claim against both countries and your status as a refugee claimant or a refugee in your current country. Be aware, if your claim is rejected, they return you to your country of origin.