Workspace aus einem Telemetrieziel entfernen
DELETE/v1/organizations/telemetry_destinations/{destination_id}/workspaces/{workspace_id}
Entfernt einen Workspace aus der Workspace-Liste eines Ziels.
Bei include werden die Spans des Workspaces nicht mehr an das Ziel gesendet. Bei exclude beginnt das Senden. Auch ein archivierter Workspace kann entfernt werden.
Die API gibt 404 zurück, wenn der Workspace nicht auf der Liste steht. Ein Ziel, dessen workspaces.type den Wert all hat, besitzt keine Liste, daher gibt die API 400 zurück.
Im OpenTelemetry-Exportleitfaden erfährst du mehr darüber, wie du die Workspaces eines Ziels auswählst.
Parameters
Returns
Workspace aus einem Telemetrieziel entfernen
package com.anthropic.example;
import com.anthropic.client.AnthropicClient;
import com.anthropic.client.okhttp.AnthropicOkHttpClient;
import com.anthropic.models.beta.organization.telemetrydestinations.workspaces.BetaDeletedTelemetryDestinationWorkspace;
import com.anthropic.models.beta.organization.telemetrydestinations.workspaces.WorkspaceRemoveParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
AnthropicClient client = AnthropicOkHttpClient.fromEnv();
WorkspaceRemoveParams params = WorkspaceRemoveParams.builder()
.destinationId("destination_id")
.workspaceId("workspace_id")
.build();
BetaDeletedTelemetryDestinationWorkspace betaDeletedTelemetryDestinationWorkspace = client.beta().organization().telemetryDestinations().workspaces().remove(params);
}
}Response 200
{
"telemetry_destination_id": "telemetry_destination_id",
"type": "telemetry_destination_workspace_deleted",
"workspace_id": "workspace_id"
}Returns Examples
Response 200
{
"telemetry_destination_id": "telemetry_destination_id",
"type": "telemetry_destination_workspace_deleted",
"workspace_id": "workspace_id"
}