feat: 优化代理服务

This commit is contained in:
tbphp
2025-07-11 17:11:00 +08:00
parent 6ffbb7e9a1
commit 1368792aa0
16 changed files with 249 additions and 262 deletions

View File

@@ -0,0 +1,12 @@
package utils
import "fmt"
// MaskAPIKey masks an API key for safe logging.
func MaskAPIKey(key string) string {
length := len(key)
if length <= 8 {
return key
}
return fmt.Sprintf("%s****%s", key[:4], key[length-4:])
}