MCPcopy Create free account
hub / github.com/Mnexa-AI/e2a / apiKeyView

Function apiKeyView

internal/httpapi/apikeys.go:34–49  ·  view source on GitHub ↗
(k identity.APIKey)

Source from the content-addressed store, hash-verified

32}
33
34func apiKeyView(k identity.APIKey) APIKeyView {
35 agent := ""
36 if k.AgentID != nil {
37 agent = *k.AgentID
38 }
39 return APIKeyView{
40 ID: k.ID,
41 Name: k.Name,
42 KeyPrefix: k.KeyPrefix,
43 Scope: k.Scope,
44 Agent: agent,
45 CreatedAt: k.CreatedAt,
46 LastUsedAt: k.LastUsedAt,
47 ExpiresAt: k.ExpiresAt,
48 }
49}
50
51type listAPIKeysOutput struct{ Body Page[APIKeyView] }
52

Callers 2

handleListAPIKeysMethod · 0.85
handleCreateAPIKeyMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected