<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://document-assistant.us.aodocs.app/assistant/api/v1/tenants/{tenant}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'id' => '<string>',
'authorized_group' => 'jsmith@example.com',
'indexing_daily_quota' => 123,
'chat_daily_quota' => 123,
'document_count_quota' => 123,
'document_count' => 123,
'primary_llm_provider' => 'OpenAI',
'google_config' => [
'gcp_project' => '<string>',
'secret_id' => '<string>',
'location' => '<string>',
'default_model' => '<string>'
],
'openai_config' => [
'secret_id' => '<string>',
'endpoint' => '<string>',
'deployment_name' => '<string>',
'api_version' => '<string>',
'model' => '<string>',
'default_model' => '<string>'
],
'mistralai_config' => [
'secret_id' => '<string>',
'default_model' => '<string>'
],
'anthropic_config' => [
'secret_id' => '<string>',
'default_model' => '<string>'
],
'trial' => true,
'trial_available' => false,
'paid_plan' => false,
'trial_end' => '2023-11-07T05:31:56Z',
'library_count' => 123,
'maximum_library_count' => 123,
'capabilities' => [
],
'default_library_capabilities' => [
[
'enabled' => true
]
],
'super_admin_email' => '<string>',
'assistant_name' => '<string>',
'default_agent_id' => '<string>',
'knowledge_base' => [
'library_id' => '<string>',
'document_class_id' => '<string>'
],
'rerank_config' => [
'model' => '<string>'
],
'image_description' => [
'llm_profile_id' => '<string>',
'instructions' => '<string>'
],
'language' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}