メッセージバッチの結果を取得
GET/v1/messages/batches/{message_batch_id}/results
メッセージバッチの結果を.jsonlファイルとしてストリーミングします。
ファイルの各行は、メッセージバッチ内の単一リクエストの結果を含むJSONオブジェクトです。結果がリクエストと同じ順序であることは保証されません。結果とリクエストを照合するにはcustom_idフィールドを使用してください。
Message Batches APIの詳細については、ユーザーガイドをご覧ください。
Parameters
Returns
メッセージバッチの結果を取得
package com.anthropic.example;
import com.anthropic.client.AnthropicClient;
import com.anthropic.client.okhttp.AnthropicOkHttpClient;
import com.anthropic.core.http.StreamResponse;
import com.anthropic.models.messages.batches.BatchResultsParams;
import com.anthropic.models.messages.batches.MessageBatchIndividualResponse;
public final class Main {
private Main() {}
public static void main(String[] args) {
AnthropicClient client = AnthropicOkHttpClient.fromEnv();
StreamResponse<MessageBatchIndividualResponse> messageBatchIndividualResponse = client.messages().batches().resultsStreaming("message_batch_id");
}
}