Add the bearer authentication#313
Conversation
9c591bc to
ffe9be5
Compare
|
Hi @marek-veber, thank you for the PR. I added some comments. Instead of asking for auth type from the UI, I think It might be better to introduce a new env Also, we need to make sure this works for both cloud and on-premises jira server. |
| return nil | ||
| }, | ||
| }) | ||
| if !c.value.bearer { |
There was a problem hiding this comment.
Don't we need similar logic for cloud server too?
| Server string | ||
| Login string | ||
| APIToken string | ||
| Bearer *bool |
There was a problem hiding this comment.
Enum types would be better for this usecase instead of a boolean flag. This will make it easy to introduce other auth types if needed.
type AuthType string
const (
AuthTypeBasic AuthType = "basic"
AuthTypeBearer AuthType = "bearer"
)And the config and client struct downstream can have AuthType field
|
Thanks for your comments, I will implement the introduced changes. |
Closes 312