Closed monde closed 10 months ago
internal reference https://oktainc.atlassian.net/browse/OKTA-658719
@monde I'm curious where this is happening myself. I dove through the code some and found that code calling the (*RequestExecutor).NewRequest(...)
method always gets the UserAgent assigned. It might be a matter of that method not being called at one point in the API.
Deep diving here to see what I can come up with.
It could also be in that same file in this function which is autogenerated.
It could also be in that same file in this function which is autogenerated.
Yes, for the v3 client in the template you've referenced.
The v2 okta-sdk-golang client is vendor'd into the okta terraform provider, this where I hacked that in: https://github.com/okta/terraform-provider-okta/blob/master/sdk/v2_requestExecutor.go#L295C40-L295C40
Describe the bug?
The
POST /oauth2/v1/token
OAuth token request is not adding a User-Agent header as occurs with all other API requests.Perhaps add a unit test for this.
What is expected to happen?
User-Agent header added
What is the actual behavior?
It isn't added
Reproduction Steps?
Make an OAuth request
Additional Information?
No response
Golang Version
any
SDK Version
all
OS version
No response