Can custom scripts determine UTM parameters for order source feedback?

Our store is connected to a third-party affiliate marketing platform, but through observation, shopify will synchronize orders that are not affiliate marketing platforms to the affiliate marketing platform. Can you use the code on the Settings→Checkout→Custom Script→Order Status page to determine the UTM parameters of the order source, and then perform order feedback and synchronization according to the fixed UTM parameters