PHP-Api: Track pageview with URL and channel (source and medium)

Hello!

I want to use the PHP Tracking Client https://developer.matomo.org/api-reference/PHP-Matomo-Tracker to add a pageview for a certain URL, but also define the source and medium the pageview came from. For example, an organic hit from google would be:
source: google.com
medium: organic

I found MatomoTracker::doTrackPageView, but the only parameter is $documentTitle - but no URL, and no source and no medium.

How is it done? I could add &url= myself to the generated matomo-URL to set the URL for the pageview (if this is the correct way), but how do I transmit the source and medium to matomo?