The present invention provides a series of compounds of pyrrolopyrimidine ring used as agonists of TLR7 and applied in prevention or therapy of allergic rhinitis and asthma. Particularly, the present invention provides compounds as shown in Formula (I) or its pharmaceutically acceptable salts.本發明公開了一類新穎的作為TLR7激動劑的吡咯並嘧啶環化合物或其藥學上可接受的鹽,用於過敏性鼻炎和哮喘的預防或治療。具體公開了式(I)所示化合物或其藥學上可接受的鹽。