wire docs

Go SDK

Official Go SDK for the Wire payment API.

The official Go SDK for Wire.

Install

go get github.com/buildry-wire/wire-go

Initialize and make a call

package main

import (
	"context"
	"fmt"
	"log"

	wire "github.com/buildry-wire/wire-go"
)

func main() {
	client := wire.NewClient("sk_live_...")
	ctx := context.Background()

	pi, err := client.PaymentIntents.Create(ctx, &wire.PaymentIntentCreateParams{
		Amount:           15000, // 15,000 ₮ — whole tögrög
		Currency:         "MNT",
		Description:      "Order #1001", // transaction description (optional)
		IdempotencyKey:   "order-1001",
	})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(pi.ID, pi.Status)
}

Learn more

On this page