Shulchan Arukh, Orach Chayim Siman 384
Can copy this into an AI, or connect the whole library to your assistant. For deeper learning, you can directly use the original seforim, sites, and apps.
עכו"ם הנכנס לשם אכסנאות אם נכנס שלא ברשות אינו אוסר לעולם ואם נכנס ברשות אם הוא רגיל לבא אוסר מיד ואם אינו רגיל אינו אוסר עד לאחר שלשים יום:
A non-Jew who enters as a guest: if he entered without permission, he never prevents [carrying]. If he entered with permission — if he regularly comes, he prevents [carrying] immediately. If he does not regularly come, he does not prevent [carrying] until after thirty days.
אנשי חיל המלך שנכנסו בבתי היהודים בין בחזקה בין ברצון אם יש לבעלי בתים באותם מקומות שנכנסו העכו"ם כלים שאסור לטלטלם בשבת אינם אוסרים עליהם:
The king's soldiers who entered into the homes of Jews, whether by force or willingly — if the homeowners have in those places where the non-Jews entered utensils that are forbidden to move on Shabbat, [the non-Jews] do not prevent [carrying] upon them.