# `NativeArtifact`
[🔗](https://github.com/gsmlg-dev/native_artifact/blob/main/lib/native_artifact.ex#L1)

Contracts for managing precompiled NIF bundles.

Explicit targets, bounded Manifest v1 validation and pure resolution/planning
and verified local installation are implemented. Plans perform no I/O; local
execution revalidates their complete snapshots. Downloads, caches, source build
execution and Mix integration remain pending. No platform has completed runtime
certification.

# `install`

```elixir
@spec install(NativeArtifact.Plan.t(), keyword()) ::
  {:ok, map()} | {:error, NativeArtifact.Error.t()}
```

Executes a consistent precompiled plan using supplied local archive bytes.

Required `:archive_path` and `:priv_dir` are normalized absolute local paths;
`:priv_dir` must be an existing physical application-owned directory. Optional
`:archive_limits` and `:timeout` are forwarded to the local Installer. Selection,
mode and manifest limits come only from the freshly revalidated plan. Source
plans return `:source_execution_pending` without filesystem/build/network work.

# `plan`

```elixir
@spec plan(term(), keyword()) ::
  {:ok, NativeArtifact.Plan.t()} | {:error, NativeArtifact.Error.t()}
```

Builds a pure, inspectable plan from pinned metadata and explicit evidence.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
