Documentation
¶
Index ¶
- Constants
- type Driver
- func (Driver) GetDriverName() string
- func (*Driver) PayMethod() string
- func (*Driver) PayURL(_ *invoice.Invoice) string
- func (d *Driver) Purchase(invoice *invoice.Invoice) (string, error)
- func (d *Driver) RenderRedirectForm(invoice *invoice.Invoice) (string, error)
- func (Driver) SetClient(c httpClient.Client)
- func (d *Driver) Verify(vReq interface{}) (*receipt.Receipt, error)
- type VerifyRequest
Constants ¶
View Source
const ( APIPurchaseURL = "https://ipgrest.asanpardakht.ir/v1/Token" APIPaymentURL = "https://asan.shaparak.ir" APIVerifyURL = "https://ipgrest.asanpardakht.ir/v1/verify" APISettlementURL = "https://ipgrest.asanpardakht.ir/v1/Settlement" APITranResultURL = "https://ipgrest.asanpardakht.ir/v1/TranResult" )
Const's for AsanPardakht
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Driver ¶
Driver configures the AsanPardakht driver
func (Driver) GetDriverName ¶
GetDriverName returns driver name
func (*Driver) RenderRedirectForm ¶
RenderRedirectForm renders the html form for redirect to payment page.
func (Driver) SetClient ¶
func (Driver) SetClient(c httpClient.Client)
SetClient sets the http client
type VerifyRequest ¶
type VerifyRequest struct {
InvoiceID string `json:"invoice_id"`
}
VerifyRequest is the request struct for verify
Click to show internal directories.
Click to hide internal directories.