Example 1: Cloud Storage and File Cleanup - m3ter Documentation
m3ter Worked Example 1 - YouTube
Suppose you run a SaaS company that provides cloud storage and file cleanup services for corrupted graphics files. You want to charge your customers in US dollars on a monthly basis using the following usage pricing metrics:
- By cumulative volume of corrupted files submitted for storage and cleanup in the month measured in gigabytes, irrespective of how long they remain stored in any given month and irrespective of whether they ever are retrieved. Charge rate is $0.15 per GB for the first 500GB; $0.10 per GB thereafter.
- By count of the number of corrupted files submitted for storage and cleanup in the month, charged at $0.50 per file.
- By an add-on amount each month based on the maximum average clean up processing time required per submitted files in any given month: charged at $12 for up to 4 seconds maximum average processing; $25 for up to 6 seconds maximum average processing; $50 for anything above 6 seconds maximum average processing.
In addition to any usage charges, you want to apply a monthly standing charge of $20. This topic provides a worked example and steps you through the setup required to implement this SaaS usage-based pricing (UBP) model. It goes on to show you how to submit some sample usage data against a test Account, generate a Bill for that Account, and check billing amounts against submitted usage.
Step 1: Create Product
Products represent a product or service that you offer to your end customers. A Meter, Aggregation, Plan Template, Plan, or Pricing typically all belong to a Product. To create a Product:
In the Console, select Products. The Products page opens.
Select Create product. We’ll create a single Product called Revive Graph Standard:
Select Create product.
The Revive Graph Standard Product can now serve as a container for any Meters, Aggregations, Pricing, Plans, and Plan Templates we’ll need for the example.
Step 2: Set up Meter
Meters define the data fields that your system will use to submit usage data to the m3ter platform:
- As well as simple data fields, which collect raw usage data, you can define derived fields that reference and apply calculations to simple fields. For the example, we’ll create three data fields and a single derived field to meet the pricing requirements.
- You can create Product-specific Meters or Global Meters. For the example, we’ll create a single Meter for our example Product.
To create a Meter:
- Select Metering. The Meters page opens.
- In the Product drop-down, select Revive Graph Standard.
- Select Create meter.
Here’s the Meter set up to support the pricing model we want to use in the example:
- Meter details:
- Data fields:
- Derived fields:
For the example, we’ve created the Store N Clean Meter and added the following fields to capture usage data:
- Three Data Fields of type Measure:
- GigaByte Store to collect quantitative data on the file storage volume in Gigabytes.
- Graphic File Submits to collect quantitative data on the number of files submitted.
- Process Time collect quantitative data on the total processing time required to clean files in seconds.
- One Derived Field of type Measure:
- Processing Average to reference two of the Data Fields and apply a calculation to derive the average processing time required per set of submitted files.
- Select Create meter.
We now have a single Meter for the example, which we can use to collect usage data on any Account that consumes the Revive Graph Standard Product. This metered usage data will serve as the basis for the pricing metrics we want to apply to rate Product consumption.
Step 3: Define Aggregations
Aggregations define how to transform into a single number the individual measurements submitted to a Meter Data Field as usage data. For example, you may choose to simply SUM the submitted usage data values. In this way, Aggregations define the usage-based pricing metrics you’ll use to set up pricing for your products and services. For the usage-based pricing model we want to implement in our example, we’ll need to create three Aggregations based on the usage data collected by our Store N Clean Meter. Each Aggregation will target a different Meter field to define a pricing metric:
- For cumulative volume of graphic files submitted for storage and cleanup, we’ll target the GigaByte Store Data Field.
- For number of files submitted for storage and cleanup, we’ll target the Graphic File Submits Data Field.
- For maximum average clean up processing time, we’ll target the Processing Average Derived Field.
To create an Aggregation:
- Select Metering. The Meters page opens.
- Select Aggregations:
- In the Product drop-down, select Revive Graph Standard.
- Select Create aggregation.
Here’s the setup for the first Aggregation:
- Aggregation details:
The Gigabyte Store Aggregation gives us our first pricing metric by:
- Targeting the Gigabyte Store field on the Store N Clean Meter and uses the Sum of the Gigabytes stored.
- We leave the Quantity per unit setting at 1, since we’ll configure a tiered pricing by Gigabyte using this Aggregation.
- Select Create Aggregation.
- Repeat steps 4. and 5. to create another two Aggregations:
Here’s the setup for the second Aggregation:
- Aggregation details:
The Graphic File Submits Aggregation gives us our second pricing metric by:
- Targeting the Graphic File Submits field on the Store N Clean Meter and uses a Sum of file submissions.
- We leave the Quantity per unit setting at 1, since we’ll configure a flat rate pricing by file submissions using this Aggregation.
Here’s the setup for the third Aggregation:
- Aggregation details:
The Processing Average Aggregation gives us our third pricing metric by:
- Targeting the Processing Average derived field on the Store N Clean Meter and uses the Maximum value resulting from the calculation built into the field.
- We leave the Quantity per unit setting at 1, since we’ll configure a tiered pricing by number of seconds using this Aggregation.
Step 4: Create Product Plan
Plans represent a pricing plan for one of your products or services. A Plan is always derived from a Plan Template and inherits settings from the Plan Template which control billing operations, such as billing frequency and currency. You can override some of these settings when you create a Plan from a Plan Template. To meet the example requirements:
- First, we’ll need a Plan Template for the Revive Graph Standard Product. We’ll configure the Plan Template:
- For monthly billing using a specific billing currency.
- To include for a Standing charge to be applied for each billing period.
- Second, we can then create a Product Plan based on the Plan Template. The Plan will then inherit the monthly billing frequency and Standing charge billing amount from the Plan Template.
To create a Product Plan Template:
- Select Pricing. The Plans page opens.
- Select Plan templates:
- In the Product drop-down, select Revive Graph Standard.
- Select Create plan template. The Create page opens.
Here’s the setup for the Plan template details: For the Revive Graph Standard Plan Template we’ve:
- Chosen US dollars as the billing currency.
- Selected a monthly Bill frequency with a Bill interval of 1, which means Accounts put on the Plan will receive a Bill each month for a month’s period of usage.
- Configure the settings for Standing charge and Minimum spend amounts:
- Standing charge settings:
- Set a Standing charge of $20 per month as required for the example.
- For Standing charge billing, leave Use organization-wide configuration checked for (In arrears).
- Set Standing charge interval at 1 to charge this amount on every monthly Bill.
- Set Standing charge offset at 0 to apply this charge from the first Bill.
- Minimum spend settings:
- Omit a Product minimum spend per billing period, since this is not required for the example.
- Select Create plan template. You are returned to the Plan template details page for the new template.
We can now proceed to create a Product Plan for the example based on this template.
- Select Plans:
- In the Product drop-down, select Revive Graph Standard.
- Select Create plan. The Create page opens.
Note that we don’t need to do any Plan template overrides for Standing charge or Minimum spend amounts we want to apply for the example - we configured the Revive Graph Standard Template for the required Standing charge amount of $20 per month, and our new Revive Graph Standard Plan will inherit this setting from the template.
- Select Create plan. You are returned to the Plan details page.
In the next step, we can price this Plan using our Aggregations.
Step 5: Price Product Plan
Pricing allows you to configure the cost of usage data under a specific Plan you apply to an Account, and is used to calculate bills. We can use the Pricing editor in the Console to quickly price up our Product Plan to meet the pricing requirements for the example.
To price Product Plan:
- Select Pricing. The Pricing page opens.
- Select Pricing editor:
- In the Product drop-down, select Revive Graph Standard.
- Select Add plans. The Select plans dialog opens and lists all Plans created for the Revive Graph Standard Product.
- Check Revive Graph Standard Plan and select Confirm:
- The dialog closes and the Plan is added to the Pricing editor page.
- A warning shows telling you: No active pricing configured.
We’ll use the Aggregations we created at Step 3 as usage-based metrics to price the Plan in accordance with the requirements set out in the example.
- Click Add aggregations. A Select aggregations dialog appears and lists all Aggregations created for the Revive Graph Standard Product.
- On the dialog check our three Aggregations:
- GigaByte Store Aggregation
- Graphic File Submits Aggregation
- Processing Average Aggregation
Click Confirm. The dialog closes and the selected Aggregations are added to the Pricing editor for the added Plan.
In the pricing grid, select Create plan pricing for the GigaByte Stored Aggregation. The Create pricing page opens:
Work down the form to enter:
- Pricing details:
- Start and End date/times for the period the pricing will be active for the Plan.
- A Description that will appear for any usage charge line items on Bills, such as Storage Charges.
- Minimum spend settings:
- Ignore these settings - there was no requirement for the example to impose minimum spend amounts for billing.
- Pricing settings:
- Leave the Usage accumulates over the entire plan contract period switch in the default position of disabled.
- Leave the Apply as setting as the default - Debit.
- Pricing type: The pricing requirement was to charge by cumulative volume of corrupted files submitted for storage and cleanup in the month measured in gigabytes - charge rate is $0.15 per GB for the first 500GB; $0.10 per GB thereafter. We can implement this pricing using a Tiered pricing structure with two pricing bands configured:
- Select Create pricing. The Create pricing page closes and the pricing using the Aggregation is shown as active in the pricing grid:
- Repeat steps 9. to 11., using the other two Aggregations we created for pricing the Plan, and use a suitable pricing type and structure for each pricing:
- Graphic File Submits Aggregation. The pricing requirement was to charge by count of the number of corrupted files submitted for storage and cleanup in the month, charged at $0.50 per file. We can use a Tiered structure with a single pricing band without limit to impose this flat rate pricing:
- Processing Average. The pricing requirement was to charge by an add-on amount each month based on maximum average clean up processing time required per submitted files: charged at $12 for up to 4 seconds average processing; $25 for up to 6 seconds average processing; $50 for anything above 6 seconds average processing. We can use a Stairstep pricing type to impose this pricing:
- When you have saved the further two pricings, each will also show as Active Pricing for the Plan in the grid:
We now have a Product Plan priced according to the pricing requirements.
Step 6: Create Test Account and Attach Priced Plan
Accounts represent one of your end-customers, and contain an end-customer’s name and contact details:
- When you attach a priced Plan to an Account, this creates a link between them to create an Account Plan. An Account Plan determines the charges incurred by customers who consume the Product the Plan is priced for.
For this step, we’ll create a test Account for the example and attach our priced Plan to it. To create a test Account and attach Plan:
- In the main Console navigation, select Accounts. The Accounts page opens.
- Select Create account. The Create page opens.
- Enter the Account details:
- Name and Code. Required fields.
- Email Address. In addition to Name and Code, this is also a required field:
- Select Create account. You are returned to the Account details page with the Overview tab selected.
For the worked example, we’ve created the Revive Graph Customer 1 test Account.
- Select the Attached plans tab.
- On the Active and pending attached plans panel, select Create plan attachment. The Create page opens.
- On the Create page, leave the radio button for Plan as default setting and enter the Plan attachment details:
- Use the Product drop-down to select the Product, which is Revive Graph Standard for the example.
- Use the Plan drop-down to select the Plan, which is Revive Graph Standard Plan for the example.
- Select Create plan attachment. On the Attached plans tab, the Account Plan is shown on the Active and pending attached plans panel:
We now have a Revive Graph Customer 1 test Account set up that will be billed according to the pricing schema we’ve configured for the Revive Graph Standard Plan for any metered usage of the Product by the Account.
Step 7: Submit Data to Test Account and Check Bill
We’ll now submit some test usage data to our test Account for the Store N Clean Meter, which will allow us to generate a Bill and check that the usage charges on the Bill for the submitted usage data are correct.
- Select Accounts. On the Accounts page, select the NAME hotlink text of the Revive Graph Customer 1 test Account we created at Step 6. The Account details page opens with the Overview tab selected.
- Select Submit usage:
- Under stage 1: Select a meter, use the Meter drop-down to select the Store N Clean Meter and then select Next. The dialog adjusts to show stage 2: Define measurements and send:
- Enter some test data Values for each of the Data Fields:
- GigaByte Store = 350
- Graphic File Submits = 8
- Process Time = 29
- Select Submit usage. If the measurement is ingested successfully, you’ll see a
{ "result" : "accepted" }message under the Log section of the Submit usage data dialog. - For additional test data measurements, repeat steps 3. to 5.
- On the Account details page, select the Bills tab.
- On the Bills tab, select Run billing. The Run billing dialog appears.
- Select Run billing. The dialog closes and your Bill job is queued.
When the Bill has generated, it will be listed on the Bills tab for the Account. Select the Reference hotlink text to open the Bill in Bill management.
Before checking a sample Bill we’ve generated for the Account, we can calculate manually what the cumulative usage charges should be for each part of the usage-based pricing we’ve implemented:
- GigaBytes Stored. The total amounts to 350 + 650 + 550 = 1,550 GiBy. Total = $180.
- File Submits. The total number of files submitted is 30. Total = $15.
- Processing Average. The maximum average processing time for the three data submissions results from the second submission, where 12 files were submitted and which required a total of 53 seconds processing time. Total = $25.
The Bill for the Account should be the total of these three usage charges = $220 plus the standing charge of $20 per billing period, which amounts to an overall total = $240. Deploying to Production: Having submitted some metered test data against a test Account, generated a Bill for the Account, and confirmed that charges are in accordance with our pricing requirements for consumption of our Product, we can be comfortable deploying our usage-based pricing implementation to live production.