Go SDK

Four SDKs are available: Node.js, Java, PHP and Go, with consistent API parameters, request signing, JSON bodies and callback verification.

Download the ZIP for your language. Each archive includes installation instructions, a client, signing utilities and examples.

Go SDK

Go standard-library client with four API methods, request signing, callback verification and a read-only query example.

Highlights
  • Includes CreatePayinOrder, GetPayinOrder, CreateExclusiveBinding and CreatePayoutOrder
  • Success returns the raw business JSON. Handle ordinary JSON errors and HTTP denials with empty bodies separately.
  • Verify callbacks using the original order API Key and raw request body bytes.
Install
cd uugate-go-sdk
go test ./...
go run ./examples/basic
Quick Example
import (
    "context"
    "os"
    uugate "uugate.local/openapi"
)

client, err := uugate.NewClient("https://api.uugate.com",
    os.Getenv("UUGATE_MERCHANT_UID"), os.Getenv("UUGATE_API_KEY"))
if err != nil { panic(err) }
order, err := client.CreatePayinOrder(context.Background(), map[string]any{
    "chainCode": "TRON", "tokenSymbol": "USDT",
    "merchantOrderNo": "M202604170001", "amount": "100.00",
    "notifyUrl": "https://merchant.example.com/api/uugate/payin-notify",
})
if err != nil { panic(err) }
_ = order