paymentlink

package
v0.2.0-beta Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 22, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Api     request.Api
	FazzURL string
}

func (*Client) Create

Create return response from Create a Payment Link API.

Docs: https://docs.fazz.com/v4-ID/reference/create-payment-link

func (c *Client) PaymentLink(ctx context.Context, paymentLinkId string) (*PaymentLink, *fazz.Error)

PaymentLink return response from Get a Payment Link API.

Docs: https://docs.fazz.com/v4-ID/reference/get-payment-link

func (*Client) Update

func (c *Client) Update(ctx context.Context, paymentLinkId string, payload fazz.PaymentLinkUpdatePayload) (*PaymentLinkUpdate, *fazz.Error)

Update return response from Update a Payment Link API.

Docs: https://docs.fazz.com/v4-ID/reference/update-payment-link

type PaymentLink struct {
	ID         string                `json:"id"`
	Type       string                `json:"type"`
	Attributes PaymentLinkAttributes `json:"attributes"`
}

PaymentLink represent response from Create & Show Payment Link API.

type PaymentLinkAttributes

type PaymentLinkAttributes struct {
	Status              string `json:"status"`
	Amount              string `json:"amount"`
	ReferenceId         string `json:"referenceId"`
	CreatedAt           string `json:"createdAt"`
	Description         string `json:"description"`
	ExpiredAt           string `json:"expiredAt"`
	PaymentLinkUrl      string `json:"paymentLinkUrl"`
	CustomerName        string `json:"customerName"`
	CustomerEmail       string `json:"customerEmail"`
	CustomerPhoneNumber string `json:"customerPhoneNumber"`
	DisplayName         string `json:"displayName"`
}

PaymentLinkAttributes is part of PaymentLink.

type PaymentLinkUpdate

type PaymentLinkUpdate struct {
	Type       string                      `json:"type"`
	Attributes PaymentLinkUpdateAttributes `json:"attributes"`
}

PaymentLinkUpdate represent response from Update Payment Link API.

type PaymentLinkUpdateAttributes

type PaymentLinkUpdateAttributes struct {
	TargetId   string `json:"targetId"`
	TargetType string `json:"targetType"`
	Action     string `json:"action"`
}

PaymentLinkUpdateAttributes is part of PaymentLinkUpdate.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL