batch モジュール

バッチ操作のパブリックな結果の種類。

クラス

BatchItemResponse

バッチ要求内の 1 つの操作からの応答。

応答は送信順序で返されます。 変更セットに追加された操作の場合、応答はその順序で変更セットの位置に表示されます。

例:


   for item in result.responses:
       if item.is_success:
           print(f"[OK] {item.status_code} entity_id={item.entity_id}")
       else:
           print(f"[ERR] {item.status_code}: {item.error_message}")
BatchResult

バッチ要求を実行した結果。

送信された HTTP 操作ごとに 1 つの BatchItemResponse が含まれています。 複数の HTTP 要求 (3 つの列を含む add_columns など) に拡張される操作は、3 つのエントリを提供します。

例:


   result = client.batch.new().execute()
   print(f"Succeeded: {len(result.succeeded)}, Failed: {len(result.failed)}")
   for guid in result.entity_ids:
       print(f"[OK] entity_id: {guid}")