21 lines
555 B
Go
21 lines
555 B
Go
package main
|
|
|
|
import (
|
|
"golang.project/gocasts/ipg-example/delivery/httphandler"
|
|
"golang.project/gocasts/ipg-example/service"
|
|
)
|
|
|
|
func main() {
|
|
config := service.Config{
|
|
PaymentGetToken: "https://sep.shaparak.ir/OnlinePG/OnlinePG",
|
|
PaymentVerifyURL: "https://sep.shaparak.ir/verifyTxnRandomSessionkey/ipg/VerifyTransaction",
|
|
CallbackURL: "http://localhost:8070/api/callback",
|
|
Credential: "15144433",
|
|
}
|
|
|
|
paymentSvc := service.NewPaymentService(config)
|
|
handler := httphandler.NewHandler(paymentSvc)
|
|
|
|
handler.StartServer(":8070")
|
|
}
|