---
title: Amplitude
description: Amplitudeを接続して同期の動作を把握し、書き込まれるすべてのテーブルと列をクエリします。
species: reference
---
# Amplitude

API キー、シークレット、過去データの取得開始日を使って Amplitude を接続します。このソースは `titan.amplitude` に 1 個の固定テーブルを書き込みます。
```sql
select
  uuid,
  event_id,
  event_type
from titan.amplitude.events
limit 10
```

## Amplitudeを接続する

1. **アプリ**を開き、**アプリを接続**を選択してから、**Amplitude**を選択します。
2. API キー、シークレット、過去データの取得開始日を入力します。
3. テーブルを確認してからソースを保存します。
4. 初回の実行が完了するまで**同期履歴**を確認します。

認証情報はシークレットとして保存されます。レイクの列になったり、クエリ結果に表示されたりすることはありません。

## 同期の動作

初回は設定した過去データの取得開始日から実行します。以降は最後に完了した期間から再開します。

新しいソースは接続時に同期し、その後はスケジュールに従います。デフォルトの繰り返し間隔は 4 時間です。実行が中断しても、完了した進捗を保持して安全に再試行します。

すべてのレイクのテーブルには[システム列](/docs/concepts/your-lake#システム列) `_synced_at` と `_deleted` もあります。以下の列リファレンスにはソースの列のみを記載しています。

## テーブルリファレンス

### `events`

`titan.amplitude.events` には 40 個のソース列があります。

```columns table=amplitude.events
uuid                                    string pk           ソースのフィールド `uuid`。
event_id                                integer             ソースのフィールド `event_id`。
event_type                              string              ソースのフィールド `event_type`。
event_time                              datetime            ソースのフィールド `event_time`。
user_id                                 string              ソースのフィールド `user_id`。
session_id                              integer             ソースのフィールド `session_id`。
amplitude_id                            integer             ソースのフィールド `amplitude_id`。
amplitude_attribution_ids               string              ソースのフィールド `amplitude_attribution_ids`。
server_received_time                    datetime            ソースのフィールド `server_received_time`。
server_upload_time                      datetime            ソースのフィールド `server_upload_time`。
client_upload_time                      datetime            ソースのフィールド `client_upload_time`。
client_event_time                       datetime            ソースのフィールド `client_event_time`。
sample_rate                             string              ソースのフィールド `sample_rate`。
start_version                           string              ソースのフィールド `start_version`。
app                                     integer             ソースのフィールド `app`。
library                                 string              ソースのフィールド `library`。
device_carrier                          string              ソースのフィールド `device_carrier`。
processed_time                          datetime            ソースのフィールド `processed_time`。
version_name                            string              ソースのフィールド `version_name`。
paying                                  boolean             ソースのフィールド `paying`。
platform                                string              ソースのフィールド `platform`。
os_name                                 string              ソースのフィールド `os_name`。
os_version                              string              ソースのフィールド `os_version`。
device_id                               string              ソースのフィールド `device_id`。
device_type                             string              ソースのフィールド `device_type`。
device_family                           string              ソースのフィールド `device_family`。
language                                string              ソースのフィールド `language`。
country                                 string              ソースのフィールド `country`。
region                                  string              ソースのフィールド `region`。
city                                    string              ソースのフィールド `city`。
dma                                     string              ソースのフィールド `dma`。
ip_address                              string              ソースのフィールド `ip_address`。
data                                    json                ソースのフィールド `data`。
event_properties                        json                ソースのフィールド `event_properties`。
user_properties                         json                ソースのフィールド `user_properties`。
group_properties                        json                ソースのフィールド `group_properties`。
groups                                  json                ソースのフィールド `groups`。
location_lat                            float               ソースのフィールド `location_lat`。
location_lng                            float               ソースのフィールド `location_lng`。
insert_id                               string              ソースのフィールド `insert_id`。
```

## 削除と履歴

行はソースのキーでマージされます。ソース側で行の削除を確認できた場合、Supernova は行を残して `_deleted` を設定します。クエリで履歴を含めるかどうかを選べます。現在の状態だけを取得するには `where not _deleted` で絞り込んでください。
