> ## Documentation Index
> Fetch the complete documentation index at: https://private-7c7dfe99-mintlify-3a82795f.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# 組織の利用コストを取得

> 照会した期間内の組織について、総額と、エンティティごとの日次組織利用コストレコードの一覧を返します（最大 31 日間）。リクエストとレスポンスの両方に含まれるすべての日付は、UTC タイムゾーンに基づいて評価されます。



## OpenAPI

````yaml /ja/products/cloud/api-reference/cloud-openapi.json get /v1/organizations/{organizationId}/usageCost
openapi: 3.0.1
info:
  contact:
    email: support@clickhouse.com
    name: ClickHouse Support
    url: >-
      https://clickhouse.com/docs/en/cloud/manage/openapi?referrer=openapi-299828
  title: OpenAPI spec for ClickHouse Cloud
  version: '1.0'
servers:
  - url: https://api.clickhouse.cloud
security:
  - basicAuth: []
tags:
  - name: Organization
  - name: User management
  - name: Billing
  - name: Service
  - name: Backup
  - name: OpenAPI
  - name: Prometheus
  - name: ClickPipes
paths:
  /v1/organizations/{organizationId}/usageCost:
    get:
      tags:
        - Billing
      summary: 組織の利用コストを取得
      description: >-
        照会した期間内の組織について、総額と、エンティティごとの日次組織利用コストレコードの一覧を返します（最大 31
        日間）。リクエストとレスポンスの両方に含まれるすべての日付は、UTC タイムゾーンに基づいて評価されます。
      parameters:
        - description: 要求された組織の ID。
          in: path
          name: organizationId
          required: true
          schema:
            format: uuid
            type: string
        - description: 'レポートの開始日。例: 2024-12-19。'
          in: query
          name: from_date
          required: true
          schema:
            format: date-time
            type: string
        - description: >-
            レポートの終了日（この日を含む）。例: 2024-12-20。この日付は from_date から 30
            日を超えて指定することはできません（照会可能な期間の上限は 31 日間）。
          in: query
          name: to_date
          required: true
          schema:
            format: date-time
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  requestId:
                    description: すべてのリクエストに割り当てられる一意の ID。UUIDv4
                    format: uuid
                    type: string
                  result:
                    $ref: '#/components/schemas/UsageCost'
                  status:
                    description: HTTP ステータスコード。
                    example: 200
                    type: number
                type: object
          description: 正常なレスポンス
        '400':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: エラーの詳細説明。
                    type: string
                  status:
                    description: HTTP ステータスコード。
                    example: 400
                    type: number
                type: object
          description: クライアントエラーと判断される何らかの理由により、サーバーはリクエストを処理できないか、処理しません。
components:
  schemas:
    UsageCost:
      properties:
        costs:
          $ref: '#/components/schemas/UsageCostRecord'
        grandTotalCHC:
          description: ClickHouse Credits（CHCs）での使用コスト総計。
          type: number
    UsageCostRecord:
      properties:
        dataWarehouseId:
          description: このエンティティが属する dataWarehouse の ID（またはこのエンティティ自体の ID）。
          format: uuid
          type: string
        date:
          description: 使用日。UTC タイムゾーンに基づく ISO-8601 形式の日付です。
          format: date
          type: string
        entityId:
          description: エンティティの一意の ID。
          format: uuid
          type: string
        entityName:
          description: エンティティの名前。
          type: string
        entityType:
          description: エンティティの種類。
          enum:
            - datawarehouse
            - service
            - clickpipe
          type: string
        locked:
          description: true の場合、このレコードは不変です。ロック解除されたレコードは、ロックされるまで変更される可能性があります。
          type: boolean
        metrics:
          $ref: '#/components/schemas/UsageCostMetrics'
        serviceId:
          description: >-
            このエンティティが属する service の ID（またはこのエンティティ自体の ID）。dataWarehouse
            エンティティの場合は null に設定されます。
          format: uuid
          nullable: true
          type: string
        totalCHC:
          description: このentityにおけるClickHouse Credits（CHCs）での使用コスト合計。
          type: number
    UsageCostMetrics:
      properties:
        backupCHC:
          description: ClickHouse Credits（CHCs）でのバックアップコスト。dataWarehouse エンティティに適用されます。
          type: number
        computeCHC:
          description: >-
            ClickHouse Credits（CHCs）でのコンピュートコスト。service および clickpipe
            エンティティに適用されます。
          type: number
        dataTransferCHC:
          description: ClickHouse Credits（CHCs）でのデータ転送コスト。clickpipe エンティティに適用されます。
          type: number
        initialLoadCHC:
          description: ClickHouse Credits（CHCs）での初期ロードおよび再同期のコスト。clickpipe エンティティに適用されます。
          type: number
        interRegionTier1DataTransferCHC:
          description: >-
            ClickHouse Credits（CHCs）での tier1 リージョン間データ転送コスト。service
            エンティティに適用されます。
          type: number
        interRegionTier2DataTransferCHC:
          description: >-
            ClickHouse Credits（CHCs）での tier2 リージョン間データ転送コスト。service
            エンティティに適用されます。
          type: number
        interRegionTier3DataTransferCHC:
          description: >-
            ClickHouse Credits（CHCs）での tier3 リージョン間データ転送コスト。service
            エンティティに適用されます。
          type: number
        interRegionTier4DataTransferCHC:
          description: >-
            ClickHouse Credits（CHCs）での tier4 リージョン間データ転送コスト。service
            エンティティに適用されます。
          type: number
        publicDataTransferCHC:
          description: ClickHouse Credits（CHCs）でのデータ転送コスト。service エンティティに適用されます。
          type: number
        storageCHC:
          description: ClickHouse Credits（CHCs）でのストレージコスト。dataWarehouse エンティティに適用されます。
          type: number
  securitySchemes:
    basicAuth:
      description: >-
        ClickHouse Cloud コンソールで取得した key ID と key secret を使用してください:
        https://clickhouse.com/docs/cloud/manage/openapi
      scheme: basic
      type: http

````