---
title: costs
description: 日付範囲のcredit費用を確認する。
canonical_url: https://orchestor.io/docs/cli/cost
markdown_url: https://orchestor.io/docs/cli/cost.md
contentType: reference
---

# costs

`orc costs get` は、対象Workspaceのcredit費用を日次bucketで取得します。`--group-by cost_type` で費用種別ごとに分けられます。

`--start-time` は必須のRFC 3339日時で、その時刻を含みます。`--end-time` は含まない上限で、開始より後を指定します。範囲は最大90日です。終了を省略すると各requestの現在時刻を使うため、ページ送りでは終了を明示して範囲を固定します。

## 使い方

```bash title="terminal"
orc costs get --start-time 2026-09-01T00:00:00Z --end-time 2026-10-01T00:00:00Z
```

*期間を固定して取得します。*

## 集計とページ送り

group化を省略すると各bucket内の該当記録を集計します。保存された値がnullのgroup項目は結果から省略されます。`--cursor` は返された値を変更せず使い、範囲・filter・group条件を維持します。

## サブコマンド

### `get`

費用は日次 `1d` のみです。`cost_type` でgroup化できます。

```bash title="terminal"
orc costs get [options]
```

#### 固有のオプション

##### `--start-time`

Inclusive lower bound for usage records, as an RFC 3339 timestamp. Required. The range from start_time to end_time cannot exceed 90 days.

型: `string`。必須。

```bash title="terminal"
orc costs get --start-time <value>
```

##### `--end-time`

Exclusive upper bound for usage records. Must be after start_time. Defaults to the time of each request; set it explicitly to keep a fixed range across pages.

型: `string`。任意。

```bash title="terminal"
orc costs get --end-time <value>
```

##### `--bucket-width`

Cost reports support daily buckets only. Defaults to 1d.; enum: 1d

型: `string`。任意。

```bash title="terminal"
orc costs get --bucket-width <value>
```

##### `--group-by`

Split each time bucket by cost_type. Omit to aggregate all matching records in each bucket. Use repeated HTTP query parameters. A grouping field is omitted from a result when its stored value is null.; csv of: cost_type

型: `string`。任意。

```bash title="terminal"
orc costs get --group-by <value>
```

## 使用例

### 種別ごとのJSONを取得します。

```bash title="terminal"
orc costs get --start-time 2026-09-01T00:00:00Z --end-time 2026-10-01T00:00:00Z --group-by cost_type --json
```

*種別ごとのJSONを取得します。*

## 必要な権限

認証し、対象Workspaceを選択して実行します。対象Workspaceへのアクセスが必要です。

## グローバルオプション

`orc costs` では、次の[グローバルオプション](https://orchestor.io/docs/cli/global-flags.md)を使用できます。

- [`--help`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%98%E3%83%AB%E3%83%97)
- [`--workspace`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%AF%E3%83%BC%E3%82%AF%E3%82%B9%E3%83%9A%E3%83%BC%E3%82%B9)
- [`--json`](https://orchestor.io/docs/cli/global-flags.md#json-%E5%87%BA%E5%8A%9B)
- [`--pretty`](https://orchestor.io/docs/cli/global-flags.md#json-%E5%87%BA%E5%8A%9B)
- [`--format`](https://orchestor.io/docs/cli/global-flags.md#%E5%87%BA%E5%8A%9B%E5%BD%A2%E5%BC%8F)
- [`--field`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%95%E3%82%A3%E3%83%BC%E3%83%AB%E3%83%89%E3%81%AE%E6%8A%BD%E5%87%BA)
- [`--fields`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%95%E3%82%A3%E3%83%BC%E3%83%AB%E3%83%89%E3%81%AE%E6%8A%BD%E5%87%BA)
- [`--raw`](https://orchestor.io/docs/cli/global-flags.md#%E5%80%A4%E3%81%A0%E3%81%91%E3%82%92%E5%87%BA%E5%8A%9B)
- [`--output`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%95%E3%82%A1%E3%82%A4%E3%83%AB%E3%81%B8%E3%81%AE%E5%87%BA%E5%8A%9B)
- [`--no-pager`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%9A%E3%83%BC%E3%82%B8%E9%80%81%E3%82%8A)
- [`--dry-run`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%AA%E3%82%AF%E3%82%A8%E3%82%B9%E3%83%88%E3%81%AE%E4%BA%8B%E5%89%8D%E7%A2%BA%E8%AA%8D)
- [`--yes`](https://orchestor.io/docs/cli/global-flags.md#%E7%A2%BA%E8%AA%8D%E3%81%AE%E7%9C%81%E7%95%A5)
- [`--limit`](https://orchestor.io/docs/cli/global-flags.md)
- [`--cursor`](https://orchestor.io/docs/cli/global-flags.md)
- [`--stdin`](https://orchestor.io/docs/cli/global-flags.md#%E6%A8%99%E6%BA%96%E5%85%A5%E5%8A%9B)
- [`--from-stdin`](https://orchestor.io/docs/cli/global-flags.md#%E6%A8%99%E6%BA%96%E5%85%A5%E5%8A%9B)
- [`--page-all`](https://orchestor.io/docs/cli/global-flags.md#%E3%81%99%E3%81%B9%E3%81%A6%E3%81%AE%E3%83%9A%E3%83%BC%E3%82%B8%E3%82%92%E5%8F%96%E5%BE%97)
- [`--timing`](https://orchestor.io/docs/cli/global-flags.md#%E3%83%AA%E3%82%AF%E3%82%A8%E3%82%B9%E3%83%88%E6%99%82%E9%96%93)
- [`--readonly`](https://orchestor.io/docs/cli/global-flags.md#%E8%AA%AD%E3%81%BF%E5%8F%96%E3%82%8A%E5%B0%82%E7%94%A8%E3%83%A2%E3%83%BC%E3%83%89)
- [`--wrap-untrusted`](https://orchestor.io/docs/cli/global-flags.md#%E5%A4%96%E9%83%A8%E3%83%86%E3%82%AD%E3%82%B9%E3%83%88%E3%81%AE%E7%9B%AE%E5%8D%B0%E4%BB%98%E3%81%91)

各オプションの詳細と使用例は、[グローバルオプション](https://orchestor.io/docs/cli/global-flags.md)を参照してください。

---

[Documentation index](https://orchestor.io/docs/llms.txt)
