GDPR defines conditions for proper consent in Article 7 and recited in Recital 32, which could be helpful:
Consent should be given by a clear affirmative act establishing a
freely given, specific, informed and unambiguous indication of the
data subject’s agreement to the processing of personal data relating
to him or her, such as by a written statement, including by electronic
means, or an oral statement. This could include ticking a box when
visiting an internet website, choosing technical settings for
information society services or another statement or conduct which
clearly indicates in this context the data subject’s acceptance of the
proposed processing of his or her personal data. Silence, pre-ticked
boxes or inactivity should not therefore constitute consent. Consent
should cover all processing activities carried out for the same
purpose or purposes. When the processing has multiple purposes,
consent should be given for all of them. If the data subject’s
consent is to be given following a request by electronic means, the
request must be clear, concise and not unnecessarily disruptive to the
use of the service for which it is provided.
Basically, whichever way you choose that lets users understand what they consent to, works. But you definitely should not bundle data processing with you terms and conditions.
@Bobby Tables's suggestion is what I usually go for, but you also should consider using "I consent to..." instead of "I agree to..." as agreeing could mean more like two sides agreeing on something, whereas consenting is one side giving explicit permission to the other side, which GDPR seems to enforce. But that might be a cultural/language thing, so think of whichever way best communicates what you want from the user in accordance to GDPR.