Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccountStatusSvc ¶
type AccountStatusSvc interface {
ListAccountStatuses(ctx context.Context, req *ListAccountStatusesRequest) (*apiresource.List[apiresource.AccountStatus], *apierror.APIError)
GetAccountStatus(ctx context.Context, req *RetrieveAccountStatusRequest) (*apiresource.AccountStatus, *apierror.APIError)
}
func NewAccountStatusSvc ¶
func NewAccountStatusSvc(config *AccountStatusSvcConfig) AccountStatusSvc
type AccountStatusSvcConfig ¶
type AccountStatusSvcConfig struct {
// CoreClient (required) is the core-service gRPC client.
CoreClient pb.CoreServiceClient
}
type ListAccountStatusesEndpoint ¶
type ListAccountStatusesEndpoint struct{}
Returns a paginated list of account statuses.
Account statuses are system-provided lookup values shared across all accounts, used to set a customer's status (for example, placing a customer on a credit hold). The list is fixed — statuses cannot be created, edited, or deleted — so use it to populate a status picker or to resolve a code to its display name.
func (*ListAccountStatusesEndpoint) Materialize ¶
func (e *ListAccountStatusesEndpoint) Materialize() *apiendpoint.APIEndpoint[*ListAccountStatusesRequest, *apiresource.List[apiresource.AccountStatus]]
type ListAccountStatusesRequest ¶
type ListAccountStatusesRequest struct {
apiresource.PaginationRequest
}
Request to list account statuses.
type RetrieveAccountStatusEndpoint ¶
type RetrieveAccountStatusEndpoint struct{}
Returns a single account status, looked up by either its ID or its code.
func (*RetrieveAccountStatusEndpoint) Materialize ¶
func (e *RetrieveAccountStatusEndpoint) Materialize() *apiendpoint.APIEndpoint[*RetrieveAccountStatusRequest, *apiresource.AccountStatus]
type RetrieveAccountStatusRequest ¶
type RetrieveAccountStatusRequest struct {
// Account status ID or code.
//
// A code such as `hold_shipment` resolves to the same status as that status's ID.
AccountStatusID string `path:"id" validate:"required"`
}
Request to retrieve an account status.
Click to show internal directories.
Click to hide internal directories.