
For your issue, run the below command before running the Register-SPWorkflowService command:
$config = (Get-SPSecurityTokenServiceConfig)
$config.AllowOAuthOverHttp = $true
$config.AllowMetaDataOverHttp = $true
$config.Update()
After that try rerun the command:
Register-SPWorkflowService -SPSite "http://myportal.mydomain.com" -WorkflowHostUri http://spwfm.mydomain.com:12291 –AllowOAuthHttp
If an Answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.