Create Product
POST
https://apisandbox.younium.com/v1/product
All products in Younium are always modeled in the following structure:
- A product always has at least one charge plan.
- A charge plan always has at least one charge.
A simple product in Younium is a product with a single charge plan and a single charge.
There are other possible product configurations:
- Multiple charges – A product with a single charge plan with multiple charges
- Multiple charge plans – A product with multiple charge plans that has single charges
- Full – A product that can have multiple charge plans with multiple charges
Below is a basic example of creating a product of type simple in Younium:
{
name: 'Basic subscription',
productType: 'simple',
category: {
key: 'name',
name: 'Subscriptions'
},
chargePlans: [
{
charges: [
chargeType: 'recurring',
model: 'quantity',
description: 'Subscription fee'
unitOfMeasureId: {
unit: 'pcs',
key: 'unit'
},
priceDetails: [
{
priceCurrencyCode: 'SEK',
priceAmount: 1000
},
{
priceCurrencyCode: 'EUR',
priceAmount: 100
}
]
]
}
]
}