RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.
Go agent-harnessagent-native-databaseagentic-aiagentic-retrievalagentic-searchaiai-agentscontext-enginecontext-engineeringcontext-managementharness-engineeringknowledge-compilationragretrieval-augmented-generationretrieval-harnesssearch-harness
fix: add create_date field to APIKeyResponse for token list display (#17186)
euvre03e583f9bcb9
diff --git a/internal/service/api_token.go b/internal/service/api_token.goindex 7c9dd33b44..77a4164c8d 100644--- a/internal/service/api_token.go+++ b/internal/service/api_token.go@@ -20,17 +20,20 @@ import ("ragflow/internal/dao""ragflow/internal/entity""ragflow/internal/utility"+ "time")// APIKeyResponse key responsetype APIKeyResponse struct {- TenantID string `json:"tenant_id"`- Token string `json:"token"`- DialogID *string `json:"dialog_id,omitempty"`- Source *string `json:"source,omitempty"`- Beta *string `json:"beta,omitempty"`- CreateTime *int64 `json:"create_time,omitempty"`- UpdateTime *int64 `json:"update_time,omitempty"`+ TenantID string `json:"tenant_id"`+ Token string `json:"token"`+ DialogID *string `json:"dialog_id,omitempty"`+ Source *string `json:"source,omitempty"`+ Beta *string `json:"beta,omitempty"`+ CreateTime *int64 `json:"create_time,omitempty"`+ CreateDate *time.Time `json:"create_date,omitempty"`+ UpdateTime *int64 `json:"update_time,omitempty"`+ UpdateDate *time.Time `json:"update_date,omitempty"`}// ListAPIKeys list all API keys for a tenant@@ -64,7 +67,9 @@ func (s *SystemService) ListAPIKeys(tenantID string) ([]*APIKeyResponse, error)Source: key.Source,Beta: beta,CreateTime: key.CreateTime,+ CreateDate: key.CreateDate,UpdateTime: key.UpdateTime,+ UpdateDate: key.UpdateDate,}}@@ -103,7 +108,9 @@ func (s *SystemService) CreateAPIKey(tenantID string, req *CreateAPIKeyRequest)Source: APIKeyData.Source,Beta: APIKeyData.Beta,CreateTime: APIKeyData.CreateTime,+ CreateDate: APIKeyData.CreateDate,UpdateTime: APIKeyData.UpdateTime,+ UpdateDate: APIKeyData.UpdateDate,}, nil}