View as Markdown

llms.txt

The API reference isn't available right now

This instance couldn't load its API specification. The reference returns as soon as the specification is readable again.

Back to the API reference

No such operation

This instance documents no operation under that identifier. It may have been renamed, or it may belong to a feature this installation hasn't enabled.

Back to the API reference

This reference may be out of date

This instance couldn't reach its API specification on the last attempt, so this page shows the copy fetched before that. Anything added or changed since then is missing here, and the reference updates itself as soon as the specification is readable again. Last fetched 2026-12-03 02:41 UTC.

API reference Merchant Billing

Price Plans: Gets a reseller's effective default price plan.

GET /api/price-plans/effective-default deprecated

Requires: MerchantBilling.PricePlans, merchant scope.

The reseller's own default plan, or, when it has none, the nearest default up the reseller hierarchy. Only a default plan that is active and in effect for the current billing period counts. When no level has such a plan, the response is `204 No Content` with an empty body, not an error. A reseller user may ask about its own reseller or one below it; any other reseller answers `404`.

Signed in, you can send this request to your own sandbox merchant from the console and read the answer. Sign in to try it.

Example request

Every block below sends the same request. Replace {{BASE_URL}} with the address of the API you are calling and {{API_KEY}} with your own key.

The request body is a . See the Request body section below for its fields.

Code sample language

cURL

curl -X GET "{{BASE_URL}}/api/price-plans/effective-default" \
  -H "api-key: {{API_KEY}}"

PowerShell

$headers = @{
    'api-key' = '{{API_KEY}}'
}

$response = Invoke-RestMethod -Method GET -Uri '{{BASE_URL}}/api/price-plans/effective-default' `
    -Headers $headers

npm install @winkpg/winkpg-api

TypeScript (SDK)

import { Configuration, MerchantBillingApi } from '@winkpg/winkpg-api';

const api = new MerchantBillingApi(new Configuration({
  basePath: '{{BASE_URL}}',
  apiKey: '{{API_KEY}}',
}));

const { data } = await api.pricePlansGetEffectiveDefaultPlan();

TypeScript (raw HTTP)

const response = await fetch('{{BASE_URL}}/api/price-plans/effective-default', {
  method: 'GET',
  headers: {
    "api-key": "{{API_KEY}}",
  },
});

const data = await response.json();

dotnet add package WinkPg.Api.Client

C# (SDK)

using WinkPg.Api.Client.Api;
using WinkPg.Api.Client.Client;

var config = new Configuration { BasePath = "{{BASE_URL}}" };
config.AddApiKey("api-key", "{{API_KEY}}");

var api = new MerchantBillingApi(config);
var result = await api.PricePlansGetEffectiveDefaultPlanAsync();

C# (raw HTTP)

using var http = new HttpClient { BaseAddress = new Uri("{{BASE_URL}}") };

var request = new HttpRequestMessage(new HttpMethod("GET"), "/api/price-plans/effective-default");
request.Headers.Add("api-key", "{{API_KEY}}");

var response = await http.SendAsync(request);
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();

pip install winkpg-api

Python (SDK)

import winkpg_api

configuration = winkpg_api.Configuration(host="{{BASE_URL}}")
configuration.api_key["ApiKey"] = "{{API_KEY}}"

with winkpg_api.ApiClient(configuration) as client:
    api = winkpg_api.MerchantBillingApi(client)
    result = api.price_plans_get_effective_default_plan()

pip install requests

Python (raw HTTP)

import requests

headers = {
    "api-key": "{{API_KEY}}",
}

response = requests.request(
    "GET",
    "{{BASE_URL}}/api/price-plans/effective-default",
    headers=headers,
)
response.raise_for_status()
data = response.json()

Parameters

Name In Type Description
resellerId required query string (uuid) The reseller to resolve the default for, sent as a query parameter.
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
suppressNulls required query boolean If true, omit properties with null values.
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

Request body

application/json , required

Field Type Description

This request body has no documented fields.

Responses

Response status

The effective default plan. It can belong to a reseller above the one you asked about.

Body: PricePlanDto PricePlanDto Each item has these fields.

Field Type Description
id required string (uuid)
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
creationTime required string (date-time) The date and time when this entity was created.
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
creatorId required string (uuid) The ID of the user who created this entity. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
lastModificationTime required string (date-time) The date and time when this entity was last modified. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
lastModifierId required string (uuid) The ID of the user who last modified this entity. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
isDeleted required boolean Indicates whether this entity has been deleted.
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
deleterId required string (uuid) The ID of the user who deleted this entity, if it is deleted. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
deletionTime required string (date-time) The date and time when this entity was deleted, if it is deleted. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
resellerId required string (uuid) nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
resellerName required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
name required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
description required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
currency required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
isDefault required boolean nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
isActive required boolean nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
effectiveFrom required string (date-time) nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
effectiveTo required string (date-time) nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
rateEntries required array of PricePlanRateEntryDto array of PricePlanRateEntryDto nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

Fields of each PricePlanRateEntryDto:

Field Type Description
id required string (uuid) The entry's identifier within the plan. Leave it out on a new entry.
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
skuCode required string Registered SKU code this entry prices. Null when `skuGroupCode` is set. Conditional: When SkuCode is not empty. Max length: 64. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
skuGroupCode required string Registered billing-group code this catch-all entry prices. Null when `skuCode` is set. Conditional: When SkuGroupCode is not empty. Max length: 64. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
displayNameOverride required string An optional name for the invoice line in place of the SKU's own display name. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
pricingStrategy required MerchantBillingPricingStrategy MerchantBillingPricingStrategy How the entry's charge is calculated. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
Fixed A fixed amount per billing period regardless of usage quantity.
PerUnit A per-unit rate multiplied by the usage quantity.
Tiered Per-unit rates that vary by quantity brackets (tiers).
FixedPlusPercentage A fixed base amount plus a percentage of the transaction amount or volume.
buyRate required number (double) The amount the reseller pays upstream, in the plan's currency: per unit for a per-unit entry, per billing period for a fixed entry. Conditional: When BuyRate is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
sellRate required number (double) The amount the merchant is charged, in the plan's currency: per unit for a per-unit entry, per billing period for a fixed entry. Conditional: When SellRate is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
tiers required array of PricingTierDto array of PricingTierDto The quantity brackets of a tiered entry. Conditional: When Tiers is not null and Tiers.Count > 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
fixedComponent required number (double) The fixed base amount of a fixed-plus-percentage entry, per billing period, in the plan's currency. Conditional: When FixedComponent is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
percentageComponent required number (double) The percentage of a fixed-plus-percentage entry, as a whole percent (2.5 means 2.5%), applied to the base `percentageBase` names. Conditional: When PercentageComponent is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
percentageBase required PercentagePricingBase PercentagePricingBase What the percentage of a fixed-plus-percentage entry is applied to. Conditional: When PercentageBase is not null. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
TransactionAmount Deprecated. Prices the period's total amount, exactly as TotalVolume does. Still accepted so stored rate entries keep validating; choose TotalVolume instead.
TotalVolume Percentage applied to the total amount recorded for the billing period. Refunds and reversals add to the base like sales.
NetVolume Percentage applied to the period's amount net of refunds and reversals: a SKU that reduces volume (a refund or a reversal) subtracts its amount instead of adding it, and the base never goes below zero. A single SKU that does not reduce volume prices exactly as TotalVolume; a single SKU that does prices a zero base.
includedQuantity required integer (int64) The number of units each billing period that are free before the entry charges. Conditional: When IncludedQuantity is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
minimumCharge required number (double) The least the entry charges the merchant in a billing period, in the plan's currency. Conditional: When MinimumCharge is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
maximumCharge required number (double) The most the entry charges the merchant in a billing period, in the plan's currency. Conditional: When MaximumCharge is not null. Must be >= 0. Conditional: When MinimumCharge is not null and MaximumCharge is not null. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
sortOrder required integer (int32) The position of the entry's line on the invoice, lowest first. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
isEnabled required boolean Whether the entry charges. A disabled entry stays on the plan and charges nothing. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

This body has no documented fields.

customItems required array of PricePlanCustomItemDto array of PricePlanCustomItemDto nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

Fields of each PricePlanCustomItemDto:

Field Type Description
id required string (uuid) The item's identifier within the plan. Leave it out on a new item.
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
name required string The name printed on the merchant's invoice line. nullablemax length 128
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
description required string An optional description of the charge. Conditional: When Description is not empty. Max length: 500. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
chargeType required CustomChargeType CustomChargeType How often the charge recurs. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
OneTime Charged once only, for the billing period of the month the assignment started.
Monthly Charged every monthly billing period.
Quarterly Charged every third billing period, counted from the month the assignment started.
Annual Charged every twelfth billing period, counted from the month the assignment started.
buyAmount required number (double) The amount the reseller pays upstream for this item each time it is charged, in the plan's currency. Conditional: When BuyAmount is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
sellAmount required number (double) The amount the merchant is charged for this item each time it is charged, in the plan's currency. Conditional: When SellAmount is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
dependencySkuCode required string A SKU code the merchant must have used in the billing period for this item to be charged, or null to charge it unconditionally. Conditional: When DependencySkuCode is not empty. Max length: 64. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
dependencyMinQuantity required integer (int64) The least number of units of `dependencySkuCode` the merchant must have used in the billing period for this item to be charged. Null means one. Conditional: When DependencyMinQuantity is not null. Must be >= 0. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

This body has no documented fields.

pricedEnvironments required array of UsageEnvironment array of UsageEnvironment The usage environments this plan's enabled rate entries price, in ascending order: `Production`, `Sandbox`, both, or empty when no enabled entry resolves to a registered SKU. A merchant is metered against the SKU family of its own environment, so a plan that prices only production usage bills a Sandbox-environment merchant nothing. nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
Production Production environment. Default for all SKUs.
Sandbox Sandbox/developer portal environment with separate quotas.
concurrencyStamp required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

This response has no documented body fields.

No level of the reseller hierarchy has a default plan in effect. The response has no body.

Body: Each item has these fields.

Field Type Description

This response has no body.

The request was refused because a rate limit was exceeded, or because something a later retry can clear stopped it. A rate limit refusal carries an `application/problem+json` body: wait at least the interval `Retry-After` names before retrying, then back off. Limits are tuned per deployment, so read the allowance from the response headers rather than assuming a fixed ceiling. Any other refusal carries the standard error envelope as `application/json`, and its `error.code` names the cause.

Body: RemoteServiceErrorResponse RemoteServiceErrorResponse Each item has these fields.

Field Type Description
error required RemoteServiceErrorInfo RemoteServiceErrorInfo
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

This response has no documented body fields.

  1. 400 Bad Request Bad request. The request was malformed or failed validation. When validation rejected it, `error.validationErrors` names each member at fault and why.
  2. 401 Unauthorized Unauthorized. The request carried no API key or signed-in session, or the key it carried is invalid, revoked or expired.
  3. 403 Forbidden Forbidden. The API key lacks the scope this operation needs, the signed-in user lacks the permission, or a business rule refused the request. The error code in the body names the reason.
  4. 404 Not Found The reseller is not one you may ask about.
  5. 500 Internal Server Error Internal server error. The platform failed unexpectedly while handling the request. If it keeps failing, contact support and quote the correlation id, which the response carries in the `X-Correlation-Id` header and as `error.data.correlationId`.
  6. 501 Not Implemented Not implemented. The operation is declared but has no implementation on this deployment, so no request to it can succeed. Retrying does not help.
  7. default The request failed. The body carries the standard error envelope: a machine-readable `error.code`, a human-readable `error.message`, and `error.validationErrors` when the failure was a validation rejection. The error reference lists the values `error.code` can take.The request failed. The body carries the standard error envelope: a machine-readable `error.code`, a human-readable `error.message`, and `error.validationErrors` when the failure was a validation rejection. The error reference lists the values `error.code` can take.

Body: RemoteServiceErrorResponse RemoteServiceErrorResponse Each item has these fields.

Field Type Description
error required RemoteServiceErrorInfo RemoteServiceErrorInfo
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

Fields of RemoteServiceErrorInfo:

Field Type Description
code required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
message required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
details required string nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
data required object nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.
validationErrors required array of RemoteServiceValidationErrorInfo array of RemoteServiceValidationErrorInfo nullable
Values: Values combine: send one or more member names separated by a comma and a space, or the integer sum of their values. Responses carry the names.

This body has no documented fields.

This response has no documented body fields.

Errors

A failed request returns the platform error envelope. The error reference lists every value error.code can carry and shows the four response shapes.

Codes declared by Merchant Billing

Authentication

  • ApiKey with scopes

Reconnecting to the server

Could not reconnect

This session has ended

Attempt 1

Your work on this page is still here. Retrying keeps it; reloading starts the page again.

The server no longer holds this page's state, so it has to be loaded again.