> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nika.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# source

> Contract, placement, related fields and source examples for this Nika YAML field.

[Language reference](/reference/language/overview) / `source`

## Meaning and placement

### → secrets · additionalProperties

Where the secret lives · never an inline value (spec/01-envelope.md §secrets).

| Property        | Declaration                                                  |
| --------------- | ------------------------------------------------------------ |
| Requirement     | Required in this object                                      |
| Schema location | `/properties/secrets/additionalProperties/properties/source` |
| enum            | \["vault", "env", "file"]                                    |

**In the same object:** [egress](/reference/language/words/egress) · [key](/reference/language/words/key) · [path](/reference/language/words/path)

[Schema source (use the pointer above)](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/schemas/workflow.schema.json)

### → secrets · additionalProperties · allOf · 0 · if

The schema declares this field at the location below.

| Property        | Declaration                                                             |
| --------------- | ----------------------------------------------------------------------- |
| Requirement     | Optional in this object                                                 |
| Schema location | `/properties/secrets/additionalProperties/allOf/0/if/properties/source` |
| const           | "file"                                                                  |

[Schema source (use the pointer above)](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/schemas/workflow.schema.json)

### infer → vision · items

The schema declares this field at the location below.

| Property        | Declaration                                              |
| --------------- | -------------------------------------------------------- |
| Requirement     | Optional in this object                                  |
| Schema location | `/$defs/infer/properties/vision/items/properties/source` |
| type            | "string"                                                 |
| enum            | \["file", "url"]                                         |

**In the same object:** [path](/reference/language/words/path) · [url](/reference/language/words/url)

[Schema source (use the pointer above)](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/schemas/workflow.schema.json)

## In a source template

Excerpt from `templates/api-upload-and-create.nika.yaml`, source lines 42–51. This is a fragment, not a runnable workflow.

```yaml illustration theme={"system"}

secrets:
  API_KEY:
    source: env
    key: EXAMPLE_API_KEY            # SLOT: the OS env var holding the key
    egress:
      - to: "nika:fetch"            # the send · default-deny otherwise
      - to: "outputs"               # the return value derives from the authed response

permits:                            # the blast radius · default-deny once present
```

### Templates containing this field

| Template                                    | Source                                                                                                                                            |
| ------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| `templates/api-upload-and-create.nika.yaml` | [Line 45](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/templates/api-upload-and-create.nika.yaml#L45) |
| `templates/chain.nika.yaml`                 | [Line 33](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/templates/chain.nika.yaml#L33)                 |
| `templates/classify-and-route.nika.yaml`    | [Line 66](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/templates/classify-and-route.nika.yaml#L66)    |
| `templates/gate-and-act.nika.yaml`          | [Line 44](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/templates/gate-and-act.nika.yaml#L44)          |
| `templates/human-gated-ship.nika.yaml`      | [Line 78](https://github.com/supernovae-st/nika-spec/blob/c5ebbb7b862b68bc6cf7235efba61173b844afc6/templates/human-gated-ship.nika.yaml#L78)      |

These are literal key occurrences in the source files, not an execution or conformance claim. [How to instantiate a template](/guides/templates).

## Contract and implementation

This page projects the named specification revision. Check [released engine status](/reference/status) and [the validation workflow](/guides/agent-authoring) before running a file. An optional field is not evidence that every engine supports every value.

Canonical identity: `language:word:source`. Spec revision: [`c5ebbb7b862b`](https://github.com/supernovae-st/nika-spec/tree/c5ebbb7b862b68bc6cf7235efba61173b844afc6).

[How documentation stays connected](/reference/knowledge-system).
