mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
feat: add flag for token lifetime (#5385)
This commit is contained in:
+2
-1
@@ -40,7 +40,8 @@ const (
|
||||
)
|
||||
|
||||
type CreateTokenRequest struct {
|
||||
Scope APIKeyScope `json:"scope"`
|
||||
Lifetime time.Duration `json:"lifetime"`
|
||||
Scope APIKeyScope `json:"scope"`
|
||||
}
|
||||
|
||||
// GenerateAPIKeyResponse contains an API key for a user.
|
||||
|
||||
@@ -42,6 +42,7 @@ type DeploymentConfig struct {
|
||||
APIRateLimit *DeploymentConfigField[int] `json:"api_rate_limit" typescript:",notnull"`
|
||||
Experimental *DeploymentConfigField[bool] `json:"experimental" typescript:",notnull"`
|
||||
UpdateCheck *DeploymentConfigField[bool] `json:"update_check" typescript:",notnull"`
|
||||
MaxTokenLifetime *DeploymentConfigField[time.Duration] `json:"max_token_lifetime" typescript:",notnull"`
|
||||
}
|
||||
|
||||
type DERP struct {
|
||||
|
||||
Reference in New Issue
Block a user