Documentation
¶
Index ¶
- type Config
- type IngestHandler
- type Router
- func (a *Router) AdvanceInvoiceAction(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) AppCustomInvoicingDraftSynchronized(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) AppCustomInvoicingIssuingSynchronized(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) AppCustomInvoicingUpdatePaymentStatus(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) AppStripeWebhook(w http.ResponseWriter, r *http.Request, appID string)
- func (a *Router) ApproveInvoiceAction(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) ArchiveAddon(w http.ResponseWriter, r *http.Request, addonId string)
- func (a *Router) ArchivePlan(w http.ResponseWriter, r *http.Request, planId string)
- func (a *Router) CancelSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) ChangeSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) CreateAddon(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateBillingProfile(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateCustomer(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateEntitlement(w http.ResponseWriter, r *http.Request, subjectIdOrKey string)
- func (a *Router) CreateFeature(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateGrant(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) CreateMeter(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateNotificationChannel(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateNotificationRule(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreatePendingInvoiceLine(w http.ResponseWriter, r *http.Request, customerId string)
- func (a *Router) CreatePlan(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreatePlanAddon(w http.ResponseWriter, r *http.Request, planId string)
- func (a *Router) CreatePortalToken(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateStripeCheckoutSession(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateSubscription(w http.ResponseWriter, r *http.Request)
- func (a *Router) CreateSubscriptionAddon(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) DeleteAddon(w http.ResponseWriter, r *http.Request, addonId string)
- func (a *Router) DeleteBillingProfile(w http.ResponseWriter, r *http.Request, id string)
- func (a *Router) DeleteBillingProfileCustomerOverride(w http.ResponseWriter, r *http.Request, customerId string)
- func (a *Router) DeleteCustomer(w http.ResponseWriter, r *http.Request, customerIDOrKey string)
- func (a *Router) DeleteCustomerAppData(w http.ResponseWriter, r *http.Request, customerIDOrKey string, appID string)
- func (a *Router) DeleteEntitlement(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) DeleteFeature(w http.ResponseWriter, r *http.Request, featureId string)
- func (a *Router) DeleteInvoice(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) DeleteMeter(w http.ResponseWriter, r *http.Request, meterIdOrSlug string)
- func (a *Router) DeleteNotificationChannel(w http.ResponseWriter, r *http.Request, channelID string)
- func (a *Router) DeleteNotificationRule(w http.ResponseWriter, r *http.Request, ruleID string)
- func (a *Router) DeletePlan(w http.ResponseWriter, r *http.Request, planId string)
- func (a *Router) DeletePlanAddon(w http.ResponseWriter, r *http.Request, planId string, planAddonId string)
- func (a *Router) DeleteSubject(w http.ResponseWriter, r *http.Request, subjectIdOrKey string)
- func (a *Router) DeleteSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) EditSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) GetAddon(w http.ResponseWriter, r *http.Request, addonId string, ...)
- func (a *Router) GetApp(w http.ResponseWriter, r *http.Request, appID string)
- func (a *Router) GetBillingProfile(w http.ResponseWriter, r *http.Request, id string, ...)
- func (a *Router) GetBillingProfileCustomerOverride(w http.ResponseWriter, r *http.Request, customerId string, ...)
- func (a *Router) GetCustomer(w http.ResponseWriter, r *http.Request, customerIDOrKey string, ...)
- func (a *Router) GetCustomerAccess(w http.ResponseWriter, r *http.Request, customerIdOrKey string)
- func (a *Router) GetCustomerEntitlementValue(w http.ResponseWriter, r *http.Request, customerIdOrKey string, ...)
- func (a *Router) GetDebugMetrics(w http.ResponseWriter, r *http.Request)
- func (a *Router) GetEntitlement(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) GetEntitlementById(w http.ResponseWriter, r *http.Request, entitlementId string)
- func (a *Router) GetEntitlementHistory(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) GetEntitlementValue(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) GetFeature(w http.ResponseWriter, r *http.Request, featureId string)
- func (a *Router) GetInvoice(w http.ResponseWriter, r *http.Request, invoiceId string, ...)
- func (a *Router) GetMarketplaceListing(w http.ResponseWriter, r *http.Request, appType api.AppType)
- func (a *Router) GetMeter(w http.ResponseWriter, r *http.Request, meterIdOrSlug string)
- func (a *Router) GetNotificationChannel(w http.ResponseWriter, r *http.Request, channelID string)
- func (a *Router) GetNotificationEvent(w http.ResponseWriter, r *http.Request, eventID string)
- func (a *Router) GetNotificationRule(w http.ResponseWriter, r *http.Request, ruleID string)
- func (a *Router) GetPlan(w http.ResponseWriter, r *http.Request, planIdOrKey string, ...)
- func (a *Router) GetPlanAddon(w http.ResponseWriter, r *http.Request, planId string, planAddonId string)
- func (a *Router) GetProgress(w http.ResponseWriter, r *http.Request, progressID string)
- func (a *Router) GetSubject(w http.ResponseWriter, r *http.Request, subjectIdOrKey string)
- func (a *Router) GetSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string, ...)
- func (a *Router) GetSubscriptionAddon(w http.ResponseWriter, r *http.Request, subscriptionId string, ...)
- func (a *Router) IngestEvents(w http.ResponseWriter, r *http.Request)
- func (a *Router) InvalidatePortalTokens(w http.ResponseWriter, r *http.Request)
- func (a *Router) InvoicePendingLinesAction(w http.ResponseWriter, r *http.Request)
- func (a *Router) ListAddons(w http.ResponseWriter, r *http.Request, params api.ListAddonsParams)
- func (a *Router) ListApps(w http.ResponseWriter, r *http.Request, params api.ListAppsParams)
- func (a *Router) ListBillingProfileCustomerOverrides(w http.ResponseWriter, r *http.Request, ...)
- func (a *Router) ListBillingProfiles(w http.ResponseWriter, r *http.Request, params api.ListBillingProfilesParams)
- func (a *Router) ListCurrencies(w http.ResponseWriter, r *http.Request)
- func (a *Router) ListCustomerAppData(w http.ResponseWriter, r *http.Request, customerIdOrKey string, ...)
- func (a *Router) ListCustomerSubscriptions(w http.ResponseWriter, r *http.Request, customerIDOrKey string, ...)
- func (a *Router) ListCustomers(w http.ResponseWriter, r *http.Request, params api.ListCustomersParams)
- func (a *Router) ListEntitlementGrants(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) ListEntitlements(w http.ResponseWriter, r *http.Request, params api.ListEntitlementsParams)
- func (a *Router) ListEvents(w http.ResponseWriter, r *http.Request, params api.ListEventsParams)
- func (a *Router) ListEventsV2(w http.ResponseWriter, r *http.Request, params api.ListEventsV2Params)
- func (a *Router) ListFeatures(w http.ResponseWriter, r *http.Request, params api.ListFeaturesParams)
- func (a *Router) ListGrants(w http.ResponseWriter, r *http.Request, params api.ListGrantsParams)
- func (a *Router) ListInvoices(w http.ResponseWriter, r *http.Request, params api.ListInvoicesParams)
- func (a *Router) ListMarketplaceListings(w http.ResponseWriter, r *http.Request, ...)
- func (a *Router) ListMeterSubjects(w http.ResponseWriter, r *http.Request, meterIDOrSlug string)
- func (a *Router) ListMeters(w http.ResponseWriter, r *http.Request, params api.ListMetersParams)
- func (a *Router) ListNotificationChannels(w http.ResponseWriter, r *http.Request, ...)
- func (a *Router) ListNotificationEvents(w http.ResponseWriter, r *http.Request, ...)
- func (a *Router) ListNotificationRules(w http.ResponseWriter, r *http.Request, params api.ListNotificationRulesParams)
- func (a *Router) ListPlanAddons(w http.ResponseWriter, r *http.Request, planId string, ...)
- func (a *Router) ListPlans(w http.ResponseWriter, r *http.Request, params api.ListPlansParams)
- func (a *Router) ListPortalTokens(w http.ResponseWriter, r *http.Request, params api.ListPortalTokensParams)
- func (a *Router) ListSubjectEntitlements(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) ListSubjects(w http.ResponseWriter, r *http.Request)
- func (a *Router) ListSubscriptionAddons(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) MarketplaceAppAPIKeyInstall(w http.ResponseWriter, r *http.Request, appType api.AppType)
- func (a *Router) MarketplaceAppInstall(w http.ResponseWriter, r *http.Request, appType api.AppType)
- func (a *Router) MarketplaceOAuth2InstallAuthorize(w http.ResponseWriter, r *http.Request, appType api.AppType, ...)
- func (a *Router) MarketplaceOAuth2InstallGetURL(w http.ResponseWriter, r *http.Request, appType api.AppType)
- func (a *Router) MigrateSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) NextPlan(w http.ResponseWriter, r *http.Request, planIdOrKey string)
- func (a *Router) OverrideEntitlement(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) PublishAddon(w http.ResponseWriter, r *http.Request, addonId string)
- func (a *Router) PublishPlan(w http.ResponseWriter, r *http.Request, planId string)
- func (a *Router) QueryMeter(w http.ResponseWriter, r *http.Request, meterIDOrSlug string, ...)
- func (a *Router) QueryMeterPost(w http.ResponseWriter, r *http.Request, meterIDOrSlug string)
- func (a *Router) QueryPortalMeter(w http.ResponseWriter, r *http.Request, meterSlug string, ...)
- func (a *Router) RecalculateInvoiceTaxAction(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) ResetEntitlementUsage(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, ...)
- func (a *Router) RestoreSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) RetryInvoiceAction(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) SimulateInvoice(w http.ResponseWriter, r *http.Request, customerId string)
- func (a *Router) SnapshotQuantitiesInvoiceAction(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) TestNotificationRule(w http.ResponseWriter, r *http.Request, ruleID string)
- func (a *Router) UninstallApp(w http.ResponseWriter, r *http.Request, appID string)
- func (a *Router) UnscheduleCancelation(w http.ResponseWriter, r *http.Request, subscriptionId string)
- func (a *Router) UpdateAddon(w http.ResponseWriter, r *http.Request, addonId string)
- func (a *Router) UpdateApp(w http.ResponseWriter, r *http.Request, appID string)
- func (a *Router) UpdateBillingProfile(w http.ResponseWriter, r *http.Request, id string)
- func (a *Router) UpdateCustomer(w http.ResponseWriter, r *http.Request, customerIDOrKey string)
- func (a *Router) UpdateInvoice(w http.ResponseWriter, r *http.Request, invoiceId string)
- func (a *Router) UpdateMeter(w http.ResponseWriter, r *http.Request, meterID string)
- func (a *Router) UpdateNotificationChannel(w http.ResponseWriter, r *http.Request, channelID string)
- func (a *Router) UpdateNotificationRule(w http.ResponseWriter, r *http.Request, ruleID string)
- func (a *Router) UpdatePlan(w http.ResponseWriter, r *http.Request, planId string)
- func (a *Router) UpdatePlanAddon(w http.ResponseWriter, r *http.Request, planId string, planAddonId string)
- func (a *Router) UpdateStripeAPIKey(w http.ResponseWriter, r *http.Request, appID string)
- func (a *Router) UpdateSubscriptionAddon(w http.ResponseWriter, r *http.Request, subscriptionId string, ...)
- func (a *Router) UpsertBillingProfileCustomerOverride(w http.ResponseWriter, r *http.Request, customerId string)
- func (a *Router) UpsertCustomerAppData(w http.ResponseWriter, r *http.Request, customerIDOrKey string)
- func (a *Router) UpsertSubject(w http.ResponseWriter, r *http.Request)
- func (a *Router) VoidGrant(w http.ResponseWriter, r *http.Request, grantId string)
- func (a *Router) VoidInvoiceAction(w http.ResponseWriter, r *http.Request, invoiceId string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Addon addon.Service App app.Service AppStripe appstripe.Service AppCustomInvoicing appcustominvoicing.SyncService Billing billing.Service BillingFeatureSwitches config.BillingFeatureSwitchesConfiguration Customer customer.Service DebugConnector debug.DebugConnector EntitlementConnector entitlement.Connector EntitlementBalanceConnector meteredentitlement.Connector ErrorHandler errorsx.Handler FeatureConnector feature.FeatureConnector GrantConnector credit.GrantConnector GrantRepo grant.Repo IngestHandler http.Handler Logger *slog.Logger MeterManageService meter.ManageService MeterEventService meterevent.Service NamespaceManager *namespace.Manager Notification notification.Service Plan plan.Service PlanAddon planaddon.Service PlanSubscriptionService plansubscription.PlanSubscriptionService PortalCORSEnabled bool Portal portal.Service ProgressManager progressmanager.Service StreamingConnector streaming.Connector SubscriptionService subscription.Service SubscriptionAddonService subscriptionaddon.Service SubscriptionWorkflowService subscriptionworkflow.Service SubjectService subject.Service }
type IngestHandler ¶
type IngestHandler interface {
ServeHTTP(w http.ResponseWriter, r *http.Request, namespace string)
}
type Router ¶
type Router struct {
// contains filtered or unexported fields
}
func (*Router) AdvanceInvoiceAction ¶
Advance the invoice's state to the next status (POST /api/v1/billing/invoices/{invoiceId}/advance)
func (*Router) AppCustomInvoicingDraftSynchronized ¶
func (a *Router) AppCustomInvoicingDraftSynchronized(w http.ResponseWriter, r *http.Request, invoiceId string)
Submit draft synchronization results (POST /api/v1/apps/custom-invoicing/{invoiceId}/draft/synchronized)
func (*Router) AppCustomInvoicingIssuingSynchronized ¶
func (a *Router) AppCustomInvoicingIssuingSynchronized(w http.ResponseWriter, r *http.Request, invoiceId string)
Submit issuing synchronization results (POST /api/v1/apps/custom-invoicing/{invoiceId}/issuing/synchronized)
func (*Router) AppCustomInvoicingUpdatePaymentStatus ¶
func (a *Router) AppCustomInvoicingUpdatePaymentStatus(w http.ResponseWriter, r *http.Request, invoiceId string)
Update payment status (POST /api/v1/apps/custom-invoicing/{invoiceId}/payment/status)
func (*Router) AppStripeWebhook ¶
Handle app stripe webhook (POST /api/v1/apps/{appId}/stripe/webhook)
func (*Router) ApproveInvoiceAction ¶
Send the invoice to the customer (POST /api/v1/billing/invoices/{invoiceId}/approve)
func (*Router) ArchiveAddon ¶
Archive addon version (POST /api/v1/addons/{addonId}/archive)
func (*Router) ArchivePlan ¶
Archive plan version (POST /api/v1/plans/{planId}/archive)
func (*Router) CancelSubscription ¶
(POST /api/v1/subscriptions/{subscriptionId}/cancel)
func (*Router) ChangeSubscription ¶
func (*Router) CreateAddon ¶
func (a *Router) CreateAddon(w http.ResponseWriter, r *http.Request)
Create a addon (POST /api/v1/addons)
func (*Router) CreateBillingProfile ¶
func (a *Router) CreateBillingProfile(w http.ResponseWriter, r *http.Request)
Create a new billing profile (POST /api/v1/billing/profile)
func (*Router) CreateCustomer ¶
func (a *Router) CreateCustomer(w http.ResponseWriter, r *http.Request)
Create a customer (POST /api/v1/customer/customers)
func (*Router) CreateEntitlement ¶
Create entitlement (POST /api/v1/subjects/{subjectIdOrKey}/entitlements)
func (*Router) CreateFeature ¶
func (a *Router) CreateFeature(w http.ResponseWriter, r *http.Request)
Create feature (POST /api/v1/features)
func (*Router) CreateGrant ¶
func (a *Router) CreateGrant(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementIdOrFeatureKey string)
Create grant (POST /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementId}/grants)
func (*Router) CreateMeter ¶
func (a *Router) CreateMeter(w http.ResponseWriter, r *http.Request)
POST /api/v1/meters/
func (*Router) CreateNotificationChannel ¶
func (a *Router) CreateNotificationChannel(w http.ResponseWriter, r *http.Request)
Create a notification channel (POST /api/v1/notification/channels)
func (*Router) CreateNotificationRule ¶
func (a *Router) CreateNotificationRule(w http.ResponseWriter, r *http.Request)
Create a notification rule (POST /api/v1/notification/rules)
func (*Router) CreatePendingInvoiceLine ¶
func (a *Router) CreatePendingInvoiceLine(w http.ResponseWriter, r *http.Request, customerId string)
Create a new line item (POST /api/v1/billing/customers/{customerId}/pending-lines)
func (*Router) CreatePlan ¶
func (a *Router) CreatePlan(w http.ResponseWriter, r *http.Request)
Create a plan (POST /api/v1/plans)
func (*Router) CreatePlanAddon ¶
Create new add-on assignment for plan (POST /api/v1/plans/{planId}/addons)
func (*Router) CreatePortalToken ¶
func (a *Router) CreatePortalToken(w http.ResponseWriter, r *http.Request)
POST /api/v1/portal/tokens
func (*Router) CreateStripeCheckoutSession ¶
func (a *Router) CreateStripeCheckoutSession(w http.ResponseWriter, r *http.Request)
Handle create app stripe checkout session (POST /api/v1/stripe/checkout/sessions)
func (*Router) CreateSubscription ¶
func (a *Router) CreateSubscription(w http.ResponseWriter, r *http.Request)
(POST /api/v1/subscriptions)
func (*Router) CreateSubscriptionAddon ¶
func (a *Router) CreateSubscriptionAddon(w http.ResponseWriter, r *http.Request, subscriptionId string)
Create a subscription addon (POST /api/v1/subscriptions/{subscriptionId}/addons)
func (*Router) DeleteAddon ¶
Delete addon (DELETE /api/v1/addons/{addonId})
func (*Router) DeleteBillingProfile ¶
Archive a billing profile (DELETE /api/v1/billing/profile/{id})
func (*Router) DeleteBillingProfileCustomerOverride ¶
func (a *Router) DeleteBillingProfileCustomerOverride(w http.ResponseWriter, r *http.Request, customerId string)
Delete a customer override (DELETE /api/v1/billing/customer/{customerId})
func (*Router) DeleteCustomer ¶
Delete a customer (DELETE /api/v1/customer/customers/{customerId})
func (*Router) DeleteCustomerAppData ¶
func (a *Router) DeleteCustomerAppData(w http.ResponseWriter, r *http.Request, customerIDOrKey string, appID string)
Delete customer app data (DELETE /api/v1/customer/customers/{customerId}/apps/{appId})
func (*Router) DeleteEntitlement ¶
func (a *Router) DeleteEntitlement(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementId string)
Delete entitlement (DELETE /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementId})
func (*Router) DeleteFeature ¶
Delete feature (DELETE /api/v1/features/{featureId})
func (*Router) DeleteInvoice ¶
Delete an invoice (DELETE /api/v1/billing/invoices/{customerId}/invoices/{invoiceId})
func (*Router) DeleteMeter ¶
DELETE /api/v1/meters/{meterIdOrSlug}
func (*Router) DeleteNotificationChannel ¶
func (a *Router) DeleteNotificationChannel(w http.ResponseWriter, r *http.Request, channelID string)
Delete a notification channel (DELETE /api/v1/notification/channels/{channelId})
func (*Router) DeleteNotificationRule ¶
Delete a notification rule (DELETE /api/v1/notification/rules/{ruleId})
func (*Router) DeletePlan ¶
Delete plan (DELETE /api/v1/plans/{planId})
func (*Router) DeletePlanAddon ¶
func (a *Router) DeletePlanAddon(w http.ResponseWriter, r *http.Request, planId string, planAddonId string)
Delete add-on assignment for plan (DELETE /api/v1/plans/{planId}/addons/{planAddonId})
func (*Router) DeleteSubject ¶
DELETE /api/v1/subjects/{subjectIdOrKey}
func (*Router) DeleteSubscription ¶
(DELETE /api/v1/subscriptions/{subscriptionId})
func (*Router) EditSubscription ¶
(PATCH /api/v1/subscriptions/{subscriptionId})
func (*Router) GetAddon ¶
func (a *Router) GetAddon(w http.ResponseWriter, r *http.Request, addonId string, params api.GetAddonParams)
Get addon (GET /api/v1/addons/{addonId})
func (*Router) GetBillingProfile ¶
func (a *Router) GetBillingProfile(w http.ResponseWriter, r *http.Request, id string, params api.GetBillingProfileParams)
Get a billing profile by ID (GET /api/v1/billing/profile/{id})
func (*Router) GetBillingProfileCustomerOverride ¶
func (a *Router) GetBillingProfileCustomerOverride(w http.ResponseWriter, r *http.Request, customerId string, params api.GetBillingProfileCustomerOverrideParams)
Get a customer override (GET /api/v1/billing/customer/{customerId})
func (*Router) GetCustomer ¶
func (a *Router) GetCustomer(w http.ResponseWriter, r *http.Request, customerIDOrKey string, params api.GetCustomerParams)
Get customer (GET /api/v1/customer/customers/{customerId})
func (*Router) GetCustomerAccess ¶
Get customer access (GET /api/v1/customers/{customerId}/access)
func (*Router) GetCustomerEntitlementValue ¶
func (a *Router) GetCustomerEntitlementValue(w http.ResponseWriter, r *http.Request, customerIdOrKey string, featureKey string, params api.GetCustomerEntitlementValueParams)
Get entitlement value (GET /api/v1/customers/{customerId}/entitlements/{featureKey}/value)
func (*Router) GetDebugMetrics ¶
func (a *Router) GetDebugMetrics(w http.ResponseWriter, r *http.Request)
Get debug metrics (GET /api/v1/debug/metrics)
func (*Router) GetEntitlement ¶
func (a *Router) GetEntitlement(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementId string)
Get entitlement (GET /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementId})
func (*Router) GetEntitlementById ¶
Get an entitlement (GET /api/v1/entitlements/{entitlementId})
func (*Router) GetEntitlementHistory ¶
func (a *Router) GetEntitlementHistory(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementId string, params api.GetEntitlementHistoryParams)
Get the balance history of a specific entitlement. (GET /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementId}/history)
func (*Router) GetEntitlementValue ¶
func (a *Router) GetEntitlementValue(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementIdOrFeatureKey string, params api.GetEntitlementValueParams)
Get the value of a specific entitlement. (GET /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementIdOrFeatureKey}/value)
func (*Router) GetFeature ¶
Get feature (GET /api/v1/features/{featureId})
func (*Router) GetInvoice ¶
func (a *Router) GetInvoice(w http.ResponseWriter, r *http.Request, invoiceId string, params api.GetInvoiceParams)
Get an invoice (GET /api/v1/billing/invoices/{invoiceId})
func (*Router) GetMarketplaceListing ¶
Get a marketplace listing (GET /api/v1/marketplace/listings/{appType})
func (*Router) GetNotificationChannel ¶
Get notification channel (GET /api/v1/notification/channels/{channelId})
func (*Router) GetNotificationEvent ¶
Get notification event (GET /api/v1/notification/events/{eventId})
func (*Router) GetNotificationRule ¶
Get notification rule (GET /api/v1/notification/rules/{ruleId})
func (*Router) GetPlan ¶
func (a *Router) GetPlan(w http.ResponseWriter, r *http.Request, planIdOrKey string, params api.GetPlanParams)
Get plan (GET /api/v1/plans/{planId})
func (*Router) GetPlanAddon ¶
func (a *Router) GetPlanAddon(w http.ResponseWriter, r *http.Request, planId string, planAddonId string)
Get add-on assignment for plan (GET /api/v1/plans/{planId}/addons/{planAddonId})
func (*Router) GetProgress ¶
Get progress (GET /api/v1/info/progress/{progress_id})
func (*Router) GetSubject ¶
GET /api/v1/subjects/{subjectIdOrKey}
func (*Router) GetSubscription ¶
func (a *Router) GetSubscription(w http.ResponseWriter, r *http.Request, subscriptionId string, params api.GetSubscriptionParams)
(GET /api/v1/subscriptions/{subscriptionId})
func (*Router) GetSubscriptionAddon ¶
func (a *Router) GetSubscriptionAddon(w http.ResponseWriter, r *http.Request, subscriptionId string, subscriptionAddonId string)
Get subscription addon (GET /api/v1/subscriptions/{subscriptionId}/addons/{subscriptionAddonId})
func (*Router) IngestEvents ¶
func (a *Router) IngestEvents(w http.ResponseWriter, r *http.Request)
POST /api/v1/events
func (*Router) InvalidatePortalTokens ¶
func (a *Router) InvalidatePortalTokens(w http.ResponseWriter, r *http.Request)
POST /api/v1/portal/tokens/invalidate
func (*Router) InvoicePendingLinesAction ¶
func (a *Router) InvoicePendingLinesAction(w http.ResponseWriter, r *http.Request)
Invoice a customer based on the pending line items (POST /api/v1/billing/invoices/{customerId}/invoice)
func (*Router) ListAddons ¶
func (a *Router) ListAddons(w http.ResponseWriter, r *http.Request, params api.ListAddonsParams)
List addons (GET /api/v1/addons)
func (*Router) ListApps ¶
func (a *Router) ListApps(w http.ResponseWriter, r *http.Request, params api.ListAppsParams)
Handle to list apps (GET /api/v1/apps)
func (*Router) ListBillingProfileCustomerOverrides ¶
func (a *Router) ListBillingProfileCustomerOverrides(w http.ResponseWriter, r *http.Request, params api.ListBillingProfileCustomerOverridesParams)
List customer overrides (GET /api/v1/billing/customer)
func (*Router) ListBillingProfiles ¶
func (a *Router) ListBillingProfiles(w http.ResponseWriter, r *http.Request, params api.ListBillingProfilesParams)
(GET /api/v1/billing/profile)
func (*Router) ListCurrencies ¶
func (a *Router) ListCurrencies(w http.ResponseWriter, r *http.Request)
List supported currencies (GET /api/v1/info/currencies)
func (*Router) ListCustomerAppData ¶
func (a *Router) ListCustomerAppData(w http.ResponseWriter, r *http.Request, customerIdOrKey string, params api.ListCustomerAppDataParams)
List customer apps (GET /api/v1/customer/customers/{customerId}/apps)
func (*Router) ListCustomerSubscriptions ¶
func (a *Router) ListCustomerSubscriptions(w http.ResponseWriter, r *http.Request, customerIDOrKey string, params api.ListCustomerSubscriptionsParams)
List customer subscriptions (GET /api/v1/customer/customers/{customerId}/subscriptions)
func (*Router) ListCustomers ¶
func (a *Router) ListCustomers(w http.ResponseWriter, r *http.Request, params api.ListCustomersParams)
List customers (GET /api/v1/customer/customers)
func (*Router) ListEntitlementGrants ¶
func (a *Router) ListEntitlementGrants(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementIdOrFeatureKey string, params api.ListEntitlementGrantsParams)
List grants for an entitlement (GET /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementIdOrFeatureKey}/grants)
func (*Router) ListEntitlements ¶
func (a *Router) ListEntitlements(w http.ResponseWriter, r *http.Request, params api.ListEntitlementsParams)
List entitlements (GET /api/v1/entitlements)
func (*Router) ListEvents ¶
func (a *Router) ListEvents(w http.ResponseWriter, r *http.Request, params api.ListEventsParams)
GET /api/v1/events
func (*Router) ListEventsV2 ¶
func (a *Router) ListEventsV2(w http.ResponseWriter, r *http.Request, params api.ListEventsV2Params)
GET /api/v2/events
func (*Router) ListFeatures ¶
func (a *Router) ListFeatures(w http.ResponseWriter, r *http.Request, params api.ListFeaturesParams)
List features (GET /api/v1/features)
func (*Router) ListGrants ¶
func (a *Router) ListGrants(w http.ResponseWriter, r *http.Request, params api.ListGrantsParams)
List grants (GET /api/v1/grants)
func (*Router) ListInvoices ¶
func (a *Router) ListInvoices(w http.ResponseWriter, r *http.Request, params api.ListInvoicesParams)
List invoices (GET /api/v1/billing/invoices)
func (*Router) ListMarketplaceListings ¶
func (a *Router) ListMarketplaceListings(w http.ResponseWriter, r *http.Request, params api.ListMarketplaceListingsParams)
List marketplace listings (GET /api/v1/marketplace/listings)
func (*Router) ListMeterSubjects ¶
GET /api/v1/meters/{meterIdOrSlug}/subjects
func (*Router) ListMeters ¶
func (a *Router) ListMeters(w http.ResponseWriter, r *http.Request, params api.ListMetersParams)
GET /api/v1/meters
func (*Router) ListNotificationChannels ¶
func (a *Router) ListNotificationChannels(w http.ResponseWriter, r *http.Request, params api.ListNotificationChannelsParams)
List notification channels (GET /api/v1/notification/channels)
func (*Router) ListNotificationEvents ¶
func (a *Router) ListNotificationEvents(w http.ResponseWriter, r *http.Request, params api.ListNotificationEventsParams)
List notification evens (GET /api/v1/notification/events)
func (*Router) ListNotificationRules ¶
func (a *Router) ListNotificationRules(w http.ResponseWriter, r *http.Request, params api.ListNotificationRulesParams)
List notification rules (GET /api/v1/notification/rules)
func (*Router) ListPlanAddons ¶
func (a *Router) ListPlanAddons(w http.ResponseWriter, r *http.Request, planId string, params api.ListPlanAddonsParams)
List all available add-ons for plan (GET /api/v1/plans/{planId}/addons)
func (*Router) ListPlans ¶
func (a *Router) ListPlans(w http.ResponseWriter, r *http.Request, params api.ListPlansParams)
List plans (GET /api/v1/plans)
func (*Router) ListPortalTokens ¶
func (a *Router) ListPortalTokens(w http.ResponseWriter, r *http.Request, params api.ListPortalTokensParams)
GET /api/v1/portal/tokens
func (*Router) ListSubjectEntitlements ¶
func (a *Router) ListSubjectEntitlements(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, params api.ListSubjectEntitlementsParams)
List entitlements (GET /api/v1/subjects/{subjectIdOrKey}/entitlements)
func (*Router) ListSubjects ¶
func (a *Router) ListSubjects(w http.ResponseWriter, r *http.Request)
GET /api/v1/subjects
func (*Router) ListSubscriptionAddons ¶
func (a *Router) ListSubscriptionAddons(w http.ResponseWriter, r *http.Request, subscriptionId string)
List subscription addons (GET /api/v1/subscriptions/{subscriptionId}/addons)
func (*Router) MarketplaceAppAPIKeyInstall ¶
func (a *Router) MarketplaceAppAPIKeyInstall(w http.ResponseWriter, r *http.Request, appType api.AppType)
Install a marketplace app by API key (POST /api/v1/marketplace/install/apikey)
func (*Router) MarketplaceAppInstall ¶
Install app (POST /api/v1/marketplace/listings/{type}/install)
func (*Router) MarketplaceOAuth2InstallAuthorize ¶
func (a *Router) MarketplaceOAuth2InstallAuthorize(w http.ResponseWriter, r *http.Request, appType api.AppType, params api.MarketplaceOAuth2InstallAuthorizeParams)
Authorize the installation of a marketplace app by OAuth2 (// (GET /api/v1/marketplace/install/oauth2/authorize))
func (*Router) MarketplaceOAuth2InstallGetURL ¶
func (a *Router) MarketplaceOAuth2InstallGetURL(w http.ResponseWriter, r *http.Request, appType api.AppType)
Get the URL to install a marketplace app by OAuth2 (GET /api/v1/marketplace/install/oauth2)
func (*Router) MigrateSubscription ¶
(POST /api/v1/subscriptions/{subscriptionId}/migrate)
func (*Router) OverrideEntitlement ¶
func (a *Router) OverrideEntitlement(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementIdOrFeatureKey string)
Override an entitlement (PUT /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementIdOrFeatureKey}/override)
func (*Router) PublishAddon ¶
Publish addon (POST /api/v1/addons/{addonId}/publish)
func (*Router) PublishPlan ¶
Publish plan (POST /api/v1/plans/{planId}/publish)
func (*Router) QueryMeter ¶
func (a *Router) QueryMeter(w http.ResponseWriter, r *http.Request, meterIDOrSlug string, params api.QueryMeterParams)
GET /api/v1/meters/{meterIdOrSlug}/query
func (*Router) QueryMeterPost ¶
POST /api/v1/meters/{meterIdOrSlug}/query
func (*Router) QueryPortalMeter ¶
func (a *Router) QueryPortalMeter(w http.ResponseWriter, r *http.Request, meterSlug string, params api.QueryPortalMeterParams)
TODO: migrate to http handler GET /api/v1/portal/meters/{meterSlug}/query
func (*Router) RecalculateInvoiceTaxAction ¶
func (a *Router) RecalculateInvoiceTaxAction(w http.ResponseWriter, r *http.Request, invoiceId string)
Recalculate an invoice's tax amounts (POST /api/v1/billing/invoices/{invoiceId}/tax/recalculate)
func (*Router) ResetEntitlementUsage ¶
func (a *Router) ResetEntitlementUsage(w http.ResponseWriter, r *http.Request, subjectIdOrKey string, entitlementId string)
Reset entitlement (POST /api/v1/subjects/{subjectIdOrKey}/entitlements/{entitlementId}/reset)
func (*Router) RestoreSubscription ¶
(POST /api/v1/subscriptions/{subscriptionId}/restore)
func (*Router) RetryInvoiceAction ¶
Retry a failed synchronization step of the invoice (POST /api/v1/billing/invoices/{invoiceId}/retry)
func (*Router) SimulateInvoice ¶
Simulate an invoice for a customer (POST /api/v1/billing/customers/{customerId}/invoices/simulate)
func (*Router) SnapshotQuantitiesInvoiceAction ¶
func (a *Router) SnapshotQuantitiesInvoiceAction(w http.ResponseWriter, r *http.Request, invoiceId string)
Snapshot quantities for usage based line items (POST /api/v1/billing/invoices/{invoiceId}/snapshot-quantities)
func (*Router) TestNotificationRule ¶
Test notification rule (POST /api/v1/notification/rules/{ruleId}/test)
func (*Router) UninstallApp ¶
Uninstall an app by id (DELETE /api/v1/apps/{id})
func (*Router) UnscheduleCancelation ¶
func (a *Router) UnscheduleCancelation(w http.ResponseWriter, r *http.Request, subscriptionId string)
(POST /api/v1/subscriptions/{subscriptionId}/unschedule-cancelation)
func (*Router) UpdateAddon ¶
Update a addon (PUT /api/v1/addons/{addonId})
func (*Router) UpdateBillingProfile ¶
Update a billing profile (PUT /api/v1/billing/profile/{id})
func (*Router) UpdateCustomer ¶
Update customer (PUT /api/v1/customer/customers/{customerId})
func (*Router) UpdateInvoice ¶
Update an invoice (PUT /api/v1/billing/invoices/{invoiceId})
func (*Router) UpdateMeter ¶
PUT /api/v1/meters/{meterIdOrSlug}
func (*Router) UpdateNotificationChannel ¶
func (a *Router) UpdateNotificationChannel(w http.ResponseWriter, r *http.Request, channelID string)
Update notification channel (PUT /api/v1/notification/channels/{channelId})
func (*Router) UpdateNotificationRule ¶
Update a notification rule (PUT /api/v1/notification/rules/{ruleId})
func (*Router) UpdatePlan ¶
Update a plan (PUT /api/v1/plans/{planId})
func (*Router) UpdatePlanAddon ¶
func (a *Router) UpdatePlanAddon(w http.ResponseWriter, r *http.Request, planId string, planAddonId string)
Update add-on assignment for plan (PUT /api/v1/plans/{planId}/addons/{planAddonId})
func (*Router) UpdateStripeAPIKey ¶
Handle update stripe api key (POST /api/v1/apps/{id}/stripe/api-key)
func (*Router) UpdateSubscriptionAddon ¶
func (a *Router) UpdateSubscriptionAddon(w http.ResponseWriter, r *http.Request, subscriptionId string, subscriptionAddonId string)
Update a subscription addon (PATCH /api/v1/subscriptions/{subscriptionId}/addons/{subscriptionAddonId})
func (*Router) UpsertBillingProfileCustomerOverride ¶
func (a *Router) UpsertBillingProfileCustomerOverride(w http.ResponseWriter, r *http.Request, customerId string)
Create/update a customer override (POST /api/v1/billing/customer/{customerId})
func (*Router) UpsertCustomerAppData ¶
func (a *Router) UpsertCustomerAppData(w http.ResponseWriter, r *http.Request, customerIDOrKey string)
Upsert customer app data (PUT /api/v1/customer/customers/{customerId}/apps/{appId})
func (*Router) UpsertSubject ¶
func (a *Router) UpsertSubject(w http.ResponseWriter, r *http.Request)
POST /api/v1/subjects
func (*Router) VoidInvoiceAction ¶
Void an invoice (POST /api/v1/billing/invoices/{invoiceId}/void)