Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
787 changes: 786 additions & 1 deletion .generator/schemas/v2/openapi.yaml

Large diffs are not rendered by default.

28 changes: 28 additions & 0 deletions examples/v2_llm-observability_CreateLLMObsAnnotationQueue.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// Create an LLM Observability annotation queue returns "Created" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV2::api_llm_observability::LLMObservabilityAPI;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueDataAttributesRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueDataRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueType;

#[tokio::main]
async fn main() {
let body = LLMObsAnnotationQueueRequest::new(LLMObsAnnotationQueueDataRequest::new(
LLMObsAnnotationQueueDataAttributesRequest::new(
"My annotation queue".to_string(),
"a33671aa-24fd-4dcd-9b33-a8ec7dde7751".to_string(),
)
.description("Queue for annotating customer support traces".to_string()),
LLMObsAnnotationQueueType::QUEUES,
));
let mut configuration = datadog::Configuration::new();
configuration.set_unstable_operation_enabled("v2.CreateLLMObsAnnotationQueue", true);
let api = LLMObservabilityAPI::with_config(configuration);
let resp = api.create_llm_obs_annotation_queue(body).await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
// Add annotation queue interactions returns "Created" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV2::api_llm_observability::LLMObservabilityAPI;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueInteractionItem;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueInteractionsDataAttributesRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueInteractionsDataRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueInteractionsRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueInteractionsType;
use datadog_api_client::datadogV2::model::LLMObsInteractionType;

#[tokio::main]
async fn main() {
let body = LLMObsAnnotationQueueInteractionsRequest::new(
LLMObsAnnotationQueueInteractionsDataRequest::new(
LLMObsAnnotationQueueInteractionsDataAttributesRequest::new(vec![
LLMObsAnnotationQueueInteractionItem::new(
"trace-abc-123".to_string(),
LLMObsInteractionType::TRACE,
),
]),
LLMObsAnnotationQueueInteractionsType::INTERACTIONS,
),
);
let mut configuration = datadog::Configuration::new();
configuration
.set_unstable_operation_enabled("v2.CreateLLMObsAnnotationQueueInteractions", true);
let api = LLMObservabilityAPI::with_config(configuration);
let resp = api
.create_llm_obs_annotation_queue_interactions("queue_id".to_string(), body)
.await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
18 changes: 18 additions & 0 deletions examples/v2_llm-observability_DeleteLLMObsAnnotationQueue.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Delete an LLM Observability annotation queue returns "No Content" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV2::api_llm_observability::LLMObservabilityAPI;

#[tokio::main]
async fn main() {
let mut configuration = datadog::Configuration::new();
configuration.set_unstable_operation_enabled("v2.DeleteLLMObsAnnotationQueue", true);
let api = LLMObservabilityAPI::with_config(configuration);
let resp = api
.delete_llm_obs_annotation_queue("queue_id".to_string())
.await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// Delete annotation queue interactions returns "No Content" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV2::api_llm_observability::LLMObservabilityAPI;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueInteractionsType;
use datadog_api_client::datadogV2::model::LLMObsDeleteAnnotationQueueInteractionsDataAttributesRequest;
use datadog_api_client::datadogV2::model::LLMObsDeleteAnnotationQueueInteractionsDataRequest;
use datadog_api_client::datadogV2::model::LLMObsDeleteAnnotationQueueInteractionsRequest;

#[tokio::main]
async fn main() {
let body = LLMObsDeleteAnnotationQueueInteractionsRequest::new(
LLMObsDeleteAnnotationQueueInteractionsDataRequest::new(
LLMObsDeleteAnnotationQueueInteractionsDataAttributesRequest::new(vec![
"00000000-0000-0000-0000-000000000000".to_string(),
"00000000-0000-0000-0000-000000000001".to_string(),
]),
LLMObsAnnotationQueueInteractionsType::INTERACTIONS,
),
);
let mut configuration = datadog::Configuration::new();
configuration
.set_unstable_operation_enabled("v2.DeleteLLMObsAnnotationQueueInteractions", true);
let api = LLMObservabilityAPI::with_config(configuration);
let resp = api
.delete_llm_obs_annotation_queue_interactions("queue_id".to_string(), body)
.await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
18 changes: 18 additions & 0 deletions examples/v2_llm-observability_GetLLMObsAnnotatedInteractions.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Get annotated queue interactions returns "OK" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV2::api_llm_observability::LLMObservabilityAPI;

#[tokio::main]
async fn main() {
let mut configuration = datadog::Configuration::new();
configuration.set_unstable_operation_enabled("v2.GetLLMObsAnnotatedInteractions", true);
let api = LLMObservabilityAPI::with_config(configuration);
let resp = api
.get_llm_obs_annotated_interactions("queue_id".to_string())
.await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
19 changes: 19 additions & 0 deletions examples/v2_llm-observability_ListLLMObsAnnotationQueues.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
// List LLM Observability annotation queues returns "OK" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV2::api_llm_observability::LLMObservabilityAPI;
use datadog_api_client::datadogV2::api_llm_observability::ListLLMObsAnnotationQueuesOptionalParams;

#[tokio::main]
async fn main() {
let mut configuration = datadog::Configuration::new();
configuration.set_unstable_operation_enabled("v2.ListLLMObsAnnotationQueues", true);
let api = LLMObservabilityAPI::with_config(configuration);
let resp = api
.list_llm_obs_annotation_queues(ListLLMObsAnnotationQueuesOptionalParams::default())
.await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
29 changes: 29 additions & 0 deletions examples/v2_llm-observability_UpdateLLMObsAnnotationQueue.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// Update an LLM Observability annotation queue returns "OK" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV2::api_llm_observability::LLMObservabilityAPI;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueType;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueUpdateDataAttributesRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueUpdateDataRequest;
use datadog_api_client::datadogV2::model::LLMObsAnnotationQueueUpdateRequest;

#[tokio::main]
async fn main() {
let body =
LLMObsAnnotationQueueUpdateRequest::new(LLMObsAnnotationQueueUpdateDataRequest::new(
LLMObsAnnotationQueueUpdateDataAttributesRequest::new()
.description("Updated description".to_string())
.name("Updated queue name".to_string()),
LLMObsAnnotationQueueType::QUEUES,
));
let mut configuration = datadog::Configuration::new();
configuration.set_unstable_operation_enabled("v2.UpdateLLMObsAnnotationQueue", true);
let api = LLMObservabilityAPI::with_config(configuration);
let resp = api
.update_llm_obs_annotation_queue("queue_id".to_string(), body)
.await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
13 changes: 13 additions & 0 deletions src/datadog/configuration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -293,19 +293,32 @@ impl Default for Configuration {
("v2.update_jira_issue_template".to_owned(), false),
("v2.create_tenancy_config".to_owned(), false),
("v2.get_tenancy_configs".to_owned(), false),
("v2.create_llm_obs_annotation_queue".to_owned(), false),
(
"v2.create_llm_obs_annotation_queue_interactions".to_owned(),
false,
),
("v2.create_llm_obs_dataset".to_owned(), false),
("v2.create_llm_obs_dataset_records".to_owned(), false),
("v2.create_llm_obs_experiment".to_owned(), false),
("v2.create_llm_obs_experiment_events".to_owned(), false),
("v2.create_llm_obs_project".to_owned(), false),
("v2.delete_llm_obs_annotation_queue".to_owned(), false),
(
"v2.delete_llm_obs_annotation_queue_interactions".to_owned(),
false,
),
("v2.delete_llm_obs_dataset_records".to_owned(), false),
("v2.delete_llm_obs_datasets".to_owned(), false),
("v2.delete_llm_obs_experiments".to_owned(), false),
("v2.delete_llm_obs_projects".to_owned(), false),
("v2.get_llm_obs_annotated_interactions".to_owned(), false),
("v2.list_llm_obs_annotation_queues".to_owned(), false),
("v2.list_llm_obs_dataset_records".to_owned(), false),
("v2.list_llm_obs_datasets".to_owned(), false),
("v2.list_llm_obs_experiments".to_owned(), false),
("v2.list_llm_obs_projects".to_owned(), false),
("v2.update_llm_obs_annotation_queue".to_owned(), false),
("v2.update_llm_obs_dataset".to_owned(), false),
("v2.update_llm_obs_dataset_records".to_owned(), false),
("v2.update_llm_obs_experiment".to_owned(), false),
Expand Down
Loading
Loading