Versions in this module Expand all Collapse all v1 v1.3.8 Mar 6, 2023 Changes in this version + const CustomerSatisfaction + const HostProduction + const HostSandBox + const OtherReasons + const PathConsumptionInfo + const PathExtendSubscriptionRenewalDate + const PathGetALLSubscriptionStatus + const PathGetNotificationHistory + const PathGetTestNotificationStatus + const PathLookUp + const PathRefundHistory + const PathRequestTestNotification + const PathTransactionHistory + const ServiceIssueOrOutage + const UndeclaredExtendReasonCode + var ErrAuthKeyInvalidPem = errors.New("token: AuthKey must be a valid .p8 PEM file") + var ErrAuthKeyInvalidType = errors.New("token: AuthKey must be of type ecdsa.PrivateKey") + type Cert struct + type ConsumptionRequestBody struct + AccountTenure int + AppAccountToken string + ConsumptionStatus int + CustomerConsented bool + DeliveryStatus int + LifetimeDollarsPurchased int + LifetimeDollarsRefunded int + Platform int + PlayTime int + SampleContentProvided bool + UserStatus int + type ExtendReasonCode int + type ExtendRenewalDateRequest struct + ExtendByDays int + ExtendReasonCode ExtendReasonCode + RequestIdentifier string + type FirstSendAttemptResult string + const FirstSendAttemptResultCircularRedirect + const FirstSendAttemptResultInvalidResponse + const FirstSendAttemptResultNoResponse + const FirstSendAttemptResultOther + const FirstSendAttemptResultPrematureClose + const FirstSendAttemptResultSocketIssue + const FirstSendAttemptResultSuccess + const FirstSendAttemptResultTimedOut + const FirstSendAttemptResultTlsIssue + const FirstSendAttemptResultUnsupportedCharset + type HistoryResponse struct + AppAppleId int + BundleId string + Environment string + HasMore bool + Revision string + SignedTransactions []string + type JWSDecodedHeader struct + Alg string + Kid string + X5C []string + type JWSRenewalInfoDecodedPayload struct + type JWSTransaction struct + AppAccountToken string + BundleID string + ExpiresDate int64 + InAppOwnershipType string + IsUpgraded bool + OfferIdentifier string + OfferType int64 + OriginalPurchaseDate int64 + OriginalTransactionId string + ProductID string + PurchaseDate int64 + Quantity int64 + RevocationDate int64 + RevocationReason int + SignedDate int64 + SubscriptionGroupIdentifier string + TransactionID string + Type string + WebOrderLineItemId string + func (J JWSTransaction) Valid() error + type LastTransactionsItem struct + OriginalTransactionId string + SignedRenewalInfo string + SignedTransactionInfo string + Status int + type NotificationHistoryRequest struct + EndDate int64 + NotificationSubtype appstore.SubtypeV2 + NotificationType appstore.NotificationTypeV2 + OriginalTransactionId string + StartDate int64 + type NotificationHistoryResponseItem struct + FirstSendAttemptResult FirstSendAttemptResult + SignedPayload string + type NotificationHistoryResponses struct + HasMore bool + NotificationHistory []NotificationHistoryResponseItem + PaginationToken string + type OrderLookupResponse struct + SignedTransactions []string + Status int + type RefundLookupResponse struct + HasMore bool + Revision string + SignedTransactions []string + type SendTestNotificationResponse struct + TestNotificationToken string + type StatusResponse struct + AppAppleId int + BundleId string + Data []SubscriptionGroupIdentifierItem + Environment string + type StoreClient struct + Token *Token + func NewStoreClient(config *StoreConfig) *StoreClient + func NewStoreClientWithHTTPClient(config *StoreConfig, httpClient *http.Client) *StoreClient + func (a *StoreClient) Do(ctx context.Context, method string, url string, body io.Reader) (int, []byte, error) + func (a *StoreClient) ExtendSubscriptionRenewalDate(ctx context.Context, originalTransactionId string, ...) (statusCode int, err error) + func (a *StoreClient) GetALLSubscriptionStatuses(ctx context.Context, originalTransactionId string) (rsp *StatusResponse, err error) + func (a *StoreClient) GetNotificationHistory(ctx context.Context, body NotificationHistoryRequest) (responses []NotificationHistoryResponseItem, err error) + func (a *StoreClient) GetRefundHistory(ctx context.Context, originalTransactionId string) (responses []*RefundLookupResponse, err error) + func (a *StoreClient) GetTestNotificationStatus(ctx context.Context, testNotificationToken string) (int, []byte, error) + func (a *StoreClient) GetTransactionHistory(ctx context.Context, originalTransactionId string, query *url.Values) (responses []*HistoryResponse, err error) + func (a *StoreClient) LookupOrderID(ctx context.Context, orderId string) (rsp *OrderLookupResponse, err error) + func (a *StoreClient) ParseSignedTransactions(transactions []string) ([]*JWSTransaction, error) + func (a *StoreClient) SendConsumptionInfo(ctx context.Context, originalTransactionId string, body ConsumptionRequestBody) (statusCode int, err error) + func (a *StoreClient) SendRequestTestNotification(ctx context.Context) (int, []byte, error) + type StoreConfig struct + BundleID string + Issuer string + KeyContent []byte + KeyID string + Sandbox bool + type SubscriptionGroupIdentifierItem struct + LastTransactions []LastTransactionsItem + SubscriptionGroupIdentifier string + type Token struct + AuthKey *ecdsa.PrivateKey + Bearer string + BundleID string + ExpiredAt int64 + Issuer string + KeyContent []byte + KeyID string + Sandbox bool + func (t *Token) Expired() bool + func (t *Token) Generate() error + func (t *Token) GenerateIfExpired() (string, error) + func (t *Token) WithConfig(c *StoreConfig)