Skip to content

Latest commit

 

History

History
169 lines (121 loc) · 7.11 KB

File metadata and controls

169 lines (121 loc) · 7.11 KB

cloudflare_dart.api.AccountLevelCustomNameserversApi

Load the API package

import 'package:cloudflare_dart/api.dart';

All URIs are relative to https://api.cloudflare.com/client/v4

Method HTTP request Description
accountLevelCustomNameserversAddAccountCustomNameserver POST /accounts/{account_id}/custom_ns Add Account Custom Nameserver
accountLevelCustomNameserversDeleteAccountCustomNameserver DELETE /accounts/{account_id}/custom_ns/{custom_ns_id} Delete Account Custom Nameserver
accountLevelCustomNameserversListAccountCustomNameservers GET /accounts/{account_id}/custom_ns List Account Custom Nameservers

accountLevelCustomNameserversAddAccountCustomNameserver

DnsCustomNameserversAcnsResponseSingle accountLevelCustomNameserversAddAccountCustomNameserver(accountId, dnsCustomNameserversCustomNSInput)

Add Account Custom Nameserver

Example

import 'package:cloudflare_dart/api.dart';
// TODO Configure API key authorization: api_key
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_key').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_key').apiKeyPrefix = 'Bearer';
// TODO Configure API key authorization: api_email
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_email').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_email').apiKeyPrefix = 'Bearer';

final api = CloudflareDart().getAccountLevelCustomNameserversApi();
final String accountId = accountId_example; // String | 
final DnsCustomNameserversCustomNSInput dnsCustomNameserversCustomNSInput = ; // DnsCustomNameserversCustomNSInput | 

try {
    final response = api.accountLevelCustomNameserversAddAccountCustomNameserver(accountId, dnsCustomNameserversCustomNSInput);
    print(response);
} catch on DioException (e) {
    print('Exception when calling AccountLevelCustomNameserversApi->accountLevelCustomNameserversAddAccountCustomNameserver: $e\n');
}

Parameters

Name Type Description Notes
accountId String
dnsCustomNameserversCustomNSInput DnsCustomNameserversCustomNSInput

Return type

DnsCustomNameserversAcnsResponseSingle

Authorization

api_key, api_token, api_email

HTTP request headers

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

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

accountLevelCustomNameserversDeleteAccountCustomNameserver

DnsCustomNameserversEmptyResponse accountLevelCustomNameserversDeleteAccountCustomNameserver(customNsId, accountId)

Delete Account Custom Nameserver

Example

import 'package:cloudflare_dart/api.dart';
// TODO Configure API key authorization: api_key
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_key').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_key').apiKeyPrefix = 'Bearer';
// TODO Configure API key authorization: api_email
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_email').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_email').apiKeyPrefix = 'Bearer';

final api = CloudflareDart().getAccountLevelCustomNameserversApi();
final String customNsId = customNsId_example; // String | 
final String accountId = accountId_example; // String | 

try {
    final response = api.accountLevelCustomNameserversDeleteAccountCustomNameserver(customNsId, accountId);
    print(response);
} catch on DioException (e) {
    print('Exception when calling AccountLevelCustomNameserversApi->accountLevelCustomNameserversDeleteAccountCustomNameserver: $e\n');
}

Parameters

Name Type Description Notes
customNsId String
accountId String

Return type

DnsCustomNameserversEmptyResponse

Authorization

api_key, api_token, api_email

HTTP request headers

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

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

accountLevelCustomNameserversListAccountCustomNameservers

DnsCustomNameserversAcnsResponseCollection accountLevelCustomNameserversListAccountCustomNameservers(accountId)

List Account Custom Nameservers

List an account's custom nameservers.

Example

import 'package:cloudflare_dart/api.dart';
// TODO Configure API key authorization: api_key
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_key').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_key').apiKeyPrefix = 'Bearer';
// TODO Configure API key authorization: api_email
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_email').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('api_email').apiKeyPrefix = 'Bearer';

final api = CloudflareDart().getAccountLevelCustomNameserversApi();
final String accountId = accountId_example; // String | 

try {
    final response = api.accountLevelCustomNameserversListAccountCustomNameservers(accountId);
    print(response);
} catch on DioException (e) {
    print('Exception when calling AccountLevelCustomNameserversApi->accountLevelCustomNameserversListAccountCustomNameservers: $e\n');
}

Parameters

Name Type Description Notes
accountId String

Return type

DnsCustomNameserversAcnsResponseCollection

Authorization

api_key, api_token, api_email

HTTP request headers

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

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