<commit_before><?php
require 'vendor/autoload.php';
header('Content-type: application/json');
$accountSid = getenv('TWILIO_ACCOUNT_SID');
$authToken = getenv('TWILIO_AUTH_TOKEN');

$appSid = getenv('TWILIO_APP_SID');



$requestFunction = $_POST['requestFunction']?:'';
$numberPhone = $_POST['numberPhone']?:'';


function ValidateNumber(){
   $client = new Services_Twilio($accountSid, $authToken);
	$response = $client->account->outgoing_caller_ids->create($numberPhone, array(   
	'FriendlyName' => "mathiu"));

	echo json_encode(array('numberPhone'=>$numberPhone, 'code'=>'12357'));
}

function getNumberValidated(){	
	$client = new Services_Twilio($accountSid, $authToken);
	$arrayObject = array('numberPhone'=>$numberPhone);
	
	$callers = $client->account->outgoing_caller_ids->getIterator(0, 50, array()); 
 
	foreach ($callers as $caller_id) {
		$arrayObject[] = $caller_id->friendly_name;
	}
	echo json_encode($arrayObject);
}

function getListRecord(){	
    $client = new Services_Twilio($accountSid, $authToken);
	$arrayObject = array();
    foreach($client->account->recordings as $recording) {
        $arrayObject[] = $recording->uri;
    }

	echo json_encode($arrayObject);
}



if($requestFunction == 'requestValid'){
	ValidateNumber();

} else if($requestFunction == 'requestValidList'){
	getNumberValidated();
} else if($requestFunction == 'requestListRecord'){
	getListRecord();
}
?>
<commit_msg>no message<commit_after><?php
require 'vendor/autoload.php';
header('Content-type: application/json');
$accountSid = getenv('TWILIO_ACCOUNT_SID');
$authToken = getenv('TWILIO_AUTH_TOKEN');

$appSid = getenv('TWILIO_APP_SID');



$requestFunction = $_POST['requestFunction']?:'';
$numberPhone = $_POST['numberPhone']?:'';


function ValidateNumber(){
//   $client = new Services_Twilio($accountSid, $authToken);
//	$response = $client->account->outgoing_caller_ids->create($numberPhone, array(   
//	'FriendlyName' => "mathiu"));

	echo json_encode(array('numberPhone'=>$numberPhone, 'code'=>'12357'));
}

function getNumberValidated(){	
	$client = new Services_Twilio($accountSid, $authToken);
	$arrayObject = array('numberPhone'=>$numberPhone);
	
	$callers = $client->account->outgoing_caller_ids->getIterator(0, 50, array()); 
 
	foreach ($callers as $caller_id) {
		$arrayObject[] = $caller_id->friendly_name;
	}
	echo json_encode($arrayObject);
}

function getListRecord(){	
    $client = new Services_Twilio($accountSid, $authToken);
	$arrayObject = array();
    foreach($client->account->recordings as $recording) {
        $arrayObject[] = $recording->uri;
    }

	echo json_encode($arrayObject);
}



if($requestFunction == 'requestValid'){
	ValidateNumber();

} else if($requestFunction == 'requestValidList'){
	getNumberValidated();
} else if($requestFunction == 'requestListRecord'){
	getListRecord();
}
?>

{'fraction_non_alphanumeric': 0.17649135192375573, 'fraction_numerical': 0.0056477232615601836, 'mean_word_length': 6.65945945945946, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 33, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1486188', 'n_tokens_mistral': 969, 'n_tokens_neox': 934, 'n_words': 151}