Version 3.0
We use YAML type abbreviations to describe the supported types of fields.
The YAML snippets demonstrating the Pricing2Yaml specification are intentionally incomplete. Certain fields have been omitted for clarity and explanation purposes.
syntaxVersion
- required
- Supported value:
3.0
Version of the Pricing2Yaml specification.
syntaxVersion: "3.0"
Libraries support
| Pricing4Java | Pricing4TS | |
syntaxVersion | ✓ | ✓ |
saasName
- required
- Field type:
str
Name of the pricing.
saasName: "Petclinic"
| Pricing4Java | Pricing4TS | |
saasName | ✓ | ✓ |
version
- optional
- Field type:
string
Specify the version of the pricing. If the field is not provided with a value, the default is the value of the createdAt field as a string
version: "jan-25"
Libraries support
| Pricing4Java | Pricing4TS | |
version | ✓ | ✓ |
createdAt
- required
- Field type:
timestamporstrin ISO 8601 format
Date in which your pricing was modeled.
Timestamp:
createdAt: 2024-11-14
String in ISO 8601:
createdAt: "2024-11-14"
Libraries support
| Pricing4Java | Pricing4TS | |
createdAt | ✓ | ✓ |
url
- optional
- Field type: a
strthat represents anURLmust be begin withhttporhttps.
Field url holds a URL that points to your pricing page.
url: https://example.org/pricing
Libraries support
| Pricing4Java | Pricing4TS | |
url | ✓ | ✓ |
tags
- optional
- Field type:
seqofstr
You add one or more features into a group. These groups help features to be organized when rendering your pricing.
tags:
- Code Management
- Code Workflow
- Collaboration
features:
publicRepositories:
tag: Code Management
privateRepositories:
tag: Code Management
githubActions:
tag: Code Workflow
issues:
tag: Collaboration
Libraries support
| Pricing4Java | Pricing4TS | |
tags | ✓ | ✓ |
currency
- required
- Field type:
str
Currency in which the pricing plans and addOns are selled. Use preferably currency codes for better pricing standarization.
For example USD stands for USA dollars and EUR stands for Euros.
currency: "USD"
Libraries support
| Pricing4Java | Pricing4TS | |
currency | ✓ | ✓ |
billing
- optional, if a map of billing is not provided
billingwill be set by default with:
billing:
monthly: 1
- Field type:
mapoffloatinside range(0..1]
The prices of plans and add-ons may vary based on the billing option chosen by the user when subscribing.
Longer subscription periods offer greater discounts. billing field holds a map
of monthly price reductions to be applied to price field of plans and add-ons.
You are free to put inside the map the billing name that you wish.
Price reductions must be positive values greater than 0 and less than or equal to 1.
Consider the following example:
billing:
monthly: 1
semester: 0.95
annual: 0.90
plans:
STANDARD:
price: 10.00
addOns:
ULTRA:
price: 15.00
Here STANDARD plan costs 10.00 monthly, 9.5 monhtly if billing
by semester and 9.00 monthly if billing annually.
ULTRA add-on costs 15.00 monthly if billing monthly, 14.25 monthly if billing by semester and
13.5 monthly if billing annually.
Libraries support
| Pricing4Java | Pricing4TS | |
billing | ✓ | ✓ |
variables
- optional
- Field type:
map
Plan or add-on price can be computed by specifying a expression using variables.
Think of variables as just a convenient way of storing parts of your equation to
reduce the length of plan or add-on expresssion. You can uses variables
in price expressions by prefixing them with a #.
Consider the following yaml that uses variables in the expression:
plans:
PRO:
price: 9.99
ENTERPRISE:
price: "5 * #x" # 5 * 3
variables:
x: 3
Here ENTERPRISE plan uses variable x inside of the expression by prefixing it with #.
Then variables x will be interpolated in the equation so equation will be
5 * 3 which results in 15.00.
Libraries support
| Pricing4Java | Pricing4TS | |
variables | ✓ | ✓ |
features
- required
- Field type:
map
A map containing your pricing features. Each key of the map is the feature name and its value is a map containing feature attributes.
features:
awesome_feature:
cool_feature:
nice_feature:
# ...
Libraries support
| Pricing4Java | Pricing4TS | |
features | ✓ | ✓ |
features.<name>.description
- optional
- Field type:
str
Brief summary of what features does and offers to your users. Feature descriptions are usually in a collapsable element or in an icon hiding it, see Github pricing descriptions for example.
features:
publicRepositories:
description: Host open source projects in public GitHub repositories, accessible via web or command line.
Public repositories are accessible to anyone at GitHub.com."
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.description | ✓ | ✓ |
features.<name>.tag
- optional
- Field type:
str
Name of the group where that feature belongs. First defined a
tags block in order to put a field here.
tags:
- Code Management
features:
publicRepositories:
tag: Code Management
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.tag | ✓ | ✓ |
features.<name>.type
- required
- Field type:
str - Supported values: one of
AUTOMATION,DOMAIN,GUARANTEE,INFORMATION,INTEGRATION,MANAGEMENT,PAYMENTorSUPPORT
Automation: they permit to configure the system in order to perform some actions autonomously or track thresholds and notify the user if anyone is exceeded. It also includes any task performed by a bot or AI, such as predictions, generative AI, etc...
features:
codeOwners:
description:
Automatically request reviews or require approval by selected contributors
when changes are made to sections of code that they own.
type: AUTOMATION
automationType: TRACKING
Domain: provide functionality related to the domain of the system, allowing to perform new operations or using exclusive services.
features:
publicRepositories:
description:
Host open source projects in public GitHub repositories, accessible via
web or command line. Public repositories are accessible to anyone at
GitHub.com.
type: DOMAIN
Guarantee: technical commitments of the company that operates the system towards the users.
features:
dataCypher:
description: Data encryption at rest and in transit.
type: GUARANTEE
Information: allow to see, use, visualize or extract additional data from your features.
features:
auditLogs:
description:
Audit logs: Audit logs provide a record of changes and usage in the
Enterprise Grid plan. You can view audit logs directly in Slack, export
them in CSV format, and use the audit logs API to create custom monitoring
tools.
type: INFORMATION
Integration: permit users to interact with the system through its API, or to use functionalities from external third-party software within the system.
features:
adminAnalyticsAPI:
description: Retrieve analytics data for a specific date in a
compressed JSON file format.
type: INTEGRATION
integrationType: API
Management: are focused on team leaders and system administrators. They ease the supervision, organization and guidance of projects, and allow the configuration of accounts and organization-based restrictions and rules.
features:
customUserGroups:
description:
Custom user groups: Facilitate receiving notifications and communicating
with entire teams, departments, and groups.
type: MANAGEMENT
Support: expose the granularity of customer support offered within the plans.
features:
enterpriseSupport:
description: Custom support for our business partners
type: SUPPORT
Payment: specify payment conditions and possibilities.
features:
paymentMethod:
type: PAYMENT
defaultValue:
- INVOICE
- OTHER
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.type | ✓ | ✓ |
features.<name>.valueType
- required
- Field type:
str - Supported values: one of
BOOLEAN,NUMERICorTEXT
Field valueType sets the defaultValue type signature of the feature you are
modeling. For example, if your feature valueType is BOOLEAN you must put
true or false in the defaultValue field, if valueType is NUMERIC you must put
a number and in the case of TEXT then defaultValue has to be a string or a list of string.
features:
boolean-feature:
valueType: BOOLEAN
defaultValue: false
numeric-feature:
valueType: NUMERIC
defaultValue: 0
text-feature:
valueType: TEXT
defaultValue: Pricing2Yaml is awesome!
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.valueType | ✓ | ✓ |
features.<name>.defaultValue
- required
- Field type is
boolifvalueTypeis set toBOOLEAN - Field type is
intifvalueTypeset toNUMERIC - Field type is
strorseqof payment methods ifvalueTypeis set toTEXT
This field holds the default value of your feature. All default values are shared in your plan and addons. You can
override your features values in plans.<plan_name>.features or in addOns.<addOn_name>.features
section of your pricing.
Supported payment methods are: CARD, GATEWAY, INVOICE, ACH, WIRE_TRANSFER or OTHER.
To help you understand how overriding features works, imagine you have the following pricing matrix:
| SILVER | GOLD | PLATINUM | |
|---|---|---|---|
| supportPriority | LOW | MEDIUM | HIGH |
If you want your supportPriority to be different in your GOLD and PLATINUM plans you
will do the following using Pricing2Yaml syntax:
features:
supportPriority:
valueType: TEXT
defaultValue: LOW
plans:
SILVER:
features: null
GOLD:
features:
supportPriority:
value: MEDIUM
PLATINUM:
features:
supportPriority:
value: HIGH
Notice that SILVER features are null, meaning that, supportPriority
will have the value LOW as you have previously define it in the features block.
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.defaultValue | ✓ | ✓ |
features.<name>.expression
A boolean expression defining the conditions under which the feature is enabled. This expression can reference other features and usage limits using the pricingContext and subscriptionContext objects.
Respectively, the pricingContext will be an object with the following structure:
{
features: {
<feature-name>: boolean | string,
...
},
usageLimits: {
<limit-name>: number | boolean,
...
}
}
while the subscriptionContext will have the following structure:
{
<usage-level-name>: number,
...
}
With this in mind, the expression field can be used to define the conditions under which a feature is enabled.
As the pricingContext utilized within the expression repressents as a map the current configuration of a user, you should be aware of using either features or usageLimits to access the atribute you want to evaluate. The features key will have the value or defaultValue of the feature with the given key, while usageLimits will return the equivalent of a declared usage limit.
For example, if we have a feature feature1 that should only be enabled if the user has not exceeded the usage limit usageLimit1, the expression would be:
feature1:
description: Pets description
valueType: BOOLEAN
defaultValue: true
expression: subscriptionContext['usageLimit1'] < pricingContext['usageLimits']['usageLimit1']
...
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.expression | ✓ | ✓ |
features.<name>.serverExpression
- OPTIONAL
It is similar to expression, but this expression is evaluated on the server side, during the pricing evaluation process. It is particularly useful when expressions for client rendering do not coincide with server access ones. If not provided, the value of the expression field is used instead.
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.serverExpression | ✓ | ✓ |
features.<name>.automationType
- If feature
typeisAUTOMATIONthis field is required - Field type:
str - Supported values: one of
BOT,FILTERING,TRACKINGorTASK_AUTOMATION
Type of the automation feature.
BOT: every automation feature that depends on machine learning algorithms or LLMs.
features:
postbot:
description: "https://learning.postman.com/docs/getting-started/basics/about-postbot/"
type: AUTOMATION
automationType: BOT
FILTERING: every automation feature that filters information. For example, spam filtering of mail clients.
features:
emailSpamFilter:
description: "Help protect your business against spam and malware with cloud-based email filtering"
type: AUTOMATION
automationType: FILTERING
TRACKING: every automation feature that monitors a metric and notify the user when reaching his threshold. For example, features that triggers some kind of event in the system like reaching the limit of API calls.
features:
dependabotAlerts:
description: "Get notified when there are new vulnerabilities affecting dependencies in your repositories."
type: AUTOMATION
automationType: TRACKING
TASK_AUTOMATION: every automation feature that permit users to automate tasks. For example, automatically moving the issues to "Done" when thery are closed in the Github kanban board.
features:
dependabotVersionUpdates:
description: "Keep projects up-to-date by automatically opening pull requests that update out-of-date dependencies."
type: AUTOMATION
automationType: TASK_AUTOMATION
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.automationType | ✓ | ✓ |
features.<name>.docUrl
- If feature
typeisGUARANTEEthis is required - Field type:
str
URL redirecting to the guarantee or compliance documentation.
features:
enterpriseGradeSecurity:
description: "https://www.wrike.com/features/admin-security/"
type: GUARANTEE
docUrl: "https://www.wrike.com/features/admin-security/"
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.docUrl | ✓ | ✓ |
features.<name>.integrationType
- If feature
typeisINTEGRATIONthis is required - Field type:
str - Supported values: one of
API,EXTENSION,IDENTITY_PROVIDER,WEB_SAAS,MARKETPLACEorEXTERNAL_DEVICE
Type of the integration feature.
API: every feature that includes an internal API that developers can consume.
adminAnalyticsAPI:
description: "Admin analytics API: Retrieve analytics data for a specific date in a compressed JSON file format."
type: INTEGRATION
integrationType: API
EXTENSION: every integration feature that extends your SaaS using an external system. For example a browser extension or code editor extension like VSCode.
features:
copilotIDEIntegration:
description: "Get IDE integration from Copilot in your IDE and mobile devices."
type: INTEGRATION
integrationType: EXTENSION
IDENTITY_PROVIDER: every integration feature, that involves a process to authenticate users internally or externally. For example Single Sign On (SSO) or LDAP.
features:
ldap:
description: Access GitHub Enterprise Server using your existing accounts and centrally manage repository access.
type: INTEGRATION
integrationType: IDENTITY_PROVIDER
WEB_SAAS: every integration feature that involves an external SaaS. For example,
sync your calendar with Outlook. Usage of features.<name>.pricingUrls is required.
features:
githubIntegration:
description: "Link your Overleaf projects directly to a GitHub repository that
acts as a remote repository for your overleaf project. This allows you to
share with collaborators outside of Overleaf, and integrate Overleaf into more complex workflows."
type: INTEGRATION
integrationType: WEB_SAAS
pricingsUrls:
- https://github.com/pricing
MARKETPLACE: every integration feature that offers many posibilities to integrate with other systems. For example a marketplace that offers widgets.
features:
githubApps:
description: Install apps that integrate directly with GitHub's API to improve
development workflows or build your own for private use or publication in the GitHub Marketplace."
type: INTEGRATION
integrationType: MARKETPLACE
EXTERNAL_DEVICE: every integration feature that involves interactiing with an outer device, like a mobile, a computer desktop. For example a 2FA feature.
features:
apps:
description: "Track time using a mobile app, desktop app, and browser extension."
type: INTEGRATION
integrationType: EXTERNAL_DEVICE
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.integrationType | ✓ | ✓ |
features.<name>.pricingUrls
- If feature
typeisINTEGRATIONandintegrationTypeisWEB_SAASthis field is required - Field type:
seqofstr
You can specify a list of URLs linking to the associated pricing page of third party integrations that you offer in your pricing.
features:
googleWorkspaceIntegration:
type: INTEGRATION
integrationType: WEB_SAAS
pricingURLs:
- https://workspace.google.com/pricing
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.pricingUrls | ✓ | ✓ |
features.<name>.render
- optional
- Field type: one of
AUTO,DISABLED,ENABLED; if not providedrenderis set toAUTOby default
Choose the behaviour when displaying a feature of the pricing. This field will only take effect on the Pricing2Yaml editor.
features:
googleWorkspaceIntegration:
render: DISABLED
Depending on the selected value, the feature will be rendered differently:
- If
renderis set to AUTO, no action is taken. - If
renderis set to ENABLED for a feature that has associated usage limits, the pricing will include one row showing the feature’s boolean value (i.e., whether it is available and for which plans). In addition, a separate row will be rendered for each associated usage limit, this time displaying the usage limit’s name in the table’s name column, along with its corresponding values. - If
renderis set to DISABLED, the feature will not be displayed in the pricing, nor will its associated usage limits.
If a usage limit is linked to multiple features and at least one of them is not set to DISABLED, then the usage limit will still be rendered—using its own name instead of the name of the feature.
Libraries support
| Pricing4Java | Pricing4TS | |
features.<name>.render | ✗ | ✓ |
usageLimits
- optional
- Field type:
map
A map containing the usage limits of your pricing. Each entry of this map will be the name of the corresponding usage limit.
usageLimits:
maxPets:
collaborators:
githubActionsQuota:
# ...
| Pricing4Java | Pricing4TS | |
usageLimits | ✓ | ✓ |
usageLimits.<name>.description
- optional
- Field type:
str
Brief summary of what the usage limit restricts.
usageLimits:
useMessagesAccess:
description: "The number of days you can access message and file information."
| Pricing4Java | Pricing4TS | |
usageLimits.<name>.description | ✓ | ✓ |
usageLimits.<name>.type
- required
- Field type:
str - Supported values: one of
NON_RENEWABLEorRENEWABLE
Field that indicates the type of usage limit based on our clasification of usage limits.
NON_RENEWABLE: define a static limit towards which the user approaches, and that will remain until the end of the subscription.
usageLimits:
uploadSizeLimit:
type: NON_RENEWABLE
RENEWABLE: their limit is reset after a period of time, could be a day, week, month...
usageLimits:
githubCodepacesCoreHours:
type: RENEWABLE
Libraries support
| Pricing4Java | Pricing4TS | |
usageLimits.<name>.type | ✓ | ✓ |
usageLimits.<name>.period
- required, if usageLimits.<name>.type is
RENEWABLE. This field will be set by default with:
usageLimits:
sampleLimit:
...
type: RENEWABLE
period:
value: 1
unit: MONTH
-
Field type: map containing the period of the usage limit. It contains two fields:
value: integer representing the period value.unit: string representing the period unit. Possible values are:SEC,MIN,HOUR,DAY,MONTH,YEAR.
Each value of the unit field corresponds to the following time periods (in seconds):
SEC= 1 secondMIN= 60 secondsHOUR= 60 * 60 = 3600 secondsDAY= 60 * 60 * 24 = 86400 secondsMONTH= 60 * 60 * 24 * 30 = 2592000 secondsYEAR= 60 * 60 * 24 * 365 = 31536000 seconds
Libraries support
| Pricing4Java | Pricing4TS | |
usageLimits.<name>.period | ✗ | ✓ |
usageLimits.<name>.trackable
- required, if usageLimits.<name>.type is
NON_RENEWABLE. This field will be set by default with:
usageLimits:
sampleLimit:
...
type: NON_RENEWABLE
trackable: false
Flag indicating whether the usage of a feature linked to a "NON_RENEWABLE" usage limit must be tracked within the user’s subscription. If true, the system records usage to ensure the limit is not exceeded during feature evaluations.
EXAMPLE: If you own an online conference service –like zoom– you may have this two NON_RENEWABLE limits:
maxMeetingDuration(e.g. 1 hour)maxRecordingsCloudStorage(e.g. 10 GB)
The former do not need to be tracked within the user subscription, since it's a limit that affects meetings. However, the latter must be tracked, since it affects users theirselves and their storage.
Therefore, you can model this situation as follows:
usageLimits:
maxMeetingDuration:
...
type: NON_RENEWABLE
trackable: false
maxRecordingsCloudStorage:
...
type: NON_RENEWABLE
trackable: true
Libraries support
| Pricing4Java | Pricing4TS | |
usageLimits.<name>.trackable | ✗ | ✓ |
usageLimits.<name>.valueType
- required
- Field type:
str - Supported values: one of
BOOLEAN,NUMERICorTEXT
Field valueType sets the defaultValue type signature of the usage limit you are
modeling. For example, if your usage limit valueType is BOOLEAN you must put
true or false in the defaultValue field, if valueType is NUMERIC you must put
a number and in the case of TEXT then defaultValue has to be a string.
usageLimits:
privateAccessToCodeRepositories:
valueType: BOOLEAN
defaultValue: false
storageQuota:
valueType: NUMERIC
defaultValue: 30
support:
valueType: TEXT
defaultValue: LOW
Libraries support
| Pricing4Java | Pricing4TS | |
usageLimits.<name>.valueType | ✓ | ✓ |
usageLimits.<name>.defaultValue
- required
- Field type is
boolifvalueTypeis set toBOOLEAN - Field type is
intifvalueTypeset toNUMERIC - Field type is
strifvalueTypeis set toTEXT
This field holds the default value of your usage limit. All default values are shared in your plan and addons. You can
override your usage limits values in plans.<plan_name>.usageLimits or in addOns.<addOn_name>.usageLimits
section of your pricing.
To help you understand how overriding usage limits works, imagine you have the following pricing matrix:
| SILVER | GOLD | PLATINUM | |
|---|---|---|---|
| collaborators | 1 | 6 | 10 |
If you want your collaborators usage limit to be different in your GOLD and PLATINUM plans you
will do the following using Pricing2Yaml syntax:
usageLimits:
collaborators:
valueType: NUMERIC
defaultValue: 1
plans:
SILVER:
usageLimits: null
GOLD:
usageLimits:
collaborators:
value: 6
PLATINUM:
usageLimits:
collaborators:
value: 10
Libraries support
| Pricing4Java | Pricing4TS | |
usageLimits.<name>.defaultValue | ✓ | ✓ |
usageLimits.<name>.unit
- required
- Field type:
str
Measure of the usage limit.
Here is an example using unit from Github pricing:
usageLimits:
githubActionsQuota:
unit: minute/month
Libraries support
| Pricing4Java | Pricing4TS | |
usageLimits.<name>.unit | ✓ |