https://github.com/gofarsi/paygap
Payment gateway providers SDK Go for zarinpal, idpay, pay.ir, and other gateway providers
https://github.com/gofarsi/paygap
api-gateway gateway go payment
Last synced: about 1 year ago
JSON representation
Payment gateway providers SDK Go for zarinpal, idpay, pay.ir, and other gateway providers
- Host: GitHub
- URL: https://github.com/gofarsi/paygap
- Owner: GoFarsi
- License: apache-2.0
- Created: 2022-09-14T11:09:19.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2024-12-10T12:34:25.000Z (over 1 year ago)
- Last Synced: 2025-04-09T18:16:40.439Z (about 1 year ago)
- Topics: api-gateway, gateway, go, payment
- Language: Go
- Homepage:
- Size: 229 KB
- Stars: 52
- Watchers: 2
- Forks: 17
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PayGap [](https://pkg.go.dev/github.com/GoFarsi/paygap)
Payment gateway providers SDK Go for zarinpal, idpay, pay.ir, and other gateway providers.

## Install For 
```shell
go get -u github.com/GoFarsi/paygap
```
## Usage
example for zarinpal provider ([Other examples](https://github.com/GoFarsi/paygap/tree/main/_example))
```go
package main
import (
"context"
"fmt"
"log"
"github.com/GoFarsi/paygap/client"
"github.com/GoFarsi/paygap/providers/zarinpal"
)
func main() {
c := client.New()
z, err := zarinpal.New(c, "YOUR_MERCHANT_ID", false)
if err != nil {
log.Fatal(err)
}
resp, err := z.RequestPayment(context.Background(), 1000, "YOUR_CALL_BACK", "YOUR_CURRENCY", "description", nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(resp)
}
```
## Contributing
1. fork project in your GitHub account.
2. create new branch for new changes.
3. after change code, send Pull Request.
## TODO
- [x] zarinpal
- [x] idpay
- [x] pay.ir
- [x] payping
- [x] vandar.io
- [ ] rayanpay
- [ ] nextpay
- [x] mellat
- [ ] parsian
- [ ] pasargad
- [x] sadad
- [x] [zibal](https://zibal.ir)