Objects represent the resources that you can access.
Name | Type | Description |
---|---|---|
id | String! | The id of the feature which is provided by you. |
name | String! | The name of the feature. |
type | FeatureType! | The type of the feature. Either BINARY or CONSUMABLE . |
unitLabel | String | The name of the consumable unit (eg. Message, API Call, etc). Only present if type is CONSUMABLE . |
unitLabelPlural | String | The pluralised name of the consumable unit (eg. Messages, API Calls, etc). Only present if type is CONSUMABLE . |
metadata | JSON | A set of key-value data which was attached by yourself to this object (ie. often additional data deemed useful to store). |
packages | [Package!]! | A list of the packages which are associated with the feature. |
Name | Argument | Argument Type | Return Type | Description |
---|---|---|---|---|
entitlement | userId | String! | Entitlement | A user’s entitlement to the feature. |
limit
and will only return the Entitlement for that package/feature combination.Name | Type | Description |
---|---|---|
id | String! | The id of the package which is provided by you. |
name | String! | The name of the package. |
isAddon | Boolean! | Represents whether the package is an add-on (true ) or a base package (false ). |
status | PackageStatus! | Represents whether the package is a DRAFT , ARCHIVED or PUBLISHED . |
updatedAt | DateTime! | When the package was last updated. |
features | [PackageFeature!]! | A list of the features within the package. |
prices | [PackagePrice!]! | A list of prices which relate to this package. |
Name | Type | Description |
---|---|---|
id | String! | The id of the Feature. |
name | String! | The name of the feature within the package. This can be different than the feature it relates to. |
type | FeatureType! | The type of the feature. Either BINARY or CONSUMABLE . |
limit | Int | Indicates the amount of the feature given in the package (ie. “500” ). Only present if type is CONSUMABLE . |
unitLabel | String | The name of the consumable unit for the feature (eg. Message, API Call, etc). Only present if type is CONSUMABLE . |
unitLabelPlural | String | The pluralised name of the consumable unit for the feature (eg. Messages, API Calls, etc). Only present if type is CONSUMABLE . |
metadata | JSON | A set of key-value data which was attached by yourself to the respective feature object (ie. often additional data deemed useful to store). |
Name | Type | String |
---|---|---|
id | String! | The id of the price as given by your billing provider (ie. price_1L7NHvIiEnRX8aivoxbSWREF ). |
provider | String! | The billing provider to which this price belongs. |
amount | Int! | The amount which users will be charged. |
displayAmount | String! | A read-friendly version of the amount. |
currency | String! | The currency of the amount which will be charged. |
interval | String! | The frequency at which someone will be charged this price. |
Name | Type | Description |
---|---|---|
access | Boolean! | Specifies whether the user has access (true ) or not (false ) to the feature. |
reason | String! | The reason why the user either has access to the feature or not. |
consumption | Consumption | The amount of the feature which the user has used, their overall allowance (budget ), and if they can go over that allowance. |
Name | Type | Description |
---|---|---|
used | Int! | The amount of the feature which has been used by the user. |
budget | Int | The amount of the feature which has been granted to the user. Will return null if unlimited. |
overageEnabled | Boolean! | Flags whether a user can run over the amount of the feature (true ) or if there is a hard limit that should prevent usage (false ). |
Name | Type | Description |
---|---|---|
periodStart | DateTime! | The start of the usage period in ISO 8601 timestamp format. |
periodEnd | DateTime! | The end of the usage period in ISO 8601 timestamp format. |
consumption | String! | The consumption of the feature within the given time period. |
Name | Type | Description |
---|---|---|
id | String! | A Kana-generated identifier for the subscription. |
userId | String! | The id of the user. |
status | SubscriptionStatus! | The status of the subscription of the user to the package. Either ACTIVE or CANCELLED . |
package | Package! | The package which is associated to the subscription. |
Name | Type | Description |
---|---|---|
access | Boolean! | Specifies whether the user has access (true ) or not (false ) to the feature. |
reason | String! | The amount of the feature which the user has used, their overall allowance (budget ), and if they can go over that allowance. |
consumption | Consumption | The amount of the feature which the user has used, their overall allowance (budget ), and if they can go over that allowance. |
Name | Type | Description |
---|---|---|
current | ConsumptionInPeriod | The consumption a the feature in the current period of usage. |
past | [ConsumptionInPeriod!] | A list detailing the previous consumption of a feature within the given periods of usage. |
Name | Type | Description |
---|---|---|
url | String! | The generated URL for a user to navigate to and pay to subscribe to a package. |
Name | Type | Description |
---|---|---|
id | String! | The id of the user which is provided by you. |
billingId | String | The id of the user as given by your billing provider (ie. cus_Lp1bSKob4laHDD ). |
name | String | The name of the user. |
String | The email of the user. | |
metadata | JSON | A set of key-value data which was attached by yourself to this object (ie. often additional data deemed useful to store). |
Name | Type | Description |
---|---|---|
recorded | Boolean! | Specifies whether the usage of the feature was recorded (true ) or not (false ). |
reason | String | The reason why the usage of the feature was either recorded or not. |
Name | Type | Description |
---|---|---|
token | String | The generated token which is scoped to the user. |