The sample type digestive tract medicine releasing and sampling device includes a shell to form sealed cavity; an inwards non-return valve communicated with the inside of the shell in the front end of the shell; a magnetic switch, a power source, a power source managing and controlling unit, a driving unit, a sealing layer and a rubber piston inside the shell; and an outer trigger. After the triggering signal the outer trigger sends is received and treated by the signal control unit, the driving unit relieves the stored mechanical energy based on the command to drive the piston, the stored medicine is exhausted through an outwards non-return valve to the digestive tract, and liquid enters the liquid storing bin through the opened inwards non-return valve. After the piston reaches to the top of the shell, the stroke ends, two valves are closed automatically to separate the collected liquid inside the liquid storing bin from outside. The medicine releasing and sampling device has high reliability, low power consumption, long stand-by time and simple structure.