naturalLanguage
Natural Language
Responds with SQL script based on SAP database and text reply to End User for Natural Language question
/demo_sap
Usage and SDK Samples
curl -X GET "https://api.apieco.ir/natural-language/demo_sap"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.NaturalLanguageUserInterfaceToDatabaseAPIApi;
import java.io.File;
import java.util.*;
public class NaturalLanguageUserInterfaceToDatabaseAPIApiExample {
public static void main(String[] args) {
NaturalLanguageUserInterfaceToDatabaseAPIApi apiInstance = new NaturalLanguageUserInterfaceToDatabaseAPIApi();
String apiecoKey = apiecoKey_example; // String |
CountryCode countryCode = ; // CountryCode | body
try {
inline_response_200 result = apiInstance.naturalLanguage(apiecoKey, countryCode);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling NaturalLanguageUserInterfaceToDatabaseAPIApi#naturalLanguage");
e.printStackTrace();
}
}
}
import io.swagger.client.api.NaturalLanguageUserInterfaceToDatabaseAPIApi;
public class NaturalLanguageUserInterfaceToDatabaseAPIApiExample {
public static void main(String[] args) {
NaturalLanguageUserInterfaceToDatabaseAPIApi apiInstance = new NaturalLanguageUserInterfaceToDatabaseAPIApi();
String apiecoKey = apiecoKey_example; // String |
CountryCode countryCode = ; // CountryCode | body
try {
inline_response_200 result = apiInstance.naturalLanguage(apiecoKey, countryCode);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling NaturalLanguageUserInterfaceToDatabaseAPIApi#naturalLanguage");
e.printStackTrace();
}
}
}
String *apiecoKey = apiecoKey_example; //
CountryCode *countryCode = ; // body
NaturalLanguageUserInterfaceToDatabaseAPIApi *apiInstance = [[NaturalLanguageUserInterfaceToDatabaseAPIApi alloc] init];
// Natural Language
[apiInstance naturalLanguageWith:apiecoKey
countryCode:countryCode
completionHandler: ^(inline_response_200 output, NSError* error) {
if (output) {
NSLog(@"%@", output);
}
if (error) {
NSLog(@"Error: %@", error);
}
}];
var NaturalLanguageToSqlApiDocumentation = require('natural_language_to_sql_api_documentation');
var api = new NaturalLanguageToSqlApiDocumentation.NaturalLanguageUserInterfaceToDatabaseAPIApi()
var apiecoKey = apiecoKey_example; // {String}
var countryCode = ; // {CountryCode} body
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
api.naturalLanguage(apiecoKey, countryCode, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace Example
{
public class naturalLanguageExample
{
public void main()
{
var apiInstance = new NaturalLanguageUserInterfaceToDatabaseAPIApi();
var apiecoKey = apiecoKey_example; // String |
var countryCode = new CountryCode(); // CountryCode | body
try
{
// Natural Language
inline_response_200 result = apiInstance.naturalLanguage(apiecoKey, countryCode);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling NaturalLanguageUserInterfaceToDatabaseAPIApi.naturalLanguage: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new Swagger\Client\Api\NaturalLanguageUserInterfaceToDatabaseAPIApi();
$apiecoKey = apiecoKey_example; // String |
$countryCode = ; // CountryCode | body
try {
$result = $api_instance->naturalLanguage($apiecoKey, $countryCode);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling NaturalLanguageUserInterfaceToDatabaseAPIApi->naturalLanguage: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::NaturalLanguageUserInterfaceToDatabaseAPIApi;
my $api_instance = WWW::SwaggerClient::NaturalLanguageUserInterfaceToDatabaseAPIApi->new();
my $apiecoKey = apiecoKey_example; # String |
my $countryCode = WWW::SwaggerClient::Object::CountryCode->new(); # CountryCode | body
eval {
my $result = $api_instance->naturalLanguage(apiecoKey => $apiecoKey, countryCode => $countryCode);
print Dumper($result);
};
if ($@) {
warn "Exception when calling NaturalLanguageUserInterfaceToDatabaseAPIApi->naturalLanguage: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint
# create an instance of the API class
api_instance = swagger_client.NaturalLanguageUserInterfaceToDatabaseAPIApi()
apiecoKey = apiecoKey_example # String |
countryCode = # CountryCode | body
try:
# Natural Language
api_response = api_instance.natural_language(apiecoKey, countryCode)
pprint(api_response)
except ApiException as e:
print("Exception when calling NaturalLanguageUserInterfaceToDatabaseAPIApi->naturalLanguage: %s\n" % e)
Parameters
Header parameters
Name | Description |
---|---|
apieco-key* |
String
Required
|
Body parameters
Name | Description |
---|---|
countryCode * |