Please look at the list of the countries that have the visa exemption agreement with Japan. If your country is included in the list, you usually do not need to apply for an entry visa to Japan.
If your country is not included in the list, you need to obtain a short-term stay visa (“tanki-shouyou visa” in Japanese) from the embassy of Japan in your country.
Read carefully the Japanese visa guide provided by the ministry of foreign affairs. Please be informed that it is the embassy of Japan in your country that makes a decision on issuing a visa.
Usually the procedure takes considerably long, it would be recommended that you begin the procedure as early as possible.