import 'package:forestvpn_api/api.dart';
All URIs are relative to https://api.forestvpn.com/v2
Method | HTTP request | Description |
---|---|---|
cancelSubscription | DELETE /billing/subscriptions/{subscriptionID}/ | Cancel subscription |
createPaymentMethodStripeSetupIntent | POST /billing/payment-methods/stripe/setup-intents/ | Create stripe's setup intent for add new payment method. |
createSubscription | POST /billing/subscriptions/ | Create subscription |
deletePaymentMethod | DELETE /billing/payment-methods/{paymentMethodID}/ | Delete payment method |
getBillingAccount | GET /billing/account/ | Billing account info |
getBillingBundle | GET /billing/bundles/{bundleID}/ | Bundle info |
getBillingPaymentOption | GET /billing/payment-options/{paymentOptionID}/ | Payment option info |
getBillingProduct | GET /billing/products/{productID}/ | Product info |
getPaymentMethod | GET /billing/payment-methods/{paymentMethodID}/ | Payment method info |
getSubscription | GET /billing/subscriptions/{subscriptionID}/ | Subscription info |
getSubscriptionItem | GET /billing/subscription-items/{subscriptionItemID}/ | Subscription item info |
listBillingBundles | GET /billing/bundles/ | Billing bundles list |
listBillingFeatures | GET /billing/features/ | Billing feature list |
listBillingPaymentOptions | GET /billing/payment-options/ | Billing payment option list |
listBillingProducts | GET /billing/products/ | Billing products list |
listPaymentMethods | GET /billing/payment-methods/ | Payment method list |
listSubscriptionItems | GET /billing/subscription-items/ | Subscription items list |
listSubscriptions | GET /billing/subscriptions/ | Billing subscriptions list |
reactivateSubscription | POST /billing/subscriptions/{subscriptionID}/reactivate/ | Reactivate subscription |
updateBillingAccount | PATCH /billing/account/ | Update billing account |
updateSubscriptionItem | PATCH /billing/subscription-items/{subscriptionItemID}/ | Update subscription item |
cancelSubscription(subscriptionID)
Cancel subscription
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String subscriptionID = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String |
try {
api.cancelSubscription(subscriptionID);
} catch on DioError (e) {
print('Exception when calling BillingApi->cancelSubscription: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
subscriptionID | String |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
StripeSetupIntent createPaymentMethodStripeSetupIntent(createStripeSetupIntentRequest)
Create stripe's setup intent for add new payment method.
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final CreateStripeSetupIntentRequest createStripeSetupIntentRequest = ; // CreateStripeSetupIntentRequest |
try {
final response = api.createPaymentMethodStripeSetupIntent(createStripeSetupIntentRequest);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->createPaymentMethodStripeSetupIntent: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
createStripeSetupIntentRequest | CreateStripeSetupIntentRequest | [optional] |
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Subscription createSubscription(subscription)
Create subscription
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final Subscription subscription = ; // Subscription |
try {
final response = api.createSubscription(subscription);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->createSubscription: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
subscription | Subscription | [optional] |
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
deletePaymentMethod(paymentMethodID)
Delete payment method
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String paymentMethodID = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String |
try {
api.deletePaymentMethod(paymentMethodID);
} catch on DioError (e) {
print('Exception when calling BillingApi->deletePaymentMethod: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
paymentMethodID | String |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BillingAccount getBillingAccount()
Billing account info
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
try {
final response = api.getBillingAccount();
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->getBillingAccount: $e\n');
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Bundle getBillingBundle(bundleID)
Bundle info
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String bundleID = bundleID_example; // String |
try {
final response = api.getBillingBundle(bundleID);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->getBillingBundle: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
bundleID | String |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
PaymentOption getBillingPaymentOption(paymentOptionID)
Payment option info
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String paymentOptionID = paymentOptionID_example; // String |
try {
final response = api.getBillingPaymentOption(paymentOptionID);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->getBillingPaymentOption: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
paymentOptionID | String |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Product getBillingProduct(productID)
Product info
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String productID = productID_example; // String |
try {
final response = api.getBillingProduct(productID);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->getBillingProduct: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
productID | String |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
PaymentMethod getPaymentMethod(paymentMethodID)
Payment method info
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String paymentMethodID = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String |
try {
final response = api.getPaymentMethod(paymentMethodID);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->getPaymentMethod: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
paymentMethodID | String |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Subscription getSubscription(subscriptionID)
Subscription info
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String subscriptionID = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String |
try {
final response = api.getSubscription(subscriptionID);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->getSubscription: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
subscriptionID | String |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SubscriptionItem getSubscriptionItem(subscriptionItemID)
Subscription item info
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String subscriptionItemID = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String |
try {
final response = api.getSubscriptionItem(subscriptionItemID);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->getSubscriptionItem: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
subscriptionItemID | String |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BuiltList listBillingBundles()
Billing bundles list
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
try {
final response = api.listBillingBundles();
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->listBillingBundles: $e\n');
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BuiltList listBillingFeatures()
Billing feature list
import 'package:forestvpn_api/api.dart';
// TODO Configure API key authorization: wireguardAuth
//defaultApiClient.getAuthentication<ApiKeyAuth>('wireguardAuth').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('wireguardAuth').apiKeyPrefix = 'Bearer';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
try {
final response = api.listBillingFeatures();
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->listBillingFeatures: $e\n');
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BuiltList listBillingPaymentOptions()
Billing payment option list
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
try {
final response = api.listBillingPaymentOptions();
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->listBillingPaymentOptions: $e\n');
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BuiltList listBillingProducts()
Billing products list
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
try {
final response = api.listBillingProducts();
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->listBillingProducts: $e\n');
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BuiltList listPaymentMethods()
Payment method list
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
try {
final response = api.listPaymentMethods();
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->listPaymentMethods: $e\n');
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BuiltList listSubscriptionItems(subscription, perPage, page)
Subscription items list
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String subscription = subscription_example; // String |
final int perPage = 56; // int |
final int page = 56; // int |
try {
final response = api.listSubscriptionItems(subscription, perPage, page);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->listSubscriptionItems: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
subscription | String | [optional] | |
perPage | int | [optional] | |
page | int | [optional] |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BuiltList listSubscriptions(product, perPage, page)
Billing subscriptions list
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String product = product_example; // String |
final int perPage = 56; // int |
final int page = 56; // int |
try {
final response = api.listSubscriptions(product, perPage, page);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->listSubscriptions: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
product | String | [optional] | |
perPage | int | [optional] | |
page | int | [optional] |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Subscription reactivateSubscription(subscriptionID)
Reactivate subscription
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String subscriptionID = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String |
try {
final response = api.reactivateSubscription(subscriptionID);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->reactivateSubscription: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
subscriptionID | String |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BillingAccount updateBillingAccount(billingAccount)
Update billing account
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final BillingAccount billingAccount = ; // BillingAccount |
try {
final response = api.updateBillingAccount(billingAccount);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->updateBillingAccount: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
billingAccount | BillingAccount |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SubscriptionItem updateSubscriptionItem(subscriptionItemID, subscriptionItem)
Update subscription item
import 'package:forestvpn_api/api.dart';
// TODO Configure HTTP basic authorization: bearerAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('bearerAuth').password = 'YOUR_PASSWORD';
final api = ForestvpnApi().getBillingApi();
final String subscriptionItemID = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String |
final SubscriptionItem subscriptionItem = ; // SubscriptionItem |
try {
final response = api.updateSubscriptionItem(subscriptionItemID, subscriptionItem);
print(response);
} catch on DioError (e) {
print('Exception when calling BillingApi->updateSubscriptionItem: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
subscriptionItemID | String | ||
subscriptionItem | SubscriptionItem |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]