/go-paypal

PayPal NVP library written in Go

Primary LanguageGoOtherNOASSERTION

go-paypal

go-paypal is a package written in Go for accessing PayPal APIs using the "NVP" format.

Included is a method for using the Digital Goods for Express Checkout payment option.

Quick Start

import (
		"paypal"
		"fmt"
)

client := paypal.NewClient(username, password, signature, true)

goods := make([]paypal.PayPalDigitalGood, 1)
good := new(paypal.PayPalDigitalGood)
good.Name, good.Amount, good.Quantity = "Test Good", paymentAmount, 1
goods[0] = *good

response, _ := client.SetExpressCheckoutDigitalGoods(paymentAmount, currencyCode, returnURL, cancelURL, goods)

fmt.Println(response.Values)