# Output Templates
Thanix uses Rust source code templates for the generated crate structure. They live in `src/templates/`.
## Template Files
| `Cargo.toml.template` | `{output}/Cargo.toml` | Package manifest with dependencies |
| `lib.rs.template` | `{output}/src/lib.rs` | Crate root with module declarations |
| `util.rs.template` | `{output}/src/util.rs` | `ThanixClient` struct and helpers |
| `usings.template` | Prepended to `paths.rs` | Imports and uses for generated path code |
| `build.rs.template` | `{output}/build.rs` | Embeds version from Cargo.toml |
| `README.md.template` | `{output}/README.md` | Generated crate readme |
## Customization
You can modify these templates to customize the generated output. The templates use Rust's `include_str!()` macro and are formatted with `format!()` for dynamic values (such as the crate name in `Cargo.toml.template`).
### Generated Crate Structure
```
{output}/
├── Cargo.toml
├── build.rs
├── README.md
└── src/
├── lib.rs
├── util.rs
├── types.rs # Generated
└── paths.rs # Generated
```
## The ThanixClient
The generated `ThanixClient` struct is flexible by design:
```rust
pub struct ThanixClient {
pub client: reqwest::blocking::Client,
pub base_url: String,
pub auth_header_value: Option<String>,
}
```
- `client`: The underlying `reqwest` blocking client
- `base_url`: The API base URL (without path prefix)
- `auth_header_value`: Optional. Set to the complete Authorization header value