---
title: Amplitude
description: Połącz Amplitude, poznaj sposób synchronizacji i wysyłaj zapytania do wszystkich zapisywanych tabel i kolumn.
species: reference
---
# Amplitude

Połącz Amplitude za pomocą klucza API i sekretu oraz ustaw datę rozpoczęcia importu historycznego. Źródło zapisuje 1 stałą tabelę w schemacie `titan.amplitude`.
```sql
select
  uuid,
  event_id,
  event_type
from titan.amplitude.events
limit 10
```

## Połącz Amplitude

1. Otwórz **Aplikacje**, wybierz **Połącz aplikację**, a następnie **Amplitude**.
2. Podaj klucz API, sekret i datę rozpoczęcia importu historycznego.
3. Sprawdź tabele, a następnie zapisz źródło.
4. Obserwuj **Historię synchronizacji**, aż pierwsze uruchomienie się zakończy.

Dane uwierzytelniające są przechowywane jako sekrety. Nigdy nie stają się kolumnami jeziora ani nie pojawiają się w wynikach zapytań.

## Sposób synchronizacji

Pierwsze uruchomienie zaczyna się od ustawionej daty importu historycznego. Kolejne są kontynuowane od ostatniego ukończonego przedziału.

Nowe źródło synchronizuje się po połączeniu, a następnie zgodnie z harmonogramem. Domyślny interwał cykliczny wynosi 4 godziny. Przerwane uruchomienie zachowuje ukończone postępy i jest bezpiecznie ponawiane.

Każda tabela jeziora ma też [kolumny systemowe](/docs/concepts/your-lake#kolumny-systemowe) `_synced_at` i `_deleted`; poniższa dokumentacja kolumn obejmuje wyłącznie kolumny źródłowe.

## Dokumentacja tabel

### `events`

`titan.amplitude.events` ma 40 kolumn źródłowych.

```columns table=amplitude.events
uuid                                    string pk           Pole źródłowe `uuid`.
event_id                                integer             Pole źródłowe `event_id`.
event_type                              string              Pole źródłowe `event_type`.
event_time                              datetime            Pole źródłowe `event_time`.
user_id                                 string              Pole źródłowe `user_id`.
session_id                              integer             Pole źródłowe `session_id`.
amplitude_id                            integer             Pole źródłowe `amplitude_id`.
amplitude_attribution_ids               string              Pole źródłowe `amplitude_attribution_ids`.
server_received_time                    datetime            Pole źródłowe `server_received_time`.
server_upload_time                      datetime            Pole źródłowe `server_upload_time`.
client_upload_time                      datetime            Pole źródłowe `client_upload_time`.
client_event_time                       datetime            Pole źródłowe `client_event_time`.
sample_rate                             string              Pole źródłowe `sample_rate`.
start_version                           string              Pole źródłowe `start_version`.
app                                     integer             Pole źródłowe `app`.
library                                 string              Pole źródłowe `library`.
device_carrier                          string              Pole źródłowe `device_carrier`.
processed_time                          datetime            Pole źródłowe `processed_time`.
version_name                            string              Pole źródłowe `version_name`.
paying                                  boolean             Pole źródłowe `paying`.
platform                                string              Pole źródłowe `platform`.
os_name                                 string              Pole źródłowe `os_name`.
os_version                              string              Pole źródłowe `os_version`.
device_id                               string              Pole źródłowe `device_id`.
device_type                             string              Pole źródłowe `device_type`.
device_family                           string              Pole źródłowe `device_family`.
language                                string              Pole źródłowe `language`.
country                                 string              Pole źródłowe `country`.
region                                  string              Pole źródłowe `region`.
city                                    string              Pole źródłowe `city`.
dma                                     string              Pole źródłowe `dma`.
ip_address                              string              Pole źródłowe `ip_address`.
data                                    json                Pole źródłowe `data`.
event_properties                        json                Pole źródłowe `event_properties`.
user_properties                         json                Pole źródłowe `user_properties`.
group_properties                        json                Pole źródłowe `group_properties`.
groups                                  json                Pole źródłowe `groups`.
location_lat                            float               Pole źródłowe `location_lat`.
location_lng                            float               Pole źródłowe `location_lng`.
insert_id                               string              Pole źródłowe `insert_id`.
```

## Usunięcia i historia

Wiersze są scalane według klucza źródłowego. Gdy źródło może potwierdzić usunięcie wiersza, Supernova zachowuje go i ustawia `_deleted`, dzięki czemu zapytania mogą zdecydować, czy uwzględniać historię. Aby pobierać bieżący stan, filtruj zapytania przez `where not _deleted`.
