About add a customize function on nakama

What does your module setup look like? Can you share your go.mod file and any Go-related environment variables?

Typically we’ve seen this error when attempting to build locally with Go modules disabled, which is not how you should build to load into Nakama. If you search around the forums you’ll find various posts with example go.mod and module setups (like this.)