curl --request POST \
--url https://api.unibee.dev/merchant/plan/copy \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"externalPlanId": "<string>",
"planId": 123
}
'{
"code": 123,
"data": {
"plan": {
"amount": 123,
"bindingAddonIds": "<string>",
"bindingOnetimeAddonIds": "<string>",
"cancelAtTrialEnd": 123,
"checkoutUrl": "<string>",
"createTime": 123,
"currency": "<string>",
"description": "<string>",
"disableAutoCharge": 123,
"externalPlanId": "<string>",
"extraMetricData": "<string>",
"gasPayer": "<string>",
"homeUrl": "<string>",
"id": 123,
"imageUrl": "<string>",
"internalName": "<string>",
"intervalCount": 123,
"intervalUnit": "<string>",
"merchantId": 123,
"metadata": {},
"metricLimits": [
{
"metricId": 123,
"metricLimit": 123
}
],
"metricMeteredCharge": [
{
"chargeType": 123,
"graduatedAmounts": [
{
"endValue": 123,
"flatAmount": 123,
"perAmount": 123,
"startValue": 123
}
],
"metricId": 123,
"standardAmount": 123,
"standardStartValue": 123
}
],
"metricRecurringCharge": [
{
"chargeType": 123,
"graduatedAmounts": [
{
"endValue": 123,
"flatAmount": 123,
"perAmount": 123,
"startValue": 123
}
],
"metricId": 123,
"standardAmount": 123,
"standardStartValue": 123
}
],
"multiCurrencies": [
{
"amount": 123,
"autoExchange": true,
"currency": "<string>",
"disable": true,
"exchangeRate": 123
}
],
"planName": "<string>",
"productId": 123,
"publishStatus": 123,
"status": 123,
"taxPercentage": 123,
"trialAmount": 123,
"trialDemand": "<string>",
"trialDurationTime": 123,
"type": 123,
"usVATConfig": {
"active": true,
"fromAddress": {
"address": "<string>",
"city": "<string>",
"countryCode": "<string>",
"state": "<string>",
"verified": true,
"zipCode": "<string>"
},
"nexusAddresses": [
{
"address": "<string>",
"city": "<string>",
"countryCode": "<string>",
"state": "<string>",
"verified": true,
"zipCode": "<string>"
}
],
"sellOnUSOnly": true,
"taxCode": "<string>",
"toAddress": {
"address": "<string>",
"city": "<string>",
"countryCode": "<string>",
"state": "<string>",
"verified": true,
"zipCode": "<string>"
}
}
}
},
"message": "<string>",
"redirect": "<string>",
"requestId": "<string>"
}curl --request POST \
--url https://api.unibee.dev/merchant/plan/copy \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"externalPlanId": "<string>",
"planId": 123
}
'{
"code": 123,
"data": {
"plan": {
"amount": 123,
"bindingAddonIds": "<string>",
"bindingOnetimeAddonIds": "<string>",
"cancelAtTrialEnd": 123,
"checkoutUrl": "<string>",
"createTime": 123,
"currency": "<string>",
"description": "<string>",
"disableAutoCharge": 123,
"externalPlanId": "<string>",
"extraMetricData": "<string>",
"gasPayer": "<string>",
"homeUrl": "<string>",
"id": 123,
"imageUrl": "<string>",
"internalName": "<string>",
"intervalCount": 123,
"intervalUnit": "<string>",
"merchantId": 123,
"metadata": {},
"metricLimits": [
{
"metricId": 123,
"metricLimit": 123
}
],
"metricMeteredCharge": [
{
"chargeType": 123,
"graduatedAmounts": [
{
"endValue": 123,
"flatAmount": 123,
"perAmount": 123,
"startValue": 123
}
],
"metricId": 123,
"standardAmount": 123,
"standardStartValue": 123
}
],
"metricRecurringCharge": [
{
"chargeType": 123,
"graduatedAmounts": [
{
"endValue": 123,
"flatAmount": 123,
"perAmount": 123,
"startValue": 123
}
],
"metricId": 123,
"standardAmount": 123,
"standardStartValue": 123
}
],
"multiCurrencies": [
{
"amount": 123,
"autoExchange": true,
"currency": "<string>",
"disable": true,
"exchangeRate": 123
}
],
"planName": "<string>",
"productId": 123,
"publishStatus": 123,
"status": 123,
"taxPercentage": 123,
"trialAmount": 123,
"trialDemand": "<string>",
"trialDurationTime": 123,
"type": 123,
"usVATConfig": {
"active": true,
"fromAddress": {
"address": "<string>",
"city": "<string>",
"countryCode": "<string>",
"state": "<string>",
"verified": true,
"zipCode": "<string>"
},
"nexusAddresses": [
{
"address": "<string>",
"city": "<string>",
"countryCode": "<string>",
"state": "<string>",
"verified": true,
"zipCode": "<string>"
}
],
"sellOnUSOnly": true,
"taxCode": "<string>",
"toAddress": {
"address": "<string>",
"city": "<string>",
"countryCode": "<string>",
"state": "<string>",
"verified": true,
"zipCode": "<string>"
}
}
}
},
"message": "<string>",
"redirect": "<string>",
"requestId": "<string>"
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Show child attributes
Show child attributes
amount, cent, without tax
binded recurring addon planIds,split with ,
binded onetime addon planIds,split with ,
whether cancel at subscription first trial end,0-false | 1-true, will pass to cancelAtPeriodEnd of subscription
CheckoutUrl
create utc time
currency
description
disable auto-charge, 0-false,1-true
external_user_id
who pay the gas, merchant|user
home_url
image_url
PlanInternalName
period unit count
period unit,day|month|year|week
merchant id
Plan's MetricMeteredCharge
Show child attributes
ChargeType,0-standard pricing 1-graduated pricing
GraduatedAmounts, used for graduated pricing
Show child attributes
EndValue, -1 = infinity value(∞)
FlatAmount,cent
PerAmount,cent
StartValue
MetricId
StandardAmount, cent, used for standard pricing,cent
StandardStartValue, used for standard pricing
Plan's MetricRecurringCharge
Show child attributes
ChargeType,0-standard pricing 1-graduated pricing
GraduatedAmounts, used for graduated pricing
Show child attributes
EndValue, -1 = infinity value(∞)
FlatAmount,cent
PerAmount,cent
StartValue
MetricId
StandardAmount, cent, used for standard pricing,cent
StandardStartValue, used for standard pricing
Plan's MultiCurrencies
Show child attributes
the amount of exchange rate
using https://app.exchangerate-api.com/ to update exchange rate if true, the exchange APIKey need setup first
target currency
disable currency exchange
exchange rate, no setup required if AutoExchange is true
PlanName
product id
1-UnPublish,2-Publish, Use For Display Plan At UserPortal
status,1-editing,2-active,3-inactive,4-soft archive, 5-hard archive
TaxPercentage 1000 = 10%
price of trial period
duration of trial
type,1-main plan,2-addon plan
Show child attributes
Show child attributes
Show child attributes
Show child attributes