Smartedit

Authentications

doGenerateOAuthTokenFromSSO

Create OAuth token from single sign-on authentication

Endpoint to create an OAuth token from a single sign-on authentication


/authenticate

Usage and SDK Samples

curl -X POST\
\
\
-H "Accept: application/xml,application/json"\
-H "Content-Type: application/json"\
"http://localhost:9001/smartedit/authenticate"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.AuthenticationsApi;

import java.io.File;
import java.util.*;

public class AuthenticationsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure OAuth2 access token for authorization: oauth2_Password
        OAuth oauth2_Password = (OAuth) defaultClient.getAuthentication("oauth2_Password");
        oauth2_Password.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: oauth2_client_credentials
        OAuth oauth2_client_credentials = (OAuth) defaultClient.getAuthentication("oauth2_client_credentials");
        oauth2_client_credentials.setAccessToken("YOUR ACCESS TOKEN");

        AuthenticationsApi apiInstance = new AuthenticationsApi();
        SSOCredentials body = ; // SSOCredentials | 
        try {
            OAuth2AccessToken result = apiInstance.doGenerateOAuthTokenFromSSO(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AuthenticationsApi#doGenerateOAuthTokenFromSSO");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.AuthenticationsApi;

public class AuthenticationsApiExample {

    public static void main(String[] args) {
        AuthenticationsApi apiInstance = new AuthenticationsApi();
        SSOCredentials body = ; // SSOCredentials | 
        try {
            OAuth2AccessToken result = apiInstance.doGenerateOAuthTokenFromSSO(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AuthenticationsApi#doGenerateOAuthTokenFromSSO");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_Password)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_client_credentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
SSOCredentials *body = ; // 

AuthenticationsApi *apiInstance = [[AuthenticationsApi alloc] init];

// Create OAuth token from single sign-on authentication
[apiInstance doGenerateOAuthTokenFromSSOWith:body
              completionHandler: ^(OAuth2AccessToken output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var Smartedit = require('smartedit');
var defaultClient = Smartedit.ApiClient.instance;

// Configure OAuth2 access token for authorization: oauth2_Password
var oauth2_Password = defaultClient.authentications['oauth2_Password'];
oauth2_Password.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: oauth2_client_credentials
var oauth2_client_credentials = defaultClient.authentications['oauth2_client_credentials'];
oauth2_client_credentials.accessToken = "YOUR ACCESS TOKEN"

var api = new Smartedit.AuthenticationsApi()
var body = ; // {{SSOCredentials}} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.doGenerateOAuthTokenFromSSO(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class doGenerateOAuthTokenFromSSOExample
    {
        public void main()
        {

            // Configure OAuth2 access token for authorization: oauth2_Password
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: oauth2_client_credentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new AuthenticationsApi();
            var body = new SSOCredentials(); // SSOCredentials | 

            try
            {
                // Create OAuth token from single sign-on authentication
                OAuth2AccessToken result = apiInstance.doGenerateOAuthTokenFromSSO(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling AuthenticationsApi.doGenerateOAuthTokenFromSSO: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2_Password
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: oauth2_client_credentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\ApiAuthenticationsApi();
$body = ; // SSOCredentials | 

try {
    $result = $api_instance->doGenerateOAuthTokenFromSSO($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AuthenticationsApi->doGenerateOAuthTokenFromSSO: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::AuthenticationsApi;

# Configure OAuth2 access token for authorization: oauth2_Password
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: oauth2_client_credentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::AuthenticationsApi->new();
my $body = WWW::SwaggerClient::Object::SSOCredentials->new(); # SSOCredentials | 

eval { 
    my $result = $api_instance->doGenerateOAuthTokenFromSSO(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AuthenticationsApi->doGenerateOAuthTokenFromSSO: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2_Password
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: oauth2_client_credentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.AuthenticationsApi()
body =  # SSOCredentials | 

try: 
    # Create OAuth token from single sign-on authentication
    api_response = api_instance.do_generate_o_auth_token_from_sso(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AuthenticationsApi->doGenerateOAuthTokenFromSSO: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 201 - Created

Status: 401 - Unauthorized

Status: 403 - Forbidden

Status: 404 - Not Found


Configurations

createConfiguration

Create configurations

Endpoint to create configurations.


/configuration

Usage and SDK Samples

curl -X POST\
\
\
-H "Accept: application/xml,application/json"\
-H "Content-Type: application/json"\
"http://localhost:9001/smartedit/configuration"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.ConfigurationsApi;

import java.io.File;
import java.util.*;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure OAuth2 access token for authorization: oauth2_Password
        OAuth oauth2_Password = (OAuth) defaultClient.getAuthentication("oauth2_Password");
        oauth2_Password.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: oauth2_client_credentials
        OAuth oauth2_client_credentials = (OAuth) defaultClient.getAuthentication("oauth2_client_credentials");
        oauth2_client_credentials.setAccessToken("YOUR ACCESS TOKEN");

        ConfigurationsApi apiInstance = new ConfigurationsApi();
        map[String, String] body = ; // map[String, String] | 
        String authorization = authorization_example; // String | Authorization bearer token
        try {
            apiInstance.createConfiguration(body, authorization);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#createConfiguration");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.ConfigurationsApi;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ConfigurationsApi apiInstance = new ConfigurationsApi();
        map[String, String] body = ; // map[String, String] | 
        String authorization = authorization_example; // String | Authorization bearer token
        try {
            apiInstance.createConfiguration(body, authorization);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#createConfiguration");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_Password)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_client_credentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
map[String, String] *body = ; // 
String *authorization = authorization_example; // Authorization bearer token

ConfigurationsApi *apiInstance = [[ConfigurationsApi alloc] init];

// Create configurations
[apiInstance createConfigurationWith:body
    authorization:authorization
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var Smartedit = require('smartedit');
var defaultClient = Smartedit.ApiClient.instance;

// Configure OAuth2 access token for authorization: oauth2_Password
var oauth2_Password = defaultClient.authentications['oauth2_Password'];
oauth2_Password.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: oauth2_client_credentials
var oauth2_client_credentials = defaultClient.authentications['oauth2_client_credentials'];
oauth2_client_credentials.accessToken = "YOUR ACCESS TOKEN"

var api = new Smartedit.ConfigurationsApi()
var body = ; // {{map[String, String]}} 
var authorization = authorization_example; // {{String}} Authorization bearer token

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.createConfiguration(bodyauthorization, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class createConfigurationExample
    {
        public void main()
        {

            // Configure OAuth2 access token for authorization: oauth2_Password
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: oauth2_client_credentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new ConfigurationsApi();
            var body = new map[String, String](); // map[String, String] | 
            var authorization = authorization_example;  // String | Authorization bearer token

            try
            {
                // Create configurations
                apiInstance.createConfiguration(body, authorization);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling ConfigurationsApi.createConfiguration: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2_Password
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: oauth2_client_credentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\ApiConfigurationsApi();
$body = ; // map[String, String] | 
$authorization = authorization_example; // String | Authorization bearer token

try {
    $api_instance->createConfiguration($body, $authorization);
} catch (Exception $e) {
    echo 'Exception when calling ConfigurationsApi->createConfiguration: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::ConfigurationsApi;

# Configure OAuth2 access token for authorization: oauth2_Password
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: oauth2_client_credentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::ConfigurationsApi->new();
my $body = WWW::SwaggerClient::Object::map[String, String]->new(); # map[String, String] | 
my $authorization = authorization_example; # String | Authorization bearer token

eval { 
    $api_instance->createConfiguration(body => $body, authorization => $authorization);
};
if ($@) {
    warn "Exception when calling ConfigurationsApi->createConfiguration: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2_Password
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: oauth2_client_credentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.ConfigurationsApi()
body =  # map[String, String] | 
authorization = authorization_example # String | Authorization bearer token

try: 
    # Create configurations
    api_instance.create_configuration(body, authorization)
except ApiException as e:
    print("Exception when calling ConfigurationsApi->createConfiguration: %s\n" % e)

Parameters

Header parameters
Name Description
Authorization*
String
Authorization bearer token
Required
Body parameters
Name Description
body *

Responses

Status: 401 - Must be authenticated as an Admin to access this resource

Status: 403 - Forbidden

Status: 404 - Not Found


getConfiguration

Get configurations

Endpoint to retrieve configurations.


/configuration

Usage and SDK Samples

curl -X GET\
\
\
-H "Accept: application/xml,application/json"\
"http://localhost:9001/smartedit/configuration"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.ConfigurationsApi;

import java.io.File;
import java.util.*;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure OAuth2 access token for authorization: oauth2_Password
        OAuth oauth2_Password = (OAuth) defaultClient.getAuthentication("oauth2_Password");
        oauth2_Password.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: oauth2_client_credentials
        OAuth oauth2_client_credentials = (OAuth) defaultClient.getAuthentication("oauth2_client_credentials");
        oauth2_client_credentials.setAccessToken("YOUR ACCESS TOKEN");

        ConfigurationsApi apiInstance = new ConfigurationsApi();
        String authorization = authorization_example; // String | Authorization bearer token
        try {
            apiInstance.getConfiguration(authorization);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#getConfiguration");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.ConfigurationsApi;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ConfigurationsApi apiInstance = new ConfigurationsApi();
        String authorization = authorization_example; // String | Authorization bearer token
        try {
            apiInstance.getConfiguration(authorization);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#getConfiguration");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_Password)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_client_credentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
String *authorization = authorization_example; // Authorization bearer token

ConfigurationsApi *apiInstance = [[ConfigurationsApi alloc] init];

// Get configurations
[apiInstance getConfigurationWith:authorization
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var Smartedit = require('smartedit');
var defaultClient = Smartedit.ApiClient.instance;

// Configure OAuth2 access token for authorization: oauth2_Password
var oauth2_Password = defaultClient.authentications['oauth2_Password'];
oauth2_Password.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: oauth2_client_credentials
var oauth2_client_credentials = defaultClient.authentications['oauth2_client_credentials'];
oauth2_client_credentials.accessToken = "YOUR ACCESS TOKEN"

var api = new Smartedit.ConfigurationsApi()
var authorization = authorization_example; // {{String}} Authorization bearer token

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.getConfiguration(authorization, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class getConfigurationExample
    {
        public void main()
        {

            // Configure OAuth2 access token for authorization: oauth2_Password
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: oauth2_client_credentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new ConfigurationsApi();
            var authorization = authorization_example;  // String | Authorization bearer token

            try
            {
                // Get configurations
                apiInstance.getConfiguration(authorization);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling ConfigurationsApi.getConfiguration: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2_Password
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: oauth2_client_credentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\ApiConfigurationsApi();
$authorization = authorization_example; // String | Authorization bearer token

try {
    $api_instance->getConfiguration($authorization);
} catch (Exception $e) {
    echo 'Exception when calling ConfigurationsApi->getConfiguration: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::ConfigurationsApi;

# Configure OAuth2 access token for authorization: oauth2_Password
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: oauth2_client_credentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::ConfigurationsApi->new();
my $authorization = authorization_example; # String | Authorization bearer token

eval { 
    $api_instance->getConfiguration(authorization => $authorization);
};
if ($@) {
    warn "Exception when calling ConfigurationsApi->getConfiguration: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2_Password
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: oauth2_client_credentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.ConfigurationsApi()
authorization = authorization_example # String | Authorization bearer token

try: 
    # Get configurations
    api_instance.get_configuration(authorization)
except ApiException as e:
    print("Exception when calling ConfigurationsApi->getConfiguration: %s\n" % e)

Parameters

Header parameters
Name Description
Authorization*
String
Authorization bearer token
Required

Responses

Status: 401 - Must be authenticated as an Admin or CMS Manager to access this resource

Status: 403 - Forbidden

Status: 404 - Not Found


removeConfiguration

Delete configurations

Endpoint to delete configurations.


/configuration/{key}

Usage and SDK Samples

curl -X DELETE\
\
\
"http://localhost:9001/smartedit/configuration/{key}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.ConfigurationsApi;

import java.io.File;
import java.util.*;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure OAuth2 access token for authorization: oauth2_Password
        OAuth oauth2_Password = (OAuth) defaultClient.getAuthentication("oauth2_Password");
        oauth2_Password.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: oauth2_client_credentials
        OAuth oauth2_client_credentials = (OAuth) defaultClient.getAuthentication("oauth2_client_credentials");
        oauth2_client_credentials.setAccessToken("YOUR ACCESS TOKEN");

        ConfigurationsApi apiInstance = new ConfigurationsApi();
        String authorization = authorization_example; // String | Authorization bearer token
        String key = key_example; // String | The key of the configuration to delete
        try {
            apiInstance.removeConfiguration(authorization, key);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#removeConfiguration");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.ConfigurationsApi;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ConfigurationsApi apiInstance = new ConfigurationsApi();
        String authorization = authorization_example; // String | Authorization bearer token
        String key = key_example; // String | The key of the configuration to delete
        try {
            apiInstance.removeConfiguration(authorization, key);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#removeConfiguration");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_Password)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_client_credentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
String *authorization = authorization_example; // Authorization bearer token
String *key = key_example; // The key of the configuration to delete

ConfigurationsApi *apiInstance = [[ConfigurationsApi alloc] init];

// Delete configurations
[apiInstance removeConfigurationWith:authorization
    key:key
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var Smartedit = require('smartedit');
var defaultClient = Smartedit.ApiClient.instance;

// Configure OAuth2 access token for authorization: oauth2_Password
var oauth2_Password = defaultClient.authentications['oauth2_Password'];
oauth2_Password.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: oauth2_client_credentials
var oauth2_client_credentials = defaultClient.authentications['oauth2_client_credentials'];
oauth2_client_credentials.accessToken = "YOUR ACCESS TOKEN"

var api = new Smartedit.ConfigurationsApi()
var authorization = authorization_example; // {{String}} Authorization bearer token
var key = key_example; // {{String}} The key of the configuration to delete

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.removeConfiguration(authorization, key, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class removeConfigurationExample
    {
        public void main()
        {

            // Configure OAuth2 access token for authorization: oauth2_Password
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: oauth2_client_credentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new ConfigurationsApi();
            var authorization = authorization_example;  // String | Authorization bearer token
            var key = key_example;  // String | The key of the configuration to delete

            try
            {
                // Delete configurations
                apiInstance.removeConfiguration(authorization, key);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling ConfigurationsApi.removeConfiguration: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2_Password
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: oauth2_client_credentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\ApiConfigurationsApi();
$authorization = authorization_example; // String | Authorization bearer token
$key = key_example; // String | The key of the configuration to delete

try {
    $api_instance->removeConfiguration($authorization, $key);
} catch (Exception $e) {
    echo 'Exception when calling ConfigurationsApi->removeConfiguration: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::ConfigurationsApi;

# Configure OAuth2 access token for authorization: oauth2_Password
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: oauth2_client_credentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::ConfigurationsApi->new();
my $authorization = authorization_example; # String | Authorization bearer token
my $key = key_example; # String | The key of the configuration to delete

eval { 
    $api_instance->removeConfiguration(authorization => $authorization, key => $key);
};
if ($@) {
    warn "Exception when calling ConfigurationsApi->removeConfiguration: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2_Password
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: oauth2_client_credentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.ConfigurationsApi()
authorization = authorization_example # String | Authorization bearer token
key = key_example # String | The key of the configuration to delete

try: 
    # Delete configurations
    api_instance.remove_configuration(authorization, key)
except ApiException as e:
    print("Exception when calling ConfigurationsApi->removeConfiguration: %s\n" % e)

Parameters

Path parameters
Name Description
key*
String
The key of the configuration to delete
Required
Header parameters
Name Description
Authorization*
String
Authorization bearer token
Required

Responses

Status: 401 - Must be authenticated as an Admin to access this resource

Status: 403 - Forbidden

Status: 404 - Not Found


replaceConfiguration

Update configurations

Endpoint to update configurations.


/configuration/{key}

Usage and SDK Samples

curl -X PUT\
\
\
-H "Accept: application/xml,application/json"\
-H "Content-Type: application/json"\
"http://localhost:9001/smartedit/configuration/{key}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.ConfigurationsApi;

import java.io.File;
import java.util.*;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure OAuth2 access token for authorization: oauth2_Password
        OAuth oauth2_Password = (OAuth) defaultClient.getAuthentication("oauth2_Password");
        oauth2_Password.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: oauth2_client_credentials
        OAuth oauth2_client_credentials = (OAuth) defaultClient.getAuthentication("oauth2_client_credentials");
        oauth2_client_credentials.setAccessToken("YOUR ACCESS TOKEN");

        ConfigurationsApi apiInstance = new ConfigurationsApi();
        map[String, String] body = ; // map[String, String] | 
        String authorization = authorization_example; // String | Authorization bearer token
        String key = key_example; // String | The key of the configuration to update
        try {
            apiInstance.replaceConfiguration(body, authorization, key);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#replaceConfiguration");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.ConfigurationsApi;

public class ConfigurationsApiExample {

    public static void main(String[] args) {
        ConfigurationsApi apiInstance = new ConfigurationsApi();
        map[String, String] body = ; // map[String, String] | 
        String authorization = authorization_example; // String | Authorization bearer token
        String key = key_example; // String | The key of the configuration to update
        try {
            apiInstance.replaceConfiguration(body, authorization, key);
        } catch (ApiException e) {
            System.err.println("Exception when calling ConfigurationsApi#replaceConfiguration");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_Password)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_client_credentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
map[String, String] *body = ; // 
String *authorization = authorization_example; // Authorization bearer token
String *key = key_example; // The key of the configuration to update

ConfigurationsApi *apiInstance = [[ConfigurationsApi alloc] init];

// Update configurations
[apiInstance replaceConfigurationWith:body
    authorization:authorization
    key:key
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var Smartedit = require('smartedit');
var defaultClient = Smartedit.ApiClient.instance;

// Configure OAuth2 access token for authorization: oauth2_Password
var oauth2_Password = defaultClient.authentications['oauth2_Password'];
oauth2_Password.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: oauth2_client_credentials
var oauth2_client_credentials = defaultClient.authentications['oauth2_client_credentials'];
oauth2_client_credentials.accessToken = "YOUR ACCESS TOKEN"

var api = new Smartedit.ConfigurationsApi()
var body = ; // {{map[String, String]}} 
var authorization = authorization_example; // {{String}} Authorization bearer token
var key = key_example; // {{String}} The key of the configuration to update

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.replaceConfiguration(bodyauthorizationkey, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class replaceConfigurationExample
    {
        public void main()
        {

            // Configure OAuth2 access token for authorization: oauth2_Password
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: oauth2_client_credentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new ConfigurationsApi();
            var body = new map[String, String](); // map[String, String] | 
            var authorization = authorization_example;  // String | Authorization bearer token
            var key = key_example;  // String | The key of the configuration to update

            try
            {
                // Update configurations
                apiInstance.replaceConfiguration(body, authorization, key);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling ConfigurationsApi.replaceConfiguration: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2_Password
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: oauth2_client_credentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\ApiConfigurationsApi();
$body = ; // map[String, String] | 
$authorization = authorization_example; // String | Authorization bearer token
$key = key_example; // String | The key of the configuration to update

try {
    $api_instance->replaceConfiguration($body, $authorization, $key);
} catch (Exception $e) {
    echo 'Exception when calling ConfigurationsApi->replaceConfiguration: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::ConfigurationsApi;

# Configure OAuth2 access token for authorization: oauth2_Password
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: oauth2_client_credentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::ConfigurationsApi->new();
my $body = WWW::SwaggerClient::Object::map[String, String]->new(); # map[String, String] | 
my $authorization = authorization_example; # String | Authorization bearer token
my $key = key_example; # String | The key of the configuration to update

eval { 
    $api_instance->replaceConfiguration(body => $body, authorization => $authorization, key => $key);
};
if ($@) {
    warn "Exception when calling ConfigurationsApi->replaceConfiguration: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2_Password
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: oauth2_client_credentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.ConfigurationsApi()
body =  # map[String, String] | 
authorization = authorization_example # String | Authorization bearer token
key = key_example # String | The key of the configuration to update

try: 
    # Update configurations
    api_instance.replace_configuration(body, authorization, key)
except ApiException as e:
    print("Exception when calling ConfigurationsApi->replaceConfiguration: %s\n" % e)

Parameters

Path parameters
Name Description
key*
String
The key of the configuration to update
Required
Header parameters
Name Description
Authorization*
String
Authorization bearer token
Required
Body parameters
Name Description
body *

Responses

Status: 400 - Configuration data input is invalid

Status: 401 - Must be authenticated as an Admin to access this resource

Status: 403 - Forbidden

Status: 404 - Not Found

Status: 405 - The configuration key is missing from the payload


Settings

getSettings

Get a map of application settings

Endpoint to retrieve a map of non-protected settings necessary for front-end to self-configure


/settings

Usage and SDK Samples

curl -X GET\
\
\
-H "Accept: application/xml,application/json"\
"http://localhost:9001/smartedit/settings"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.SettingsApi;

import java.io.File;
import java.util.*;

public class SettingsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure OAuth2 access token for authorization: oauth2_Password
        OAuth oauth2_Password = (OAuth) defaultClient.getAuthentication("oauth2_Password");
        oauth2_Password.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: oauth2_client_credentials
        OAuth oauth2_client_credentials = (OAuth) defaultClient.getAuthentication("oauth2_client_credentials");
        oauth2_client_credentials.setAccessToken("YOUR ACCESS TOKEN");

        SettingsApi apiInstance = new SettingsApi();
        try {
            map['String', Object] result = apiInstance.getSettings();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SettingsApi#getSettings");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.SettingsApi;

public class SettingsApiExample {

    public static void main(String[] args) {
        SettingsApi apiInstance = new SettingsApi();
        try {
            map['String', Object] result = apiInstance.getSettings();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SettingsApi#getSettings");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_Password)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
// Configure OAuth2 access token for authorization: (authentication scheme: oauth2_client_credentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

SettingsApi *apiInstance = [[SettingsApi alloc] init];

// Get a map of application settings
[apiInstance getSettingsWithCompletionHandler: 
              ^(map['String', Object] output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var Smartedit = require('smartedit');
var defaultClient = Smartedit.ApiClient.instance;

// Configure OAuth2 access token for authorization: oauth2_Password
var oauth2_Password = defaultClient.authentications['oauth2_Password'];
oauth2_Password.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: oauth2_client_credentials
var oauth2_client_credentials = defaultClient.authentications['oauth2_client_credentials'];
oauth2_client_credentials.accessToken = "YOUR ACCESS TOKEN"

var api = new Smartedit.SettingsApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getSettings(callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class getSettingsExample
    {
        public void main()
        {

            // Configure OAuth2 access token for authorization: oauth2_Password
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: oauth2_client_credentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new SettingsApi();

            try
            {
                // Get a map of application settings
                map['String', Object] result = apiInstance.getSettings();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling SettingsApi.getSettings: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2_Password
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: oauth2_client_credentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\ApiSettingsApi();

try {
    $result = $api_instance->getSettings();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SettingsApi->getSettings: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::SettingsApi;

# Configure OAuth2 access token for authorization: oauth2_Password
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: oauth2_client_credentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::SettingsApi->new();

eval { 
    my $result = $api_instance->getSettings();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling SettingsApi->getSettings: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2_Password
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: oauth2_client_credentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.SettingsApi()

try: 
    # Get a map of application settings
    api_response = api_instance.get_settings()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SettingsApi->getSettings: %s\n" % e)

Parameters

Responses

Status: 200 - OK

Status: 401 - Unauthorized

Status: 403 - Forbidden

Status: 404 - Not Found