How to specify separate Git LFS credentials?

I need to be able to specify separate credentials for Git LFS to be able to authenticate against Artifactory. In JENKINS-47531, Mark Waite states that no code changes will be made to the enable this and suggests using the git credentials binding for this “advanced use case”.

I don’t understand how to use the git credentials binding to provide extra credentials for the LFS aspects of either the default checkout or when calling checkout. Even if I delay the LFS pull until after cloning, Jenkins still executes the pull before my manual pipeline step that uses the credential binding and thus fails.

I’ve not been able to find any examples of how to use this binding to execute the git clone with separate LFS credentials. I’m surprised that the plugin won’t be updated to provide support for this and that the author suggests using an approach that only supports shell/batch.

Please could someone provide an example declarative pipeline that uses different credentials for the git clone and git lfs pull?