## 2 Materials and Methods
### Determination of Adsorption Properties of Functionalized Magnetic Polystyrene Microspheres  
Sample pretreatment of melamine: Samples (2 g, accurate to 0.01 g) were weighed in 15 mL scale test tubes. After 7 mL of anhydrous acetonitrile was added, the oscillation and vortex were performed for 2 min. Then, 1 mL of ethylenediamine was added to perform volume metering with ultrapure water to 10 mL, followed by oscillation and vortex for 2 min. Subsequently, ultrasonic extraction was performed for 15 min at 8000 r/min and 4 \({}^{\circ}\)C under freezing conditions for 8 min. The mixture was filtered for later use. Next, 2 mL of the mixture was taken under nitrogen drying at 80 \({}^{\circ}\)C to be re-dissolved with 1 mL of 20% methanol solution for testing on the machine.  
Chromatographic conditions: The chromatographic column was the TM HILIC column (2.6 \(\upmu\)m, 100 mm \(\times\) 2.1 mm); the column temperature was 40 \({}^{\circ}\)C. The mobile phase A was 2 mmol/L ammonium formate, and the mobile phase B was acetonitrile; gradient program: 0-2 min, 10% A; 2-4 min, 10%-50% A; 4-5 min, 50% A; 5-5.2 min, 50%-10% A; 5.2-7 min, 10% A. Sample volume: 10 \(\upmu\)L; low rate: 0.4 mL/min.  
Mass spectrometry conditions: The positive ion ionization (ESI\({}^{+}\)) from the electrospray ion source was used to select quantitative ions (127.1 \(>\) 85.2) and qualitative ions (127.1 \(>\) 68.4). The capillary voltage was set to 3500 V, and the ion source temperature was 350 \({}^{\circ}\)C. The pyrolysis voltage was 77 V; the collision energy m/z 127.1 \(>\) 85.2 was 17 V, and the collision energy m/z 127.1 \(>\) 68.4 was 28 V.  
Sample pretreatment of \(\beta\)-agonists: Samples (2 g, accurate to 0.01 g) were weighed in a 50 mL centrifuge tube. After 8 mL of sodium acetate buffer was added and fully mixed, 50 \(\upmu\)L of \(\beta\)-glucuronidase/arylsulfatase was added for mixing. Then, the samples were hydrolyzed in a water bath at 37 \({}^{\circ}\)C for 12 h. Subsequently, 100 \(\upmu\)L of 10 ng/mL internal standard solution was added to these samples. The cover was oscillated in a horizontal oscillator for 15 min and then centrifuged at 5000 r/min for 10 min. After that, 4 mL of supernatant was transferred to another 50 mL centrifuge tube, followed by the addition of 5 mL of 0.1 mol/L perchloric acid solution and even mixing. The pH was adjusted to 1 \(\pm\) 0.3 with perchloric acid. After the centrifugation at 5000 r/min for 10 min, all the supernatant (about 10 mL) was transferred to another 50 mL centrifuge tube, and the pH was adjusted to 11 with 10 mol/L sodium hydroxide solution. Next, the mixed solution containing 10 mL of saturated sodium chloride solution and 10 mL of isopropyl alcohol-ethyl acetate (6 + 4) was added for full extraction, followed by the centrifugation at 5000 r/min for 10 min. All organic phases were transferred and dried with nitrogen in a water bath at 40 \({}^{\circ}\)C. After that, 5 mL of sodium acetate buffer solution was added for ultrasonic mixing so that the residue could be fully dissolved for later use.  
Chromatographic conditions: The chromatographic column was the Kinetex LC Column C\({}_{18}\) (2.6 \(\upmu\)m, 100 mm \(\times\) 2.1 mm); the column temperature was 30 \({}^{\circ}\)C; the mobile phase A was 0.1% formic acid water, and the mobile phase B was acetonitrile; gradient program: 0-1 min, 97% A; 1-3.5 min, 97-70% A; 3.5-4.5 min, 70% A; 4.5-6.4 min, 70-25% A; 6.4-6.5 min, 25-5% A; 6.5-8.2 min, 5% A; 8.2-8.3 min, 5-97% A; 8.3-10 min, 97% A. Sample volume: 10 \(\upmu\)L; flow rate: 0.4 mL/min.  
Mass spectrometry conditions: The electrospray ion source (ESI\({}^{+}\)) was used at the ion source temperature of 500 \({}^{\circ}\)C, a capillary voltage of 5500 V and an atomizer flow rate of 55 L/min. The mass spectrometry parameters of three \(\beta\)-agonists are listed in Table 1.