# Connect data

> Bring data in from files, Singer taps, or an app pushing records over the API.

Each entry under `adapters` is one source. Its `transport` says how records are fetched, its `trigger`
when, and its `normalize` block what they mean (see [Observations](/loom-site/concepts/observations/)).

## Files in a folder

The built-in `native` transport reads one record per file:

```yaml
adapters:
  - name: expenses
    transport: native
    auth: { type: none }
    trigger: { mode: poll }
    options:
      path: ~/expenses
      pattern: "*.json"
      format: json        # or text
    normalize: { ... }
```

## Singer taps

Any [Singer](https://www.singer.io) tap works, written in any language. Loom runs it as a subprocess
once per cycle and keeps its bookmark, so each run picks up where the last stopped:

```yaml
adapters:
  - name: hosts
    transport: singer
    trigger: { mode: poll }
    options:
      command: ["tap-host-metrics"]
      stream: host_metrics
    normalize: { ... }
```

The Loom repository ships taps for git, GitHub and Gmail, and a conformance kit that checks your own
tap speaks the protocol the way Loom expects.

## Pushed by an app

With `trigger: { mode: push }`, Loom fetches nothing. An app sends records to `POST /observations`,
naming the adapter, and they are normalized by that adapter's recipe.

## Triggers

| `trigger.mode` | When records arrive |
|---|---|
| `poll` | Loom fetches once per cycle, so `goal.evaluate_every` sets the pace. |
| `push` | An app posts them to the API. |

## Credentials

Adapters declare their auth method; secrets live behind `vault://<namespace>/<name>` references,
never inline. A bundle lists the vault namespaces it may read in `secrets.namespaces`.