Skip to content

Latest commit

 

History

History
99 lines (67 loc) · 2.94 KB

AdsApi.md

File metadata and controls

99 lines (67 loc) · 2.94 KB

forestvpn_api.api.AdsApi

Load the API package

import 'package:forestvpn_api/api.dart';

All URIs are relative to https://api.forestvpn.com/v2

Method HTTP request Description
createAdUnitRequestLog POST /ads/request-logs/ Create ad unit request log
listAdPlacements GET /ads/placements/ Get ad placement list

createAdUnitRequestLog

CreateAdUnitRequestLogRequest createAdUnitRequestLog(createAdUnitRequestLogRequest)

Create ad unit request log

Example

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().getAdsApi();
final CreateAdUnitRequestLogRequest createAdUnitRequestLogRequest = ; // CreateAdUnitRequestLogRequest | 

try {
    final response = api.createAdUnitRequestLog(createAdUnitRequestLogRequest);
    print(response);
} catch on DioError (e) {
    print('Exception when calling AdsApi->createAdUnitRequestLog: $e\n');
}

Parameters

Name Type Description Notes
createAdUnitRequestLogRequest CreateAdUnitRequestLogRequest [optional]

Return type

CreateAdUnitRequestLogRequest

Authorization

bearerAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

listAdPlacements

BuiltList listAdPlacements()

Get ad placement list

Example

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().getAdsApi();

try {
    final response = api.listAdPlacements();
    print(response);
} catch on DioError (e) {
    print('Exception when calling AdsApi->listAdPlacements: $e\n');
}

Parameters

This endpoint does not need any parameter.

Return type

BuiltList<AdPlacement>

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]