The Get list of plans method returns the list of plans of the current reseller or any of its downstream resellers.
GET {base_url}/api/v3/resellers/{reseller_id}/plans
Arguments
|
Name |
Parameter type |
Data type |
Required/Optional |
Description |
||||
|---|---|---|---|---|---|---|---|---|
|
X-Api-Token |
header |
string |
Required |
API token of a manager that performs the operation (see
) |
||||
|
Content-Type |
header |
string |
Required |
Media type of the request. Specify the following: application/vnd.api+json |
||||
|
Accept |
header |
string |
Required |
Supported media types of the answer. Specify the following: application/vnd.api+json |
||||
|
base_url |
path |
string |
Required |
ActivePlatform URL |
||||
|
reseller_id |
path |
integer |
Required |
ID of the current reseller or any of its downstream resellers (see
) |
||||
|
page[size] |
query |
integer |
Optional |
Page navigation: number of elements per page. The default value is 50 |
||||
|
page[number] |
query |
integer |
Optional |
Page navigation: page number |
||||
|
filter[name] |
query |
integer |
Optional |
Filtering the list of plans by |
||||
|
filter[sku] |
query |
integer |
Optional |
Filtering the list of plans by |
||||
|
filter[updated_at]
|
|
string |
Optional |
Filtering plans by the date and time when the plan was updated in the YYYY-MM-DD or YYYY-MM-DDTHH:MM:SS format for the platform time zone or in the specified time zone (for example, YYYY-MM-DDTHH:MM:SSZ for UTC, see RFC 3339). To specify the period, the following filters are used:
|
||||
|
include |
query |
string
|
Optional |
Returns additional information about objects related to a plan. The following objects and possible values are supported:
|
Response model
Request example
GET /api/v3/resellers/1/plans/?page[size]=2&page[number]=78
Host: test.activeplatform.com
Content-Type: application/vnd.api+json
X-Api-Token: vY5fwetestK3gJXZH5uHCw
Accept: application/vnd.api+json
Response example
{
"data": [
{
"id": "367",
"type": "plans",
"attributes": {
"created_at": "2017-07-07T10:06:26.669+03:00",
"updated_at": "2019-11-22T14:13:51.378+03:00",
"status": "active",
"name": "test plan",
"description": "",
"public": true,
"plan_class_id": 1300,
"product_id": 403,
"billing_type": "reservation",
"ancestry": null,
"reseller_id": 1,
"fixed_price": true,
"sku": "91fd106f-4b2c",
"singleton": false,
"auto_renewal": false,
"auto_renewal_disabled": false,
"plan_class": "test",
"product_category_id": 190,
"product_category": "default",
"product_category_public": false,
"product": "Default",
"plan_resources": {
"data": [
{
"id": "2003",
"type": "plan_resources",
"attributes": {
"created_at": "2017-07-07T10:06:38.197+03:00",
"updated_at": "2017-07-07T10:06:38.197+03:00",
"name": "res2",
"measurable": false,
"unit_of_measure": "unit",
"application_template_name": "Auto provisioning",
"included": 0,
"minimum": 0,
"limit": 0,
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0",
"unlimited_units": false,
"public": true,
"status": "active",
"resource_id": 9,
"priority": 0,
"net_costs": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"erp": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"custom_attributes": {}
}
},
{
"id": "2004",
"type": "plan_resources",
"attributes": {
"created_at": "2017-07-07T10:06:38.226+03:00",
"updated_at": "2017-07-07T10:06:38.226+03:00",
"name": "res3",
"measurable": false,
"unit_of_measure": "unit",
"application_template_name": "Auto provisioning",
"included": 0,
"minimum": 0,
"limit": 0,
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0",
"unlimited_units": false,
"public": true,
"status": "active",
"resource_id": 10,
"priority": 1,
"net_costs": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"erp": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"custom_attributes": {}
}
}
]
},
"plan_periods": {
"data": [
{
"id": "818",
"type": "plan_periods",
"attributes": {
"created_at": "2017-07-07T10:06:41.766+03:00",
"updated_at": "2017-07-07T10:06:41.766+03:00",
"duration_value": null,
"duration_type": null,
"setup_fee": "0.0",
"recurring_fee": "0.0",
"transfer_fee": "0.0",
"renewal_fee": "0.0",
"trial": false,
"public": true,
"status": "active",
"description": null,
"endless": true,
"net_costs": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"transfer_fee": "0.0",
"renewal_fee": "0.0"
},
"erp": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"transfer_fee": "0.0",
"renewal_fee": "0.0"
}
}
}
]
},
"available_account_types": {
"data": [
{
"id": "12",
"type": "account_types",
"attributes": {
"created_at": "2016-10-25T05:16:28.789779+0000",
"updated_at": "2017-02-01T12:04:39.227805+0000",
"reseller_id": 1,
"name": "Business",
"ancestry": null,
"default_payment_method_id": 197,
"key": "business",
"name_pattern": "%primary_name",
"use_by_default": false,
"primary_name": "Company name"
}
},
{
"id": "1564",
"type": "account_types",
"attributes": {
"created_at": "2017-03-20T13:34:28.163302+0000",
"updated_at": "2022-09-15T08:33:31.943006+0000",
"reseller_id": 1,
"name": "Personal",
"ancestry": "1562",
"default_payment_method_id": 2,
"key": "personal",
"name_pattern": "%first_name %middle_name %last_name",
"use_by_default": false,
"primary_name": ""
}
}
]
},
"plan_currency": "RUB",
"custom_attributes": {
"vat25": "0"
}
},
"relationships": {
"plan_category": {
"data": {
"id": "190",
"type": "plan_categories"
}
}
}
},
{
"id": "368",
"type": "plans",
"attributes": {
"created_at": "2017-07-07T11:28:07.244+03:00",
"updated_at": "2017-07-07T11:28:07.404+03:00",
"status": "active",
"name": "Plan VSP billing info 7/1",
"description": "The best Plan",
"public": true,
"plan_class_id": 1366,
"product_id": 403,
"billing_type": "reservation",
"ancestry": null,
"reseller_id": 1,
"fixed_price": true,
"sku": "f54f74e9a239",
"singleton": false,
"auto_renewal": true,
"auto_renewal_disabled": false,
"plan_class": "Plan VSP billing info 7-Reservation",
"product_category_id": 190,
"product_category": "default",
"product_category_public": false,
"product": "Default",
"plan_resources": {
"data": [
{
"id": "2005",
"type": "plan_resources",
"attributes": {
"created_at": "2017-07-07T11:28:07.320+03:00",
"updated_at": "2017-07-07T11:28:07.320+03:00",
"name": "Users",
"measurable": null,
"unit_of_measure": "unit",
"application_template_name": "Plan VSP billing info 7",
"included": 1,
"minimum": 1,
"limit": 300,
"setup_fee": "0.0",
"recurring_fee": "249.93",
"overuse_fee": "0.0",
"renewal_fee": "0.0",
"unlimited_units": false,
"public": true,
"status": "active",
"resource_id": 997,
"priority": 0,
"net_costs": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"erp": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"custom_attributes": {}
}
},
{
"id": "2006",
"type": "plan_resources",
"attributes": {
"created_at": "2017-07-07T11:28:07.349+03:00",
"updated_at": "2017-07-07T11:28:07.349+03:00",
"name": "Licenses",
"measurable": null,
"unit_of_measure": "unit",
"application_template_name": "Plan VSP billing info 7",
"included": 0,
"minimum": 0,
"limit": 300,
"setup_fee": "0.0",
"recurring_fee": "249.93",
"overuse_fee": "0.0",
"renewal_fee": "0.0",
"unlimited_units": false,
"public": true,
"status": "active",
"resource_id": 998,
"priority": 1,
"net_costs": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"erp": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"overuse_fee": "0.0",
"renewal_fee": "0.0"
},
"custom_attributes": {}
}
}
]
},
"plan_periods": {
"data": [
{
"id": "819",
"type": "plan_periods",
"attributes": {
"created_at": "2017-07-07T11:28:07.366+03:00",
"updated_at": "2017-07-07T11:28:07.366+03:00",
"duration_value": 1,
"duration_type": "year",
"setup_fee": "4.0",
"recurring_fee": "4.0",
"transfer_fee": "0.4",
"renewal_fee": "5.54",
"trial": false,
"public": true,
"status": "active",
"description": null,
"endless": false,
"net_costs": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"transfer_fee": "0.0",
"renewal_fee": "0.0"
},
"erp": {
"setup_fee": "0.0",
"recurring_fee": "0.0",
"transfer_fee": "0.0",
"renewal_fee": "0.0"
}
}
}
]
},
"available_account_types": {
"data": [
{
"id": "12",
"type": "account_types",
"attributes": {
"created_at": "2016-10-25T05:16:28.789779+0000",
"updated_at": "2017-02-01T12:04:39.227805+0000",
"reseller_id": 1,
"name": "Business",
"ancestry": null,
"default_payment_method_id": 197,
"key": "business",
"name_pattern": "%primary_name",
"use_by_default": false,
"primary_name": "Company name"
}
},
{
"id": "1564",
"type": "account_types",
"attributes": {
"created_at": "2017-03-20T13:34:28.163302+0000",
"updated_at": "2022-09-15T08:33:31.943006+0000",
"reseller_id": 1,
"name": "Personal",
"ancestry": "1562",
"default_payment_method_id": 2,
"key": "personal",
"name_pattern": "%first_name %middle_name %last_name",
"use_by_default": false,
"primary_name": ""
}
}
]
},
"plan_currency": "RUB",
"custom_attributes": {}
},
"relationships": {
"plan_category": {
"data": {
"id": "190",
"type": "plan_categories"
}
}
}
}
],
"links": {
"self": "http://test.activeplatform.com/api/v3/resellers/1/plans/?page%5Bnumber%5D=78&page%5Bsize%5D=2",
"first": "http://test.activeplatform.com/api/v3/resellers/1/plans/?page%5Bnumber%5D=1&page%5Bsize%5D=2",
"prev": "http://test.activeplatform.com/api/v3/resellers/1/plans/?page%5Bnumber%5D=77&page%5Bsize%5D=2",
"next": "http://test.activeplatform.com/api/v3/resellers/1/plans/?page%5Bnumber%5D=79&page%5Bsize%5D=2",
"last": "http://test.activeplatform.com/api/v3/resellers/1/plans/?page%5Bnumber%5D=242&page%5Bsize%5D=2"
}
}