MCPcopy Create free account
hub / github.com/egonelbre/exp / CreateUser

Method CreateUser

site_test/api/users.go:23–38  ·  view source on GitHub ↗
(c echo.Context)

Source from the content-addressed store, hash-verified

21}
22
23func (server *Server) CreateUser(c echo.Context) error {
24 ctx := c.Request().Context()
25
26 var u user.User
27 if err := c.Bind(&u); err != nil {
28 return err
29 }
30
31 created, err := server.users.Create(ctx, &u)
32 if err != nil {
33 return err
34 }
35
36 c.JSON(http.StatusOK, created)
37 return nil
38}

Callers

nothing calls this directly

Calls 1

CreateMethod · 0.65

Tested by

no test coverage detected