MCPcopy Create free account
hub / github.com/aurora-develop/aurora / teamAccountIDFromRequest

Function teamAccountIDFromRequest

initialize/handlers.go:1868–1876  ·  view source on GitHub ↗
(c *gin.Context)

Source from the content-addressed store, hash-verified

1866}
1867
1868func teamAccountIDFromRequest(c *gin.Context) string {
1869 for _, header := range []string{"ChatGPT-Account-ID", "Chatgpt-Account-Id", "Team-Account-ID", "X-ChatGPT-Account-ID"} {
1870 if value := strings.TrimSpace(c.GetHeader(header)); value != "" {
1871 return value
1872 }
1873 }
1874 _, teamAccountID := splitAuthorizationTokenAndTeam(c.GetHeader("Authorization"))
1875 return teamAccountID
1876}
1877
1878func authorizationTokenAndTeam(c *gin.Context) (string, string, bool) {
1879 token, authorizationTeamID := splitAuthorizationTokenAndTeam(c.GetHeader("Authorization"))

Callers 2

Calls 1

Tested by 1