# Reference
## reference
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">exchange_rates_sync</a>(request: ExchangeRatesSyncReferenceRequest) -> Result<ExchangeRatesSyncReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Fetches the euro exchange rates the Bank of Lithuania web service publishes for `date` (default: the company's current date) and stores them in the rate table shared by all companies, replacing the rates already stored for that date. Answers 404 when no rates are published for the date.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.exchange_rates_sync(
&ExchangeRatesSyncReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">exchange_rates_list</a>(request: ExchangeRatesListReferenceRequest) -> Result<ExchangeRatesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the stored euro exchange rates, which are shared by all companies. Filterable by `currencyCode` and `date`; sortable by `date` and `currencyCode`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.exchange_rates_list(
&ExchangeRatesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ExchangeRatesListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ExchangeRatesListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">exchange_rates_set</a>(request: ExchangeRatesSetReferenceRequest) -> Result<ExchangeRatesSetReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Stores a company exchange rate for `currency` on `date`, in units of the currency per one unit of the company's base currency, replacing the company rate stored for that currency and date. Rate lookups use the company rate when it is dated on or after the latest shared rate on or before the lookup date. Answers 422 when `rate` is not positive.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.exchange_rates_set(
&ExchangeRatesSetReferenceRequest {
currency: "currency".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
rate: "121.00000000".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**currency:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**rate:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">exchange_rates_overrides_list</a>(request: ExchangeRatesOverridesListReferenceRequest) -> Result<ExchangeRatesOverridesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's own exchange rates set with `reference/exchange-rates/set`. Filterable by `currencyCode` and `date`; sortable by `date` and `currencyCode`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.exchange_rates_overrides_list(
&ExchangeRatesOverridesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ExchangeRatesOverridesListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ExchangeRatesOverridesListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">exchange_rates_overrides_delete</a>(request: ExchangeRatesOverridesDeleteReferenceRequest) -> Result<ExchangeRatesOverridesDeleteReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Removes the company's own exchange rate for `currency` on `date`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.exchange_rates_overrides_delete(
&ExchangeRatesOverridesDeleteReferenceRequest {
currency: "currency".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**currency:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">countries_list</a>(request: CountriesListReferenceRequest) -> Result<CountriesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists every country code Nordlet knows with its EU and EEA membership and its name in each supported locale.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.countries_list(
&CountriesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">lt_counties_list</a>(request: LtCountiesListReferenceRequest) -> Result<LtCountiesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the ten Lithuanian counties (apskritys) with their code and ISO code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.lt_counties_list(
&LtCountiesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">lt_municipalities_list</a>(request: LtMunicipalitiesListReferenceRequest) -> Result<LtMunicipalitiesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the Lithuanian municipalities (savivaldybės) with the county each belongs to; `countyCode` limits the list to one county.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.lt_municipalities_list(
&LtMunicipalitiesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**county_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">lt_cities_list</a>(request: LtCitiesListReferenceRequest) -> Result<LtCitiesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists Lithuanian cities with their municipality; `municipalityCode` limits the list to one municipality and `q` to names that start with the given text (case-insensitive).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.lt_cities_list(
&LtCitiesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**municipality_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**q:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">banks_list</a>(request: BanksListReferenceRequest) -> Result<BanksListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the banks of the bank directory shared by all companies. Filterable by `countryCode`, `name`, `bic` and `bankCode`; sortable by `name`, `bic` and `countryCode`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.banks_list(
&BanksListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<BanksListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<BanksListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">banks_upsert</a>(request: BanksUpsertReferenceRequest) -> Result<BanksUpsertReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds a bank to the shared bank directory or, when a bank with the same `countryCode` and `bic` exists, replaces its name, bank code and active flag. Platform administrators only.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.banks_upsert(
&BanksUpsertReferenceRequest {
country_code: "countryCode".to_string(),
name: "name".to_string(),
bic: "bic".to_string(),
bank_code: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country_code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**bic:** `String`
</dd>
</dl>
<dl>
<dd>
**bank_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">lt_regions_list</a>(request: LtRegionsListReferenceRequest) -> Result<LtRegionsListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the ten Lithuanian regions (apskritys) with their code and ISO code; the same list as `reference/lt/counties/list`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.lt_regions_list(
&LtRegionsListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">currencies_list</a>(request: CurrenciesListReferenceRequest) -> Result<CurrenciesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the currencies known to Nordlet with their minor units. Filterable and sortable by `code` and `name`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.currencies_list(
&CurrenciesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<CurrenciesListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<CurrenciesListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">vat_classifiers_list</a>(request: VatClassifiersListReferenceRequest) -> Result<VatClassifiersListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's VAT classifiers (code, country, name and rate). A document line that names a classifier in `vatClassifierCode` takes its rate from it when neither the line nor the item has a rate. Filterable by `code`, `countryCode` and `ratePercent`; sortable by `code` and `ratePercent`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.vat_classifiers_list(
&VatClassifiersListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<VatClassifiersListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<VatClassifiersListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">vat_classifiers_upsert</a>(request: VatClassifiersUpsertReferenceRequest) -> Result<VatClassifiersUpsertReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds VAT classifiers to the company or replaces the country, name and rate of the ones whose `code` already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.vat_classifiers_upsert(
&VatClassifiersUpsertReferenceRequest {
rows: vec![VatClassifiersUpsertReferenceRequestRowsItem {
code: "code".to_string(),
name: "name".to_string(),
..Default::default()
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**rows:** `Vec<VatClassifiersUpsertReferenceRequestRowsItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">eu_vat_rates_list</a>(request: EuVatRatesListReferenceRequest) -> Result<EuVatRatesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Effective EU VAT rate mapping for this company: EC TEDB defaults, replaced per country by any company overrides. Verify the mapping fits the goods and services you sell before relying on it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.eu_vat_rates_list(
&EuVatRatesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">eu_vat_rates_set_overrides</a>(request: EuVatRatesSetOverridesReferenceRequest) -> Result<EuVatRatesSetOverridesReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replace the VAT rate mapping this company uses for one EU country. Pass an empty rates array to drop the overrides and return to the TEDB defaults. Overrides feed rate suggestions (vat/resolve) and OSS/IOSS return rate classification.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.eu_vat_rates_set_overrides(
&EuVatRatesSetOverridesReferenceRequest {
country_code: "countryCode".to_string(),
rates: vec![EuVatRatesSetOverridesReferenceRequestRatesItem {
category: EuVatRatesSetOverridesReferenceRequestRatesItemCategory::Standard,
rate_percent: "121.00".to_string(),
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country_code:** `String`
</dd>
</dl>
<dl>
<dd>
**rates:** `Vec<EuVatRatesSetOverridesReferenceRequestRatesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">vat_resolve</a>(request: VatResolveReferenceRequest) -> Result<VatResolveReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Works out the VAT treatment of a supply by this company: the scheme (domestic, intra-EU B2B, reverse charge, OSS, IOSS, marketplace deemed supplier, export, out of scope or SME exempt), the country whose VAT applies, its rates with the company's overrides applied, and the legal basis. The customer comes from `partnerId` (country from the partner's address or VAT number, business status from the VAT number) or from `customerCountryCode` and `customerIsBusiness`; `date` defaults to the company's current date; when `belowDistanceSalesThreshold` is not given, the distance-sales threshold is tracked from the company's ledger. Answers 422 when the partner has neither an address country nor a VAT code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.vat_resolve(
&VatResolveReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**customer_country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**customer_is_business:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**supply_type:** `Option<VatResolveReferenceRequestSupplyType>`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**below_distance_sales_threshold:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**facilitated_by_marketplace:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**acting_as_marketplace:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**seller_established_in_eu:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**imported_consignment_value_eur:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**service_kind:** `Option<VatResolveReferenceRequestServiceKind>`
</dd>
</dl>
<dl>
<dd>
**service_country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**underlying_supplier_gave_vat_number:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**underlying_supplier_charges_vat:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**goods_kind:** `Option<VatResolveReferenceRequestGoodsKind>`
</dd>
</dl>
<dl>
<dd>
**goods_location_country_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">cn_codes_list</a>(request: CnCodesListReferenceRequest) -> Result<CnCodesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the Combined Nomenclature codes of the directory shared by all companies. Filterable by `code`, `name` and `nameLt`; sortable by `code`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.cn_codes_list(
&CnCodesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<CnCodesListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<CnCodesListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">cn_codes_upsert</a>(request: CnCodesUpsertReferenceRequest) -> Result<CnCodesUpsertReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds Combined Nomenclature codes to the shared directory or replaces the names and supplementary unit of the codes that exist. Platform administrators only.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.cn_codes_upsert(
&CnCodesUpsertReferenceRequest {
rows: vec![CnCodesUpsertReferenceRequestRowsItem {
code: "code".to_string(),
name: "name".to_string(),
..Default::default()
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**rows:** `Vec<CnCodesUpsertReferenceRequestRowsItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">compliance_versions_list</a>(request: ComplianceVersionsListReferenceRequest) -> Result<ComplianceVersionsListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the versions of the filing systems, schemas and forms Nordlet's output was checked against, with the date of the check and the source; `country` limits the list to one country.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.compliance_versions_list(
&ComplianceVersionsListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">intrastat_thresholds_list</a>(request: IntrastatThresholdsListReferenceRequest) -> Result<IntrastatThresholdsListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the Intrastat thresholds stored per year: the reporting and the statistical-value threshold for arrivals and for dispatches.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.intrastat_thresholds_list(
&IntrastatThresholdsListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">units_list</a>(request: UnitsListReferenceRequest) -> Result<UnitsListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the measurement units of the directory shared by all companies, with Lithuanian and English names. Filterable by `code`, `nameLt` and `nameEn`; sortable by `code`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.units_list(
&UnitsListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<UnitsListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<UnitsListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">series_create</a>(request: SeriesCreateReferenceRequest) -> Result<SeriesCreateReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a numbering series for a document type, prefix and year; the first number the series hands out is at least `startAt`. Answers 409 when a series with the same document type, prefix and year exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.series_create(
&SeriesCreateReferenceRequest {
document_type: "documentType".to_string(),
year: 1000000,
prefix: None,
start_at: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**document_type:** `String`
</dd>
</dl>
<dl>
<dd>
**prefix:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**start_at:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reference.<a href="/src/api/resources/reference/client.rs">series_list</a>(request: SeriesListReferenceRequest) -> Result<SeriesListReferenceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's numbering series with the next number of each. Filterable and sortable by `documentType`, `prefix` and `year`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reference
.series_list(
&SeriesListReferenceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<SeriesListReferenceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<SeriesListReferenceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## partners
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">addresses_create</a>(request: AddressesCreatePartnersRequest) -> Result<AddressesCreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds an address of type billing, shipping, registered or other to the partner in `partnerId`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.addresses_create(
&AddressesCreatePartnersRequest {
partner_id: "partnerId".to_string(),
r#type: None,
street: None,
city: None,
postal_code: None,
country_code: None,
is_default: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `Option<AddressesCreatePartnersRequestType>`
</dd>
</dl>
<dl>
<dd>
**street:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**city:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**postal_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_default:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">addresses_update</a>(request: AddressesUpdatePartnersRequest) -> Result<AddressesUpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of a partner address.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.addresses_update(
&AddressesUpdatePartnersRequest {
id: "id".to_string(),
r#type: None,
street: None,
city: None,
postal_code: None,
country_code: None,
is_default: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `Option<AddressesUpdatePartnersRequestType>`
</dd>
</dl>
<dl>
<dd>
**street:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**city:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**postal_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_default:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">addresses_delete</a>(request: AddressesDeletePartnersRequest) -> Result<AddressesDeletePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a partner address.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.addresses_delete(
&AddressesDeletePartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">addresses_list</a>(request: AddressesListPartnersRequest) -> Result<AddressesListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists partner addresses; filterable by `partnerId`, `type` and `city`, sortable by `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.addresses_list(
&AddressesListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<AddressesListPartnersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<AddressesListPartnersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">contacts_create</a>(request: ContactsCreatePartnersRequest) -> Result<ContactsCreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds a contact person to the partner in `partnerId`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.contacts_create(
&ContactsCreatePartnersRequest {
name: "name".to_string(),
partner_id: "partnerId".to_string(),
role: None,
email: None,
phone: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**role:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">contacts_update</a>(request: ContactsUpdatePartnersRequest) -> Result<ContactsUpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of a partner contact.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.contacts_update(
&ContactsUpdatePartnersRequest {
id: "id".to_string(),
name: None,
role: None,
email: None,
phone: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**role:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">contacts_delete</a>(request: ContactsDeletePartnersRequest) -> Result<ContactsDeletePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a partner contact.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.contacts_delete(
&ContactsDeletePartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">contacts_list</a>(request: ContactsListPartnersRequest) -> Result<ContactsListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists partner contacts; filterable by `partnerId`, `name` and `email`, sortable by `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.contacts_list(
&ContactsListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ContactsListPartnersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ContactsListPartnersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">bank_accounts_create</a>(request: BankAccountsCreatePartnersRequest) -> Result<BankAccountsCreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds a bank account to the partner in `partnerId`. The IBAN is stored without spaces in upper case; an IBAN the partner already has is refused with 409. With `isDefault` true the partner's other accounts lose their default mark.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.bank_accounts_create(
&BankAccountsCreatePartnersRequest {
iban: "iban".to_string(),
partner_id: "partnerId".to_string(),
bank_name: None,
bic: None,
currency: None,
is_default: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**iban:** `String`
</dd>
</dl>
<dl>
<dd>
**bank_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**bic:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_default:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">bank_accounts_update</a>(request: BankAccountsUpdatePartnersRequest) -> Result<BankAccountsUpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of a partner bank account. A new IBAN is stored without spaces in upper case and is refused with 409 when the partner already has it; when the account is the default after the change, the partner's other accounts lose their default mark.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.bank_accounts_update(
&BankAccountsUpdatePartnersRequest {
id: "id".to_string(),
iban: None,
bank_name: None,
bic: None,
currency: None,
is_default: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**iban:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**bank_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**bic:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_default:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">bank_accounts_delete</a>(request: BankAccountsDeletePartnersRequest) -> Result<BankAccountsDeletePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a partner bank account.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.bank_accounts_delete(
&BankAccountsDeletePartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">bank_accounts_list</a>(request: BankAccountsListPartnersRequest) -> Result<BankAccountsListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists partner bank accounts; filterable by `partnerId` and `iban`, sortable by `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.bank_accounts_list(
&BankAccountsListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<BankAccountsListPartnersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<BankAccountsListPartnersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">files_list</a>(request: FilesListPartnersRequest) -> Result<FilesListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the files attached to a partner, newest first. `partners/create` attaches one with `documentRef`, and `leads/convert` moves the lead's files here.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.files_list(
&FilesListPartnersRequest {
partner_id: "partnerId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">debt_reminders_preview</a>(request: DebtRemindersPreviewPartnersRequest) -> Result<DebtRemindersPreviewPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Runs the overdue selection of the daily debt-reminder job for this company as of the company's current date and returns the overdue reminders it would send, without sending or recording anything. A partner is included when it has `autoDebtReminder`, is active, has an e-mail address, got no overdue reminder in the last `repeatDays` days (`partners/debt-reminders/settings/get`) and has issued invoices or advance invoices past their due date with an unpaid remainder; the interest per invoice is the remainder times the partner's `lateInterestPercent` times the days late over 365, and the totals are per currency. Sent reminders are listed by `partners/debt-reminders/list`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.debt_reminders_preview(
&DebtRemindersPreviewPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">debt_reminders_list</a>(request: DebtRemindersListPartnersRequest) -> Result<DebtRemindersListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the debt reminders the daily job has sent, one row per partner and currency with the ids of the invoices it covered and its `kind` (`before_due` or `overdue`); filterable by `partnerId`, sortable by `sentAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.debt_reminders_list(
&DebtRemindersListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<DebtRemindersListPartnersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<DebtRemindersListPartnersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">debt_reminders_settings_get</a>(request: DebtRemindersSettingsGetPartnersRequest) -> Result<DebtRemindersSettingsGetPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns the debt-reminder schedule of the company: `daysBefore`, the days before the due date on which the first reminder is sent (null when no reminder is sent before the due date), and `repeatDays`, the days between overdue reminders to a partner.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.debt_reminders_settings_get(
&DebtRemindersSettingsGetPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">debt_reminders_settings_update</a>(request: DebtRemindersSettingsUpdatePartnersRequest) -> Result<DebtRemindersSettingsUpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of the company's debt-reminder schedule. `daysBefore` (1 to 90, or null to send nothing before the due date) makes the daily job send one "payment due soon" reminder per invoice that many days before its due date; `repeatDays` (1 to 90) is the number of days between overdue reminders to a partner. Only partners with `autoDebtReminder` get reminders. A body without fields is refused with 400.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.debt_reminders_settings_update(
&DebtRemindersSettingsUpdatePartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**days_before:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**repeat_days:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">debt_reminders_upcoming</a>(request: DebtRemindersUpcomingPartnersRequest) -> Result<DebtRemindersUpcomingPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns the next reminder the daily debt-reminder job would send for each unpaid issued invoice or advance invoice of the partners that get reminders (`autoDebtReminder`, active, with an e-mail address), as of the company's current date and sorted by `date`. A `before_due` reminder is sent once per invoice, `daysBefore` days before its due date or on the first daily run after that while the due date is still ahead; `overdue` reminders start the day after the due date and repeat every `repeatDays` days per partner, counting only overdue reminders. Nothing is sent or recorded.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.debt_reminders_upcoming(
&DebtRemindersUpcomingPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">validate_vat</a>(request: ValidateVatPartnersRequest) -> Result<ValidateVatPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Checks a VAT number against VIES, either a free `vatCode` or the VAT code of the partner in `partnerId` (exactly one of the two); a code without an EU country prefix and 2 to 12 alphanumeric characters is refused with 422, as is a partner without a VAT code, and a VIES outage answers 503. With a partner the outcome is written to it (`vatValid`, `vatValidatedAt`): an invalid number or a VIES name that shares no word with the partner's name opens or refreshes the partner's VAT review (`vat_review.opened`), a VIES failure opens one with reason `service_error`, and a valid matching number resolves the open review as `revalidated` (`vat_review.resolved`). Reviews are listed and closed with `partners/vat-reviews/list` and `partners/vat-reviews/resolve`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.validate_vat(
&ValidateVatPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**vat_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">vat_reviews_list</a>(request: VatReviewsListPartnersRequest) -> Result<VatReviewsListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the VAT reviews opened by VIES checks of partners' VAT codes, with reason `invalid`, `name_mismatch` or `service_error`; filterable by `partnerId`, `status` and `reason`, sortable by `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.vat_reviews_list(
&VatReviewsListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<VatReviewsListPartnersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<VatReviewsListPartnersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">vat_reviews_resolve</a>(request: VatReviewsResolvePartnersRequest) -> Result<VatReviewsResolvePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Closes an open VAT review as `confirmed_valid`, `confirmed_invalid` or `dismissed`, with an optional note. The first two also set the partner's `vatValid` and stamp `vatValidatedAt` when the partner still carries the reviewed VAT code; `dismissed` leaves the partner unchanged. A review that is already resolved answers 409; emits `vat_review.resolved`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.vat_reviews_resolve(
&VatReviewsResolvePartnersRequest {
id: "id".to_string(),
resolution: VatReviewsResolvePartnersRequestResolution::ConfirmedValid,
note: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**resolution:** `VatReviewsResolvePartnersRequestResolution`
</dd>
</dl>
<dl>
<dd>
**note:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">create</a>(request: CreatePartnersRequest) -> Result<CreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a partner. `groupId`, `statusId` and `priceListId` must belong to the company; without `legalCountryClass` the class is derived from the address country (`lt`, `eu` or `non_eu`); `documentRef` attaches an uploaded file that is not yet linked to a record; a `code` already used by a live partner of the company is refused with 409. A `vatCode` is checked against VIES at once and the result stored on the partner: an invalid number, a VIES name that shares no word with the partner's name, or a VIES failure opens a VAT review (`vat_review.opened`), while a code that is not an EU VAT number is stored unchecked (see `partners/validate-vat`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.create(
&CreatePartnersRequest {
name: "name".to_string(),
r#type: None,
code: None,
vat_code: None,
peppol_id: None,
email: None,
phone: None,
self_employment_cert_no: None,
birth_date: None,
is_customer: None,
is_supplier: None,
payment_term_days: None,
credit_limit: None,
price_list_id: None,
group_id: None,
status_id: None,
address: None,
correspondence_address: None,
notes: None,
document_ref: None,
short_name: None,
website: None,
fax: None,
eori_code: None,
auto_debt_reminder: None,
late_interest_percent: None,
first_call_date: None,
last_call_date: None,
next_call_date: None,
rating: None,
is_employee: None,
is_group_member: None,
is_active: None,
legal_country_class: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `Option<CreatePartnersRequestType>`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**peppol_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**self_employment_cert_no:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_customer:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_supplier:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**payment_term_days:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**credit_limit:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**price_list_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**group_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**status_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<CreatePartnersRequestAddress>`
</dd>
</dl>
<dl>
<dd>
**correspondence_address:** `Option<CreatePartnersRequestCorrespondenceAddress>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**short_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**website:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**fax:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**eori_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**auto_debt_reminder:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**late_interest_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**first_call_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**last_call_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**next_call_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**rating:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_employee:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_group_member:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**legal_country_class:** `Option<CreatePartnersRequestLegalCountryClass>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">find_or_create</a>(request: FindOrCreatePartnersRequest) -> Result<FindOrCreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns the live partner matched by `code`, then `vatCode`, then `email` (at least one is required), or creates one from the body with the same validation and VIES check as `partners/create`; `created` says which happened. A creation that loses a race on the partner code returns the partner the other call created.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.find_or_create(
&FindOrCreatePartnersRequest {
name: "name".to_string(),
r#type: None,
code: None,
vat_code: None,
peppol_id: None,
email: None,
phone: None,
self_employment_cert_no: None,
birth_date: None,
is_customer: None,
is_supplier: None,
payment_term_days: None,
credit_limit: None,
price_list_id: None,
group_id: None,
status_id: None,
address: None,
correspondence_address: None,
notes: None,
document_ref: None,
short_name: None,
website: None,
fax: None,
eori_code: None,
auto_debt_reminder: None,
late_interest_percent: None,
first_call_date: None,
last_call_date: None,
next_call_date: None,
rating: None,
is_employee: None,
is_group_member: None,
is_active: None,
legal_country_class: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `Option<FindOrCreatePartnersRequestType>`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**peppol_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**self_employment_cert_no:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_customer:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_supplier:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**payment_term_days:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**credit_limit:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**price_list_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**group_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**status_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<FindOrCreatePartnersRequestAddress>`
</dd>
</dl>
<dl>
<dd>
**correspondence_address:** `Option<FindOrCreatePartnersRequestCorrespondenceAddress>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**short_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**website:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**fax:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**eori_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**auto_debt_reminder:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**late_interest_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**first_call_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**last_call_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**next_call_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**rating:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_employee:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_group_member:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**legal_country_class:** `Option<FindOrCreatePartnersRequestLegalCountryClass>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">get</a>(request: GetPartnersRequest) -> Result<GetPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns one partner; a deleted partner answers 404.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.get(
&GetPartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">update</a>(request: UpdatePartnersRequest) -> Result<UpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of a partner; the clearable fields accept null. A new address country re-derives `legalCountryClass` unless the class is given, and a `code` already used by another live partner of the company is refused with 409. A changed `vatCode` resets the VIES result and is checked at once as in `partners/create`; a removed code, or one that is not an EU VAT number, resolves the partner's open VAT review as `superseded` (`vat_review.resolved`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.update(
&UpdatePartnersRequest {
id: "id".to_string(),
r#type: None,
name: None,
code: None,
vat_code: None,
peppol_id: None,
email: None,
phone: None,
self_employment_cert_no: None,
birth_date: None,
is_customer: None,
is_supplier: None,
payment_term_days: None,
credit_limit: None,
price_list_id: None,
group_id: None,
status_id: None,
address: None,
correspondence_address: None,
notes: None,
document_ref: None,
short_name: None,
website: None,
fax: None,
eori_code: None,
auto_debt_reminder: None,
late_interest_percent: None,
first_call_date: None,
last_call_date: None,
next_call_date: None,
rating: None,
is_employee: None,
is_group_member: None,
is_active: None,
legal_country_class: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<UpdatePartnersRequestType>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**peppol_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**self_employment_cert_no:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_customer:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_supplier:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**payment_term_days:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**credit_limit:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**price_list_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**group_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**status_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<Option<UpdatePartnersRequestAddress>>`
</dd>
</dl>
<dl>
<dd>
**correspondence_address:** `Option<Option<UpdatePartnersRequestCorrespondenceAddress>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**short_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**website:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**fax:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**eori_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**auto_debt_reminder:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**late_interest_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**first_call_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**last_call_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**next_call_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**rating:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_employee:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_group_member:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**legal_country_class:** `Option<Option<UpdatePartnersRequestLegalCountryClass>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">delete</a>(request: DeletePartnersRequest) -> Result<DeletePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Marks a partner as deleted; it no longer appears in lists or lookups.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.delete(
&DeletePartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">merge</a>(request: MergePartnersRequest) -> Result<MergePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Moves every row that references the duplicate `sourceId` through a foreign key to partners (looked up in the database catalogue, within the company) to `targetId`, then marks the source partner as deleted; `moved` lists the tables, columns and row counts. Merging a partner into itself is 422, and when both partners hold the same unique entry (for example the same IBAN or item supplier row) the merge is refused with 409 until it is removed from one of them. When the kept partner has an open VAT review, the duplicate's open review is resolved as `superseded` (`vat_review.resolved`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.merge(
&MergePartnersRequest {
source_id: "sourceId".to_string(),
target_id: "targetId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**source_id:** `String`
</dd>
</dl>
<dl>
<dd>
**target_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">anonymize</a>(request: AnonymizePartnersRequest) -> Result<AnonymizePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Removes birth date, self-employment certificate number, email, phone, address, notes, contacts, addresses and bank accounts, then hides the partner. The name, code and VAT number stay because issued invoices must keep identifying the counterparty for the statutory retention period.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.anonymize(
&AnonymizePartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">list</a>(request: ListPartnersRequest) -> Result<ListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists live partners; filterable by `name`, `code`, `vatCode`, `email`, `type`, `isCustomer`, `isSupplier`, `isActive`, `legalCountryClass`, `isEmployee`, `groupId`, `statusId` and `nextCallDate`, sortable by `name`, `code`, `createdAt`, `nextCallDate` and `rating`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.list(
&ListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListPartnersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListPartnersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">groups_create</a>(request: GroupsCreatePartnersRequest) -> Result<GroupsCreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a partner group; a `code` already used by a group of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.groups_create(
&GroupsCreatePartnersRequest {
code: "code".to_string(),
name: "name".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">groups_update</a>(request: GroupsUpdatePartnersRequest) -> Result<GroupsUpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the code or name of a partner group; a code already used by another group of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.groups_update(
&GroupsUpdatePartnersRequest {
id: "id".to_string(),
code: None,
name: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">groups_delete</a>(request: GroupsDeletePartnersRequest) -> Result<GroupsDeletePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a partner group; a group still assigned to a live partner is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.groups_delete(
&GroupsDeletePartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">groups_list</a>(request: GroupsListPartnersRequest) -> Result<GroupsListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's partner groups ordered by code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.groups_list(
&GroupsListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">statuses_create</a>(request: StatusesCreatePartnersRequest) -> Result<StatusesCreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a partner status with a `sortOrder`; a `code` already used by a status of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.statuses_create(
&StatusesCreatePartnersRequest {
code: "code".to_string(),
name: "name".to_string(),
sort_order: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**sort_order:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">statuses_update</a>(request: StatusesUpdatePartnersRequest) -> Result<StatusesUpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the code, name or sort order of a partner status; a code already used by another status of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.statuses_update(
&StatusesUpdatePartnersRequest {
id: "id".to_string(),
code: None,
name: None,
sort_order: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort_order:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">statuses_delete</a>(request: StatusesDeletePartnersRequest) -> Result<StatusesDeletePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a partner status; a status still assigned to a live partner is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.statuses_delete(
&StatusesDeletePartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">statuses_list</a>(request: StatusesListPartnersRequest) -> Result<StatusesListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's partner statuses ordered by sort order, then code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.statuses_list(
&StatusesListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">inquiries_create</a>(request: InquiriesCreatePartnersRequest) -> Result<InquiriesCreatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Records an inquiry in status `new`, from a partner (`partnerId`) or from a contact given by `contactName` or `contactEmail`; without any of the three it is refused with 422. `assignedUserId` must be a member of the company. Emits `partner_inquiry.created`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.inquiries_create(
&InquiriesCreatePartnersRequest {
subject: "subject".to_string(),
partner_id: None,
contact_name: None,
contact_email: None,
contact_phone: None,
body: None,
channel: None,
assigned_user_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**contact_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**contact_email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**contact_phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**subject:** `String`
</dd>
</dl>
<dl>
<dd>
**body:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**channel:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**assigned_user_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">inquiries_update</a>(request: InquiriesUpdatePartnersRequest) -> Result<InquiriesUpdatePartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of an inquiry; `partnerId` and `assignedUserId` accept null. Setting `status` to `closed` stamps `closedAt`, and moving a closed inquiry to another status clears it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.inquiries_update(
&InquiriesUpdatePartnersRequest {
id: "id".to_string(),
partner_id: None,
subject: None,
body: None,
channel: None,
status: None,
assigned_user_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**subject:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**body:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**channel:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<InquiriesUpdatePartnersRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**assigned_user_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">inquiries_get</a>(request: InquiriesGetPartnersRequest) -> Result<InquiriesGetPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns one inquiry with the name of its partner.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.inquiries_get(
&InquiriesGetPartnersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">inquiries_list</a>(request: InquiriesListPartnersRequest) -> Result<InquiriesListPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists inquiries with their partner names; filterable by `status`, `channel`, `partnerId`, `assignedUserId` and `subject`, sortable by `createdAt` and `updatedAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.inquiries_list(
&InquiriesListPartnersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<InquiriesListPartnersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<InquiriesListPartnersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.partners.<a href="/src/api/resources/partners/client.rs">credit_check</a>(request: CreditCheckPartnersRequest) -> Result<CreditCheckPartnersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Compares a partner's open receivables plus an optional `additionalAmount` with its `creditLimit`. The open receivables are the unpaid remainder of the partner's issued invoices, advance invoices and credit notes (credit notes negative), converted to the company's base currency at each invoice's `fxRate`. Without a credit limit `available` is null and `exceeded` is false.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.partners
.credit_check(
&CreditCheckPartnersRequest {
partner_id: "partnerId".to_string(),
additional_amount: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**additional_amount:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## Leads
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">create</a>(request: CreateLeadsRequest) -> Result<CreateLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a lead in status `new`, `contacted`, `qualified` or `lost`. `assignedUserId` must be a member of the company and `sourceId` and `typeId` must exist in it; `countryCode` and `currency` are stored in upper case; `documents` attach uploaded files not yet linked to a record, and `notes` become the lead's first notes with the caller as author. Emits `lead.created`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.create(
&CreateLeadsRequest {
name: "name".to_string(),
contact_name: None,
email: None,
phone: None,
website: None,
country_code: None,
source_id: None,
type_id: None,
status: None,
estimated_value: None,
currency: None,
description: None,
assigned_user_id: None,
documents: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**contact_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**website:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**source_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**type_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<CreateLeadsRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**estimated_value:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**assigned_user_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**documents:** `Option<Vec<CreateLeadsRequestDocumentsItem>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Vec<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">get</a>(request: GetLeadsRequest) -> Result<GetLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns one lead with its source and type names.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.get(
&GetLeadsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">update</a>(request: UpdateLeadsRequest) -> Result<UpdateLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of a lead; the clearable fields accept null, `documents` attach more uploaded files, and `countryCode` and `currency` are stored in upper case. A lead that is already converted cannot change `status` (409).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.update(
&UpdateLeadsRequest {
id: "id".to_string(),
name: None,
contact_name: None,
email: None,
phone: None,
website: None,
country_code: None,
source_id: None,
type_id: None,
status: None,
estimated_value: None,
currency: None,
description: None,
assigned_user_id: None,
documents: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**contact_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**website:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**country_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**source_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<UpdateLeadsRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**estimated_value:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**assigned_user_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**documents:** `Option<Vec<UpdateLeadsRequestDocumentsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">delete</a>(request: DeleteLeadsRequest) -> Result<DeleteLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a lead with its notes and detaches its files, which stay in the company's files without a record.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.delete(
&DeleteLeadsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">list</a>(request: ListLeadsRequest) -> Result<ListLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists leads with their source and type names; filterable by `name`, `contactName`, `email`, `phone`, `status`, `sourceId`, `typeId`, `countryCode`, `assignedUserId`, `partnerId`, `estimatedValue` and `createdAt`, sortable by `name`, `status`, `estimatedValue`, `createdAt` and `updatedAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.list(
&ListLeadsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListLeadsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListLeadsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">notes_create</a>(request: NotesCreateLeadsRequest) -> Result<NotesCreateLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds a note to a lead with the caller as author and refreshes the lead's `updatedAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.notes_create(
&NotesCreateLeadsRequest {
lead_id: "leadId".to_string(),
body: "body".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**lead_id:** `String`
</dd>
</dl>
<dl>
<dd>
**body:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">notes_delete</a>(request: NotesDeleteLeadsRequest) -> Result<NotesDeleteLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a lead note.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.notes_delete(
&NotesDeleteLeadsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">notes_list</a>(request: NotesListLeadsRequest) -> Result<NotesListLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the notes of a lead, newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.notes_list(
&NotesListLeadsRequest {
lead_id: "leadId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**lead_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">files_list</a>(request: FilesListLeadsRequest) -> Result<FilesListLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the files attached to a lead, newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.files_list(
&FilesListLeadsRequest {
lead_id: "leadId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**lead_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">sources_create</a>(request: SourcesCreateLeadsRequest) -> Result<SourcesCreateLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a lead source; a `name` already used by a source of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.sources_create(
&SourcesCreateLeadsRequest {
name: "name".to_string(),
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">sources_update</a>(request: SourcesUpdateLeadsRequest) -> Result<SourcesUpdateLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the name or `isActive` flag of a lead source; a name already used by another source of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.sources_update(
&SourcesUpdateLeadsRequest {
id: "id".to_string(),
name: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">sources_delete</a>(request: SourcesDeleteLeadsRequest) -> Result<SourcesDeleteLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a lead source; one still referenced by a lead is refused with 409 and should be deactivated with `leads/sources/update` instead.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.sources_delete(
&SourcesDeleteLeadsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">sources_list</a>(request: SourcesListLeadsRequest) -> Result<SourcesListLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists all lead sources of the company, active and inactive, ordered by name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.sources_list(
&SourcesListLeadsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">sources_options</a>(request: SourcesOptionsLeadsRequest) -> Result<SourcesOptionsLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the id and name of the active lead sources, ordered by name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.sources_options(
&SourcesOptionsLeadsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">types_create</a>(request: TypesCreateLeadsRequest) -> Result<TypesCreateLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a lead type; a `name` already used by a type of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.types_create(
&TypesCreateLeadsRequest {
name: "name".to_string(),
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">types_update</a>(request: TypesUpdateLeadsRequest) -> Result<TypesUpdateLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the name or `isActive` flag of a lead type; a name already used by another type of the company is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.types_update(
&TypesUpdateLeadsRequest {
id: "id".to_string(),
name: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">types_delete</a>(request: TypesDeleteLeadsRequest) -> Result<TypesDeleteLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a lead type; one still referenced by a lead is refused with 409 and should be deactivated with `leads/types/update` instead.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.types_delete(
&TypesDeleteLeadsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">types_list</a>(request: TypesListLeadsRequest) -> Result<TypesListLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists all lead types of the company, active and inactive, ordered by name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.types_list(
&TypesListLeadsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">types_options</a>(request: TypesOptionsLeadsRequest) -> Result<TypesOptionsLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the id and name of the active lead types, ordered by name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.types_options(
&TypesOptionsLeadsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.leads.<a href="/src/api/resources/leads/client.rs">convert</a>(request: ConvertLeadsRequest) -> Result<ConvertLeadsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a customer partner from the lead, move the lead files to the partner, copy the lead notes into the partner notes and mark the lead as converted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.leads
.convert(
&ConvertLeadsRequest {
id: "id".to_string(),
partner_type: None,
code: None,
vat_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_type:** `Option<ConvertLeadsRequestPartnerType>`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## catalog
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_create</a>(request: ItemsCreateCatalogRequest) -> Result<ItemsCreateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a catalog item: a product, a service or a set of other items. `unit` must be `vnt`, a global measurement unit or one of the company's own units (`catalog/units/options`), the sale, purchase and expense account codes must be postable accounts of the chart, and `priceFrom`/`priceTo` and `validFrom`/`validTo` must be in order; otherwise 422. A `set` needs at least one component and none of them may be a set; `components` on any other type is refused with 422. 409 when an active item already carries the `code`. `documentRef` is the storage key of a file uploaded with `files/upload`, which is attached to the item. Emits `item.created`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_create(
&ItemsCreateCatalogRequest {
name: "name".to_string(),
r#type: None,
tracking: None,
code: None,
barcode: None,
unit: None,
vat_classifier_code: None,
vat_rate_percent: None,
sale_price_excl_vat: None,
purchase_price_excl_vat: None,
cn_code: None,
origin_country: None,
net_mass_kg: None,
supplementary_unit: None,
supplementary_qty_per_unit: None,
description: None,
group_id: None,
attributes: None,
document_ref: None,
translations: None,
components: None,
kind_id: None,
sale_account_code: None,
purchase_account_code: None,
expense_account_code: None,
manufacturer: None,
gross_mass_kg: None,
min_quantity: None,
cost_price: None,
is_free_price: None,
external_id: None,
is_returnable: None,
comment_required: None,
price_from: None,
price_to: None,
min_price: None,
discount_percent: None,
max_discount_percent: None,
loyalty_points: None,
department: None,
age_restriction: None,
package_quantity: None,
tara_code: None,
certificate_number: None,
certificate_date: None,
valid_from: None,
valid_to: None,
pos_flags: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `Option<ItemsCreateCatalogRequestType>`
</dd>
</dl>
<dl>
<dd>
**tracking:** `Option<ItemsCreateCatalogRequestTracking>`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**barcode:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**unit:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_classifier_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_rate_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sale_price_excl_vat:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**purchase_price_excl_vat:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cn_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**origin_country:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**net_mass_kg:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**supplementary_unit:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**supplementary_qty_per_unit:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**group_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**attributes:** `Option<std::collections::HashMap<String, String>>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**translations:** `Option<std::collections::HashMap<String, ItemsCreateCatalogRequestTranslationsValue>>`
</dd>
</dl>
<dl>
<dd>
**components:** `Option<Vec<ItemsCreateCatalogRequestComponentsItem>>`
</dd>
</dl>
<dl>
<dd>
**kind_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sale_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**purchase_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**expense_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**manufacturer:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**gross_mass_kg:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**min_quantity:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cost_price:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_free_price:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**external_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_returnable:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**comment_required:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**price_from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**price_to:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**min_price:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**discount_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**max_discount_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**loyalty_points:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**department:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**age_restriction:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**package_quantity:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**tara_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**certificate_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**certificate_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**valid_from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**valid_to:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**pos_flags:** `Option<std::collections::HashMap<String, bool>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_get</a>(request: ItemsGetCatalogRequest) -> Result<ItemsGetCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one item; a set comes with its components.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_get(
&ItemsGetCatalogRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_update</a>(request: ItemsUpdateCatalogRequest) -> Result<ItemsUpdateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the fields of an item; the fields that are nullable in the request can be set to null to clear them. The checks of `catalog/items/create` apply. `components` replaces the whole component list and is accepted only when the item is or becomes a set (422); turning an item into a set needs components and is refused with 409 while the item is itself a component of another set. Turning a set into another type removes its components. 409 when an active item already carries the new `code`. Emits `item.updated`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_update(
&ItemsUpdateCatalogRequest {
id: "id".to_string(),
r#type: None,
tracking: None,
name: None,
code: None,
barcode: None,
unit: None,
vat_classifier_code: None,
vat_rate_percent: None,
sale_price_excl_vat: None,
purchase_price_excl_vat: None,
cn_code: None,
origin_country: None,
net_mass_kg: None,
supplementary_unit: None,
supplementary_qty_per_unit: None,
description: None,
group_id: None,
attributes: None,
document_ref: None,
translations: None,
components: None,
kind_id: None,
sale_account_code: None,
purchase_account_code: None,
expense_account_code: None,
manufacturer: None,
gross_mass_kg: None,
min_quantity: None,
cost_price: None,
is_free_price: None,
external_id: None,
is_returnable: None,
comment_required: None,
price_from: None,
price_to: None,
min_price: None,
discount_percent: None,
max_discount_percent: None,
loyalty_points: None,
department: None,
age_restriction: None,
package_quantity: None,
tara_code: None,
certificate_number: None,
certificate_date: None,
valid_from: None,
valid_to: None,
pos_flags: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<ItemsUpdateCatalogRequestType>`
</dd>
</dl>
<dl>
<dd>
**tracking:** `Option<ItemsUpdateCatalogRequestTracking>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**barcode:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**unit:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_classifier_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_rate_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**sale_price_excl_vat:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**purchase_price_excl_vat:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**cn_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**origin_country:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**net_mass_kg:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**supplementary_unit:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**supplementary_qty_per_unit:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**group_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**attributes:** `Option<Option<std::collections::HashMap<String, Option<String>>>>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**translations:** `Option<Option<std::collections::HashMap<String, Option<ItemsUpdateCatalogRequestTranslationsValue>>>>`
</dd>
</dl>
<dl>
<dd>
**components:** `Option<Vec<ItemsUpdateCatalogRequestComponentsItem>>`
</dd>
</dl>
<dl>
<dd>
**kind_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**sale_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**purchase_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**expense_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**manufacturer:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**gross_mass_kg:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**min_quantity:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**cost_price:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_free_price:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**external_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_returnable:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**comment_required:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**price_from:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**price_to:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**min_price:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**discount_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**max_discount_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**loyalty_points:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**department:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**age_restriction:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**package_quantity:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**tara_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**certificate_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**certificate_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**valid_from:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**valid_to:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**pos_flags:** `Option<Option<std::collections::HashMap<String, Option<bool>>>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_delete</a>(request: ItemsDeleteCatalogRequest) -> Result<ItemsDeleteCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Soft-delete an item. Refused with 409 while the item is a component of an active set. Emits `item.deleted`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_delete(
&ItemsDeleteCatalogRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_list</a>(request: ItemsListCatalogRequest) -> Result<ItemsListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the active items. Filterable: name, code, barcode, type, vatClassifierCode, groupId, kindId, externalId, manufacturer, department. Sortable: name, code, createdAt, updatedAt, salePriceExclVat; default name ascending. Rows carry no components; `catalog/items/get` returns them.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_list(
&ItemsListCatalogRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ItemsListCatalogRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ItemsListCatalogRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_files_list</a>(request: ItemsFilesListCatalogRequest) -> Result<ItemsFilesListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the files attached to an item, newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_files_list(
&ItemsFilesListCatalogRequest {
item_id: "itemId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**item_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_kinds_create</a>(request: ItemsKindsCreateCatalogRequest) -> Result<ItemsKindsCreateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an item kind: a code, a name, the SAF-T item type, whether quantities are accounted for, and a sort order. 409 when the code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_kinds_create(
&ItemsKindsCreateCatalogRequest {
code: "code".to_string(),
name: "name".to_string(),
saft_type: None,
quantity_accounting: None,
sort_order: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**saft_type:** `Option<ItemsKindsCreateCatalogRequestSaftType>`
</dd>
</dl>
<dl>
<dd>
**quantity_accounting:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**sort_order:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_kinds_update</a>(request: ItemsKindsUpdateCatalogRequest) -> Result<ItemsKindsUpdateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change an item kind. 409 when the new code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_kinds_update(
&ItemsKindsUpdateCatalogRequest {
id: "id".to_string(),
code: None,
name: None,
saft_type: None,
quantity_accounting: None,
sort_order: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**saft_type:** `Option<ItemsKindsUpdateCatalogRequestSaftType>`
</dd>
</dl>
<dl>
<dd>
**quantity_accounting:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**sort_order:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_kinds_delete</a>(request: ItemsKindsDeleteCatalogRequest) -> Result<ItemsKindsDeleteCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete an item kind. Refused with 409 while an active item uses it; soft-deleted items that still carry it are detached.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_kinds_delete(
&ItemsKindsDeleteCatalogRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_kinds_list</a>(request: ItemsKindsListCatalogRequest) -> Result<ItemsKindsListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's item kinds in sort order, then by code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_kinds_list(
&ItemsKindsListCatalogRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">units_create</a>(request: UnitsCreateCatalogRequest) -> Result<UnitsCreateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a unit of measure of the company's own, in addition to the global measurement units (`reference/units/list`). 409 when the code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.units_create(
&UnitsCreateCatalogRequest {
code: "code".to_string(),
name: "name".to_string(),
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">units_update</a>(request: UnitsUpdateCatalogRequest) -> Result<UnitsUpdateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the code, name or active flag of a company unit. 409 when the new code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.units_update(
&UnitsUpdateCatalogRequest {
id: "id".to_string(),
code: None,
name: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">units_delete</a>(request: UnitsDeleteCatalogRequest) -> Result<UnitsDeleteCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a company unit of measure.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.units_delete(
&UnitsDeleteCatalogRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">units_list</a>(request: UnitsListCatalogRequest) -> Result<UnitsListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's own units of measure, ordered by code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.units_list(
&UnitsListCatalogRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">units_options</a>(request: UnitsOptionsCatalogRequest) -> Result<UnitsOptionsCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the unit codes an item can use: the company's active own units first, then the global measurement units, named in the requested `locale` (Lithuanian for `lt`, English otherwise). A company unit hides a global unit with the same code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.units_options(
&UnitsOptionsCatalogRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**locale:** `Option<UnitsOptionsCatalogRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">item_groups_create</a>(request: ItemGroupsCreateCatalogRequest) -> Result<ItemGroupsCreateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an item group, optionally under `parentId`. 409 when the code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.item_groups_create(
&ItemGroupsCreateCatalogRequest {
code: "code".to_string(),
name: "name".to_string(),
parent_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**parent_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">item_groups_update</a>(request: ItemGroupsUpdateCatalogRequest) -> Result<ItemGroupsUpdateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the code, name or parent of an item group; `parentId` null moves it to the top level. 422 when the new parent is the group itself or one of its descendants. 409 when the new code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.item_groups_update(
&ItemGroupsUpdateCatalogRequest {
id: "id".to_string(),
code: None,
name: None,
parent_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**parent_id:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">item_groups_delete</a>(request: ItemGroupsDeleteCatalogRequest) -> Result<ItemGroupsDeleteCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete an item group. Refused with 409 while it has child groups or active items assigned.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.item_groups_delete(
&ItemGroupsDeleteCatalogRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">item_groups_list</a>(request: ItemGroupsListCatalogRequest) -> Result<ItemGroupsListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's item groups, ordered by code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.item_groups_list(
&ItemGroupsListCatalogRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_suppliers_upsert</a>(request: ItemsSuppliersUpsertCatalogRequest) -> Result<ItemsSuppliersUpsertCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create or replace the supplier record of an item for a partner (one per item and partner): supplier code, purchase price excluding VAT, currency (EUR when omitted) and notes. Fields omitted from the request are cleared on an existing record.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_suppliers_upsert(
&ItemsSuppliersUpsertCatalogRequest {
item_id: "itemId".to_string(),
partner_id: "partnerId".to_string(),
supplier_code: None,
purchase_price_excl_vat: None,
currency: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**item_id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**supplier_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**purchase_price_excl_vat:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_suppliers_list</a>(request: ItemsSuppliersListCatalogRequest) -> Result<ItemsSuppliersListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the supplier records, optionally for one `itemId` and/or `partnerId`, ordered by partner name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_suppliers_list(
&ItemsSuppliersListCatalogRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**item_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">items_suppliers_delete</a>(request: ItemsSuppliersDeleteCatalogRequest) -> Result<ItemsSuppliersDeleteCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete the supplier record of an item.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.items_suppliers_delete(
&ItemsSuppliersDeleteCatalogRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">price_lists_create</a>(request: PriceListsCreateCatalogRequest) -> Result<PriceListsCreateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a price list (currency EUR and active when omitted). 409 when the code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.price_lists_create(
&PriceListsCreateCatalogRequest {
code: "code".to_string(),
name: "name".to_string(),
currency: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">price_lists_update</a>(request: PriceListsUpdateCatalogRequest) -> Result<PriceListsUpdateCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a price list. 409 when the new code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.price_lists_update(
&PriceListsUpdateCatalogRequest {
id: "id".to_string(),
code: None,
name: None,
currency: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">price_lists_list</a>(request: PriceListsListCatalogRequest) -> Result<PriceListsListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's price lists, ordered by code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.price_lists_list(
&PriceListsListCatalogRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">price_lists_items_set</a>(request: PriceListsItemsSetCatalogRequest) -> Result<PriceListsItemsSetCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set the unit price excluding VAT of up to 500 items on a price list; a price already on the list is replaced and the other items on the list are kept. 422 when an item appears twice in the request. Emits `price_list.updated` with the item ids.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.price_lists_items_set(
&PriceListsItemsSetCatalogRequest {
price_list_id: "priceListId".to_string(),
items: vec![PriceListsItemsSetCatalogRequestItemsItem {
item_id: "itemId".to_string(),
unit_price_excl_vat: "121.0000".to_string(),
..Default::default()
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**price_list_id:** `String`
</dd>
</dl>
<dl>
<dd>
**items:** `Vec<PriceListsItemsSetCatalogRequestItemsItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">price_lists_items_list</a>(request: PriceListsItemsListCatalogRequest) -> Result<PriceListsItemsListCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the prices of a price list with the item name and code, ordered by item name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.price_lists_items_list(
&PriceListsItemsListCatalogRequest {
price_list_id: "priceListId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**price_list_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.catalog.<a href="/src/api/resources/catalog/client.rs">price_lists_items_delete</a>(request: PriceListsItemsDeleteCatalogRequest) -> Result<PriceListsItemsDeleteCatalogResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Remove one item from a price list.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.catalog
.price_lists_items_delete(
&PriceListsItemsDeleteCatalogRequest {
price_list_id: "priceListId".to_string(),
item_id: "itemId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**price_list_id:** `String`
</dd>
</dl>
<dl>
<dd>
**item_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## sales
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_create</a>(request: InvoicesCreateSalesRequest) -> Result<InvoicesCreateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft sale document - an invoice, credit note, proforma or advance invoice (`type`) - with its lines; the totals are computed from the lines and `discountPercent`, and the number is assigned by `sales/invoices/issue`. Answers 422 when a credit note credits a proforma, another credit note or a document that is not issued, when the credited document has another partner or currency, when an OSS or IOSS document has no EU `vatCountryCode`, when the lines carry VAT but the company is not a VAT payer or the VAT scheme charges none, or when the operation type or document series is for another document type.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_create(
&InvoicesCreateSalesRequest {
partner_id: "partnerId".to_string(),
lines: vec![InvoicesCreateSalesRequestLinesItem {
..Default::default()
}],
r#type: None,
currency: None,
issue_date: None,
due_date: None,
credited_invoice_id: None,
credited_invoice_reference: None,
credited_invoice_date: None,
agreement_id: None,
vat_scheme: None,
intrastat_transport_mode: None,
intrastat_delivery_terms: None,
intrastat_region: None,
intrastat_nature_of_transaction: None,
vat_country_code: None,
deemed_supplier: None,
notes: None,
document_ref: None,
locale: None,
operation_type_id: None,
document_series_id: None,
series_label: None,
order_number: None,
issued_by_name: None,
issued_by_title: None,
received_by_name: None,
received_by_title: None,
discount_percent: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<InvoicesCreateSalesRequestType>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issue_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**due_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**credited_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**credited_invoice_reference:** `Option<String>` — Number of an original invoice issued outside Nordlet; give it with creditedInvoiceDate
</dd>
</dl>
<dl>
<dd>
**credited_invoice_date:** `Option<String>` — Issue date of the original invoice issued outside Nordlet
</dd>
</dl>
<dl>
<dd>
**agreement_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_scheme:** `Option<InvoicesCreateSalesRequestVatScheme>`
</dd>
</dl>
<dl>
<dd>
**intrastat_transport_mode:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_delivery_terms:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_region:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_nature_of_transaction:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**deemed_supplier:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<InvoicesCreateSalesRequestLocale>` — Language of the PDF and of the e-mail the invoice is sent with; unset means the language asked for when the PDF is made
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_series_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**series_label:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**order_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issued_by_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issued_by_title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**received_by_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**received_by_title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**discount_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<InvoicesCreateSalesRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_get</a>(request: InvoicesGetSalesRequest) -> Result<InvoicesGetSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one sale document with its lines, its VAT evidence and, on an advance invoice, the gross amount already applied to final invoices.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_get(
&InvoicesGetSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_pdf</a>(request: InvoicesPdfSalesRequest) -> Result<InvoicesPdfSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Render a sale document, draft or issued, as a PDF returned base64-encoded. The document's own `locale` wins over the requested one. When the company has a payment link template and the document is issued and not paid, the PDF carries the payment link.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_pdf(
&InvoicesPdfSalesRequest {
id: "id".to_string(),
locale: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<InvoicesPdfSalesRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_send</a>(request: InvoicesSendSalesRequest) -> Result<InvoicesSendSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
E-mail an issued sale document as a PDF attachment to `to`, else to the partner's e-mail address, and emit `sale_invoice.sent`. The PDF is the one of `sales/invoices/pdf`. Answers 422 when e-mail sending is not configured, when the document is not issued, or when neither `to` nor the partner's e-mail is set.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_send(
&InvoicesSendSalesRequest {
id: "id".to_string(),
to: None,
locale: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**to:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<InvoicesSendSalesRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_peppol_xml</a>(request: InvoicesPeppolXmlSalesRequest) -> Result<InvoicesPeppolXmlSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Render an issued invoice or credit note as a Peppol BIS Billing 3.0 UBL file, returned base64-encoded with the sender and receiver participant identifiers, without sending it; `sales/invoices/peppol-send` sends the same file. Answers 422 for a draft, a proforma or an advance invoice.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_peppol_xml(
&InvoicesPeppolXMLSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_peppol_send</a>(request: InvoicesPeppolSendSalesRequest) -> Result<InvoicesPeppolSendSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Send an issued invoice or credit note to the customer over Peppol through the company's own access point (Account → Compliance → EU; Nordlet supports Recommand, Storecove and e-invoice.be). Without one the call is refused with 422 and the document can only be downloaded with `sales/invoices/peppol-xml`. `status` is `pending` until the receiving access point confirms, then `delivered`; `failed` and `rejected` come with `detail`, and the invoice can then be sent again. Later changes arrive through the access point's webhook and are announced as `sale_invoice.peppol_delivered`, `sale_invoice.peppol_rejected` and `sale_invoice.peppol_failed`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_peppol_send(
&InvoicesPeppolSendSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_peppol_status</a>(request: InvoicesPeppolStatusSalesRequest) -> Result<InvoicesPeppolStatusSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Ask the company's Peppol access point what happened to an invoice sent with `sales/invoices/peppol-send`, and store the answer: `pending`, `delivered` (the receiving access point confirmed it), `rejected` (the receiver refused it, see `detail`) or `failed` (it could not be delivered, see `detail`). The access point's webhook updates the same fields without this call. Storecove has no call for the status of a sent document, so for a Storecove access point this answers 422 and the status comes only from its webhook.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_peppol_status(
&InvoicesPeppolStatusSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_einvoice_xml</a>(request: InvoicesEinvoiceXmlSalesRequest) -> Result<InvoicesEinvoiceXmlSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Render an issued invoice as the national e-invoicing payload for the company country: FatturaPA (IT), KSeF FA(3) (PL) or UBL CIUS-RO (RO). Review the warnings - data the invoice does not carry is flagged, never invented.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_einvoice_xml(
&InvoicesEinvoiceXMLSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_einvoice_send</a>(request: InvoicesEinvoiceSendSalesRequest) -> Result<InvoicesEinvoiceSendSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the national e-invoicing payload and deliver it over the transport configured for the country gateway in compliance settings. With transport=direct the request talks to the tax authority itself - SdICoop over 2-way TLS for Italy, a KSeF session for Poland, ANAF SPV OAuth for Romania - and returns the national number as soon as the channel assigns one. With transport=bridge the payload goes to the configured bridge endpoint (an accredited intermediary or connector) instead.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_einvoice_send(
&InvoicesEinvoiceSendSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_einvoice_status</a>(request: InvoicesEinvoiceStatusSalesRequest) -> Result<InvoicesEinvoiceStatusSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Ask the national e-invoicing channel what happened to an invoice that was already sent, and store the answer. Italy, Poland and Romania return the outcome only on request - none of them calls back - so this is the way the national number and any rejection reason reach the invoice.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_einvoice_status(
&InvoicesEinvoiceStatusSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_update</a>(request: InvoicesUpdateSalesRequest) -> Result<InvoicesUpdateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a draft sale document. Fields left out keep their value, `lines` replaces every line, and a changed `discountPercent` recomputes the existing lines. Answers 409 when the document is issued or locked, and 422 under the checks of `sales/invoices/create` (the credited document's partner and currency, the OSS and IOSS country, VAT on the lines, the operation type and document series).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_update(
&InvoicesUpdateSalesRequest {
id: "id".to_string(),
partner_id: None,
agreement_id: None,
currency: None,
issue_date: None,
due_date: None,
vat_scheme: None,
intrastat_transport_mode: None,
intrastat_delivery_terms: None,
intrastat_region: None,
intrastat_nature_of_transaction: None,
vat_country_code: None,
deemed_supplier: None,
notes: None,
locale: None,
operation_type_id: None,
document_series_id: None,
series_label: None,
discount_percent: None,
order_number: None,
issued_by_name: None,
issued_by_title: None,
received_by_name: None,
received_by_title: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**agreement_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issue_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**due_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_scheme:** `Option<Option<InvoicesUpdateSalesRequestVatScheme>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_transport_mode:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_delivery_terms:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_region:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_nature_of_transaction:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_country_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**deemed_supplier:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<Option<InvoicesUpdateSalesRequestLocale>>`
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**document_series_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**series_label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**discount_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**order_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**issued_by_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**issued_by_title:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**received_by_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**received_by_title:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<InvoicesUpdateSalesRequestLinesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_delete</a>(request: InvoicesDeleteSalesRequest) -> Result<InvoicesDeleteSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a draft sale document and release the time entries billed on it. Answers 409 when the document is issued (credit it instead) or locked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_delete(
&InvoicesDeleteSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_issue</a>(request: InvoicesIssueSalesRequest) -> Result<InvoicesIssueSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Issue a draft sale document: assigns the next number (from its document series, else from `series` or the type's default prefix and the year), the issue date (`issueDate`, else the draft's, else today) and a missing due date from the partner's payment term, and for an invoice, credit note or advance invoice posts the journal entry and stores the VAT evidence. `warehouseId` (or the series' warehouse) takes the sold goods of an invoice out of stock with a cost of goods sold entry; `returnToStock` puts them back for a credit note that credits an invoice. A credit note is set against the unpaid balance of the credited document. Emits `sale_invoice.issued`, `sale_invoice.paid` when a credit note settles the credited invoice in full, and `intercompany.invoice_mirrored` when the partner is linked to another company of the group (a draft purchase invoice is created there). Answers 409 when the document is already issued or locked or the accounting period is locked, 422 when the lines carry VAT under a scheme that charges none, when credit notes would exceed the credited total, or when `returnToStock` is used on anything but a credit note of an invoice.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_issue(
&InvoicesIssueSalesRequest {
id: "id".to_string(),
series: None,
issue_date: None,
warehouse_id: None,
return_to_stock: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**series:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issue_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**return_to_stock:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_lock</a>(request: InvoicesLockSalesRequest) -> Result<InvoicesLockSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lock a sale document. A locked document is refused with 409 by `sales/invoices/update`, `sales/invoices/delete`, `sales/invoices/issue` and `sales/invoices/apply-advance` until `sales/invoices/unlock`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_lock(
&InvoicesLockSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_unlock</a>(request: InvoicesUnlockSalesRequest) -> Result<InvoicesUnlockSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Unlock a sale document locked with `sales/invoices/lock`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_unlock(
&InvoicesUnlockSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_payment_link</a>(request: InvoicesPaymentLinkSalesRequest) -> Result<InvoicesPaymentLinkSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the customer payment link of a sale document, rendered from the company's payment link template (`sales/invoices/payment-settings/update`); `url` is null when the company has no template or the document is not issued. The document's payment token is created on first use. Answers 409 when the document is already paid.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_payment_link(
&InvoicesPaymentLinkSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_payment_settings_get</a>(request: InvoicesPaymentSettingsGetSalesRequest) -> Result<InvoicesPaymentSettingsGetSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the company's payment link template, the https URL that `sales/invoices/payment-link`, the invoice PDF and the invoice e-mail fill in for an issued, unpaid document.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_payment_settings_get(
&InvoicesPaymentSettingsGetSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_payment_settings_update</a>(request: InvoicesPaymentSettingsUpdateSalesRequest) -> Result<InvoicesPaymentSettingsUpdateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set or clear (null) the company's payment link template: an https URL in which `{{number}}`, `{{amount}}` (the unpaid balance), `{{currency}}`, `{{token}}`, `{{invoiceId}}` and `{{partnerName}}` are replaced, URL-encoded, when a link is rendered.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_payment_settings_update(
&InvoicesPaymentSettingsUpdateSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**payment_link_template:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recognition_schedules_list</a>(request: RecognitionSchedulesListSalesRequest) -> Result<RecognitionSchedulesListSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the revenue recognition schedules: the tranches of deferred income of issued invoices whose lines are recognised ratably, by milestone or by percent complete, each with its status and the journal transaction that recognised it. Filterable by invoiceId, invoiceLineId, status, method and scheduleDate; sortable by scheduleDate and createdAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recognition_schedules_list(
&RecognitionSchedulesListSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<RecognitionSchedulesListSalesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<RecognitionSchedulesListSalesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_apply_advance</a>(request: InvoicesApplyAdvanceSalesRequest) -> Result<InvoicesApplyAdvanceSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Apply a fully paid advance invoice to an issued invoice of the same partner: posts the settlement journal entry dated `date` (default today), with the applied amount's share of the advance VAT, and records the amount as a payment of the invoice. `amount` defaults to the smaller of the unapplied advance and the invoice's unpaid balance. Emits `sale_invoice.paid` when the invoice becomes fully paid. Answers 409 when the advance is not fully paid, is already applied or credited, when the invoice has nothing left to pay, or when `amount` exceeds the unapplied advance or the unpaid balance; 422 when the advance is not in the company's base currency or the two documents differ in currency.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_apply_advance(
&InvoicesApplyAdvanceSalesRequest {
advance_id: "advanceId".to_string(),
invoice_id: "invoiceId".to_string(),
date: None,
amount: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**advance_id:** `String`
</dd>
</dl>
<dl>
<dd>
**invoice_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**amount:** `Option<String>` — Gross amount of the advance to apply; defaults to the unapplied advance or the unpaid balance of the invoice, whichever is smaller
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoices_list</a>(request: InvoicesListSalesRequest) -> Result<InvoicesListSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the sale documents of the company with the partner name. Filterable by partnerId, type, status, paymentStatus, fullNumber, issueDate, currency, agreementId, creditedInvoiceId, operationTypeId, documentSeriesId, lockedAt, grossTotal, netTotal, vatTotal, dueDate, orderNumber, seriesLabel, locale and recurringInvoiceId; sortable by createdAt, issueDate, fullNumber, grossTotal, netTotal, vatTotal, status and paymentStatus.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoices_list(
&InvoicesListSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<InvoicesListSalesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<InvoicesListSalesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">acts_create</a>(request: ActsCreateSalesRequest) -> Result<ActsCreateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft delivery act of goods or services (`type`) for a partner, dated `documentDate` (default today). Lines come from `lines`, else from the sale invoice in `saleInvoiceId`, else the act has none; the number is assigned by `sales/acts/issue`. Answers 422 when the sale invoice belongs to another partner or, when its lines are copied, has none.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.acts_create(
&ActsCreateSalesRequest {
partner_id: "partnerId".to_string(),
r#type: None,
document_date: None,
sale_invoice_id: None,
transferred_by_name: None,
transferred_by_title: None,
accepted_by_name: None,
accepted_by_title: None,
notes: None,
series: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<ActsCreateSalesRequestType>`
</dd>
</dl>
<dl>
<dd>
**document_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sale_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**transferred_by_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**transferred_by_title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**accepted_by_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**accepted_by_title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**series:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<ActsCreateSalesRequestLinesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">acts_update</a>(request: ActsUpdateSalesRequest) -> Result<ActsUpdateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a draft delivery act; fields left out keep their value and `lines` replaces every line. Answers 409 when the act is issued or cancelled, 422 when the linked sale invoice belongs to another partner.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.acts_update(
&ActsUpdateSalesRequest {
id: "id".to_string(),
partner_id: None,
r#type: None,
document_date: None,
sale_invoice_id: None,
transferred_by_name: None,
transferred_by_title: None,
accepted_by_name: None,
accepted_by_title: None,
notes: None,
series: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<ActsUpdateSalesRequestType>`
</dd>
</dl>
<dl>
<dd>
**document_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sale_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**transferred_by_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**transferred_by_title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**accepted_by_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**accepted_by_title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**series:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<ActsUpdateSalesRequestLinesItem>>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">acts_issue</a>(request: ActsIssueSalesRequest) -> Result<ActsIssueSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Issue a draft delivery act: assigns the next number of its series for the year of the document date. When the act is linked to a sale invoice with pending milestone recognition schedules, they are all recognised on the act's document date, which posts the recognition journal entry and emits `revenue_recognition.posted`. Answers 409 when the act is not a draft, 422 when it has no lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.acts_issue(
&ActsIssueSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">acts_cancel</a>(request: ActsCancelSalesRequest) -> Result<ActsCancelSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cancel a draft or issued delivery act. Answers 409 when it is already cancelled.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.acts_cancel(
&ActsCancelSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">acts_get</a>(request: ActsGetSalesRequest) -> Result<ActsGetSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one delivery act with its lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.acts_get(
&ActsGetSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">acts_list</a>(request: ActsListSalesRequest) -> Result<ActsListSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List delivery acts. Filterable by status, type, partnerId and documentDate; sortable by createdAt, documentDate and fullNumber.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.acts_list(
&ActsListSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ActsListSalesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ActsListSalesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">acts_pdf</a>(request: ActsPdfSalesRequest) -> Result<ActsPdfSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Render a delivery act as a PDF in `locale`, returned base64-encoded, with the number of the linked sale invoice when there is one.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.acts_pdf(
&ActsPdfSalesRequest {
id: "id".to_string(),
locale: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<ActsPdfSalesRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoice_templates_create</a>(request: InvoiceTemplatesCreateSalesRequest) -> Result<InvoiceTemplatesCreateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a named template for invoices or credit notes (`documentType`): the header defaults and the lines that `sales/recurring-invoices/generate` turns into invoices. Answers 422 when a referenced partner, agreement, operation type, document series, catalog item or project does not exist or the series is for another document type; 409 when a template with that name exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoice_templates_create(
&InvoiceTemplatesCreateSalesRequest {
name: "name".to_string(),
document_type: None,
partner_id: None,
currency: None,
payment_term_days: None,
vat_scheme: None,
vat_country_code: None,
agreement_id: None,
operation_type_id: None,
document_series_id: None,
discount_percent: None,
issued_by_name: None,
issued_by_title: None,
received_by_name: None,
received_by_title: None,
notes: None,
supply_type: None,
series_label: None,
order_number: None,
intrastat_transport_mode: None,
intrastat_delivery_terms: None,
intrastat_region: None,
intrastat_nature_of_transaction: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**document_type:** `Option<InvoiceTemplatesCreateSalesRequestDocumentType>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**payment_term_days:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_scheme:** `Option<Option<InvoiceTemplatesCreateSalesRequestVatScheme>>`
</dd>
</dl>
<dl>
<dd>
**vat_country_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**agreement_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**document_series_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**discount_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**issued_by_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**issued_by_title:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**received_by_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**received_by_title:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**supply_type:** `Option<Option<InvoiceTemplatesCreateSalesRequestSupplyType>>`
</dd>
</dl>
<dl>
<dd>
**series_label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**order_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_transport_mode:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_delivery_terms:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_region:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_nature_of_transaction:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<InvoiceTemplatesCreateSalesRequestLinesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoice_templates_update</a>(request: InvoiceTemplatesUpdateSalesRequest) -> Result<InvoiceTemplatesUpdateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a template; fields left out keep their value and `lines` replaces every line. The 422 reference checks of `sales/invoice-templates/create` apply; 409 when the new name is taken.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoice_templates_update(
&InvoiceTemplatesUpdateSalesRequest {
id: "id".to_string(),
name: None,
document_type: None,
partner_id: None,
currency: None,
payment_term_days: None,
vat_scheme: None,
vat_country_code: None,
agreement_id: None,
operation_type_id: None,
document_series_id: None,
discount_percent: None,
issued_by_name: None,
issued_by_title: None,
received_by_name: None,
received_by_title: None,
notes: None,
supply_type: None,
series_label: None,
order_number: None,
intrastat_transport_mode: None,
intrastat_delivery_terms: None,
intrastat_region: None,
intrastat_nature_of_transaction: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_type:** `Option<InvoiceTemplatesUpdateSalesRequestDocumentType>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**payment_term_days:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_scheme:** `Option<Option<InvoiceTemplatesUpdateSalesRequestVatScheme>>`
</dd>
</dl>
<dl>
<dd>
**vat_country_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**agreement_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**document_series_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**discount_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**issued_by_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**issued_by_title:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**received_by_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**received_by_title:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**supply_type:** `Option<Option<InvoiceTemplatesUpdateSalesRequestSupplyType>>`
</dd>
</dl>
<dl>
<dd>
**series_label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**order_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_transport_mode:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_delivery_terms:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_region:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_nature_of_transaction:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<InvoiceTemplatesUpdateSalesRequestLinesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoice_templates_get</a>(request: InvoiceTemplatesGetSalesRequest) -> Result<InvoiceTemplatesGetSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one invoice template.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoice_templates_get(
&InvoiceTemplatesGetSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoice_templates_delete</a>(request: InvoiceTemplatesDeleteSalesRequest) -> Result<InvoiceTemplatesDeleteSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete an invoice template.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoice_templates_delete(
&InvoiceTemplatesDeleteSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">invoice_templates_list</a>(request: InvoiceTemplatesListSalesRequest) -> Result<InvoiceTemplatesListSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List invoice templates. Filterable by name, documentType and partnerId; sortable by name, documentType and createdAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.invoice_templates_list(
&InvoiceTemplatesListSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<InvoiceTemplatesListSalesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<InvoiceTemplatesListSalesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recurring_invoices_create</a>(request: RecurringInvoicesCreateSalesRequest) -> Result<RecurringInvoicesCreateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a schedule that generates invoices from an invoice template every `interval` periods of `frequency` from `startDate` (the first run) until `endDate`, for `partnerId` or else the template's partner. `autoIssue` issues each generated invoice and `autoSend` e-mails it to `sendTo`, else to the partner. Invoices are generated by `sales/recurring-invoices/run`, `sales/recurring-invoices/generate` and the scheduled job `recurring-invoices`. Answers 422 when the template is a credit note template, when neither the schedule nor the template names a partner, when `endDate` is before `startDate`, or when `autoSend` is set without `autoIssue`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recurring_invoices_create(
&RecurringInvoicesCreateSalesRequest {
template_id: "templateId".to_string(),
start_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
partner_id: None,
frequency: None,
interval: None,
end_date: None,
locale: None,
auto_issue: None,
auto_send: None,
send_to: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**template_id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**frequency:** `Option<RecurringInvoicesCreateSalesRequestFrequency>`
</dd>
</dl>
<dl>
<dd>
**interval:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**start_date:** `String`
</dd>
</dl>
<dl>
<dd>
**end_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<Option<RecurringInvoicesCreateSalesRequestLocale>>`
</dd>
</dl>
<dl>
<dd>
**auto_issue:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**auto_send:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**send_to:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recurring_invoices_update</a>(request: RecurringInvoicesUpdateSalesRequest) -> Result<RecurringInvoicesUpdateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a schedule; fields left out keep their value. A change of `startDate`, `frequency` or `interval` moves `nextRunDate` to the first occurrence of the new grid on or after the current next run (or the new start date, if later); an explicit `nextRunDate` wins. `status` switches between `active` and `paused`; a next run past `endDate` makes the schedule `finished`. The 422 checks of `sales/recurring-invoices/create` apply.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recurring_invoices_update(
&RecurringInvoicesUpdateSalesRequest {
id: "id".to_string(),
template_id: None,
partner_id: None,
frequency: None,
interval: None,
start_date: None,
end_date: None,
next_run_date: None,
status: None,
locale: None,
auto_issue: None,
auto_send: None,
send_to: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**template_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**frequency:** `Option<RecurringInvoicesUpdateSalesRequestFrequency>`
</dd>
</dl>
<dl>
<dd>
**interval:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**start_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**end_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**next_run_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<RecurringInvoicesUpdateSalesRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<Option<RecurringInvoicesUpdateSalesRequestLocale>>`
</dd>
</dl>
<dl>
<dd>
**auto_issue:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**auto_send:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**send_to:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recurring_invoices_get</a>(request: RecurringInvoicesGetSalesRequest) -> Result<RecurringInvoicesGetSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one recurring invoice schedule with the names of its template and partner.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recurring_invoices_get(
&RecurringInvoicesGetSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recurring_invoices_delete</a>(request: RecurringInvoicesDeleteSalesRequest) -> Result<RecurringInvoicesDeleteSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a recurring invoice schedule. The invoices it generated stay.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recurring_invoices_delete(
&RecurringInvoicesDeleteSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recurring_invoices_generate</a>(request: RecurringInvoicesGenerateSalesRequest) -> Result<RecurringInvoicesGenerateSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate the next invoice of a schedule now, dated its `nextRunDate`: creates a draft from the template (due date from the template's payment term, VAT scheme from the template or else resolved for the partner and supply type), issues it when `autoIssue` is set and e-mails it when `autoSend` is set, then moves the schedule to its next occurrence (or to `finished` after the last one) and emits `recurring_invoice.generated`. A failure to issue or send comes back in `error` and is stored as `lastError`; the draft stays. Answers 409 when the schedule is finished, 422 when the template is a credit note template or has no lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recurring_invoices_generate(
&RecurringInvoicesGenerateSalesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recurring_invoices_run</a>(request: RecurringInvoicesRunSalesRequest) -> Result<RecurringInvoicesRunSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate every invoice due up to `asOfDate` (default today) from the active schedules of the company, catching up to 60 missed occurrences per schedule, as `sales/recurring-invoices/generate` does for one; each generated invoice emits `recurring_invoice.generated`. The answer lists what was generated and the schedules that failed; a failure is also stored as the schedule's `lastError`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recurring_invoices_run(
&RecurringInvoicesRunSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**as_of_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recurring_invoices_list</a>(request: RecurringInvoicesListSalesRequest) -> Result<RecurringInvoicesListSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List recurring invoice schedules with the names of their template and partner. Filterable by status, partnerId, templateId, frequency, nextRunDate and autoIssue; sortable by nextRunDate, startDate, status, frequency and createdAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recurring_invoices_list(
&RecurringInvoicesListSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<RecurringInvoicesListSalesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<RecurringInvoicesListSalesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recognition_compute</a>(request: RecognitionComputeSalesRequest) -> Result<RecognitionComputeSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Preview the pending ratable revenue schedules due on or before `asOfDate` (default the company's current date) with their total; nothing is posted. `sales/recognition/run` posts them.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recognition_compute(
&RecognitionComputeSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**as_of_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recognition_run</a>(request: RecognitionRunSalesRequest) -> Result<RecognitionRunSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Recognise deferred revenue: posts one journal entry dated `postingDate` (default `asOfDate`, default the company's current date) that debits the deferred income account and credits each line's revenue account, for the pending ratable schedules due on or before `asOfDate` or for exactly the `scheduleIds` given, marks them recognised, records a run with trigger `manual` and emits `revenue_recognition.posted`. Answers 422 when nothing is due or a given schedule is missing or no longer pending, and 409 when the posting period is locked. Due ratable schedules are also posted by the scheduler once their date has passed (trigger `schedule_due`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recognition_run(
&RecognitionRunSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**as_of_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**posting_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**schedule_ids:** `Option<Vec<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recognition_progress</a>(request: RecognitionProgressSalesRequest) -> Result<RecognitionProgressSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Report the percentage of completion of a `percent_complete` invoice line and recognise the revenue up to it: a schedule for the difference between the revenue due at that percentage and the amount already recognised is created and posted at once, dated `date` (default the company's current date), as a run with trigger `progress` that emits `revenue_recognition.posted`. Refused with 422 when the line is not `percent_complete`, the invoice is not an issued standard invoice, the percentage is 0 or above 100, or nothing new is to be recognised; 409 when the period is locked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recognition_progress(
&RecognitionProgressSalesRequest {
invoice_line_id: "invoiceLineId".to_string(),
percent_complete: "121.00".to_string(),
date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**invoice_line_id:** `String`
</dd>
</dl>
<dl>
<dd>
**percent_complete:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recognition_modify</a>(request: RecognitionModifySalesRequest) -> Result<RecognitionModifySalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Apply an IFRS 15 contract modification to a deferred invoice line. Prospective: cancel the pending schedule and respread the unrecognized remainder over the new terms. Cumulative catch-up (ratable only): recompute revenue as if the new terms applied from the start and post the difference immediately.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recognition_modify(
&RecognitionModifySalesRequest {
invoice_line_id: "invoiceLineId".to_string(),
approach: RecognitionModifySalesRequestApproach::Prospective,
date: None,
new_end_date: None,
new_milestones: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**invoice_line_id:** `String`
</dd>
</dl>
<dl>
<dd>
**approach:** `RecognitionModifySalesRequestApproach`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**new_end_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**new_milestones:** `Option<Vec<RecognitionModifySalesRequestNewMilestonesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recognition_runs_list</a>(request: RecognitionRunsListSalesRequest) -> Result<RecognitionRunsListSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the revenue recognition runs, newest first; filterable by `runDate` and `trigger`, sortable by `runDate` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recognition_runs_list(
&RecognitionRunsListSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<RecognitionRunsListSalesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<RecognitionRunsListSalesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">recognition_summary</a>(request: RecognitionSummarySalesRequest) -> Result<RecognitionSummarySalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deferred revenue per line of the issued standard invoices whose recognition method is not `point_in_time`: the deferred total, the amount recognised so far, the remainder, the number of pending schedules and the next schedule date, with totals; `invoiceId` limits it to one invoice. For a `percent_complete` line the deferred total is the line's base amount, for the other methods the sum of its schedules.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.recognition_summary(
&RecognitionSummarySalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**invoice_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">refund_liability_list</a>(request: RefundLiabilityListSalesRequest) -> Result<RefundLiabilityListSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the refund liabilities of issued invoices (created at issue from the lines' `refundEstimatePercent` or by `sales/refund-liability/true-up`): the estimate, the part consumed by credit notes, the settlement refunds and the remaining amount (estimate less consumed), with the invoice number. Filterable by invoiceId; sortable by createdAt and updatedAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.refund_liability_list(
&RefundLiabilityListSalesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<RefundLiabilityListSalesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<RefundLiabilityListSalesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.sales.<a href="/src/api/resources/sales/client.rs">refund_liability_true_up</a>(request: RefundLiabilityTrueUpSalesRequest) -> Result<RefundLiabilityTrueUpSalesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Re-estimate the refund liability of an issued standard invoice to `estimatedTotal` and post the difference on `date` (default today) between the refund liability account and the invoice's revenue accounts, in proportion to the lines' allocated or net amounts; creates the liability when the invoice has none. Emits `refund_liability.trued_up`. Answers 422 when the invoice is not an issued standard invoice, when the estimate is below the amount already consumed or unchanged, or when the invoice has no revenue to allocate against; 409 when the accounting period is locked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.sales
.refund_liability_true_up(
&RefundLiabilityTrueUpSalesRequest {
invoice_id: "invoiceId".to_string(),
estimated_total: "121.0000".to_string(),
date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**invoice_id:** `String`
</dd>
</dl>
<dl>
<dd>
**estimated_total:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## OperationTypes
<details><summary><code>client.operation_types.<a href="/src/api/resources/operation_types/client.rs">create</a>(request: CreateOperationTypesRequest) -> Result<CreateOperationTypesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an operation type: a `code` with the flags that say what it is for (`isSale`, `isPurchase`, ...), an optional `invoiceType` (`invoice`, `credit_note`, `proforma`, `advance`) and optional account codes. An invoice names it in `operationTypeId`: a sale invoice needs `isSale` and a matching `invoiceType`, a purchase invoice `isPurchase`, and the type's account codes then replace the default posting accounts when the invoice is issued (`sales/invoices/issue`) or registered (`purchases/invoices/register`). `includeInVatRegister: false` keeps the type's invoices out of the Lithuanian i.SAF and FR0600, `includeInSaft: false` out of the SAF-T file. Account codes must exist and be postable and `payerPartnerId` must be an active partner (422 otherwise); a repeated `code` is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.operation_types
.create(
&CreateOperationTypesRequest {
code: "code".to_string(),
name: "name".to_string(),
invoice_type: None,
payer_partner_id: None,
debit_account_code: None,
credit_account_code: None,
vat_account_code: None,
expense_account_code: None,
advance_account_code: None,
income_account_code: None,
is_purchase: None,
is_sale: None,
is_write_off: None,
is_internal_movement: None,
is_purchase_return: None,
is_sales_return: None,
is_consignment: None,
is_production: None,
is_asset_in: None,
is_asset_out: None,
is_cash_register_sale: None,
include_in_vat_register: None,
include_in_saft: None,
is_active: None,
sort_order: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**invoice_type:** `Option<Option<CreateOperationTypesRequestInvoiceType>>`
</dd>
</dl>
<dl>
<dd>
**payer_partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**debit_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**credit_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**expense_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**advance_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**income_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_purchase:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_sale:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_write_off:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_internal_movement:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_purchase_return:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_sales_return:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_consignment:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_production:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_asset_in:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_asset_out:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_cash_register_sale:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**include_in_vat_register:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**include_in_saft:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**sort_order:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.operation_types.<a href="/src/api/resources/operation_types/client.rs">update</a>(request: UpdateOperationTypesRequest) -> Result<UpdateOperationTypesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change an operation type's fields; omitted ones keep their value. A `code` already used by another type is refused with 409, a body without changes with 400.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.operation_types
.update(
&UpdateOperationTypesRequest {
id: "id".to_string(),
code: None,
name: None,
invoice_type: None,
payer_partner_id: None,
debit_account_code: None,
credit_account_code: None,
vat_account_code: None,
expense_account_code: None,
advance_account_code: None,
income_account_code: None,
is_purchase: None,
is_sale: None,
is_write_off: None,
is_internal_movement: None,
is_purchase_return: None,
is_sales_return: None,
is_consignment: None,
is_production: None,
is_asset_in: None,
is_asset_out: None,
is_cash_register_sale: None,
include_in_vat_register: None,
include_in_saft: None,
is_active: None,
sort_order: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**invoice_type:** `Option<Option<UpdateOperationTypesRequestInvoiceType>>`
</dd>
</dl>
<dl>
<dd>
**payer_partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**debit_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**credit_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**expense_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**advance_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**income_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_purchase:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_sale:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_write_off:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_internal_movement:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_purchase_return:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_sales_return:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_consignment:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_production:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_asset_in:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_asset_out:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_cash_register_sale:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**include_in_vat_register:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**include_in_saft:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**sort_order:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.operation_types.<a href="/src/api/resources/operation_types/client.rs">get</a>(request: GetOperationTypesRequest) -> Result<GetOperationTypesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one operation type.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.operation_types
.get(
&GetOperationTypesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.operation_types.<a href="/src/api/resources/operation_types/client.rs">delete</a>(request: DeleteOperationTypesRequest) -> Result<DeleteOperationTypesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete an operation type that no sale invoice, purchase invoice or document series refers to. Otherwise the call is refused with 409; deactivate the type with `operation-types/update` instead.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.operation_types
.delete(
&DeleteOperationTypesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.operation_types.<a href="/src/api/resources/operation_types/client.rs">list</a>(request: ListOperationTypesRequest) -> Result<ListOperationTypesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List operation types. Filterable by `code`, `name`, `isSale`, `isPurchase` and `isActive`; sortable by `code`, `name`, `sortOrder` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.operation_types
.list(
&ListOperationTypesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListOperationTypesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListOperationTypesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## DocumentSeries
<details><summary><code>client.document_series.<a href="/src/api/resources/document_series/client.rs">create</a>(request: CreateDocumentSeriesRequest) -> Result<CreateDocumentSeriesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a numbering series for sale invoices, credit notes, proformas or advance invoices (`documentType`). Numbers run from `nextNumber`, padded to `numberLength` digits, and are written as `prefix`-number or, with `printSeries` false, as the bare number; a series may be bound to an operation type (a default series of an operation type is picked for its documents that name no series) and to a warehouse, which `sales/invoices/issue` takes the goods from. `isDefault` makes it the default of its document type and clears the previous one. Answers 422 when only one end of the allocated range `allocatedFrom`..`allocatedTo` is given or the range is reversed, 409 when the prefix exists for the document type.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.document_series
.create(
&CreateDocumentSeriesRequest {
prefix: "prefix".to_string(),
document_type: None,
name: None,
label: None,
operation_type_id: None,
number_length: None,
next_number: None,
allocated_from: None,
allocated_to: None,
warehouse_id: None,
print_series: None,
is_default: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**document_type:** `Option<CreateDocumentSeriesRequestDocumentType>`
</dd>
</dl>
<dl>
<dd>
**prefix:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**number_length:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**next_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**allocated_from:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**allocated_to:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**print_series:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_default:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.document_series.<a href="/src/api/resources/document_series/client.rs">update</a>(request: UpdateDocumentSeriesRequest) -> Result<UpdateDocumentSeriesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a document series; fields left out keep their value. `nextNumber` cannot go below its current value (409); `isDefault` clears the previous default of the document type. Answers 422 for an incomplete or reversed allocated range, 409 when the prefix is taken for the document type.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.document_series
.update(
&UpdateDocumentSeriesRequest {
id: "id".to_string(),
document_type: None,
prefix: None,
name: None,
label: None,
operation_type_id: None,
number_length: None,
next_number: None,
allocated_from: None,
allocated_to: None,
warehouse_id: None,
print_series: None,
is_default: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**document_type:** `Option<UpdateDocumentSeriesRequestDocumentType>`
</dd>
</dl>
<dl>
<dd>
**prefix:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**number_length:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**next_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**allocated_from:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**allocated_to:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**print_series:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_default:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.document_series.<a href="/src/api/resources/document_series/client.rs">get</a>(request: GetDocumentSeriesRequest) -> Result<GetDocumentSeriesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one document series.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.document_series
.get(
&GetDocumentSeriesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.document_series.<a href="/src/api/resources/document_series/client.rs">delete</a>(request: DeleteDocumentSeriesRequest) -> Result<DeleteDocumentSeriesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a document series no sale document uses. Answers 409 when invoices reference it; deactivate it with `isActive` instead.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.document_series
.delete(
&DeleteDocumentSeriesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.document_series.<a href="/src/api/resources/document_series/client.rs">list</a>(request: ListDocumentSeriesRequest) -> Result<ListDocumentSeriesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List document series. Filterable by documentType, prefix, operationTypeId and isActive; sortable by prefix, documentType and createdAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.document_series
.list(
&ListDocumentSeriesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListDocumentSeriesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListDocumentSeriesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## purchases
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">invoices_create</a>(request: InvoicesCreatePurchasesRequest) -> Result<InvoicesCreatePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft purchase invoice or credit note (`type`) from a supplier document; it is posted with `purchases/invoices/register`. Lines without a unit price take the item's supplier or purchase price, `currency` defaults to the company's invoice currency, `documentRef` links an uploaded file, and the gross total leaves out self-assessed VAT. `creditedInvoiceId` (credit notes only) must be an invoice of the same partner, `purchaseOrderId` an order of the same partner that is not draft, submitted or cancelled, and `operationTypeId` an active purchase operation type, each 422 otherwise; the same `documentNumber` for the same partner is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.invoices_create(
&InvoicesCreatePurchasesRequest {
partner_id: "partnerId".to_string(),
document_number: "documentNumber".to_string(),
document_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
lines: vec![InvoicesCreatePurchasesRequestLinesItem {
..Default::default()
}],
r#type: None,
due_date: None,
currency: None,
credited_invoice_id: None,
purchase_order_id: None,
operation_type_id: None,
notes: None,
intrastat_transport_mode: None,
intrastat_delivery_terms: None,
intrastat_region: None,
intrastat_nature_of_transaction: None,
einvoice_number: None,
document_ref: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<InvoicesCreatePurchasesRequestType>`
</dd>
</dl>
<dl>
<dd>
**document_number:** `String`
</dd>
</dl>
<dl>
<dd>
**document_date:** `String`
</dd>
</dl>
<dl>
<dd>
**due_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**credited_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**purchase_order_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_transport_mode:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_delivery_terms:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_region:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_nature_of_transaction:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**einvoice_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<InvoicesCreatePurchasesRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">invoices_get</a>(request: InvoicesGetPurchasesRequest) -> Result<InvoicesGetPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one purchase invoice or credit note with its lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.invoices_get(
&InvoicesGetPurchasesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">invoices_update</a>(request: InvoicesUpdatePurchasesRequest) -> Result<InvoicesUpdatePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a draft purchase invoice (409 once registered); only the fields sent are changed, and `lines` replace all existing lines with the totals recomputed. `purchaseOrderId` and `operationTypeId` are checked as on `purchases/invoices/create` (422). A `documentNumber` already used for the partner is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.invoices_update(
&InvoicesUpdatePurchasesRequest {
id: "id".to_string(),
partner_id: None,
document_number: None,
document_date: None,
due_date: None,
currency: None,
purchase_order_id: None,
operation_type_id: None,
notes: None,
intrastat_transport_mode: None,
intrastat_delivery_terms: None,
intrastat_region: None,
intrastat_nature_of_transaction: None,
einvoice_number: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**due_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**purchase_order_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**intrastat_transport_mode:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_delivery_terms:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_region:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**intrastat_nature_of_transaction:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**einvoice_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<InvoicesUpdatePurchasesRequestLinesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">invoices_delete</a>(request: InvoicesDeletePurchasesRequest) -> Result<InvoicesDeletePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Mark a draft purchase invoice as deleted (409 once registered). A document capture linked to it goes back to `extracted` (or `pending` when it has no extraction) and can be confirmed again.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.invoices_delete(
&InvoicesDeletePurchasesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">invoices_register</a>(request: InvoicesRegisterPurchasesRequest) -> Result<InvoicesRegisterPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Register a draft purchase invoice or credit note: posts the journal entry dated `registrationDate` (default the document date) and sets the status to `registered`. The entry debits each line's expense account (the line's `accountCode`, else the item's purchase or expense account, else the operation type's expense account, else the `purchases.goodsForResale` or `purchases.defaultExpense` rule account), debits VAT receivable (a company that is not a VAT payer books the VAT into the expense instead), credits payables (the operation type's credit account when set) and credits output VAT for self-assessed VAT; a credit note posts the reverse. Lines with `deferralStartDate` and `deferralEndDate` are debited to the `purchases.prepaidExpenses` account instead and get a monthly release schedule for `purchases/deferrals/post`. With `warehouseId` the product lines of an invoice are received into stock at their base-currency cost (422 on an order-linked invoice, whose goods arrive through `purchases/receipts/create`, and for a line that is also deferred); `returnFromStock` on a credit note that credits an invoice takes the goods back out of stock at their FIFO cost and books the difference to the credited amount on the `inventory.cogs` account (422 on an invoice, without `creditedInvoiceId`, or when no goods of the credited invoice are in stock). A credit note that credits a registered invoice in the same currency is applied to it as a payment up to the open amount. Refused with 409 when already registered or the accounting period is locked, and with 422 when the credit notes would exceed the credited invoice, a posting account is missing or no exchange rate exists for the date. Emits `purchase_invoice.registered`, `purchase_invoice.paid` when the credited invoice becomes fully paid, and `stock.changed` when stock moves.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.invoices_register(
&InvoicesRegisterPurchasesRequest {
id: "id".to_string(),
registration_date: None,
warehouse_id: None,
return_from_stock: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**registration_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**return_from_stock:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">deferrals_list</a>(request: DeferralsListPurchasesRequest) -> Result<DeferralsListPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the monthly release rows that `purchases/invoices/register` creates for lines booked as prepaid expenses, each with its amount, expense and prepaid account and `status` (`pending`, `posted`, `cancelled`). Filterable by `invoiceId`, `status` and `scheduleDate`; sortable by `scheduleDate`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.deferrals_list(
&DeferralsListPurchasesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<DeferralsListPurchasesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<DeferralsListPurchasesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">deferrals_post</a>(request: DeferralsPostPurchasesRequest) -> Result<DeferralsPostPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Post every `pending` prepaid-expense release row dated on or before `asOfDate` (default today in the company's time zone): one journal entry per schedule date debiting the expense account and crediting the prepaid account, and the rows become `posted`. A locked accounting period is refused with 409. The scheduled job `expense-deferrals` runs the same release for every active company.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.deferrals_post(
&DeferralsPostPurchasesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**as_of_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">invoices_list</a>(request: InvoicesListPurchasesRequest) -> Result<InvoicesListPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List purchase invoices and credit notes without lines, with the supplier's `partnerName`. Filterable by `partnerId`, `type`, `status`, `paymentStatus`, `documentNumber`, `documentDate`, `currency`, `operationTypeId`, `purchaseOrderId`, `grossTotal`, `netTotal`, `vatTotal` and `dueDate`; sortable by `createdAt`, `documentDate`, `documentNumber`, `grossTotal` and `dueDate`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.invoices_list(
&InvoicesListPurchasesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<InvoicesListPurchasesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<InvoicesListPurchasesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_create</a>(request: OrdersCreatePurchasesRequest) -> Result<OrdersCreatePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft purchase order for a supplier. Lines without a unit price take the item's supplier or purchase price; `orderNumber` comes from the `purchase_order` series with prefix PO when not given; `currency` defaults to the company's invoice currency; `documentRef` links an uploaded file to the order. A number already in use is refused with 409. The order continues with `purchases/orders/submit`, `purchases/orders/approve` and `purchases/receipts/create`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_create(
&OrdersCreatePurchasesRequest {
partner_id: "partnerId".to_string(),
order_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
lines: vec![OrdersCreatePurchasesRequestLinesItem {
..Default::default()
}],
order_number: None,
expected_date: None,
warehouse_id: None,
currency: None,
notes: None,
document_ref: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**order_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**order_date:** `String`
</dd>
</dl>
<dl>
<dd>
**expected_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<OrdersCreatePurchasesRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_update</a>(request: OrdersUpdatePurchasesRequest) -> Result<OrdersUpdatePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a draft purchase order (409 once it is submitted); only the fields sent are changed. `lines` replace all existing lines and the totals are recomputed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_update(
&OrdersUpdatePurchasesRequest {
id: "id".to_string(),
partner_id: None,
order_date: None,
expected_date: None,
warehouse_id: None,
currency: None,
notes: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**order_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**expected_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<OrdersUpdatePurchasesRequestLinesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_get</a>(request: OrdersGetPurchasesRequest) -> Result<OrdersGetPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one purchase order with its lines; each line carries `receivedQty` and `remainingQty`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_get(
&OrdersGetPurchasesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_list</a>(request: OrdersListPurchasesRequest) -> Result<OrdersListPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List purchase orders without lines, with the supplier's `partnerName`. Filterable by `partnerId`, `status`, `orderNumber`, `orderDate`, `currency` and `grossTotal`; sortable by `createdAt`, `orderDate`, `orderNumber` and `grossTotal`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_list(
&OrdersListPurchasesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<OrdersListPurchasesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<OrdersListPurchasesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_submit</a>(request: OrdersSubmitPurchasesRequest) -> Result<OrdersSubmitPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Move a `draft` purchase order to `submitted` for approval (409 from any other status). `reason` is kept in the audit log.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_submit(
&OrdersSubmitPurchasesRequest {
id: "id".to_string(),
reason: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_approve</a>(request: OrdersApprovePurchasesRequest) -> Result<OrdersApprovePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Approve a `submitted` purchase order (409 from any other status), recording who approved it and when; needs the `purchases:approve` scope. Goods are then received with `purchases/receipts/create`. Emits `purchase_order.approved`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_approve(
&OrdersApprovePurchasesRequest {
id: "id".to_string(),
reason: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_reject</a>(request: OrdersRejectPurchasesRequest) -> Result<OrdersRejectPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Send a `submitted` purchase order back to `draft` (409 from any other status); needs the `purchases:approve` scope. `reason` is kept in the audit log.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_reject(
&OrdersRejectPurchasesRequest {
id: "id".to_string(),
reason: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_cancel</a>(request: OrdersCancelPurchasesRequest) -> Result<OrdersCancelPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cancel a `draft`, `submitted` or `approved` purchase order (409 from any other status, or when the order already has a goods receipt).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_cancel(
&OrdersCancelPurchasesRequest {
id: "id".to_string(),
reason: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_close</a>(request: OrdersClosePurchasesRequest) -> Result<OrdersClosePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Close an `approved`, `partially_received` or `received` purchase order (409 from any other status); a closed order accepts no further goods receipts.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_close(
&OrdersClosePurchasesRequest {
id: "id".to_string(),
reason: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">orders_delete</a>(request: OrdersDeletePurchasesRequest) -> Result<OrdersDeletePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Mark a `draft` purchase order as deleted (409 once it is submitted).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.orders_delete(
&OrdersDeletePurchasesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">receipts_create</a>(request: ReceiptsCreatePurchasesRequest) -> Result<ReceiptsCreatePurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a goods receipt against an `approved` or `partially_received` purchase order (409 otherwise), numbered from the `goods_receipt` series with prefix GR. Lines whose item is a product go into stock in `warehouseId`, else the order's warehouse (422 when neither is set), at their share of the order line's net amount converted at the receipt date's rate; `lotNumber` and `expiryDate` receive them into a lot, and an item that needs lot or serial tracking is refused with 422 without one. A quantity above the line's remaining quantity is refused with 409; the order becomes `received` when every line is fully received, else `partially_received`. Emits `goods_receipt.posted`, `stock.changed` and, when fully received, `purchase_order.received`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.receipts_create(
&ReceiptsCreatePurchasesRequest {
order_id: "orderId".to_string(),
receipt_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
lines: vec![ReceiptsCreatePurchasesRequestLinesItem {
order_line_id: "orderLineId".to_string(),
quantity: "121.0000".to_string(),
..Default::default()
}],
warehouse_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**order_id:** `String`
</dd>
</dl>
<dl>
<dd>
**receipt_date:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<ReceiptsCreatePurchasesRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">receipts_get</a>(request: ReceiptsGetPurchasesRequest) -> Result<ReceiptsGetPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one goods receipt with its lines and their stock movement ids.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.receipts_get(
&ReceiptsGetPurchasesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">receipts_list</a>(request: ReceiptsListPurchasesRequest) -> Result<ReceiptsListPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List goods receipts without lines. Filterable by `orderId`, `warehouseId`, `receiptDate` and `receiptNumber`; sortable by `createdAt` and `receiptDate`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.receipts_list(
&ReceiptsListPurchasesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ReceiptsListPurchasesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ReceiptsListPurchasesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.purchases.<a href="/src/api/resources/purchases/client.rs">invoices_match</a>(request: InvoicesMatchPurchasesRequest) -> Result<InvoicesMatchPurchasesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Compare a purchase invoice with its linked purchase order and the goods received so far, grouped by item (by description for lines without one). Each row is `matched`, `not_received` (invoiced but nothing received), `over_invoiced` (invoiced more than received), `price_mismatch` (unit price differs by more than `priceTolerancePercent`), `not_on_order` or `not_invoiced`; `status` is `mismatched` when any row other than `not_invoiced` is not matched. Refused with 422 when the invoice has no `purchaseOrderId` or its currency differs from the order's. Nothing is changed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.purchases
.invoices_match(
&InvoicesMatchPurchasesRequest {
invoice_id: "invoiceId".to_string(),
price_tolerance_percent: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**invoice_id:** `String`
</dd>
</dl>
<dl>
<dd>
**price_tolerance_percent:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## capture
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">settings_get</a>(request: SettingsGetCaptureRequest) -> Result<SettingsGetCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the company's document capture settings: whether intake by e-mail is enabled, whether e-mailed documents are read on arrival, the company's intake e-mail address and whether a reading provider is configured. The intake token behind the address is created on the first call.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.settings_get(
&SettingsGetCaptureRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">settings_update</a>(request: SettingsUpdateCaptureRequest) -> Result<SettingsUpdateCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Switch `intakeEnabled` (documents sent to the intake address are accepted) and `captureAutoExtract` (they are read on arrival) on or off; at least one field is required.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.settings_update(
&SettingsUpdateCaptureRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**intake_enabled:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**capture_auto_extract:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">settings_regenerate_intake</a>(request: SettingsRegenerateIntakeCaptureRequest) -> Result<SettingsRegenerateIntakeCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replace the company's intake token, so the previous intake e-mail address stops working and the settings come back with the new one.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.settings_regenerate_intake(
&SettingsRegenerateIntakeCaptureRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">inbound_email</a>(request: InboundEmailCaptureRequest) -> Result<InboundEmailCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Endpoint for the inbound e-mail provider (Postmark field names or the generic `to`, `from`, `subject` and `attachments` form). It needs the `x-inbound-secret` header and finds the company by the `intake+<token>@` recipient address (404 when unknown, 403 when intake is disabled). Every PDF, image, Word or PowerPoint attachment up to 10 MB becomes a `pending` capture (`accepted`), anything else is `skipped`; when the company has automatic reading on, is not on trial and a reading provider is configured, each capture is read at once.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.inbound_email(
&InboundEmailCaptureRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**postmark_to:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**to_full:** `Option<Vec<InboundEmailCaptureRequestToFullItem>>`
</dd>
</dl>
<dl>
<dd>
**postmark_from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**postmark_subject:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**postmark_attachments:** `Option<Vec<InboundEmailCaptureRequestAttachmentsItem>>`
</dd>
</dl>
<dl>
<dd>
**to:** `Option<InboundEmailCaptureRequestTo>`
</dd>
</dl>
<dl>
<dd>
**from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**subject:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**attachments:** `Option<Vec<InboundEmailCaptureRequestAttachmentsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">documents_upload</a>(request: DocumentsUploadCaptureRequest) -> Result<DocumentsUploadCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Upload a supplier document (PDF, image, Word or PowerPoint, up to 10 MB; 422 for any other type) as a capture and read it at once. The result holds the extracted supplier, dates, totals and lines, the partner matched by VAT code, then partner code, then name, the raw text, and `status` `extracted` or `failed` with `error`. Needs a configured reading provider, is refused with 402 for a company on trial until its first top-up, and counts every page read as `ocr_page` usage. The draft is reviewed and saved with `capture/documents/confirm`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.documents_upload(
&DocumentsUploadCaptureRequest {
file_name: "fileName".to_string(),
mime_type: "mimeType".to_string(),
content: "content".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**file_name:** `String`
</dd>
</dl>
<dl>
<dd>
**mime_type:** `String`
</dd>
</dl>
<dl>
<dd>
**content:** `String` — Base64-encoded scan, photo or PDF of the supplier document
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">documents_extract</a>(request: DocumentsExtractCaptureRequest) -> Result<DocumentsExtractCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read a stored capture again and replace its draft (supplier, totals, lines, matched partner). A capture received over Peppol is parsed from its document again without a reading provider; any other needs the provider and, for a company on trial, the first top-up (402). Refused with 409 once the capture is linked to a purchase invoice.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.documents_extract(
&DocumentsExtractCaptureRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">documents_get</a>(request: DocumentsGetCaptureRequest) -> Result<DocumentsGetCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one capture with its extraction and raw text.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.documents_get(
&DocumentsGetCaptureRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">documents_list</a>(request: DocumentsListCaptureRequest) -> Result<DocumentsListCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List captures without raw text. Filterable by `status`, `matchedPartnerId` and `purchaseInvoiceId`; sortable by `createdAt` and `updatedAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.documents_list(
&DocumentsListCaptureRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<DocumentsListCaptureRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<DocumentsListCaptureRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">documents_delete</a>(request: DocumentsDeleteCaptureRequest) -> Result<DocumentsDeleteCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a capture and its stored file (409 once it is linked to a purchase invoice).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.documents_delete(
&DocumentsDeleteCaptureRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.capture.<a href="/src/api/resources/capture/client.rs">documents_confirm</a>(request: DocumentsConfirmCaptureRequest) -> Result<DocumentsConfirmCaptureResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates the purchase invoice (or credit note, see `type`) from `lines`. Lines with the opposite sign go in `oppositeLines` and are saved as a second document of the opposite type for the same supplier: a purchase credit note against the new invoice, or a purchase invoice next to the new credit note. It is numbered `oppositeDocumentNumber`, by default the document number followed by "-CR" (credit note) or "-INV" (invoice).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.capture
.documents_confirm(
&DocumentsConfirmCaptureRequest {
id: "id".to_string(),
document_number: "documentNumber".to_string(),
document_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
lines: vec![DocumentsConfirmCaptureRequestLinesItem {
..Default::default()
}],
partner_id: None,
new_supplier: None,
r#type: None,
due_date: None,
currency: None,
notes: None,
opposite_lines: None,
opposite_document_number: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**new_supplier:** `Option<DocumentsConfirmCaptureRequestNewSupplier>`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<DocumentsConfirmCaptureRequestType>`
</dd>
</dl>
<dl>
<dd>
**document_number:** `String`
</dd>
</dl>
<dl>
<dd>
**document_date:** `String`
</dd>
</dl>
<dl>
<dd>
**due_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<DocumentsConfirmCaptureRequestLinesItem>`
</dd>
</dl>
<dl>
<dd>
**opposite_lines:** `Option<Vec<DocumentsConfirmCaptureRequestOppositeLinesItem>>`
</dd>
</dl>
<dl>
<dd>
**opposite_document_number:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## peppol
<details><summary><code>client.peppol.<a href="/src/api/resources/peppol/client.rs">participants_lookup</a>(request: ParticipantsLookupPeppolRequest) -> Result<ParticipantsLookupPeppolResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Look a receiver up on the Peppol network (SML and SMP) and say which Peppol BIS Billing 3.0 documents it accepts. Give `partnerId` to look up a partner by its Peppol ID, VAT code or registration code, or `participantId` as "<scheme>:<identifier>". Works without an access point.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.peppol
.participants_lookup(
&ParticipantsLookupPeppolRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**participant_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.peppol.<a href="/src/api/resources/peppol/client.rs">webhooks</a>(provider: WebhooksPeppolRequestProvider, company_id: String) -> Result<WebhooksPeppolResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Apply one event: a delivery status event updates the Peppol status of the sale invoice with that message id and, when the status changes, emits `sale_invoice.peppol_delivered`, `sale_invoice.peppol_rejected` or `sale_invoice.peppol_failed`; a received-document event fetches the document from the access point, stores it as a document capture with the matched supplier, emits `document_capture.peppol_received` and marks it read at the access point (a document already stored is skipped). `handled` is false when the event matched no invoice or document. Answers 404 when no company uses that provider account, 401 when the signature does not match.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.peppol
.webhooks(
&WebhooksPeppolRequestProvider::Recommand,
&"companyId".to_string(),
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**provider:** `WebhooksPeppolRequestProvider`
</dd>
</dl>
<dl>
<dd>
**company_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## declarations
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_intrastat_compute</a>(request: LtIntrastatComputeDeclarationsRequest) -> Result<LtIntrastatComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the Lithuanian Intrastat report of a month for one flow as the IDAIS INTRASTATReportSubmission XML: dispatches from the issued sale invoices and purchase credit notes, arrivals from the registered purchase invoices and sale credit notes, grouped into report items. `transactionNature`, `deliveryTerms`, `transportMode` and `regionCode` are the defaults for lines without their own values; `statisticalValueRequired` adds the statistical value to each item. Answers 422 when the company is not a VAT payer. With `persist`, the file is stored and a submission for `lt-intrastat-arrivals` or `lt-intrastat-dispatches` is created.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_intrastat_compute(
&LtIntrastatComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
flow: LtIntrastatComputeDeclarationsRequestFlow::Arrivals,
transaction_nature: None,
delivery_terms: None,
transport_mode: None,
region_code: None,
statistical_value_required: None,
preparation_time_hours: None,
preparation_time_minutes: None,
persist: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**flow:** `LtIntrastatComputeDeclarationsRequestFlow`
</dd>
</dl>
<dl>
<dd>
**transaction_nature:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**delivery_terms:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**transport_mode:** `Option<LtIntrastatComputeDeclarationsRequestTransportMode>`
</dd>
</dl>
<dl>
<dd>
**region_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**statistical_value_required:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**preparation_time_hours:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**preparation_time_minutes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**persist:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_ivaz_generate</a>(request: LtIvazGenerateDeclarationsRequest) -> Result<LtIvazGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the i.VAZ transport document message (iVAZ1.3.3) for up to 100 issued waybills and returns the XML. Answers 422 when the registration code of the company is not numeric or when a waybill is not issued. With `persist`, the file is stored and a submission for `lt-ivaz` is created.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_ivaz_generate(
&LtIvazGenerateDeclarationsRequest {
waybill_ids: vec!["waybillIds".to_string()],
persist: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**waybill_ids:** `Vec<String>`
</dd>
</dl>
<dl>
<dd>
**persist:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_intrastat_obligation</a>(request: LtIntrastatObligationDeclarationsRequest) -> Result<LtIntrastatObligationDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Checks the Intrastat reporting obligation of a year per flow: the value of goods traded with other Member States in the previous year, the month from which reporting is due (January when that value already passed the reporting threshold, else the month the cumulative value of the year passes it), whether the statistical value is required, and the monthly values. Answers 422 when no thresholds are stored for the year.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_intrastat_obligation(
&LtIntrastatObligationDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_isaf_generate</a>(request: LtIsafGenerateDeclarationsRequest) -> Result<LtIsafGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the Lithuanian i.SAF register XML of a month: `dataType` F covers both registers, S the issued sale invoices only, P the registered purchase invoices only. Returns the XML without storing it; `declarations/submissions/create` stores it as a submission.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_isaf_generate(
&LtIsafGenerateDeclarationsRequest {
year: 1000000,
month: 1000000,
data_type: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**data_type:** `Option<LtIsafGenerateDeclarationsRequestDataType>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_fr0600_compute</a>(request: LtFr0600ComputeDeclarationsRequest) -> Result<LtFr0600ComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the fields of the Lithuanian VAT return FR0600 for the period of `months` months starting in `month`, with the breakdown by VAT classifier behind them. `deductionPercent` is the share of input VAT deducted and is written to field 28.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_fr0600compute(
&LtFr0600ComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
months: None,
deduction_percent: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**months:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**deduction_percent:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_gpm313_compute</a>(request: LtGpm313ComputeDeclarationsRequest) -> Result<LtGpm313ComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes fields 5 to 7 of the monthly GPM313 from the payroll run of the month the pay was earned: the run of the previous month with `payoutTiming` `next-month`, the run of the same month with `same-month`. `paymentDay` decides whether the withheld tax goes to field 6 (paid by the 15th) or field 7 (after it). Fields 8 to 12 are returned as zero.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_gpm313compute(
&LtGpm313ComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
payout_timing: None,
payment_day: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**payout_timing:** `Option<LtGpm313ComputeDeclarationsRequestPayoutTiming>`
</dd>
</dl>
<dl>
<dd>
**payment_day:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_sam_compute</a>(request: LtSamComputeDeclarationsRequest) -> Result<LtSamComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the monthly SAM figures from the payroll run of the month: per employee the insured income, the employee and employer contributions together and the resulting tariff, plus the insured count and the totals. A missing run or a run still in draft is reported in the warnings.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_sam_compute(
&LtSamComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_sd_generate</a>(request: LtSdGenerateDeclarationsRequest) -> Result<LtSdGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the rows of the 1-SD (employment contracts that start in the date range) or of the 2-SD (contracts that ended in the range, with the final insured income and contributions from the payroll line of the termination month). Answers 422 when `fromDate` is after `toDate`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_sd_generate(
&LtSdGenerateDeclarationsRequest {
r#type: LtSdGenerateDeclarationsRequestType::OneSd,
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `LtSdGenerateDeclarationsRequestType`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_saft_generate</a>(request: LtSaftGenerateDeclarationsRequest) -> Result<LtSaftGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the Lithuanian SAF-T (version 2.01) XML for a date range: `dataType` F is the full file, GL, SI, PI, PA, MG and AS limit it to the general ledger, sale invoices, purchase invoices, payments, movements of goods or asset transactions. Answers 422 when `fromDate` is after `toDate`. With `persist`, the file is stored and a submission for `lt-saft` is created.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_saft_generate(
&LtSaftGenerateDeclarationsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
data_type: None,
persist: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**data_type:** `Option<LtSaftGenerateDeclarationsRequestDataType>`
</dd>
</dl>
<dl>
<dd>
**persist:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_ivaz_amend</a>(request: LtIvazAmendDeclarationsRequest) -> Result<LtIvazAmendDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds an i.VAZ amendment message for up to 100 issued waybills, carrying their current data as TransportDocumentAmendment elements. Answers 422 when the registration code of the company is not numeric or when a waybill is not issued. With `persist`, the file is stored and a submission for `lt-ivaz-amendment` is created.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_ivaz_amend(
&LtIvazAmendDeclarationsRequest {
waybill_ids: vec!["waybillIds".to_string()],
persist: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**waybill_ids:** `Vec<String>`
</dd>
</dl>
<dl>
<dd>
**persist:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_ivaz_cancel</a>(request: LtIvazCancelDeclarationsRequest) -> Result<LtIvazCancelDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds an i.VAZ cancellation message for up to 100 waybills, each with a cancellation reason code and optional additional information. Answers 422 when the registration code of the company is not numeric; a waybill that was never issued is reported in the warnings. With `persist`, the file is stored and a submission for `lt-ivaz-cancellation` is created.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_ivaz_cancel(
&LtIvazCancelDeclarationsRequest {
entries: vec![LtIvazCancelDeclarationsRequestEntriesItem {
waybill_id: "waybillId".to_string(),
reason: LtIvazCancelDeclarationsRequestEntriesItemReason::One,
additional_info: None,
}],
persist: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**entries:** `Vec<LtIvazCancelDeclarationsRequestEntriesItem>`
</dd>
</dl>
<dl>
<dd>
**persist:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_fr0564_compute</a>(request: LtFr0564ComputeDeclarationsRequest) -> Result<LtFr0564ComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the rows of the Lithuanian FR0564 report of a month from the issued sale invoices and credit notes with the `intra_eu_b2b` or `reverse_charge` scheme: one row per buyer VAT number of another Member State, with goods and services split by the type of the catalogue item. Invoices not in EUR and buyers without a valid EU VAT number are left out and named in the warnings; the triangular column is always zero.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_fr0564compute(
&LtFr0564ComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_gpm312_compute</a>(request: LtGpm312ComputeDeclarationsRequest) -> Result<LtGpm312ComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the rows of the annual GPM312 from the payroll runs of the payout months of the year (December of the previous year to November with `payoutTiming` `next-month`, January to December with `same-month`): one row per employee and payment type code, with the amount paid, the tax withheld and the rate applied.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_gpm312compute(
&LtGpm312ComputeDeclarationsRequest {
year: 1000000,
payout_timing: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**payout_timing:** `Option<LtGpm312ComputeDeclarationsRequestPayoutTiming>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_pln204_compute</a>(request: LtPln204ComputeDeclarationsRequest) -> Result<LtPln204ComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the boxes of the Lithuanian annual corporate income tax return PLN204 for the fiscal year from the financial statements and the tax adjustments recorded with `declarations/tax-adjustments/create`: the PLN204S annex from the `non_deductible` adjustments and the PLN204Z annex from the `non_taxable_income` ones, by their `code`. The small-entity rate is applied when the size criteria allow it. Answers 422 when such an adjustment has no code or a code the annex does not list, or when no rate table covers the period.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_pln204compute(&LtPln204ComputeDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_oss_compute</a>(request: EuOssComputeDeclarationsRequest) -> Result<EuOssComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the Union OSS return of a quarter from the issued invoices and credit notes with the `oss_union` VAT scheme: one row per Member State of consumption and VAT rate, classified as standard or reduced, and a corrections section for the credit notes that credit invoices of earlier periods. Amounts are in EUR, converted at the official rate of the last day of the period. Answers 422 when the company is not established in the EU.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_oss_compute(
&EuOssComputeDeclarationsRequest {
year: 1000000,
quarter: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**quarter:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_ioss_compute</a>(request: EuIossComputeDeclarationsRequest) -> Result<EuIossComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the IOSS return of a month from the issued invoices and credit notes with the `ioss` VAT scheme, with the same rows, corrections and EUR conversion as `declarations/eu/oss/compute`. Answers 422 when the company is not established in the EU.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_ioss_compute(
&EuIossComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_own_goods_transfers_compute</a>(request: EuOwnGoodsTransfersComputeDeclarationsRequest) -> Result<EuOwnGoodsTransfersComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the monthly return of the special scheme for transfers of own goods from the warehouse transfers between warehouses in two different EU Member States: one row per destination and dispatch country with the cost of the goods as the taxable amount in EUR, the transfers behind the rows, and the due date. Answers 422 when the company is not established in the EU.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_own_goods_transfers_compute(
&EuOwnGoodsTransfersComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_digital_reporting_list</a>(request: EuDigitalReportingListDeclarationsRequest) -> Result<EuDigitalReportingListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the transactions of a date range that fall under EU digital reporting: issued sale invoices and credit notes with the `intra_eu_b2b` or `reverse_charge` scheme to EU customers, and registered purchase invoices from suppliers in other Member States whose lines carry a self-assessed VAT classifier. Each transaction names the article it is reported under, the Member State it is reported to, its deadline and the data still missing. Answers 422 when the company is not identified for VAT in the EU.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_digital_reporting_list(
&EuDigitalReportingListDeclarationsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_dac7_preview</a>(request: EuDac7PreviewDeclarationsRequest) -> Result<EuDac7PreviewDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Which platform sellers are reportable for the year (Council Directive (EU) 2021/514, Annex V) and why the others are excluded, the data still missing, and how the company files the report in its Member State.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_dac7preview(&EuDac7PreviewDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_dac7_xml</a>(request: EuDac7XmlDeclarationsRequest) -> Result<EuDac7XmlDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the DAC7 (DPI) XML report of a year for the Member State of the company and returns it base64-encoded with the file name the administration expects. Answers 422 when no DAC7 filing channel exists for the company country. The sellers and the missing data behind it come from `declarations/eu/dac7/preview`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_dac7xml(&EuDac7XMLDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_distance_sales_threshold_get</a>(request: EuDistanceSalesThresholdGetDeclarationsRequest) -> Result<EuDistanceSalesThresholdGetDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Sums the cross-border sales to EU consumers (invoices under the `oss_union` scheme, and domestic-scheme invoices to partners without a VAT number in another Member State) of the current and the preceding calendar year as of `date` (default: the current date of the company) and compares both with the EUR 10 000 distance sales threshold.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_distance_sales_threshold_get(
&EuDistanceSalesThresholdGetDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_union_turnover_get</a>(request: EuUnionTurnoverGetDeclarationsRequest) -> Result<EuUnionTurnoverGetDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Sums the turnover of the company within the Union (issued invoices and credit notes other than export and out-of-scope supplies) for the current and the previous calendar year as of `date` (default: the current date of the company) and compares it with the EUR 100 000 cap of the cross-border SME scheme. The status is `not_applicable` for a registered VAT payer, otherwise `below`, `approaching` or `exceeded`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_union_turnover_get(
&EuUnionTurnoverGetDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_sme_cross_border_report_compute</a>(request: EuSmeCrossBorderReportComputeDeclarationsRequest) -> Result<EuSmeCrossBorderReportComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the quarterly report of the cross-border SME scheme: the value of the issued supplies within the Union per Member State of supply (the VAT country of the invoice, else the country of the partner, else the home country), in the base currency of the company. Supplies that resolve to a non-EU country are left out and named in the warnings.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_sme_cross_border_report_compute(
&EuSmeCrossBorderReportComputeDeclarationsRequest {
year: 1000000,
quarter: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**quarter:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_sme_thresholds_list</a>(request: EuSmeThresholdsListDeclarationsRequest) -> Result<EuSmeThresholdsListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns the stored table of national SME VAT exemption thresholds per Member State, with sector thresholds and intra-EU acquisition triggers where recorded, and the national and Union-wide caps of the directive. No company data is read.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_sme_thresholds_list(
&EuSmeThresholdsListDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_sme_threshold_get</a>(request: EuSmeThresholdGetDeclarationsRequest) -> Result<EuSmeThresholdGetDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Compares the gross turnover of the company in the current calendar year as of `date` (default: the current date of the company) with the national SME exemption threshold of its country. The status is `not_applicable` for a registered VAT payer, `unknown` when no threshold is on file or its currency differs from the base currency, otherwise `below`, `approaching` or `exceeded`; when the country has an intra-EU acquisitions trigger, the acquisitions from and services to other Member States are compared with it too.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_sme_threshold_get(
&EuSmeThresholdGetDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_vat_return_packs_list</a>(request: EuVatReturnPacksListDeclarationsRequest) -> Result<EuVatReturnPacksListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the national VAT return forms Nordlet can compute, with the country, form key, form name, filing frequency and source.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_vat_return_packs_list(
&EuVatReturnPacksListDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">eu_vat_return_compute</a>(request: EuVatReturnComputeDeclarationsRequest) -> Result<EuVatReturnComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Computes the national VAT return of `countryCode` for the period of `months` months starting in `month`, as the numbered boxes of the form with labels and amounts. Answers 422 when no return pack is registered for the country; the packs are listed by `declarations/eu/vat-return/packs/list`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.eu_vat_return_compute(
&EuVatReturnComputeDeclarationsRequest {
country_code: "countryCode".to_string(),
year: 1000000,
month: 1000000,
months: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country_code:** `String`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**months:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_jpk_v7m_generate</a>(request: PlJpkV7MGenerateDeclarationsRequest) -> Result<PlJpkV7MGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate the Polish JPK_V7M(3) file (VAT declaration with evidence) for a month, per the MF schema in force since February 2026. Amounts must already be in PLN; rows are marked BFK until a KSeF integration supplies invoice numbers. Review the warnings before submitting via e-dokumenty.mf.gov.pl.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_jpk_v7m_generate(
&PlJpkV7MGenerateDeclarationsRequest {
year: 1000000,
month: 1000000,
kod_urzedu: "kodUrzedu".to_string(),
email: "email".to_string(),
cel_zlozenia: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**kod_urzedu:** `String`
</dd>
</dl>
<dl>
<dd>
**email:** `String`
</dd>
</dl>
<dl>
<dd>
**cel_zlozenia:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_vat_ue_generate</a>(request: PlVatUeGenerateDeclarationsRequest) -> Result<PlVatUeGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the rows of the Polish recapitulative statement VAT-UE for a month: section C intra-Community supplies of goods, section D intra-Community acquisitions, section E services taxed where the customer is established. Amounts are full złoty per counterparty. The VAT-UE(5) file itself goes out from the EU sales list deadline in the calendar.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_vat_ue_generate(
&PlVatUeGenerateDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_intrastat_generate</a>(request: PlIntrastatGenerateDeclarationsRequest) -> Result<PlIntrastatGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the rows of the Polish INTRASTAT declaration for a month, arrivals or dispatches, grouped by CN code, partner country, country of origin, partner VAT number, nature of transaction, transport and delivery terms. Values are whole złoty converted at the invoice rate; credit notes with goods lines are returns (code 21). Goods without a CN code are left out and named in the warnings. The IST message itself goes out from the Intrastat deadline in the calendar.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_intrastat_generate(
&PlIntrastatGenerateDeclarationsRequest {
year: 1000000,
month: 1000000,
flow: PlIntrastatGenerateDeclarationsRequestFlow::Arrivals,
transaction_nature: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**flow:** `PlIntrastatGenerateDeclarationsRequestFlow`
</dd>
</dl>
<dl>
<dd>
**transaction_nature:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_ksef_received_list</a>(request: PlKsefReceivedListDeclarationsRequest) -> Result<PlKsefReceivedListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the invoices KSeF holds for this company as the buyer, for a window of acquisition timestamps. Each row carries the KSeF number and, when the document number matches a registered purchase invoice, the invoice it belongs to.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_ksef_received_list(
&PlKsefReceivedListDeclarationsRequest {
from: DateTime::parse_from_rfc3339("2024-01-15T09:30:00Z").unwrap(),
to: DateTime::parse_from_rfc3339("2024-01-15T09:30:00Z").unwrap(),
page_size: None,
page_offset: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from:** `String`
</dd>
</dl>
<dl>
<dd>
**to:** `String`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_offset:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_ksef_received_fetch</a>(request: PlKsefReceivedFetchDeclarationsRequest) -> Result<PlKsefReceivedFetchDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one invoice out of KSeF by its national number. With a purchase invoice given, the KSeF number is written onto that invoice, which is what makes the purchase row of JPK_V7M carry NrKSeF instead of the BFK marker.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_ksef_received_fetch(
&PlKsefReceivedFetchDeclarationsRequest {
ksef_number: "ksefNumber".to_string(),
purchase_invoice_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**ksef_number:** `String`
</dd>
</dl>
<dl>
<dd>
**purchase_invoice_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_ksef_receipt</a>(request: PlKsefReceiptDeclarationsRequest) -> Result<PlKsefReceiptDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
The UPO for a KSeF session. KSeF issues one receipt per session rather than per invoice, so the session reference number from the send is what identifies it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_ksef_receipt(
&PlKsefReceiptDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**session_reference_number:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_adjustments_list</a>(request: TaxAdjustmentsListDeclarationsRequest) -> Result<TaxAdjustmentsListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
The differences between the accounting result and the taxable profit: non-deductible expenses, income added to or left out of the tax base, extra deductible expenses, donations, losses carried forward, reliefs and tax credits. The annual corporate income tax return is built from them.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_adjustments_list(
&TaxAdjustmentsListDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_adjustments_create</a>(request: TaxAdjustmentsCreateDeclarationsRequest) -> Result<TaxAdjustmentsCreateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Records a tax adjustment of one kind for a tax year, with an optional form `code`. Answers 422 when the amount is zero.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_adjustments_create(
&TaxAdjustmentsCreateDeclarationsRequest {
year: 1000000,
kind: TaxAdjustmentsCreateDeclarationsRequestKind::NonDeductible,
amount: "121.00".to_string(),
description: "description".to_string(),
code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**kind:** `TaxAdjustmentsCreateDeclarationsRequestKind`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**description:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_adjustments_update</a>(request: TaxAdjustmentsUpdateDeclarationsRequest) -> Result<TaxAdjustmentsUpdateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the kind, code, amount or description of a recorded tax adjustment; fields left out keep their value and an empty `code` clears it. Answers 422 when the new amount is zero.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_adjustments_update(
&TaxAdjustmentsUpdateDeclarationsRequest {
id: "id".to_string(),
kind: None,
code: None,
amount: None,
description: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**kind:** `Option<TaxAdjustmentsUpdateDeclarationsRequestKind>`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**amount:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_adjustments_delete</a>(request: TaxAdjustmentsDeleteDeclarationsRequest) -> Result<TaxAdjustmentsDeleteDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a recorded tax adjustment.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_adjustments_delete(
&TaxAdjustmentsDeleteDeclarationsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_payments_list</a>(request: TaxPaymentsListDeclarationsRequest) -> Result<TaxPaymentsListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
What the company has paid the administration towards a tax before the return is filed: payments on account, tax withheld at source by others, a final settlement, and a refund received. Returns report these on their own lines, so the amount they ask for is the balance.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_payments_list(
&TaxPaymentsListDeclarationsRequest {
tax: TaxPaymentsListDeclarationsRequestTax::CorporateIncomeTax,
year: 1000000,
month: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**tax:** `TaxPaymentsListDeclarationsRequestTax`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_payments_create</a>(request: TaxPaymentsCreateDeclarationsRequest) -> Result<TaxPaymentsCreateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Records a payment made towards a tax (`tax`) of a year, and of a month when given, as an advance payment, tax withheld by others, a final settlement or a refund received. Answers 422 when the amount is zero.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_payments_create(
&TaxPaymentsCreateDeclarationsRequest {
tax: TaxPaymentsCreateDeclarationsRequestTax::CorporateIncomeTax,
year: 1000000,
kind: TaxPaymentsCreateDeclarationsRequestKind::Advance,
amount: "121.00".to_string(),
paid_on: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
description: "description".to_string(),
month: None,
reference: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**tax:** `TaxPaymentsCreateDeclarationsRequestTax`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**kind:** `TaxPaymentsCreateDeclarationsRequestKind`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**paid_on:** `String`
</dd>
</dl>
<dl>
<dd>
**reference:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**description:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_payments_update</a>(request: TaxPaymentsUpdateDeclarationsRequest) -> Result<TaxPaymentsUpdateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the kind, amount, payment date, reference or description of a recorded tax payment; fields left out keep their value and an empty `reference` clears it. Answers 422 when the new amount is zero.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_payments_update(
&TaxPaymentsUpdateDeclarationsRequest {
id: "id".to_string(),
kind: None,
amount: None,
paid_on: None,
reference: None,
description: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**kind:** `Option<TaxPaymentsUpdateDeclarationsRequestKind>`
</dd>
</dl>
<dl>
<dd>
**amount:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**paid_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**reference:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">tax_payments_delete</a>(request: TaxPaymentsDeleteDeclarationsRequest) -> Result<TaxPaymentsDeleteDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a recorded tax payment.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.tax_payments_delete(
&TaxPaymentsDeleteDeclarationsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_get</a>(request: AnnualAccountsGetDeclarationsRequest) -> Result<AnnualAccountsGetDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Whether the general meeting adopted the annual accounts and on which date, the date the accounts were prepared, and which directors signed them. The annual accounts filed with the trade register are built from these facts.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_get(
&AnnualAccountsGetDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_set</a>(request: AnnualAccountsSetDeclarationsRequest) -> Result<AnnualAccountsSetDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates or replaces the record of a year: whether and when the accounts were adopted, when they were prepared, whether they were audited (with the qualification flag and the auditor report date) or the auditor was not elected, the report texts and the appropriation of the result. Answers 422 when `adopted` is true without `adoptionDate`, when the adoption date is not after 31 December of the year, or when the date of preparation is after the adoption date.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_set(
&AnnualAccountsSetDeclarationsRequest {
year: 1000000,
adopted: true,
date_of_preparation: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
adoption_date: None,
audited: None,
audit_report_qualified: None,
auditor_not_elected: None,
notes_text: None,
management_report_text: None,
auditor_report_text: None,
auditor_report_date: None,
result_to_reserves: None,
result_to_loss_compensation: None,
result_to_remainder: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**adopted:** `bool`
</dd>
</dl>
<dl>
<dd>
**adoption_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_of_preparation:** `String`
</dd>
</dl>
<dl>
<dd>
**audited:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**audit_report_qualified:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**auditor_not_elected:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**notes_text:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**management_report_text:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**auditor_report_text:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**auditor_report_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**result_to_reserves:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**result_to_loss_compensation:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**result_to_remainder:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_signatures_create</a>(request: AnnualAccountsSignaturesCreateDeclarationsRequest) -> Result<AnnualAccountsSignaturesCreateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds a director to the signatures of the annual accounts of the year: signed, with the date and place of signature, or not signed, with the reason. Answers 422 when no annual accounts record exists for the year (`declarations/annual-accounts/set` first), when a signed entry lacks the date or the place, or when an unsigned entry lacks the reason.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_signatures_create(
&AnnualAccountsSignaturesCreateDeclarationsRequest {
year: 1000000,
director_name: "directorName".to_string(),
director_type:
AnnualAccountsSignaturesCreateDeclarationsRequestDirectorType::ManagingCurrent,
signed: true,
signed_on: None,
signed_at: None,
reason_not_signed: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**director_name:** `String`
</dd>
</dl>
<dl>
<dd>
**director_type:** `AnnualAccountsSignaturesCreateDeclarationsRequestDirectorType`
</dd>
</dl>
<dl>
<dd>
**signed:** `bool`
</dd>
</dl>
<dl>
<dd>
**signed_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**signed_at:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**reason_not_signed:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_signatures_update</a>(request: AnnualAccountsSignaturesUpdateDeclarationsRequest) -> Result<AnnualAccountsSignaturesUpdateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replaces the name, type and signing facts of a recorded director signature. Answers 422 when a signed entry lacks the date or the place of signature, or when an unsigned entry lacks the reason.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_signatures_update(
&AnnualAccountsSignaturesUpdateDeclarationsRequest {
id: "id".to_string(),
director_name: "directorName".to_string(),
director_type:
AnnualAccountsSignaturesUpdateDeclarationsRequestDirectorType::ManagingCurrent,
signed: true,
signed_on: None,
signed_at: None,
reason_not_signed: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**director_name:** `String`
</dd>
</dl>
<dl>
<dd>
**director_type:** `AnnualAccountsSignaturesUpdateDeclarationsRequestDirectorType`
</dd>
</dl>
<dl>
<dd>
**signed:** `bool`
</dd>
</dl>
<dl>
<dd>
**signed_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**signed_at:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**reason_not_signed:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_signatures_delete</a>(request: AnnualAccountsSignaturesDeleteDeclarationsRequest) -> Result<AnnualAccountsSignaturesDeleteDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a recorded director signature.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_signatures_delete(
&AnnualAccountsSignaturesDeleteDeclarationsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_distributions_create</a>(request: AnnualAccountsDistributionsCreateDeclarationsRequest) -> Result<AnnualAccountsDistributionsCreateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds a profit distribution decision (decision date, kind, amount, description) to the annual accounts record of the year. Answers 422 when no annual accounts record exists for the year.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_distributions_create(
&AnnualAccountsDistributionsCreateDeclarationsRequest {
year: 1000000,
decided_on: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
kind: AnnualAccountsDistributionsCreateDeclarationsRequestKind::Dividend,
amount: "121.00".to_string(),
description: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**decided_on:** `String`
</dd>
</dl>
<dl>
<dd>
**kind:** `AnnualAccountsDistributionsCreateDeclarationsRequestKind`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_distributions_update</a>(request: AnnualAccountsDistributionsUpdateDeclarationsRequest) -> Result<AnnualAccountsDistributionsUpdateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replaces the decision date, kind, amount and description of a recorded profit distribution.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_distributions_update(
&AnnualAccountsDistributionsUpdateDeclarationsRequest {
id: "id".to_string(),
decided_on: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
kind: AnnualAccountsDistributionsUpdateDeclarationsRequestKind::Dividend,
amount: "121.00".to_string(),
description: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**decided_on:** `String`
</dd>
</dl>
<dl>
<dd>
**kind:** `AnnualAccountsDistributionsUpdateDeclarationsRequestKind`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_distributions_delete</a>(request: AnnualAccountsDistributionsDeleteDeclarationsRequest) -> Result<AnnualAccountsDistributionsDeleteDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a recorded profit distribution.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_distributions_delete(
&AnnualAccountsDistributionsDeleteDeclarationsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_attachments_add</a>(request: AnnualAccountsAttachmentsAddDeclarationsRequest) -> Result<AnnualAccountsAttachmentsAddDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Links a file uploaded through files/upload (its storageKey) to the annual accounts of the year as the notes, the management report, the auditor statement, the profit appropriation resolution, the approval certificate, the general data sheet, the full report as a pdf, or another document. Deposits that must carry these documents take them from here.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_attachments_add(
&AnnualAccountsAttachmentsAddDeclarationsRequest {
year: 1000000,
kind: AnnualAccountsAttachmentsAddDeclarationsRequestKind::FullReport,
r#ref: "ref".to_string(),
name: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**kind:** `AnnualAccountsAttachmentsAddDeclarationsRequestKind`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**ref_:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">annual_accounts_attachments_delete</a>(request: AnnualAccountsAttachmentsDeleteDeclarationsRequest) -> Result<AnnualAccountsAttachmentsDeleteDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Removes the attachment from the annual accounts and deletes its file record and the stored bytes.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.annual_accounts_attachments_delete(
&AnnualAccountsAttachmentsDeleteDeclarationsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">cy_td4_generate</a>(request: CyTd4GenerateDeclarationsRequest) -> Result<CyTd4GenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Compute the company income tax return TD4 of a tax year from the ledger and the recorded tax adjustments: the accounting profit, the add-backs, deductions, capital allowances and losses brought forward, the chargeable income, the corporation tax at the rate of the year and the double tax relief, as the fields the company keys into TAXISnet or Tax For All. The Tax Department publishes no upload layout for the TD4; the XML is a working file.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.cy_td4generate(&CyTd4GenerateDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">cy_he32_generate</a>(request: CyHe32GenerateDeclarationsRequest) -> Result<CyHe32GenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the annual return HE32 of a year: the figures the Registrar’s e-filing screens ask for (company number, registered office, made-up-to date, share capital, register of members, directors and secretary, annual general meeting date, the accounts summary), the working file, and the printed form HE32(I) filled in as a PDF for signing and for keying into the Registrar’s system, which takes the return only through its own screens.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.cy_he32generate(&CyHe32GenerateDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">de_returns_generate</a>(request: DeReturnsGenerateDeclarationsRequest) -> Result<DeReturnsGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build one of the German returns that ELSTER accepts only through a licensed ERiC transmission (E-Bilanz, Körperschaftsteuer, Gewerbesteuer with its Zerlegungserklärung, annual VAT return, Lohnsteuer-Anmeldung, Lohnsteuerbescheinigung) for the company to send through its own ELSTER-capable program. The period is the year, or YYYY-MM for the monthly Lohnsteuer-Anmeldung.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.de_returns_generate(
&DeReturnsGenerateDeclarationsRequest {
rule_key: DeReturnsGenerateDeclarationsRequestRuleKey::DeEBilanz,
period: "period".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**rule_key:** `DeReturnsGenerateDeclarationsRequestRuleKey`
</dd>
</dl>
<dl>
<dd>
**period:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">de_return_facts_get</a>(request: DeReturnFactsGetDeclarationsRequest) -> Result<DeReturnFactsGetDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
The facts of one year that the German annual returns (Körperschaftsteuer, Gewerbesteuer, Umsatzsteuererklärung) need and the ledger does not hold: changes of shareholders, contracts with shareholders, the tax contribution account, loss carry-back, the donation carry-forward, the business premises with the municipalities for the apportionment of the trade tax, the land values or property tax and the participations for the trade tax additions and reductions, the foreign income per country for the Anlage AESt, the date of leaving the small-business scheme and the Anlage UN answers of a company seated abroad. A key that is absent has not been answered.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.de_return_facts_get(&DeReturnFactsGetDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">de_return_facts_set</a>(request: DeReturnFactsSetDeclarationsRequest) -> Result<DeReturnFactsSetDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replace the facts of one year for the German annual returns. The returns built afterwards read them; a key left out stays unanswered.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.de_return_facts_set(
&DeReturnFactsSetDeclarationsRequest {
year: 1000000,
facts: DeReturnFactsSetDeclarationsRequestFacts {
..Default::default()
},
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**facts:** `DeReturnFactsSetDeclarationsRequestFacts`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">de_deuev_generate</a>(request: DeDeuevGenerateDeclarationsRequest) -> Result<DeDeuevGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the DEÜV notifications of a month (Anmeldung for every start, Abmeldung for every leaving, in December the Jahresmeldung for everyone employed on 31 December) as DSME records with the DBME, DBNA, DBGB and DBAN blocks of Anlage 4 in force from 2026, from the approved payroll runs and the employee record, for the company's own transmission channel.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.de_deuev_generate(
&DeDeuevGenerateDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">de_beitragsnachweis_generate</a>(request: DeBeitragsnachweisGenerateDeclarationsRequest) -> Result<DeBeitragsnachweisGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the monthly contribution statement to the health insurers (Beitragsnachweis) from the payroll run: one fixed-length record BW02 per insurer, in the record layout in force from 2026, ready for the company's own transmission channel.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.de_beitragsnachweis_generate(
&DeBeitragsnachweisGenerateDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">dk_selskabsskat_generate</a>(request: DkSelskabsskatGenerateDeclarationsRequest) -> Result<DkSelskabsskatGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Compute the oplysningsskema for selskaber (selskabsselvangivelsen) of an income year from the ledger and the recorded tax adjustments: accounting result before tax, tax adjustments, losses carried forward, taxable income, the 22 % corporation tax, reliefs and the balance, as the rubrikker the company keys into TastSelv Selskabsskat (DIAS). Skatteforvaltningen publishes no file format for the return; the XML is a working file.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.dk_selskabsskat_generate(
&DkSelskabsskatGenerateDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">ee_employment_register_send</a>(request: EeEmploymentRegisterSendDeclarationsRequest) -> Result<EeEmploymentRegisterSendDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Send one employment register (töötamise register) entry for an employment contract to e-MTA over X-tee: the start of work, or its end with the reason recorded on the contract.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.ee_employment_register_send(
&EeEmploymentRegisterSendDeclarationsRequest {
contract_id: "contractId".to_string(),
event: EeEmploymentRegisterSendDeclarationsRequestEvent::Start,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**contract_id:** `String`
</dd>
</dl>
<dl>
<dd>
**event:** `EeEmploymentRegisterSendDeclarationsRequestEvent`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">es_verifactu_declaracion_responsable</a>(request: EsVerifactuDeclaracionResponsableDeclarationsRequest) -> Result<EsVerifactuDeclaracionResponsableDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Nordlet's declaración responsable for its VERI*FACTU invoicing system (Orden HAC/1177/2024, art. 15), as a PDF and as plain text.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.es_verifactu_declaracion_responsable(
&EsVerifactuDeclaracionResponsableDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">ie_ct1_generate</a>(request: IeCt1GenerateDeclarationsRequest) -> Result<IeCt1GenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the Form CT1 of an accounting year as the ROS version 26 XML and the accompanying financial statements as inline XBRL on the FRS 102 Irish Extension 2026 taxonomy Revenue accepts, both from the ledger, the recorded tax adjustments, the annual accounts record and the officers, for upload through the company’s own ROS account. Says whether the company is above the iXBRL deferral limits (balance sheet total €4.4 million, turnover €8.8 million, 50 employees).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.ie_ct1generate(&IeCt1GenerateDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">ie_b1_generate</a>(request: IeB1GenerateDeclarationsRequest) -> Result<IeB1GenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the working paper for the Form B1 annual return of a financial year - company details, registered office, directors and secretary from Account → Officers, the members from Account → Shareholders, the issued share capital and the figures of the financial statements - in the order the CORE screens ask for them. The CRO publishes no file format for the B1, so it is keyed into CORE.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.ie_b1generate(&IeB1GenerateDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">it_sdi_purchase_send</a>(request: ItSdiPurchaseSendDeclarationsRequest) -> Result<ItSdiPurchaseSendDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the TD16-TD19 integration document for a registered purchase invoice and send it to the Sistema di Interscambio. Since July 2022 a purchase from a supplier established abroad is reported this way instead of the esterometro. The Italian VAT rate to self-assess is a judgement about the supply: pass vatRatePercent unless the purchase lines already carry it, otherwise the request is refused rather than guessed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.it_sdi_purchase_send(
&ItSdiPurchaseSendDeclarationsRequest {
purchase_invoice_id: "purchaseInvoiceId".to_string(),
vat_rate_percent: None,
tipo_documento: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**purchase_invoice_id:** `String`
</dd>
</dl>
<dl>
<dd>
**vat_rate_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**tipo_documento:** `Option<ItSdiPurchaseSendDeclarationsRequestTipoDocumento>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">it_sdi_purchase_preview</a>(request: ItSdiPurchasePreviewDeclarationsRequest) -> Result<ItSdiPurchasePreviewDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Render the TD16-TD19 integration document for a registered purchase invoice without sending it, so the rate and the document type can be checked first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.it_sdi_purchase_preview(
&ItSdiPurchasePreviewDeclarationsRequest {
purchase_invoice_id: "purchaseInvoiceId".to_string(),
vat_rate_percent: None,
tipo_documento: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**purchase_invoice_id:** `String`
</dd>
</dl>
<dl>
<dd>
**vat_rate_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**tipo_documento:** `Option<ItSdiPurchasePreviewDeclarationsRequestTipoDocumento>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_saft_send</a>(request: LtSaftSendDeclarationsRequest) -> Result<LtSaftSendDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Upload the SAF-T file to i.SAF-T over the iSAFTUploaderService web service and start its processing. The file, the case reference and the status are kept as a declaration submission (submissionId), whose outcome Nordlet then checks with i.SAF-T. The submission itself is confirmed separately, because after confirmation the file can no longer be corrected. A range and data type already sent is sent again only with amend: true.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_saft_send(
&LtSaftSendDeclarationsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
data_type: None,
confirm: None,
amend: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**data_type:** `Option<LtSaftSendDeclarationsRequestDataType>`
</dd>
</dl>
<dl>
<dd>
**confirm:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**amend:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_sd_ffdata</a>(request: LtSdFfdataDeclarationsRequest) -> Result<LtSdFfdataDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Render the Sodra 1-SD or 2-SD notice for the contracts starting or ending in the range as an .ffdata document for EDAS.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_sd_ffdata(
&LtSdFfdataDeclarationsRequest {
r#type: LtSdFfdataDeclarationsRequestType::OneSd,
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
manager_full_name: None,
preparator_details: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `LtSdFfdataDeclarationsRequestType`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**manager_full_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**preparator_details:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">lt_pln204_ffdata</a>(request: LtPln204FfdataDeclarationsRequest) -> Result<LtPln204FfdataDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Render the annual corporate income tax return PLN204 as an .ffdata document, including the PLN204S and PLN204Z annexes, from the ledger and the tax adjustments recorded for that year.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.lt_pln204ffdata(&LtPln204FfdataDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">mt_company_tax_generate</a>(request: MtCompanyTaxGenerateDeclarationsRequest) -> Result<MtCompanyTaxGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Compute the company income tax return and self-assessment of a year of assessment from the ledger and the recorded tax adjustments: the accounting profit before tax, the add-backs and deductions, the approved donations, capital allowances and losses carried forward, the chargeable income, the 35 % charge, the relief against the tax and the allocation of the distributable profit to the five tax accounts. The Malta Tax and Customs Administration issues the return as a personalised spreadsheet to the registered tax practitioner and publishes no layout, so the XML is a working file and the figures are keyed into that spreadsheet.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.mt_company_tax_generate(
&MtCompanyTaxGenerateDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">mt_annual_return_generate</a>(request: MtAnnualReturnGenerateDeclarationsRequest) -> Result<MtAnnualReturnGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the annual return of a year: the company number, registered office and made-up-to date, the share capital, the register of members, the directors and the company secretary and the accounts summary, as the figures the Malta Business Registry asks for on its own screens, plus the printed Annual Return Form of the Seventh Schedule filled in as a PDF for signing.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.mt_annual_return_generate(
&MtAnnualReturnGenerateDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_jpk_fa_generate</a>(request: PlJpkFaGenerateDeclarationsRequest) -> Result<PlJpkFaGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate JPK_FA(4), the on-demand structure with every sales invoice issued in a period, its VAT bases per rate and one row per invoice line. Filed only when the tax office asks for it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_jpk_fa_generate(
&PlJpkFaGenerateDeclarationsRequest {
date_from: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
date_to: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date_from:** `String`
</dd>
</dl>
<dl>
<dd>
**date_to:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_jpk_kr_generate</a>(request: PlJpkKrGenerateDeclarationsRequest) -> Result<PlJpkKrGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate JPK_KR(1), the on-demand structure with the chart of accounts and its opening balances and turnover, the journal and the double entries behind it. Filed only when the tax office asks for it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_jpk_kr_generate(
&PlJpkKrGenerateDeclarationsRequest {
date_from: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
date_to: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date_from:** `String`
</dd>
</dl>
<dl>
<dd>
**date_to:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_jpk_mag_generate</a>(request: PlJpkMagGenerateDeclarationsRequest) -> Result<PlJpkMagGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate JPK_MAG(2), the on-demand structure with the warehouse documents of one warehouse: goods received from outside (PZ) or internally (PW) and issued to a customer (WZ) or internally (RW). Filed only when the tax office asks for it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_jpk_mag_generate(
&PlJpkMagGenerateDeclarationsRequest {
date_from: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
date_to: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
warehouse_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date_from:** `String`
</dd>
</dl>
<dl>
<dd>
**date_to:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_pit11_generate</a>(request: PlPit11GenerateDeclarationsRequest) -> Result<PlPit11GenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate PIT-11(29) for every person on the payroll of one year: the pay, the deductible costs, the advance withheld and the social and health contributions taken off it. One document per person, because that is how the form is filed, addressed to the tax office of the place of residence of that person (employee field plKodUrzedu); a person without that code is refused with 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_pit11generate(&PlPit11GenerateDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_cit8_generate</a>(request: PlCit8GenerateDeclarationsRequest) -> Result<PlCit8GenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate CIT-8(34), the annual corporate income tax return, from the ledger of the year and the recorded tax adjustments. The tax office code and the small-taxpayer setting come from the e-Deklaracje compliance settings, the seat address from the JPK gateway settings. Names the annexes the figures would need, which are not produced.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_cit8generate(&PlCit8GenerateDeclarationsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_zus_dra_compute</a>(request: PlZusDraComputeDeclarationsRequest) -> Result<PlZusDraComputeDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Compute the monthly ZUS DRA settlement from the payroll run of one month: the pension, disability, sickness, accident and health insurance contributions and the Labour Fund, Solidarity Fund and guaranteed benefits fund charges, each split between the insured person and the payer. The amounts are carried into Płatnik or ePłatnik by hand.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_zus_dra_compute(
&PlZusDraComputeDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_zus_dra_kedu</a>(request: PlZusDraKeduDeclarationsRequest) -> Result<PlZusDraKeduDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the KEDU file for one month: the ZUS DRA settlement and one ZUS RCA report per person on the payroll, in the schema kedu_5_4 that Płatnik and ePłatnik import. The payer REGON, short name and declaration deadline code come from the ZUS compliance settings; the insurance title code and working time of each person from the employee record.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_zus_dra_kedu(
&PlZusDraKeduDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">pl_zus_dra_pdf</a>(request: PlZusDraPdfDeclarationsRequest) -> Result<PlZusDraPdfDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Fill the published ZUS DRA form for one month and return it as a PDF. The amounts, the payer identity and the deadline code are the same ones the KEDU file carries; blocks the payroll does not hold (paid benefits, bridging pensions, income declaration of a self-paying person) stay empty.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.pl_zus_dra_pdf(
&PlZusDraPdfDeclarationsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">ro_etransport_build</a>(request: RoEtransportBuildDeclarationsRequest) -> Result<RoEtransportBuildDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the RO e-Transport declaration for an issued waybill: goods with their tariff codes and masses, the commercial partner, the route and the vehicle. The XML follows the ANAF eTransport v2 schema and is kept as a file on the waybill. Anything listed in blockers has to be filled in before /etransport/send will accept it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.ro_etransport_build(
&RoEtransportBuildDeclarationsRequest {
waybill_id: "waybillId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**waybill_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">ro_etransport_submit</a>(request: RoEtransportSubmitDeclarationsRequest) -> Result<RoEtransportSubmitDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Hand the RO e-Transport declaration for an issued waybill to ANAF under the SPV OAuth token in compliance settings, and return the upload index the UIT is read back with. Answers 422 while any field the ANAF validator requires is still missing.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.ro_etransport_submit(
&RoEtransportSubmitDeclarationsRequest {
waybill_id: "waybillId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**waybill_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">ro_etransport_status</a>(request: RoEtransportStatusDeclarationsRequest) -> Result<RoEtransportStatusDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read the outcome of an e-Transport declaration from ANAF by its upload index, under the SPV OAuth token in compliance settings. Returns the UIT code once the declaration validates.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.ro_etransport_status(
&RoEtransportStatusDeclarationsRequest {
reference: "reference".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**reference:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">li_lohndeklaration_generate</a>(request: LiLohndeklarationGenerateDeclarationsRequest) -> Result<LiLohndeklarationGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the annual wage declaration (Lohndeklaration) to the AHV-IV-FAK from the approved payroll runs of the year as the CSV that AHVeasy imports under Lohndeklaration → CSV-Import der Lohndaten: one row per employee with the 18 columns of the AHVeasy template, the AHV-liable wage and the ALV wage.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.li_lohndeklaration_generate(
&LiLohndeklarationGenerateDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">li_lohnlisten_generate</a>(request: LiLohnlistenGenerateDeclarationsRequest) -> Result<LiLohnlistenGenerateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build the annual wage list (Lohnliste) of a Liechtenstein employer from the approved payroll runs of the year as the XLSX file the tax administration's eLohnausweis / eLohnlisten application imports: one row per employee with PEID, name, birth date, address, gross wage, wage tax withheld and the settlement period.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.li_lohnlisten_generate(
&LiLohnlistenGenerateDeclarationsRequest { year: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">configs_list</a>(request: ConfigsListDeclarationsRequest) -> Result<ConfigsListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the filing systems the company can configure: those of the company country (or of `country` when given), the EU-wide systems and the cross-border e-invoicing systems `it_sdi`, `pl_ksef` and `ro_efactura`. Each row carries the stored values, with a secret or certificate field shown as `__secret_set__` and the fields taken from the company profile filled from it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.configs_list(
&ConfigsListDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country:** `Option<String>` — List the systems of this country instead of the company country
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">configs_update</a>(request: ConfigsUpdateDeclarationsRequest) -> Result<ConfigsUpdateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Stores the settings of one filing system for the company, merging the given fields into the stored ones. A secret or certificate value is encrypted before it is stored, an empty string clears a field, and `__secret_set__` leaves a stored secret unchanged. Answers 422 for an unknown system.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.configs_update(
&ConfigsUpdateDeclarationsRequest {
system: "system".to_string(),
config: HashMap::from([("key".to_string(), "value".to_string())]),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**system:** `String`
</dd>
</dl>
<dl>
<dd>
**config:** `std::collections::HashMap<String, String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">certificates_upload</a>(request: CertificatesUploadDeclarationsRequest) -> Result<CertificatesUploadDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Stores a PEM certificate, a PEM private key or a PKCS#12 bundle (base64 in `content`, opened with `passphrase` when it needs one) in the settings of the filing system and replaces the earlier upload of the same kind; for a PEM certificate the fingerprint, subject, issuer and validity dates are recorded. Answers 422 when the system is unknown or does not authenticate with a certificate. Returns the full certificate list of the company.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.certificates_upload(
&CertificatesUploadDeclarationsRequest {
system: "system".to_string(),
file_name: "fileName".to_string(),
content: "content".to_string(),
passphrase: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**system:** `String`
</dd>
</dl>
<dl>
<dd>
**file_name:** `String`
</dd>
</dl>
<dl>
<dd>
**content:** `String` — Base64-encoded PEM or PKCS#12 file
</dd>
</dl>
<dl>
<dd>
**passphrase:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">certificates_list</a>(request: CertificatesListDeclarationsRequest) -> Result<CertificatesListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the certificates and private keys stored for the filing systems of the company, ordered by system and field, each with its validity facts and health (`ok`, `expiring`, `expired` or `unknown`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.certificates_list(
&CertificatesListDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">certificates_delete</a>(request: CertificatesDeleteDeclarationsRequest) -> Result<CertificatesDeleteDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Removes the certificate or the private key (`fieldKey`) of a filing system from the settings of the company and from the certificate list, and returns the remaining certificates.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.certificates_delete(
&CertificatesDeleteDeclarationsRequest {
system: "system".to_string(),
field_key: CertificatesDeleteDeclarationsRequestFieldKey::Certificate,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**system:** `String`
</dd>
</dl>
<dl>
<dd>
**field_key:** `CertificatesDeleteDeclarationsRequestFieldKey`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">automation_list</a>(request: AutomationListDeclarationsRequest) -> Result<AutomationListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the filing deadlines Nordlet can file by itself for the country of the company: for each, whether automatic filing is switched on, whether the rule applies to the company profile, whether its filing system is configured, the state of its certificate and whether it would go to the test or the production service.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.automation_list(
&AutomationListDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">automation_update</a>(request: AutomationUpdateDeclarationsRequest) -> Result<AutomationUpdateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Switches automatic filing of one deadline on or off for the company and returns the list of `declarations/automation/list`. Answers 422 when the deadline is not one Nordlet files, or when switching on while the filing system is connected to the test service of the administration (unless the company is a sandbox), is not configured, or has no valid certificate.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.automation_update(
&AutomationUpdateDeclarationsRequest {
rule_key: "ruleKey".to_string(),
enabled: true,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**rule_key:** `String`
</dd>
</dl>
<dl>
<dd>
**enabled:** `bool`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">submissions_retry</a>(request: SubmissionsRetryDeclarationsRequest) -> Result<SubmissionsRetryDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Sends a submission that is still in status `generated` through its filing system once more, with the stored file or, when none was stored yet, a freshly generated one, and returns the updated submission. Answers 409 when the submission is already submitted, accepted or rejected.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.submissions_retry(
&SubmissionsRetryDeclarationsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">submissions_create</a>(request: SubmissionsCreateDeclarationsRequest) -> Result<SubmissionsCreateDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the Lithuanian i.SAF register file of a month (`dataType` F both registers, S sale invoices only, P purchase invoices only), stores it and creates a submission in status `generated` for the obligation `lt-isaf`, the only obligation accepted. The XML alone comes from `declarations/lt/isaf/generate`; the submission is moved on with `declarations/submissions/mark`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.submissions_create(
&SubmissionsCreateDeclarationsRequest {
obligation: SubmissionsCreateDeclarationsRequestObligation::LtIsaf,
year: 1000000,
month: 1000000,
data_type: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**obligation:** `SubmissionsCreateDeclarationsRequestObligation`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**data_type:** `Option<SubmissionsCreateDeclarationsRequestDataType>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">submissions_mark</a>(request: SubmissionsMarkDeclarationsRequest) -> Result<SubmissionsMarkDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Records by hand that a submission was sent, accepted or rejected, with the reference and message of the administration when given. The allowed moves are `generated` to `submitted` and `submitted` to `accepted` or `rejected`; any other move answers 409. A submission without a transport system is marked as sent manually.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.submissions_mark(
&SubmissionsMarkDeclarationsRequest {
id: "id".to_string(),
status: SubmissionsMarkDeclarationsRequestStatus::Submitted,
external_ref: None,
message: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**status:** `SubmissionsMarkDeclarationsRequestStatus`
</dd>
</dl>
<dl>
<dd>
**external_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**message:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.declarations.<a href="/src/api/resources/declarations/client.rs">submissions_list</a>(request: SubmissionsListDeclarationsRequest) -> Result<SubmissionsListDeclarationsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the declaration submissions of the company, newest first, filterable by `obligation`, `status`, `periodYear` and `periodMonth` and sortable by `createdAt` or `periodYear`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.declarations
.submissions_list(
&SubmissionsListDeclarationsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<SubmissionsListDeclarationsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<SubmissionsListDeclarationsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## ledger
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">accounts_list</a>(request: AccountsListLedgerRequest) -> Result<AccountsListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's chart of accounts. Filterable by `code`, `name`, `type` and `isPostable`; sortable by `code` and `name`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.accounts_list(
&AccountsListLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<AccountsListLedgerRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<AccountsListLedgerRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">accounts_create</a>(request: AccountsCreateLedgerRequest) -> Result<AccountsCreateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds an account to the company's chart of accounts. `parentId` must name an account of the same company. Answers 409 when an account with the same `code` already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.accounts_create(
&AccountsCreateLedgerRequest {
code: "code".to_string(),
name: "name".to_string(),
r#type: AccountsCreateLedgerRequestType::Asset,
parent_id: None,
is_postable: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `AccountsCreateLedgerRequestType`
</dd>
</dl>
<dl>
<dd>
**parent_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_postable:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">accounts_update</a>(request: AccountsUpdateLedgerRequest) -> Result<AccountsUpdateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the name, parent or postability of an account; the code and type cannot be changed. An account cannot be its own parent.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.accounts_update(
&AccountsUpdateLedgerRequest {
id: "id".to_string(),
name: None,
parent_id: None,
is_postable: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**parent_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_postable:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">accounts_apply_template</a>(request: AccountsApplyTemplateLedgerRequest) -> Result<AccountsApplyTemplateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds the accounts of the company's chart template that the chart does not have yet (an account whose code already exists is not replaced) and sets the parent links the template defines. Returns the number of accounts in the chart afterwards.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.accounts_apply_template(
&AccountsApplyTemplateLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">accounts_switch_chart</a>(request: AccountsSwitchChartLedgerRequest) -> Result<AccountsSwitchChartLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replaces the seeded chart with the chart template of the company country (the Romanian general chart for a company registered in Romania, the Estonian e-arveldaja chart for a company registered in Estonia, the Lithuanian standard chart otherwise) and switches the posting defaults with it. Answers 409 when the company already uses that chart, has journal entries, holds accounts created by hand, or has settings that name an account the new chart does not have.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.accounts_switch_chart(
&AccountsSwitchChartLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">periods_list</a>(request: PeriodsListLedgerRequest) -> Result<PeriodsListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's accounting periods with their `open` or `locked` status. Filterable by `year`, `month` and `status`; sortable by `year` and `month`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.periods_list(
&PeriodsListLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<PeriodsListLedgerRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<PeriodsListLedgerRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">periods_lock</a>(request: PeriodsLockLedgerRequest) -> Result<PeriodsLockLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Locks the month so that postings dated in it are refused with 409 (`ledger/journal/transactions/create`, `cash/orders/create` and `cash/expense-reports/create` among them). Before locking a month that is not locked yet, posts the pending ratable revenue recognition tranches scheduled up to the month end and emits `revenue_recognition.posted` when there were any; when the month is the company's fiscal year end and no year-end close is posted for that year, posts the year-end close that moves the income and expense balances of the fiscal year to the retained earnings account (posting rule `closing.retainedEarnings`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.periods_lock(
&PeriodsLockLedgerRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">periods_unlock</a>(request: PeriodsUnlockLedgerRequest) -> Result<PeriodsUnlockLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Opens the month for posting again. When the month is the company's fiscal year end and a year-end close is posted for it, posts a reversal of that close dated the same day.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.periods_unlock(
&PeriodsUnlockLedgerRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">journal_transactions_list</a>(request: JournalTransactionsListLedgerRequest) -> Result<JournalTransactionsListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists journal transactions with the partner name. Filterable by `date`, `status`, `documentType`, `partnerId` and `documentId`; sortable by `date` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.journal_transactions_list(
&JournalTransactionsListLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<JournalTransactionsListLedgerRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<JournalTransactionsListLedgerRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">cost_centers_create</a>(request: CostCentersCreateLedgerRequest) -> Result<CostCentersCreateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a cost center, optionally inside a cost center group. Answers 409 when the `code` is already used.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.cost_centers_create(
&CostCentersCreateLedgerRequest {
code: "code".to_string(),
name: "name".to_string(),
group_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**group_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">cost_centers_update</a>(request: CostCentersUpdateLedgerRequest) -> Result<CostCentersUpdateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the name, group or active flag of a cost center. An inactive cost center is refused on new manual journal entries (`ledger/journal/transactions/create` answers 422).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.cost_centers_update(
&CostCentersUpdateLedgerRequest {
id: "id".to_string(),
name: None,
is_active: None,
group_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**group_id:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">cost_centers_list</a>(request: CostCentersListLedgerRequest) -> Result<CostCentersListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists cost centers with their group name. Filterable by `code`, `name`, `isActive` and `groupId`; sortable by `code`, `name` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.cost_centers_list(
&CostCentersListLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<CostCentersListLedgerRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<CostCentersListLedgerRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">cost_center_groups_create</a>(request: CostCenterGroupsCreateLedgerRequest) -> Result<CostCenterGroupsCreateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a cost center group. Answers 409 when the `code` is already used.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.cost_center_groups_create(
&CostCenterGroupsCreateLedgerRequest {
code: "code".to_string(),
name: "name".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">cost_center_groups_update</a>(request: CostCenterGroupsUpdateLedgerRequest) -> Result<CostCenterGroupsUpdateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the code or name of a cost center group. Answers 409 when the new code is already used.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.cost_center_groups_update(
&CostCenterGroupsUpdateLedgerRequest {
id: "id".to_string(),
code: None,
name: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">cost_center_groups_delete</a>(request: CostCenterGroupsDeleteLedgerRequest) -> Result<CostCenterGroupsDeleteLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a cost center group. Answers 409 while cost centers are still assigned to it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.cost_center_groups_delete(
&CostCenterGroupsDeleteLedgerRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">cost_center_groups_list</a>(request: CostCenterGroupsListLedgerRequest) -> Result<CostCenterGroupsListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists cost center groups. Filterable and sortable by `code` and `name`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.cost_center_groups_list(
&CostCenterGroupsListLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<CostCenterGroupsListLedgerRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<CostCenterGroupsListLedgerRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">posting_rules_list</a>(request: PostingRulesListLedgerRequest) -> Result<PostingRulesListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists every posting rule with its default account code on the company's chart template, the account code in effect and whether the company has overridden it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.posting_rules_list(
&PostingRulesListLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">posting_rules_update</a>(request: PostingRulesUpdateLedgerRequest) -> Result<PostingRulesUpdateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Overrides the account code of one or more posting rules; an `accountCode` of null removes the override and the chart default applies again. Every code given must be a postable account of the company's chart, else 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.posting_rules_update(
&PostingRulesUpdateLedgerRequest {
rules: vec![PostingRulesUpdateLedgerRequestRulesItem {
key: PostingRulesUpdateLedgerRequestRulesItemKey::SalesReceivable,
account_code: None,
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**rules:** `Vec<PostingRulesUpdateLedgerRequestRulesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">owners_create</a>(request: OwnersCreateLedgerRequest) -> Result<OwnersCreateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds an owner of the company. `equityAccountCode` defaults to the share capital account of the company's chart; a code that is not in the chart of accounts answers 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.owners_create(
&OwnersCreateLedgerRequest {
name: "name".to_string(),
code: None,
equity_account_code: None,
shares_quantity: None,
shares_amount: None,
shares_type: None,
shares_acquisition_date: None,
withholding_tax_percent: None,
partner_liability: None,
special_balance_required: None,
supplementary_balance_required: None,
address: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**equity_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**shares_quantity:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**shares_amount:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**shares_type:** `Option<OwnersCreateLedgerRequestSharesType>`
</dd>
</dl>
<dl>
<dd>
**shares_acquisition_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**withholding_tax_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_liability:** `Option<Option<OwnersCreateLedgerRequestPartnerLiability>>`
</dd>
</dl>
<dl>
<dd>
**special_balance_required:** `Option<Option<bool>>`
</dd>
</dl>
<dl>
<dd>
**supplementary_balance_required:** `Option<Option<bool>>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<OwnersCreateLedgerRequestAddress>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">owners_update</a>(request: OwnersUpdateLedgerRequest) -> Result<OwnersUpdateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the fields of an owner. An `equityAccountCode` that is not in the chart of accounts answers 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.owners_update(
&OwnersUpdateLedgerRequest {
id: "id".to_string(),
name: None,
code: None,
equity_account_code: None,
shares_quantity: None,
shares_amount: None,
shares_type: None,
shares_acquisition_date: None,
withholding_tax_percent: None,
partner_liability: None,
special_balance_required: None,
supplementary_balance_required: None,
address: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**equity_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**shares_quantity:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**shares_amount:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**shares_type:** `Option<Option<OwnersUpdateLedgerRequestSharesType>>`
</dd>
</dl>
<dl>
<dd>
**shares_acquisition_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**withholding_tax_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**partner_liability:** `Option<Option<OwnersUpdateLedgerRequestPartnerLiability>>`
</dd>
</dl>
<dl>
<dd>
**special_balance_required:** `Option<Option<bool>>`
</dd>
</dl>
<dl>
<dd>
**supplementary_balance_required:** `Option<Option<bool>>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<Option<OwnersUpdateLedgerRequestAddress>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">owners_delete</a>(request: OwnersDeleteLedgerRequest) -> Result<OwnersDeleteLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes an owner.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.owners_delete(
&OwnersDeleteLedgerRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">owners_list</a>(request: OwnersListLedgerRequest) -> Result<OwnersListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's owners. Filterable by `name` and `code`; sortable by `name` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.owners_list(
&OwnersListLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<OwnersListLedgerRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<OwnersListLedgerRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">journal_transactions_get</a>(request: JournalTransactionsGetLedgerRequest) -> Result<JournalTransactionsGetLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns a journal transaction with its entries, ordered by account code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.journal_transactions_get(
&JournalTransactionsGetLedgerRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">journal_transactions_create</a>(request: JournalTransactionsCreateLedgerRequest) -> Result<JournalTransactionsCreateLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Posts a manual journal transaction (`documentType` `manual`, status `posted`) in the company's base currency. Every `accountCode` must be a postable account of the chart, cost centers must exist and be active, projects must exist, and the debits must equal the credits. Answers 422 for an amount with more than two decimals, for a `currency` other than the base currency and for an inactive cost center, and 409 when the accounting period of `date` is locked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.journal_transactions_create(
&JournalTransactionsCreateLedgerRequest {
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
entries: vec![JournalTransactionsCreateLedgerRequestEntriesItem {
account_code: "accountCode".to_string(),
..Default::default()
}],
description: None,
currency: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**entries:** `Vec<JournalTransactionsCreateLedgerRequestEntriesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">statement_rows_schemes</a>(request: StatementRowsSchemesLedgerRequest) -> Result<StatementRowsSchemesLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
The rows or codes of each return or registry deposit of the company country that are filled from account balances. Accounts fall into a row by the layout defaults for the standard chart of accounts unless mapped under Account → Statement rows.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.statement_rows_schemes(
&StatementRowsSchemesLedgerRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">statement_rows_list</a>(request: StatementRowsListLedgerRequest) -> Result<StatementRowsListLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Every postable account of the company with the row of `scheme` it falls into, by a mapping (`ledger/statement-rows/set`) or by the layout default, and the amount it carries there: the balance up to `toDate` on a balance-sheet row, the movement from `fromDate` to `toDate` on an income-statement row. `toDate` defaults to today and `fromDate` to 1 January of that year. `rows` holds the row totals and `unmapped` the accounts with a balance but no row.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.statement_rows_list(
&StatementRowsListLedgerRequest {
scheme: "scheme".to_string(),
from_date: None,
to_date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**scheme:** `String`
</dd>
</dl>
<dl>
<dd>
**from_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**to_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ledger.<a href="/src/api/resources/ledger/client.rs">statement_rows_set</a>(request: StatementRowsSetLedgerRequest) -> Result<StatementRowsSetLedgerResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
A mapping on a code prefix covers every account whose code starts with it; the longest matching prefix wins. An empty rowCode removes the mapping so the layout default applies again.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ledger
.statement_rows_set(
&StatementRowsSetLedgerRequest {
scheme: "scheme".to_string(),
account_code: "accountCode".to_string(),
row_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**scheme:** `String`
</dd>
</dl>
<dl>
<dd>
**account_code:** `String`
</dd>
</dl>
<dl>
<dd>
**row_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## Officers
<details><summary><code>client.officers.<a href="/src/api/resources/officers/client.rs">list</a>(request: ListOfficersRequest) -> Result<ListOfficersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Directors, board members, the company secretary, representatives and liquidators, with their personal identifier, appointment and resignation dates and whether they sign the annual accounts. Annual returns and registry deposits are built from this register.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.officers
.list(
&ListOfficersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.officers.<a href="/src/api/resources/officers/client.rs">create</a>(request: CreateOfficersRequest) -> Result<CreateOfficersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Add an officer to the company's register (`officers/list`); `signsAccounts` defaults to true. Refused with 422 when `resignedOn` is before `appointedOn`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.officers
.create(
&CreateOfficersRequest {
name: "name".to_string(),
role: CreateOfficersRequestRole::Director,
personal_code: None,
birth_date: None,
appointed_on: None,
power_notary: None,
resigned_on: None,
signs_accounts: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**role:** `CreateOfficersRequestRole`
</dd>
</dl>
<dl>
<dd>
**personal_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**appointed_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**power_notary:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**resigned_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**signs_accounts:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.officers.<a href="/src/api/resources/officers/client.rs">update</a>(request: UpdateOfficersRequest) -> Result<UpdateOfficersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replace the recorded data of an officer; every field is written as sent, so a field left out is cleared and `signsAccounts` falls back to true. Refused with 422 when `resignedOn` is before `appointedOn`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.officers
.update(
&UpdateOfficersRequest {
id: "id".to_string(),
name: "name".to_string(),
role: UpdateOfficersRequestRole::Director,
personal_code: None,
birth_date: None,
appointed_on: None,
power_notary: None,
resigned_on: None,
signs_accounts: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**role:** `UpdateOfficersRequestRole`
</dd>
</dl>
<dl>
<dd>
**personal_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**appointed_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**power_notary:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**resigned_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**signs_accounts:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.officers.<a href="/src/api/resources/officers/client.rs">delete</a>(request: DeleteOfficersRequest) -> Result<DeleteOfficersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Remove an officer from the company's register.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.officers
.delete(
&DeleteOfficersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## PlatformSellers
<details><summary><code>client.platform_sellers.<a href="/src/api/resources/platform_sellers/client.rs">list</a>(request: ListPlatformSellersRequest) -> Result<ListPlatformSellersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Individuals and entities that sell goods, rent out property or transport, or perform personal services through the platform the company operates. The yearly DAC7 report is built from them.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.platform_sellers
.list(
&ListPlatformSellersRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListPlatformSellersRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListPlatformSellersRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.platform_sellers.<a href="/src/api/resources/platform_sellers/client.rs">get</a>(request: GetPlatformSellersRequest) -> Result<GetPlatformSellersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one platform seller with its activities, ordered by year.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.platform_sellers
.get(
&GetPlatformSellersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.platform_sellers.<a href="/src/api/resources/platform_sellers/client.rs">create</a>(request: CreatePlatformSellersRequest) -> Result<CreatePlatformSellersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a seller on the company's platform for the DAC7 report: an `individual` (first and last name required) or an `entity` (`entityName` required), with its `activities` per year and quarter. An `immovable_property` activity needs `propertyAddress`; property address, type and rented days on any other kind of activity are refused. These checks answer 422; a `partnerId` that does not exist answers 404. The report is built from the sellers with `declarations/eu/dac7/preview` and `declarations/eu/dac7/xml`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.platform_sellers
.create(
&CreatePlatformSellersRequest {
kind: CreatePlatformSellersRequestKind::Individual,
address: CreatePlatformSellersRequestAddress {
country_code: "countryCode".to_string(),
..Default::default()
},
partner_id: None,
first_name: None,
middle_name: None,
last_name: None,
entity_name: None,
tax_residences: None,
vat_code: None,
business_registration_number: None,
birth_date: None,
birth_city: None,
birth_country_code: None,
iban: None,
account_holder_name: None,
government_entity: None,
listed_entity: None,
permanent_establishments: None,
activities: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**kind:** `CreatePlatformSellersRequestKind`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**first_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**middle_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**last_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**entity_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**tax_residences:** `Option<Vec<CreatePlatformSellersRequestTaxResidencesItem>>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**business_registration_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**address:** `CreatePlatformSellersRequestAddress`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**birth_city:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**birth_country_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**account_holder_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**government_entity:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**listed_entity:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**permanent_establishments:** `Option<Vec<String>>`
</dd>
</dl>
<dl>
<dd>
**activities:** `Option<Vec<CreatePlatformSellersRequestActivitiesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.platform_sellers.<a href="/src/api/resources/platform_sellers/client.rs">update</a>(request: UpdatePlatformSellersRequest) -> Result<UpdatePlatformSellersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replace a platform seller's details and all of its activities with the ones given, under the same checks as `platform-sellers/create`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.platform_sellers
.update(
&UpdatePlatformSellersRequest {
id: "id".to_string(),
kind: UpdatePlatformSellersRequestKind::Individual,
address: UpdatePlatformSellersRequestAddress {
country_code: "countryCode".to_string(),
..Default::default()
},
partner_id: None,
first_name: None,
middle_name: None,
last_name: None,
entity_name: None,
tax_residences: None,
vat_code: None,
business_registration_number: None,
birth_date: None,
birth_city: None,
birth_country_code: None,
iban: None,
account_holder_name: None,
government_entity: None,
listed_entity: None,
permanent_establishments: None,
activities: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**kind:** `UpdatePlatformSellersRequestKind`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**first_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**middle_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**last_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**entity_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**tax_residences:** `Option<Vec<UpdatePlatformSellersRequestTaxResidencesItem>>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**business_registration_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**address:** `UpdatePlatformSellersRequestAddress`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**birth_city:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**birth_country_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**account_holder_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**government_entity:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**listed_entity:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**permanent_establishments:** `Option<Vec<String>>`
</dd>
</dl>
<dl>
<dd>
**activities:** `Option<Vec<UpdatePlatformSellersRequestActivitiesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.platform_sellers.<a href="/src/api/resources/platform_sellers/client.rs">delete</a>(request: DeletePlatformSellersRequest) -> Result<DeletePlatformSellersResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Mark a platform seller as deleted. It leaves the lists and the DAC7 report.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.platform_sellers
.delete(
&DeletePlatformSellersRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## migration
<details><summary><code>client.migration.<a href="/src/api/resources/migration/client.rs">books_validate</a>(request: BooksValidateMigrationRequest) -> Result<BooksValidateMigrationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Runs every check the import runs (accounts, partners, balances, open invoices, assets, stock) and returns the same summary and warnings, then rolls everything back. Nothing is stored.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.migration
.books_validate(
&BooksValidateMigrationRequest {
cutover_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
source: None,
accounts: None,
partners: None,
items: None,
opening_balances: None,
journal: None,
open_receivables: None,
open_payables: None,
asset_groups: None,
fixed_assets: None,
stock: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**cutover_date:** `String`
</dd>
</dl>
<dl>
<dd>
**source:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**accounts:** `Option<Vec<BooksValidateMigrationRequestAccountsItem>>`
</dd>
</dl>
<dl>
<dd>
**partners:** `Option<Vec<BooksValidateMigrationRequestPartnersItem>>`
</dd>
</dl>
<dl>
<dd>
**items:** `Option<Vec<BooksValidateMigrationRequestItemsItem>>`
</dd>
</dl>
<dl>
<dd>
**opening_balances:** `Option<BooksValidateMigrationRequestOpeningBalances>`
</dd>
</dl>
<dl>
<dd>
**journal:** `Option<Vec<BooksValidateMigrationRequestJournalItem>>`
</dd>
</dl>
<dl>
<dd>
**open_receivables:** `Option<Vec<BooksValidateMigrationRequestOpenReceivablesItem>>`
</dd>
</dl>
<dl>
<dd>
**open_payables:** `Option<Vec<BooksValidateMigrationRequestOpenPayablesItem>>`
</dd>
</dl>
<dl>
<dd>
**asset_groups:** `Option<Vec<BooksValidateMigrationRequestAssetGroupsItem>>`
</dd>
</dl>
<dl>
<dd>
**fixed_assets:** `Option<Vec<BooksValidateMigrationRequestFixedAssetsItem>>`
</dd>
</dl>
<dl>
<dd>
**stock:** `Option<Vec<BooksValidateMigrationRequestStockItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.migration.<a href="/src/api/resources/migration/client.rs">books_import</a>(request: BooksImportMigrationRequest) -> Result<BooksImportMigrationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Brings a company over from another system in one call: chart of accounts, partners, items, opening balances (or the full journal history), open customer and supplier invoices, fixed assets with their accumulated depreciation, and stock on hand. The whole package is written in one database transaction - if any row fails, nothing is stored.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.migration
.books_import(
&BooksImportMigrationRequest {
cutover_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
source: None,
accounts: None,
partners: None,
items: None,
opening_balances: None,
journal: None,
open_receivables: None,
open_payables: None,
asset_groups: None,
fixed_assets: None,
stock: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**cutover_date:** `String`
</dd>
</dl>
<dl>
<dd>
**source:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**accounts:** `Option<Vec<BooksImportMigrationRequestAccountsItem>>`
</dd>
</dl>
<dl>
<dd>
**partners:** `Option<Vec<BooksImportMigrationRequestPartnersItem>>`
</dd>
</dl>
<dl>
<dd>
**items:** `Option<Vec<BooksImportMigrationRequestItemsItem>>`
</dd>
</dl>
<dl>
<dd>
**opening_balances:** `Option<BooksImportMigrationRequestOpeningBalances>`
</dd>
</dl>
<dl>
<dd>
**journal:** `Option<Vec<BooksImportMigrationRequestJournalItem>>`
</dd>
</dl>
<dl>
<dd>
**open_receivables:** `Option<Vec<BooksImportMigrationRequestOpenReceivablesItem>>`
</dd>
</dl>
<dl>
<dd>
**open_payables:** `Option<Vec<BooksImportMigrationRequestOpenPayablesItem>>`
</dd>
</dl>
<dl>
<dd>
**asset_groups:** `Option<Vec<BooksImportMigrationRequestAssetGroupsItem>>`
</dd>
</dl>
<dl>
<dd>
**fixed_assets:** `Option<Vec<BooksImportMigrationRequestFixedAssetsItem>>`
</dd>
</dl>
<dl>
<dd>
**stock:** `Option<Vec<BooksImportMigrationRequestStockItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## assets
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">settings_get</a>(request: SettingsGetAssetsRequest) -> Result<SettingsGetAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the company's fixed asset setting `autoDepreciation`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.settings_get(
&SettingsGetAssetsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">settings_update</a>(request: SettingsUpdateAssetsRequest) -> Result<SettingsUpdateAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Turn automatic depreciation on or off. When it is on, the scheduler posts the previous month's depreciation for the company once a day, as `assets/depreciation/post` does.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.settings_update(
&SettingsUpdateAssetsRequest {
auto_depreciation: true,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**auto_depreciation:** `bool`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">groups_create</a>(request: GroupsCreateAssetsRequest) -> Result<GroupsCreateAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an asset group: the asset, accumulated depreciation and depreciation expense accounts its assets are posted to, and an optional default useful life in months. `expenseAccountCode` defaults to the chart's depreciation expense account; each account must exist and be postable (422). A duplicate code is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.groups_create(
&GroupsCreateAssetsRequest {
code: "code".to_string(),
name: "name".to_string(),
asset_account_code: "assetAccountCode".to_string(),
depreciation_account_code: "depreciationAccountCode".to_string(),
default_useful_life_months: None,
expense_account_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**default_useful_life_months:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**asset_account_code:** `String`
</dd>
</dl>
<dl>
<dd>
**depreciation_account_code:** `String`
</dd>
</dl>
<dl>
<dd>
**expense_account_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">groups_list</a>(request: GroupsListAssetsRequest) -> Result<GroupsListAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the asset groups; filterable and sortable by `code` and `name`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.groups_list(
&GroupsListAssetsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<GroupsListAssetsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<GroupsListAssetsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">assets_create</a>(request: AssetsCreateAssetsRequest) -> Result<AssetsCreateAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Register a fixed asset in a group with its acquisition date and cost, salvage value, useful life in months (defaults to the group's default; 422 when neither is set) and depreciation start date (defaults to the acquisition date). The salvage value must be below the acquisition cost (422); a duplicate code is refused with 409. Depreciation is posted with `assets/depreciation/post`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.assets_create(
&AssetsCreateAssetsRequest {
group_id: "groupId".to_string(),
code: "code".to_string(),
name: "name".to_string(),
acquisition_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
acquisition_cost: "121.0000".to_string(),
depreciation_start_date: None,
salvage_value: None,
useful_life_months: None,
notes: None,
documents: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**acquisition_date:** `String`
</dd>
</dl>
<dl>
<dd>
**depreciation_start_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**acquisition_cost:** `String`
</dd>
</dl>
<dl>
<dd>
**salvage_value:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**useful_life_months:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**documents:** `Option<Vec<AssetsCreateAssetsRequestDocumentsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">assets_update</a>(request: AssetsUpdateAssetsRequest) -> Result<AssetsUpdateAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change an asset that has no posted depreciation yet: group, code, name, dates, cost, salvage value, useful life, notes or documents. Refused with 409 once depreciation is posted or the asset is disposed, and with 422 when the salvage value would reach the acquisition cost; a duplicate code is 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.assets_update(
&AssetsUpdateAssetsRequest {
id: "id".to_string(),
group_id: None,
code: None,
name: None,
acquisition_date: None,
depreciation_start_date: None,
acquisition_cost: None,
salvage_value: None,
useful_life_months: None,
notes: None,
documents: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**acquisition_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**depreciation_start_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**acquisition_cost:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**salvage_value:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**useful_life_months:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**documents:** `Option<Vec<AssetsUpdateAssetsRequestDocumentsItem>>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">assets_input_vat</a>(request: AssetsInputVatAssetsRequest) -> Result<AssetsInputVatAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record the input VAT facts of a capital good that the annual VAT return needs for the adjustment of the deduction over the adjustment period (Article 187 of the VAT Directive, § 15a UStG): the input VAT on the acquisition, the date of first use, the share of use for deductible turnover at first use, whether it is land or a building (ten-year period instead of five), and every later year in which the share changed or the good was sold or withdrawn. Allowed also after depreciation has been posted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.assets_input_vat(
&AssetsInputVatAssetsRequest {
id: "id".to_string(),
input_vat_real_estate: true,
input_vat_use_changes: vec![AssetsInputVatAssetsRequestInputVatUseChangesItem {
year: 1000000,
percent: "121.00".to_string(),
reason: AssetsInputVatAssetsRequestInputVatUseChangesItemReason::UseChange,
}],
input_vat_amount: None,
input_vat_first_use_date: None,
input_vat_deductible_percent: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**input_vat_amount:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**input_vat_first_use_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**input_vat_deductible_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**input_vat_real_estate:** `bool`
</dd>
</dl>
<dl>
<dd>
**input_vat_use_changes:** `Vec<AssetsInputVatAssetsRequestInputVatUseChangesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">assets_get</a>(request: AssetsGetAssetsRequest) -> Result<AssetsGetAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one fixed asset with its totals (cost including modernisations, accumulated depreciation, net book value, total life in months), its input VAT facts and its disposal.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.assets_get(
&AssetsGetAssetsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">assets_list</a>(request: AssetsListAssetsRequest) -> Result<AssetsListAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the fixed assets; filterable by `code`, `name`, `groupId`, `status`, `acquisitionDate`, `acquisitionCost` and `accumulatedDepreciation`, sortable by `code`, `name`, `acquisitionDate` and `acquisitionCost`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.assets_list(
&AssetsListAssetsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<AssetsListAssetsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<AssetsListAssetsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">assets_modernize</a>(request: AssetsModernizeAssetsRequest) -> Result<AssetsModernizeAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a modernisation of a fixed asset: `amount` is added to its cost and `addedLifeMonths` to its useful life from the month of `date` on, and the remaining depreciable value is spread over the months left. Refused with 422 when the asset is disposed or when no depreciation month would be left (give `addedLifeMonths` of at least 1); a fully depreciated asset becomes active again.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.assets_modernize(
&AssetsModernizeAssetsRequest {
id: "id".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
amount: "121.0000".to_string(),
added_life_months: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**added_life_months:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">assets_dispose</a>(request: AssetsDisposeAssetsRequest) -> Result<AssetsDisposeAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Dispose of a fixed asset (sold, scrapped or written off). Removes its cost and accumulated depreciation, books the net book value as a disposal loss and the proceeds as a disposal gain (posting rules assets.disposalLoss, assets.disposalGain, assets.disposalProceeds), and stops its depreciation. Depreciation must be posted for every month before the disposal month.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.assets_dispose(
&AssetsDisposeAssetsRequest {
id: "id".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
reason: AssetsDisposeAssetsRequestReason::Sold,
proceeds: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `AssetsDisposeAssetsRequestReason`
</dd>
</dl>
<dl>
<dd>
**proceeds:** `Option<String>` — Sale price excluding VAT; 0 when scrapped or written off
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">depreciation_preview</a>(request: DepreciationPreviewAssetsRequest) -> Result<DepreciationPreviewAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Preview what `assets/depreciation/post` would post for a month: per active asset the amount and the months it covers, earlier unposted months included, and whether the month is already posted. Nothing is written.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.depreciation_preview(
&DepreciationPreviewAssetsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.assets.<a href="/src/api/resources/assets/client.rs">depreciation_post</a>(request: DepreciationPostAssetsRequest) -> Result<DepreciationPostAssetsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Post the depreciation of a month: one journal entry dated the last day of the month that debits each group's expense account and credits its accumulated depreciation account, for every active asset whose depreciation has started, covering that month and any earlier month not yet posted. Each month's amount is the remaining depreciable value (cost plus modernisations less salvage value less accumulated depreciation) divided by the months left; an asset whose life or value is used up becomes `fully_depreciated`. Answers 409 when the period is locked, and `journalTransactionId` null when nothing is due.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.assets
.depreciation_post(
&DepreciationPostAssetsRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## hr
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">positions_create</a>(request: PositionsCreateHrRequest) -> Result<PositionsCreateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a job position with an optional code and name translations, for use in `hr/contracts/create`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.positions_create(
&PositionsCreateHrRequest {
name: "name".to_string(),
code: None,
translations: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**translations:** `Option<std::collections::HashMap<String, PositionsCreateHrRequestTranslationsValue>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">positions_update</a>(request: PositionsUpdateHrRequest) -> Result<PositionsUpdateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the code, name or translations of a position; a null `translations` removes them.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.positions_update(
&PositionsUpdateHrRequest {
id: "id".to_string(),
code: None,
name: None,
translations: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**translations:** `Option<Option<std::collections::HashMap<String, Option<PositionsUpdateHrRequestTranslationsValue>>>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">positions_list</a>(request: PositionsListHrRequest) -> Result<PositionsListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's positions; filterable and sortable by `name` and `code`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.positions_list(
&PositionsListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<PositionsListHrRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<PositionsListHrRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_create</a>(request: EmployeesCreateHrRequest) -> Result<EmployeesCreateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates an employee record. `payrollOptions` holds the country-specific settings the payroll engine reads for the person (see `hr/employees/fields`); `applyAllowance` defaults to true and `pensionAccumulation` to false.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_create(
&EmployeesCreateHrRequest {
first_name: "firstName".to_string(),
last_name: "lastName".to_string(),
code: None,
personal_code: None,
birth_date: None,
email: None,
phone: None,
address: None,
iban: None,
social_insurance_no: None,
social_insurance_start: None,
hire_date: None,
apply_allowance: None,
allowance_override: None,
pension_accumulation: None,
payroll_options: None,
notes: None,
attributes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**first_name:** `String`
</dd>
</dl>
<dl>
<dd>
**last_name:** `String`
</dd>
</dl>
<dl>
<dd>
**personal_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<EmployeesCreateHrRequestAddress>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**social_insurance_no:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**social_insurance_start:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**hire_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**apply_allowance:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**allowance_override:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**pension_accumulation:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**payroll_options:** `Option<std::collections::HashMap<String, String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**attributes:** `Option<Vec<EmployeesCreateHrRequestAttributesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_update</a>(request: EmployeesUpdateHrRequest) -> Result<EmployeesUpdateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of an employee; a null clears the fields that allow it (code, personal code, birth date, contact details, address, IBAN, social insurance number and start, hire date, notes). `status` and `terminationDate` are set here too.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_update(
&EmployeesUpdateHrRequest {
id: "id".to_string(),
code: None,
first_name: None,
last_name: None,
personal_code: None,
birth_date: None,
email: None,
phone: None,
address: None,
iban: None,
social_insurance_no: None,
social_insurance_start: None,
hire_date: None,
apply_allowance: None,
allowance_override: None,
pension_accumulation: None,
payroll_options: None,
notes: None,
attributes: None,
termination_date: None,
status: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**first_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**last_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**personal_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**birth_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<Option<EmployeesUpdateHrRequestAddress>>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**social_insurance_no:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**social_insurance_start:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**hire_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**apply_allowance:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**allowance_override:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**pension_accumulation:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**payroll_options:** `Option<std::collections::HashMap<String, String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**attributes:** `Option<Vec<EmployeesUpdateHrRequestAttributesItem>>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**termination_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<EmployeesUpdateHrRequestStatus>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_get</a>(request: EmployeesGetHrRequest) -> Result<EmployeesGetHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Reads one employee.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_get(
&EmployeesGetHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_fields</a>(request: EmployeesFieldsHrRequest) -> Result<EmployeesFieldsHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Attributes a filing of the company country needs about a person that the shared employee record does not carry, such as the sex and place of birth an Italian income certificate asks for. Their values are kept in the payrollOptions of the employee.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_fields(
&EmployeesFieldsHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_list</a>(request: EmployeesListHrRequest) -> Result<EmployeesListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the employees that are not deleted; filterable by `firstName`, `lastName`, `code`, `status` and `email`, sortable by `lastName`, `code` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_list(
&EmployeesListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<EmployeesListHrRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<EmployeesListHrRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_delete</a>(request: EmployeesDeleteHrRequest) -> Result<EmployeesDeleteHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Marks the employee deleted; the record stays and no longer appears in lists or payroll runs. `hr/employees/anonymize` also blanks the personal data.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_delete(
&EmployeesDeleteHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_anonymize</a>(request: EmployeesAnonymizeHrRequest) -> Result<EmployeesAnonymizeHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Replaces the name with a placeholder and removes personal code, birth date, contact details, address, bank account, social-insurance number, notes and sick-leave reasons. Payroll and contract rows stay linked to the record for the statutory retention period.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_anonymize(
&EmployeesAnonymizeHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">contracts_create</a>(request: ContractsCreateHrRequest) -> Result<ContractsCreateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates an employment contract for an employee. A `permanent` contract takes no `endDate` and a `fixed_term` one requires it; the number comes from `contractNo` or, with `agreementId`, from the employee's agreement; `workHours` defaults by `salaryType`. Answers 422 when the end date is before the start, and 409 when the employee already has a contract overlapping the period (end it with `hr/contracts/end` first) or the contract number already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.contracts_create(
&ContractsCreateHrRequest {
employee_id: "employeeId".to_string(),
start_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
base_salary: "121.0000".to_string(),
position_id: None,
department_id: None,
schedule_id: None,
agreement_id: None,
contract_no: None,
r#type: None,
end_date: None,
salary_type: None,
work_hours: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**position_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**department_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**schedule_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**agreement_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**contract_no:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<ContractsCreateHrRequestType>`
</dd>
</dl>
<dl>
<dd>
**start_date:** `String`
</dd>
</dl>
<dl>
<dd>
**end_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**base_salary:** `String`
</dd>
</dl>
<dl>
<dd>
**salary_type:** `Option<ContractsCreateHrRequestSalaryType>`
</dd>
</dl>
<dl>
<dd>
**work_hours:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">contracts_end</a>(request: ContractsEndHrRequest) -> Result<ContractsEndHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Ends a contract on `endDate` with an optional reason. Answers 422 when the end date is before the contract start.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.contracts_end(
&ContractsEndHrRequest {
id: "id".to_string(),
end_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
end_reason: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**end_date:** `String`
</dd>
</dl>
<dl>
<dd>
**end_reason:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">contracts_list</a>(request: ContractsListHrRequest) -> Result<ContractsListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists employment contracts; filterable by `employeeId`, `agreementId`, `status` and `contractNo`, sortable by `startDate` and `contractNo`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.contracts_list(
&ContractsListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ContractsListHrRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ContractsListHrRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">leave_balances_set</a>(request: LeaveBalancesSetHrRequest) -> Result<LeaveBalancesSetHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates or replaces the leave entitlement of an employee for a year; `usedDays` is kept unless given (0 on a new row) and `remainingDays` is the entitled days less the used ones.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.leave_balances_set(
&LeaveBalancesSetHrRequest {
employee_id: "employeeId".to_string(),
year: 1000000,
entitled_days: "121.00".to_string(),
used_days: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**entitled_days:** `String`
</dd>
</dl>
<dl>
<dd>
**used_days:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">leave_balances_list</a>(request: LeaveBalancesListHrRequest) -> Result<LeaveBalancesListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists leave balances, narrowed to an employee and/or a year when given, oldest year first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.leave_balances_list(
&LeaveBalancesListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**year:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">incapacity_certificates_create</a>(request: IncapacityCertificatesCreateHrRequest) -> Result<IncapacityCertificatesCreateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Records a sick-leave certificate of an employee. Answers 422 when `toDate` is before `fromDate`. `payroll/runs/create` warns when a certificate covers working days of a month that has no timesheet.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.incapacity_certificates_create(
&IncapacityCertificatesCreateHrRequest {
employee_id: "employeeId".to_string(),
number: "number".to_string(),
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
series: None,
reason: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**series:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**number:** `String`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">incapacity_certificates_list</a>(request: IncapacityCertificatesListHrRequest) -> Result<IncapacityCertificatesListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists incapacity certificates; filterable by `employeeId` and `number`, sortable by `fromDate` and `number`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.incapacity_certificates_list(
&IncapacityCertificatesListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<IncapacityCertificatesListHrRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<IncapacityCertificatesListHrRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">per_diem_rates_create</a>(request: PerDiemRatesCreateHrRequest) -> Result<PerDiemRatesCreateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds the company's daily per diem rate for a destination country from `validFrom`; `hr/business-trips/create` takes the latest rate valid on the trip's start date. Answers 409 when a rate for that country already starts on that date.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.per_diem_rates_create(
&PerDiemRatesCreateHrRequest {
country_code: "countryCode".to_string(),
daily_amount: "121.00".to_string(),
valid_from: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country_code:** `String`
</dd>
</dl>
<dl>
<dd>
**daily_amount:** `String`
</dd>
</dl>
<dl>
<dd>
**valid_from:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">per_diem_rates_list</a>(request: PerDiemRatesListHrRequest) -> Result<PerDiemRatesListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists per diem rates; filterable by `countryCode`, sortable by `countryCode` and `validFrom`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.per_diem_rates_list(
&PerDiemRatesListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<PerDiemRatesListHrRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<PerDiemRatesListHrRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">per_diem_rates_delete</a>(request: PerDiemRatesDeleteHrRequest) -> Result<PerDiemRatesDeleteHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a per diem rate.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.per_diem_rates_delete(
&PerDiemRatesDeleteHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">business_trips_create</a>(request: BusinessTripsCreateHrRequest) -> Result<BusinessTripsCreateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Stores the trip as a draft with `days` counted as calendar days, both ends included, and `perDiemAmount` as the days times the company's rate for the destination valid on the start date (`hr/per-diem-rates/create`). Answers 422 when the trip ends before it starts or no rate covers the destination on that date, and 409 when the employee already has a trip overlapping the dates.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.business_trips_create(
&BusinessTripsCreateHrRequest {
employee_id: "employeeId".to_string(),
destination_country_code: "destinationCountryCode".to_string(),
purpose: "purpose".to_string(),
start_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
end_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**destination_country_code:** `String`
</dd>
</dl>
<dl>
<dd>
**purpose:** `String`
</dd>
</dl>
<dl>
<dd>
**start_date:** `String`
</dd>
</dl>
<dl>
<dd>
**end_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">business_trips_get</a>(request: BusinessTripsGetHrRequest) -> Result<BusinessTripsGetHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Reads one business trip.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.business_trips_get(
&BusinessTripsGetHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">business_trips_list</a>(request: BusinessTripsListHrRequest) -> Result<BusinessTripsListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists business trips; filterable by `employeeId`, `status` and `payrollRunId`, sortable by `startDate`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.business_trips_list(
&BusinessTripsListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<BusinessTripsListHrRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<BusinessTripsListHrRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">business_trips_approve</a>(request: BusinessTripsApproveHrRequest) -> Result<BusinessTripsApproveHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Sets the trip's status to `approved`. `payroll/runs/create` without explicit lines adds the per diem of every approved trip ending in the run month as an untaxed addition and sets the trip's `payrollRunId`; reversing or cancelling the run releases the trip again. Answers 409 when the trip is not a draft.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.business_trips_approve(
&BusinessTripsApproveHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">business_trips_delete</a>(request: BusinessTripsDeleteHrRequest) -> Result<BusinessTripsDeleteHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a draft trip; answers 409 when the trip is not a draft.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.business_trips_delete(
&BusinessTripsDeleteHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_records_create</a>(request: EmployeesRecordsCreateHrRequest) -> Result<EmployeesRecordsCreateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Adds an education, qualification, certificate or training record to an employee, optionally linked to one of the company's uploaded files (`fileId`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_records_create(
&EmployeesRecordsCreateHrRequest {
employee_id: "employeeId".to_string(),
r#type: EmployeesRecordsCreateHrRequestType::Education,
title: "title".to_string(),
institution: None,
issued_at: None,
valid_until: None,
file_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `EmployeesRecordsCreateHrRequestType`
</dd>
</dl>
<dl>
<dd>
**title:** `String`
</dd>
</dl>
<dl>
<dd>
**institution:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issued_at:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**valid_until:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**file_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_records_update</a>(request: EmployeesRecordsUpdateHrRequest) -> Result<EmployeesRecordsUpdateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes the given fields of an employee record; `issuedAt`, `validUntil` and `fileId` can be cleared with null.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_records_update(
&EmployeesRecordsUpdateHrRequest {
id: "id".to_string(),
r#type: None,
title: None,
institution: None,
issued_at: None,
valid_until: None,
file_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<EmployeesRecordsUpdateHrRequestType>`
</dd>
</dl>
<dl>
<dd>
**title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**institution:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issued_at:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**valid_until:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**file_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_records_delete</a>(request: EmployeesRecordsDeleteHrRequest) -> Result<EmployeesRecordsDeleteHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes an employee record.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_records_delete(
&EmployeesRecordsDeleteHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_records_list</a>(request: EmployeesRecordsListHrRequest) -> Result<EmployeesRecordsListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists employee records; filterable by `employeeId`, `type` and `title`, sortable by `createdAt` and `issuedAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_records_list(
&EmployeesRecordsListHrRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<EmployeesRecordsListHrRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<EmployeesRecordsListHrRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">employees_attachments_list</a>(request: EmployeesAttachmentsListHrRequest) -> Result<EmployeesAttachmentsListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the files uploaded against an employee, newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.employees_attachments_list(
&EmployeesAttachmentsListHrRequest {
employee_id: "employeeId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">timesheets_generate</a>(request: TimesheetsGenerateHrRequest) -> Result<TimesheetsGenerateHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the timesheet of the month for every employee with a contract in it, or for one employee with `employeeId`, replacing any existing timesheet: the Monday to Friday days within the contract get the contract's daily hours (its weekly hours over five), and for a Lithuanian company the public holidays are `holiday` days with 0 hours. Answers 422 when no contract covers the month.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.timesheets_generate(
&TimesheetsGenerateHrRequest {
year: 1000000,
month: 1000000,
employee_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**employee_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">timesheets_upsert</a>(request: TimesheetsUpsertHrRequest) -> Result<TimesheetsUpsertHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates or replaces the timesheet of an employee for a month from the given days; `workedDays` and `workedHours` count the `work` and `business_trip` days with hours. Answers 422 for a day outside the month, a day given twice or more than 24 hours in a day. `payroll/runs/create` reads the timesheet for the paid days, the days worked and the business-trip days of the month.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.timesheets_upsert(
&TimesheetsUpsertHrRequest {
employee_id: "employeeId".to_string(),
year: 1000000,
month: 1000000,
days: vec![TimesheetsUpsertHrRequestDaysItem {
day: 1000000,
hours: "121.00".to_string(),
r#type: TimesheetsUpsertHrRequestDaysItemType::Work,
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**days:** `Vec<TimesheetsUpsertHrRequestDaysItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">timesheets_get</a>(request: TimesheetsGetHrRequest) -> Result<TimesheetsGetHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Reads the timesheet of an employee for a month.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.timesheets_get(
&TimesheetsGetHrRequest {
employee_id: "employeeId".to_string(),
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">timesheets_list</a>(request: TimesheetsListHrRequest) -> Result<TimesheetsListHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the timesheets of a month, ordered by employee name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.timesheets_list(
&TimesheetsListHrRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.hr.<a href="/src/api/resources/hr/client.rs">timesheets_delete</a>(request: TimesheetsDeleteHrRequest) -> Result<TimesheetsDeleteHrResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a timesheet.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.hr
.timesheets_delete(
&TimesheetsDeleteHrRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## fleet
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">vehicles_create</a>(request: VehiclesCreateFleetRequest) -> Result<VehiclesCreateFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Register a vehicle. The plate number is stored in upper case and must be unique in the company (409 otherwise); `fixedAssetId` must name an existing fixed asset. Uploaded `documents` are attached to the vehicle.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.vehicles_create(
&VehiclesCreateFleetRequest {
plate_number: "plateNumber".to_string(),
make: "make".to_string(),
model: "model".to_string(),
year: None,
vin: None,
fuel_type: None,
acquisition_date: None,
market_value: None,
fixed_asset_id: None,
technical_inspection_due: None,
insurance_due: None,
notes: None,
documents: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**plate_number:** `String`
</dd>
</dl>
<dl>
<dd>
**make:** `String`
</dd>
</dl>
<dl>
<dd>
**model:** `String`
</dd>
</dl>
<dl>
<dd>
**year:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vin:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**fuel_type:** `Option<VehiclesCreateFleetRequestFuelType>`
</dd>
</dl>
<dl>
<dd>
**acquisition_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**market_value:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**fixed_asset_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**technical_inspection_due:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**insurance_due:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**documents:** `Option<Vec<VehiclesCreateFleetRequestDocumentsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">vehicles_update</a>(request: VehiclesUpdateFleetRequest) -> Result<VehiclesUpdateFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a vehicle's details or set its `status` to `active`, `sold` or `scrapped`; omitted fields keep their value. A plate number already used by another vehicle is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.vehicles_update(
&VehiclesUpdateFleetRequest {
id: "id".to_string(),
plate_number: None,
make: None,
model: None,
year: None,
vin: None,
fuel_type: None,
acquisition_date: None,
market_value: None,
fixed_asset_id: None,
technical_inspection_due: None,
insurance_due: None,
status: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**plate_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**make:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**model:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**year:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vin:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**fuel_type:** `Option<Option<VehiclesUpdateFleetRequestFuelType>>`
</dd>
</dl>
<dl>
<dd>
**acquisition_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**market_value:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**fixed_asset_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**technical_inspection_due:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**insurance_due:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<VehiclesUpdateFleetRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">vehicles_get</a>(request: VehiclesGetFleetRequest) -> Result<VehiclesGetFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one vehicle with its current assignment, when an employee holds it today.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.vehicles_get(
&VehiclesGetFleetRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">vehicles_list</a>(request: VehiclesListFleetRequest) -> Result<VehiclesListFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List vehicles with their current assignment. Filterable by `plateNumber`, `make`, `model` and `status`; sortable by `plateNumber`, `make` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.vehicles_list(
&VehiclesListFleetRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<VehiclesListFleetRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<VehiclesListFleetRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">assignments_create</a>(request: AssignmentsCreateFleetRequest) -> Result<AssignmentsCreateFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Assign a vehicle to an employee from `fromDate`, open-ended or until `toDate`. A period that overlaps another assignment of the same vehicle is refused with 409, a `toDate` before `fromDate` with 422. `privateUse` makes the car a benefit in kind in `fleet/natura/preview`, and `employerPaysFuel` picks its rate.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.assignments_create(
&AssignmentsCreateFleetRequest {
vehicle_id: "vehicleId".to_string(),
employee_id: "employeeId".to_string(),
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: None,
private_use: None,
employer_pays_fuel: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**vehicle_id:** `String`
</dd>
</dl>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**private_use:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**employer_pays_fuel:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">assignments_end</a>(request: AssignmentsEndFleetRequest) -> Result<AssignmentsEndFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
End an open assignment on `toDate`. An assignment that already has an end date is refused with 409, a `toDate` before its `fromDate` with 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.assignments_end(
&AssignmentsEndFleetRequest {
id: "id".to_string(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">assignments_list</a>(request: AssignmentsListFleetRequest) -> Result<AssignmentsListFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List vehicle assignments with the plate number and the employee's name. Filterable by `vehicleId`, `employeeId` and `privateUse`; sortable by `fromDate` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.assignments_list(
&AssignmentsListFleetRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<AssignmentsListFleetRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<AssignmentsListFleetRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.fleet.<a href="/src/api/resources/fleet/client.rs">natura_preview</a>(request: NaturaPreviewFleetRequest) -> Result<NaturaPreviewFleetResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Preview the car benefit in kind of a month for a Lithuanian company: every assignment with `privateUse` that overlaps the month is valued at 0.75 % of the vehicle's market value when the employer pays the fuel, else 0.70 %, one row per employee and vehicle, with the total. A company registered in another country is refused with 422. The same amounts are added to a payroll run created with `includeNatura` (`payroll/runs/create`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.fleet
.natura_preview(
&NaturaPreviewFleetRequest {
year: 1000000,
month: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## payroll
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">departments_create</a>(request: DepartmentsCreatePayrollRequest) -> Result<DepartmentsCreatePayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a department with a code and a name; answers 409 when the code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.departments_create(
&DepartmentsCreatePayrollRequest {
code: "code".to_string(),
name: "name".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">departments_list</a>(request: DepartmentsListPayrollRequest) -> Result<DepartmentsListPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's departments ordered by code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.departments_list(
&DepartmentsListPayrollRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">schedules_create</a>(request: SchedulesCreatePayrollRequest) -> Result<SchedulesCreatePayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a work schedule with a code, a name and `hoursPerWeek` (default 40); answers 409 when the code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.schedules_create(
&SchedulesCreatePayrollRequest {
code: "code".to_string(),
name: "name".to_string(),
hours_per_week: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**hours_per_week:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">schedules_list</a>(request: SchedulesListPayrollRequest) -> Result<SchedulesListPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists the company's work schedules ordered by code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.schedules_list(
&SchedulesListPayrollRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">payment_types_list</a>(request: PaymentTypesListPayrollRequest) -> Result<PaymentTypesListPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Reads the payment types of the company country's payroll engine, each with the labels of the taxes, contributions and reporting lines it is subject to (`applies`), and the default type an untyped payment falls under. These codes are what `payroll/calc` and the additions of `payroll/runs/create` accept as `paymentType`. Answers 422 when Nordlet has no payroll engine for the company's country.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.payment_types_list(
&PaymentTypesListPayrollRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">calc</a>(request: CalcPayrollRequest) -> Result<CalcPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Runs the company country's payroll engine once on a taxable base at a date, with the employee settings given in the body instead of an employee record, and returns the allowance, income tax, contributions, components and net; nothing is saved. `payments` passes typed payments to the engine; each `paymentType` must be a code from `payroll/payment-types/list` (422 otherwise). Answers 422 when Nordlet has no payroll engine for the company's country.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.calc(
&CalcPayrollRequest {
taxable_base: "121.00".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
apply_allowance: None,
allowance_override: None,
pension_accumulation: None,
fixed_term: None,
benefit_in_kind: None,
options: None,
payments: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**taxable_base:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**apply_allowance:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**allowance_override:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**pension_accumulation:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**fixed_term:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**benefit_in_kind:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**options:** `Option<std::collections::HashMap<String, String>>`
</dd>
</dl>
<dl>
<dd>
**payments:** `Option<Vec<CalcPayrollRequestPaymentsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">runs_create</a>(request: RunsCreatePayrollRequest) -> Result<RunsCreatePayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a draft payroll run for a month, computing each line with the company country's payroll engine, the employee's approved runs of the year so far and of the two previous years, the month's timesheet and `payDate` (default the last day of the month). Without `lines`, every active employee whose contract covers the month gets a line: the gross is the contract's monthly salary reduced to the paid working days of the contract and the timesheet, unless `grossOverrides` sets it; the per diems of approved business trips ending in the month are added untaxed and the trips linked to the run; for a Lithuanian company the car benefit in kind (`includeNatura`) and the compensation for unused leave of a contract ending in the month are added. With `lines`, only the given employees are computed with their gross, additions and deductions; a taxable addition may carry a `paymentType` from `payroll/payment-types/list` and `hours`. Answers 422 when the country has no engine, an employee is given twice, has two contracts in the month, has no contract and no gross, or is paid by the hour or day without a gross; 409 when a run for the month already exists or the accounting period is locked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.runs_create(
&RunsCreatePayrollRequest {
year: 1000000,
month: 1000000,
include_natura: None,
gross_overrides: None,
lines: None,
notes: None,
pay_date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
<dl>
<dd>
**month:** `String`
</dd>
</dl>
<dl>
<dd>
**include_natura:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**gross_overrides:** `Option<Vec<RunsCreatePayrollRequestGrossOverridesItem>>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<RunsCreatePayrollRequestLinesItem>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**pay_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">runs_get</a>(request: RunsGetPayrollRequest) -> Result<RunsGetPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Reads a payroll run with its lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.runs_get(
&RunsGetPayrollRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">runs_list</a>(request: RunsListPayrollRequest) -> Result<RunsListPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists payroll runs without their lines; filterable by `status`, `year` and `month`, sortable by `createdAt`, `year` and `month`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.runs_list(
&RunsListPayrollRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<RunsListPayrollRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<RunsListPayrollRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">lines_attendance</a>(request: LinesAttendancePayrollRequest) -> Result<LinesAttendancePayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
The days and hours worked, the days on the register and the average hourly earnings that some countries report per employment. The Czech monthly employer report asks for all four. They can be set while the run is a draft.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.lines_attendance(
&LinesAttendancePayrollRequest {
id: "id".to_string(),
days_worked: None,
hours_worked: None,
registered_days: None,
average_hourly_earnings: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**days_worked:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**hours_worked:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**registered_days:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**average_hourly_earnings:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">runs_approve</a>(request: RunsApprovePayrollRequest) -> Result<RunsApprovePayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Posts the run's journal entry dated the last day of the month and sets the status to `approved`: the wage expense (net pay, income tax, employee contributions and deductions) and the employer contributions are debited; the net payable, the income tax, the social contributions (on one account, or split between the employee and employer accounts when their codes differ) and the deductions are credited. The accounts default to the payroll accounts of the company's chart template; each can be given per call. Answers 409 when the run is not a draft or the accounting period is locked, 422 when the run has no lines or nothing to post, and emits `payroll_run.approved`. For an Irish company with the automation of the `ie-payroll-withholding` deadline switched on, the month's payroll submission is sent at once and a failure is added to the run's `warnings`. Undo with `payroll/runs/reverse`, pay with `payroll/payments/export`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.runs_approve(
&RunsApprovePayrollRequest {
id: "id".to_string(),
wage_account_code: None,
employer_account_code: None,
payable_account_code: None,
gpm_account_code: None,
sodra_account_code: None,
employer_social_account_code: None,
deduction_account_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**wage_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**employer_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**payable_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**gpm_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sodra_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**employer_social_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**deduction_account_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">runs_reverse</a>(request: RunsReversePayrollRequest) -> Result<RunsReversePayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Posts a journal entry dated the last day of the month that mirrors the run's entry (debits and credits swapped), sets the status to `reversed` with the reason, and releases the business trips the run paid so the next run picks them up again. Answers 409 when the run is not approved, when part of it is matched to bank payments (`paidAmount`, unmatch them first) or when the accounting period is locked. Emits `payroll_run.reversed`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.runs_reverse(
&RunsReversePayrollRequest {
id: "id".to_string(),
reason: "reason".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**reason:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">runs_cancel</a>(request: RunsCancelPayrollRequest) -> Result<RunsCancelPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a draft run with its lines and releases the business trips linked to it; answers 409 when the run is not a draft. An approved run is undone with `payroll/runs/reverse`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.runs_cancel(
&RunsCancelPayrollRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.payroll.<a href="/src/api/resources/payroll/client.rs">payments_export</a>(request: PaymentsExportPayrollRequest) -> Result<PaymentsExportPayrollResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds a SEPA credit transfer file (pain.001.001.03) for an approved run: one transfer from the chosen bank account to each employee's IBAN for the line's net when it is positive, with a remittance text in `locale` (default the locale of the calling user) and the run period, executed on `executionDate` (default the company's current date). Answers 409 when the run is not approved, and 422 when the bank account has no IBAN or is not in the company's base currency, an employee has no IBAN (`hr/employees/update`) or no line has a positive net. The file is returned in `xml`; nothing is sent to the bank.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.payroll
.payments_export(
&PaymentsExportPayrollRequest {
run_id: "runId".to_string(),
bank_account_id: "bankAccountId".to_string(),
execution_date: None,
locale: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**run_id:** `String`
</dd>
</dl>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**execution_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<PaymentsExportPayrollRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## agreements
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">settings_get</a>(request: SettingsGetAgreementsRequest) -> Result<SettingsGetAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return whether automatic agreement billing is switched on for the company.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.settings_get(
&SettingsGetAgreementsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">settings_update</a>(request: SettingsUpdateAgreementsRequest) -> Result<SettingsUpdateAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Switch automatic agreement billing on or off for the company. With it on, a scheduled job runs the same billing as `agreements/agreements/billing/run` for the company once a day.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.settings_update(
&SettingsUpdateAgreementsRequest { auto_billing: true },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**auto_billing:** `bool`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">types_create</a>(request: TypesCreateAgreementsRequest) -> Result<TypesCreateAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an agreement type with a `code` and a `name`. Answers 409 when the company already has a type with that code.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.types_create(
&TypesCreateAgreementsRequest {
code: "code".to_string(),
name: "name".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">types_list</a>(request: TypesListAgreementsRequest) -> Result<TypesListAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's agreement types. Filterable and sortable by `code` and `name`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.types_list(
&TypesListAgreementsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<TypesListAgreementsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<TypesListAgreementsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">agreements_create</a>(request: AgreementsCreateAgreementsRequest) -> Result<AgreementsCreateAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an agreement for exactly one party, a partner, an employee or a bank account, which must exist in the company (400 otherwise). Without `kind`, an employee agreement is `employment`, a bank account agreement is `bank` and a partner agreement is `other`; a `documentRef` (the `storageKey` of an uploaded file) attaches that file to the agreement. Answers 409 when the company already has an agreement with that `number`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.agreements_create(
&AgreementsCreateAgreementsRequest {
number: "number".to_string(),
start_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
type_id: None,
kind: None,
partner_id: None,
employee_id: None,
bank_account_id: None,
name: None,
end_date: None,
auto_renew: None,
value: None,
billing_period: None,
currency: None,
status: None,
notes: None,
document_ref: None,
items: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**kind:** `Option<AgreementsCreateAgreementsRequestKind>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**employee_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**bank_account_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**number:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**start_date:** `String`
</dd>
</dl>
<dl>
<dd>
**end_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**auto_renew:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**value:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**billing_period:** `Option<AgreementsCreateAgreementsRequestBillingPeriod>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<AgreementsCreateAgreementsRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**items:** `Option<Vec<AgreementsCreateAgreementsRequestItemsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">agreements_get</a>(request: AgreementsGetAgreementsRequest) -> Result<AgreementsGetAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one agreement with its items.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.agreements_get(
&AgreementsGetAgreementsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">agreements_update</a>(request: AgreementsUpdateAgreementsRequest) -> Result<AgreementsUpdateAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the given fields of an agreement and return it with its items. The party, `number`, `startDate`, `currency` and items are not changed by this call.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.agreements_update(
&AgreementsUpdateAgreementsRequest {
id: "id".to_string(),
type_id: None,
kind: None,
name: None,
end_date: None,
auto_renew: None,
value: None,
billing_period: None,
status: None,
notes: None,
document_ref: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**kind:** `Option<AgreementsUpdateAgreementsRequestKind>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**end_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**auto_renew:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**value:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**billing_period:** `Option<Option<AgreementsUpdateAgreementsRequestBillingPeriod>>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<AgreementsUpdateAgreementsRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">agreements_delete</a>(request: AgreementsDeleteAgreementsRequest) -> Result<AgreementsDeleteAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Mark an agreement as deleted. It is no longer returned, changed or billed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.agreements_delete(
&AgreementsDeleteAgreementsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">agreements_list</a>(request: AgreementsListAgreementsRequest) -> Result<AgreementsListAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's agreements without their items, each with `partnerName`. Filterable by `number`, `name`, `partnerId`, `employeeId`, `bankAccountId`, `kind`, `typeId`, `status`, `startDate`, `endDate` and `value`; sortable by `number`, `startDate` and `createdAt` (default `startDate` descending).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.agreements_list(
&AgreementsListAgreementsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<AgreementsListAgreementsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<AgreementsListAgreementsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">agreements_generate_invoice</a>(request: AgreementsGenerateInvoiceAgreementsRequest) -> Result<AgreementsGenerateInvoiceAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft sale invoice for the next unbilled period of an active agreement that has a partner and a `billingPeriod`. The period follows the monthly, quarterly or annual grid from `startDate`, continues after the last period already invoiced for the agreement, and is prorated by days when it starts late or is cut by `endDate`; an `autoRenew` agreement has its `endDate` moved forward by whole terms instead (`renewedEndDate`). The lines come from the agreement items, else one line of `value`, with revenue recognised ratably over the period. Answers 422 when the agreement is not active, has no partner, billing period, items or value, carries VAT while the company is not a VAT payer, is fully billed through its end date, or when the next period starts after `asOfDate` (default today). Emits `agreement.invoice_generated`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.agreements_generate_invoice(
&AgreementsGenerateInvoiceAgreementsRequest {
id: "id".to_string(),
as_of_date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**as_of_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">agreements_billing_run</a>(request: AgreementsBillingRunAgreementsRequest) -> Result<AgreementsBillingRunAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Generate the invoices due up to `asOfDate` (default today) for every active agreement of the company that has a partner and a billing period, one invoice per period and at most 60 per agreement in one run, in the same way as `agreements/agreements/generate-invoice`. An agreement that is fully billed and whose `endDate` has passed is set to `expired`. A failing agreement is listed in `errors` and does not stop the run. Each invoice emits `agreement.invoice_generated`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.agreements_billing_run(
&AgreementsBillingRunAgreementsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**as_of_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">insurance_policies_create</a>(request: InsurancePoliciesCreateAgreementsRequest) -> Result<InsurancePoliciesCreateAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an insurance policy. Answers 422 when `toDate` is before `fromDate`, 400 when `insurerPartnerId` is not a partner of the company, and 409 when the company already has a policy with that `policyNumber`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.insurance_policies_create(
&InsurancePoliciesCreateAgreementsRequest {
policy_number: "policyNumber".to_string(),
insured_object: "insuredObject".to_string(),
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
insurer_partner_id: None,
premium: None,
currency: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**insurer_partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**policy_number:** `String`
</dd>
</dl>
<dl>
<dd>
**insured_object:** `String`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**premium:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">insurance_policies_list</a>(request: InsurancePoliciesListAgreementsRequest) -> Result<InsurancePoliciesListAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's insurance policies. Filterable by `policyNumber`, `insurerPartnerId` and `toDate`; sortable by `policyNumber` and `toDate` (default `toDate` descending).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.insurance_policies_list(
&InsurancePoliciesListAgreementsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<InsurancePoliciesListAgreementsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<InsurancePoliciesListAgreementsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.agreements.<a href="/src/api/resources/agreements/client.rs">insurance_policies_delete</a>(request: InsurancePoliciesDeleteAgreementsRequest) -> Result<InsurancePoliciesDeleteAgreementsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Mark an insurance policy as deleted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.agreements
.insurance_policies_delete(
&InsurancePoliciesDeleteAgreementsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## inventory
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">settings_get</a>(request: SettingsGetInventoryRequest) -> Result<SettingsGetInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the company's negative stock policy.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.settings_get(
&SettingsGetInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">settings_update</a>(request: SettingsUpdateInventoryRequest) -> Result<SettingsUpdateInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set the negative stock policy. With `reject` a consumption larger than the stock on hand of the item in the warehouse is refused with 422. With `allow` the missing quantity is written as a shortage priced at the unit cost of the last receipt in that warehouse (the item's purchase price when there is none); the next receipt of the item there settles the shortage and posts any cost difference between `inventory.cogs` and `inventory.stock`. A consumption from a named lot is refused with 422 under both policies.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.settings_update(
&SettingsUpdateInventoryRequest {
negative_stock_policy: SettingsUpdateInventoryRequestNegativeStockPolicy::Reject,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**negative_stock_policy:** `SettingsUpdateInventoryRequestNegativeStockPolicy`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">warehouses_create</a>(request: WarehousesCreateInventoryRequest) -> Result<WarehousesCreateInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a warehouse. 409 when the code already exists.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.warehouses_create(
&WarehousesCreateInventoryRequest {
code: "code".to_string(),
name: "name".to_string(),
is_default: None,
country_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**is_default:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**country_code:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">warehouses_list</a>(request: WarehousesListInventoryRequest) -> Result<WarehousesListInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the warehouses. Filterable and sortable: code, name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.warehouses_list(
&WarehousesListInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<WarehousesListInventoryRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<WarehousesListInventoryRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">warehouses_update</a>(request: WarehousesUpdateInventoryRequest) -> Result<WarehousesUpdateInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the name or the country code of a warehouse.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.warehouses_update(
&WarehousesUpdateInventoryRequest {
id: "id".to_string(),
name: None,
country_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**country_code:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">stock_receive</a>(request: StockReceiveInventoryRequest) -> Result<StockReceiveInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a manual receipt of an item into a warehouse at `unitCost` (document type `manual_receipt`); the quantity must be positive (422). A lot- or serial-tracked item needs `lotNumber` (422); an unknown lot is created, and `expiryDate` is stored on a lot that has none. A serial-tracked item is received one unit at a time (422), and 409 when that serial number is already in stock. Open shortages of the item in the warehouse (negative stock policy `allow`) are settled from the receipt. Emits `stock.changed`. Receipts against a purchase order go through `purchases/receipts/create`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.stock_receive(
&StockReceiveInventoryRequest {
warehouse_id: "warehouseId".to_string(),
item_id: "itemId".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
quantity: "121.0000".to_string(),
unit_cost: "121.000000".to_string(),
lot_number: None,
expiry_date: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**warehouse_id:** `String`
</dd>
</dl>
<dl>
<dd>
**item_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**quantity:** `String`
</dd>
</dl>
<dl>
<dd>
**unit_cost:** `String`
</dd>
</dl>
<dl>
<dd>
**lot_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**expiry_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">stock_write_off</a>(request: StockWriteOffInventoryRequest) -> Result<StockWriteOffInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Consume a quantity of an item from a warehouse, oldest layers first (from one lot when `lotNumber` is given), and post a journal entry: debit the expense account (`expenseAccountCode`, default the chart's inventory expense account), credit the stock account each consumed layer was received on (the chart's inventory account for layers without one), or `inventoryAccountCode` for the whole cost when given. 409 when the accounting period of `date` is locked; 422 when the stock is insufficient under the `reject` policy or in the named lot. Emits `stock.changed` and, when the consumption takes the available quantity from above a reorder rule's minimum to at or below it, `stock.reorder_needed`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.stock_write_off(
&StockWriteOffInventoryRequest {
warehouse_id: "warehouseId".to_string(),
item_id: "itemId".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
quantity: "121.0000".to_string(),
lot_number: None,
expense_account_code: None,
inventory_account_code: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**warehouse_id:** `String`
</dd>
</dl>
<dl>
<dd>
**item_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**quantity:** `String`
</dd>
</dl>
<dl>
<dd>
**lot_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**expense_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**inventory_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">stock_transfer</a>(request: StockTransferInventoryRequest) -> Result<StockTransferInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Move a quantity of an item from one warehouse to another: the source layers are consumed oldest first (from one lot when `lotNumber` is given) and received in the target with the same quantities, costs, lots and stock accounts (document type `warehouse_transfer`). 422 when both warehouses are the same or the source stock is insufficient under the `reject` policy. `inMovementId` is the first receipt when the consumption spans several lots or stock accounts. Emits `stock.changed` for both warehouses and `stock.reorder_needed` as `inventory/stock/write-off` does.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.stock_transfer(
&StockTransferInventoryRequest {
from_warehouse_id: "fromWarehouseId".to_string(),
to_warehouse_id: "toWarehouseId".to_string(),
item_id: "itemId".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
quantity: "121.0000".to_string(),
lot_number: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_warehouse_id:** `String`
</dd>
</dl>
<dl>
<dd>
**to_warehouse_id:** `String`
</dd>
</dl>
<dl>
<dd>
**item_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**quantity:** `String`
</dd>
</dl>
<dl>
<dd>
**lot_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">stock_take</a>(request: StockTakeInventoryRequest) -> Result<StockTakeInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Post a stock count for a warehouse. Each line names an item by `itemId` or `barcode` with its `countedQty`; the difference to the quantity on hand in the warehouse (all lots together) is written off oldest layers first or received as a surplus at `unitCost` (the item's purchase price when omitted; 422 when neither is set), with document type `stock_take`, and a surplus of a lot- or serial-tracked item needs `lotNumber` (422). The shortage cost less the surplus cost is posted in one journal entry between the expense account (`expenseAccountCode`, default the chart's inventory expense account) and the stock accounts (`inventoryAccountCode` for everything when given, else the accounts of the consumed layers and the chart's inventory account for the surpluses); nothing is posted and `journalTransactionId` is null when the net is zero. 409 when the accounting period of `date` is locked. Emits `stock.changed` per adjusted item.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.stock_take(
&StockTakeInventoryRequest {
warehouse_id: "warehouseId".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
lines: vec![StockTakeInventoryRequestLinesItem {
counted_qty: "121.0000".to_string(),
..Default::default()
}],
expense_account_code: None,
inventory_account_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**warehouse_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**expense_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**inventory_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<StockTakeInventoryRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">stock_levels</a>(request: StockLevelsInventoryRequest) -> Result<StockLevelsInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the quantity and value on hand per item and warehouse, summed from the stock movements, optionally for one `warehouseId` and/or `itemId`. Rows with a zero quantity are left out.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.stock_levels(
&StockLevelsInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**item_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">stock_movements_list</a>(request: StockMovementsListInventoryRequest) -> Result<StockMovementsListInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the stock movements. Filterable: itemId, warehouseId, lotId, direction, documentType, date, quantity, totalCost. Sortable: date, createdAt, quantity, totalCost; default newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.stock_movements_list(
&StockMovementsListInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<StockMovementsListInventoryRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<StockMovementsListInventoryRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">lots_list</a>(request: LotsListInventoryRequest) -> Result<LotsListInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the lots with their quantity on hand (the remaining quantity of the lot's incoming movements). Filterable: itemId, lotNumber, expiryDate. Sortable: lotNumber, expiryDate, createdAt; default newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.lots_list(
&LotsListInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<LotsListInventoryRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<LotsListInventoryRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">lots_get</a>(request: LotsGetInventoryRequest) -> Result<LotsGetInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return a lot with its quantity on hand and its movements in date order.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.lots_get(
&LotsGetInventoryRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">lots_update</a>(request: LotsUpdateInventoryRequest) -> Result<LotsUpdateInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the expiry date or the notes of a lot; null clears the value.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.lots_update(
&LotsUpdateInventoryRequest {
id: "id".to_string(),
expiry_date: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**expiry_date:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">landed_costs_create</a>(request: LandedCostsCreateInventoryRequest) -> Result<LandedCostsCreateInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Allocate an extra cost `amount` (positive, whole cents; 422 otherwise) over incoming stock movements, named by `movementIds` or taken from the lines of a goods receipt (`goodsReceiptId`; 422 when the receipt has no stock movements), in proportion to their cost (`by_value`) or quantity (`by_quantity`), largest remainder to the cent. The part of each share that belongs to the quantity still on hand raises the movement's remaining cost and recomputes its unit cost; the part that belongs to quantity already consumed is posted in a journal entry dated `date` debiting `inventory.cogs` and crediting the movement's stock account (`inventory.stock` when it has none), 409 when that period is locked. 422 when a movement is not incoming or the weights sum to zero. `sourceInvoiceId` records the purchase invoice the cost came from. Goods receipts come from `purchases/receipts/create`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.landed_costs_create(
&LandedCostsCreateInventoryRequest {
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
amount: "121.000000".to_string(),
method: None,
goods_receipt_id: None,
movement_ids: None,
source_invoice_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**method:** `Option<LandedCostsCreateInventoryRequestMethod>`
</dd>
</dl>
<dl>
<dd>
**goods_receipt_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**movement_ids:** `Option<Vec<String>>`
</dd>
</dl>
<dl>
<dd>
**source_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">landed_costs_get</a>(request: LandedCostsGetInventoryRequest) -> Result<LandedCostsGetInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return a landed cost with its allocation lines and the journal transaction it posted, if any.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.landed_costs_get(
&LandedCostsGetInventoryRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">landed_costs_list</a>(request: LandedCostsListInventoryRequest) -> Result<LandedCostsListInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the landed costs without their lines. Filterable: date, method, goodsReceiptId, sourceInvoiceId. Sortable: date, createdAt, amount; default newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.landed_costs_list(
&LandedCostsListInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<LandedCostsListInventoryRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<LandedCostsListInventoryRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">reorder_rules_create</a>(request: ReorderRulesCreateInventoryRequest) -> Result<ReorderRulesCreateInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a reorder rule for an item, for one warehouse or, without `warehouseId`, for the item over all warehouses; one rule per item and warehouse (409). While the rule is active, an outgoing movement or a reservation that takes the available quantity (on hand less reserved) from above `minQty` to at or below it emits `stock.reorder_needed` with the `reorderQty`. `inventory/reorder-rules/check` lists the rules currently at or below their minimum.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.reorder_rules_create(
&ReorderRulesCreateInventoryRequest {
item_id: "itemId".to_string(),
min_qty: "121.0000".to_string(),
warehouse_id: None,
reorder_qty: None,
is_active: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**item_id:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**min_qty:** `String`
</dd>
</dl>
<dl>
<dd>
**reorder_qty:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">reorder_rules_update</a>(request: ReorderRulesUpdateInventoryRequest) -> Result<ReorderRulesUpdateInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the minimum quantity, the reorder quantity (null clears it), the active flag or the notes of a reorder rule.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.reorder_rules_update(
&ReorderRulesUpdateInventoryRequest {
id: "id".to_string(),
min_qty: None,
reorder_qty: None,
is_active: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**min_qty:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**reorder_qty:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">reorder_rules_delete</a>(request: ReorderRulesDeleteInventoryRequest) -> Result<ReorderRulesDeleteInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a reorder rule.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.reorder_rules_delete(
&ReorderRulesDeleteInventoryRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">reorder_rules_list</a>(request: ReorderRulesListInventoryRequest) -> Result<ReorderRulesListInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the reorder rules. Filterable: itemId, warehouseId, isActive. Sortable: createdAt, minQty; default newest first.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.reorder_rules_list(
&ReorderRulesListInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ReorderRulesListInventoryRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ReorderRulesListInventoryRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.inventory.<a href="/src/api/resources/inventory/client.rs">reorder_rules_check</a>(request: ReorderRulesCheckInventoryRequest) -> Result<ReorderRulesCheckInventoryResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the active reorder rules whose available quantity (on hand less reserved, in the rule's warehouse or over all warehouses) is at or below `minQty`, with the quantities. Emits no event.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.inventory
.reorder_rules_check(
&ReorderRulesCheckInventoryRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## production
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">work_centers_create</a>(request: WorkCentersCreateProductionRequest) -> Result<WorkCentersCreateProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a work center with its `costPerHour`. `costAccountCode` must be a postable account of the chart (422 otherwise); when a production order completes, the labor cost of the operations run on this center is credited to it instead of the `production.laborApplied` posting rule account. A duplicate `code` is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.work_centers_create(
&WorkCentersCreateProductionRequest {
code: "code".to_string(),
name: "name".to_string(),
cost_per_hour: None,
cost_account_code: None,
maintenance_interval_days: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**cost_per_hour:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cost_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**maintenance_interval_days:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">work_centers_update</a>(request: WorkCentersUpdateProductionRequest) -> Result<WorkCentersUpdateProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a work center; only the fields sent are changed. `costAccountCode` must be a postable account of the chart (422 otherwise); a `code` already used by another work center is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.work_centers_update(
&WorkCentersUpdateProductionRequest {
id: "id".to_string(),
code: None,
name: None,
cost_per_hour: None,
cost_account_code: None,
maintenance_interval_days: None,
is_active: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cost_per_hour:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cost_account_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**maintenance_interval_days:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">work_centers_list</a>(request: WorkCentersListProductionRequest) -> Result<WorkCentersListProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List work centers. `nextMaintenanceDate` is the latest completed maintenance date (the creation date when there is none) plus `maintenanceIntervalDays`, null without an interval. Filterable by `code`, `name` and `isActive`; sortable by `code`, `name` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.work_centers_list(
&WorkCentersListProductionRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<WorkCentersListProductionRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<WorkCentersListProductionRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">routings_create</a>(request: RoutingsCreateProductionRequest) -> Result<RoutingsCreateProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a routing with its operations: `sequence`, work center, `setupMinutes`, `runMinutesPerUnit` and an optional `qualityCheckName` that becomes a pending quality check on every production order using the routing. Operation sequences must be unique (422); a duplicate `code` is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.routings_create(
&RoutingsCreateProductionRequest {
code: "code".to_string(),
name: "name".to_string(),
operations: vec![RoutingsCreateProductionRequestOperationsItem {
sequence: 1000000,
name: "name".to_string(),
work_center_id: "workCenterId".to_string(),
..Default::default()
}],
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**operations:** `Vec<RoutingsCreateProductionRequestOperationsItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">routings_get</a>(request: RoutingsGetProductionRequest) -> Result<RoutingsGetProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one routing with its operations in sequence order.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.routings_get(
&RoutingsGetProductionRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">routings_list</a>(request: RoutingsListProductionRequest) -> Result<RoutingsListProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List routings without their operations. Filterable by `code`, `name` and `isActive`; sortable by `code`, `name` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.routings_list(
&RoutingsListProductionRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<RoutingsListProductionRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<RoutingsListProductionRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">maintenance_create</a>(request: MaintenanceCreateProductionRequest) -> Result<MaintenanceCreateProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a `preventive` or `corrective` maintenance planned for a work center on `plannedDate`; it starts as `planned`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.maintenance_create(
&MaintenanceCreateProductionRequest {
work_center_id: "workCenterId".to_string(),
r#type: MaintenanceCreateProductionRequestType::Preventive,
planned_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
description: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**work_center_id:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `MaintenanceCreateProductionRequestType`
</dd>
</dl>
<dl>
<dd>
**planned_date:** `String`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">maintenance_complete</a>(request: MaintenanceCompleteProductionRequest) -> Result<MaintenanceCompleteProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Mark a `planned` maintenance as completed on `completedDate`, with optional `downtimeHours` and `cost` (409 when it is already completed or cancelled). The work center's `nextMaintenanceDate` is then counted from the latest completed maintenance date.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.maintenance_complete(
&MaintenanceCompleteProductionRequest {
id: "id".to_string(),
completed_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
downtime_hours: None,
cost: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**completed_date:** `String`
</dd>
</dl>
<dl>
<dd>
**downtime_hours:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cost:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">maintenance_cancel</a>(request: MaintenanceCancelProductionRequest) -> Result<MaintenanceCancelProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cancel a `planned` maintenance (409 when it is already completed or cancelled).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.maintenance_cancel(
&MaintenanceCancelProductionRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">maintenance_list</a>(request: MaintenanceListProductionRequest) -> Result<MaintenanceListProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List maintenance records. Filterable by `workCenterId`, `status` and `type`; sortable by `plannedDate` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.maintenance_list(
&MaintenanceListProductionRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<MaintenanceListProductionRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<MaintenanceListProductionRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">boms_create</a>(request: BomsCreateProductionRequest) -> Result<BomsCreateProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a bill of materials for a finished item. `outputQuantity` is the finished quantity made per unit of order quantity; each line's `quantity` is the component consumed per unit of order quantity, increased by its `scrapPercent` at completion; `routingId` is the default routing of assembly orders. A BOM that consumes its own finished item is refused with 422, a duplicate `code` with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.boms_create(
&BomsCreateProductionRequest {
code: "code".to_string(),
name: "name".to_string(),
finished_item_id: "finishedItemId".to_string(),
lines: vec![BomsCreateProductionRequestLinesItem {
component_item_id: "componentItemId".to_string(),
quantity: "121.0000".to_string(),
..Default::default()
}],
output_quantity: None,
routing_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**finished_item_id:** `String`
</dd>
</dl>
<dl>
<dd>
**output_quantity:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**routing_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<BomsCreateProductionRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">boms_get</a>(request: BomsGetProductionRequest) -> Result<BomsGetProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one bill of materials with its component lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.boms_get(
&BomsGetProductionRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">boms_list</a>(request: BomsListProductionRequest) -> Result<BomsListProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List bills of materials without their lines. Filterable by `code`, `name`, `finishedItemId` and `isActive`; sortable by `code` and `name`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.boms_list(
&BomsListProductionRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<BomsListProductionRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<BomsListProductionRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">orders_create</a>(request: OrdersCreateProductionRequest) -> Result<OrdersCreateProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft production order for `quantity` units of a BOM in a warehouse; stock moves only at `production/orders/complete`. An `assembly` order takes its routing from `routingId`, else from the BOM, and copies the routing's operations onto the order (`plannedMinutes` = setup minutes + run minutes per unit × finished quantity, priced at the work center's current `costPerHour`) with a pending quality check for every operation that names one. A `routingId` on a `disassembly` order, an inactive routing or a routing without operations is refused with 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.orders_create(
&OrdersCreateProductionRequest {
bom_id: "bomId".to_string(),
warehouse_id: "warehouseId".to_string(),
quantity: "121.0000".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
r#type: None,
routing_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `Option<OrdersCreateProductionRequestType>`
</dd>
</dl>
<dl>
<dd>
**bom_id:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `String`
</dd>
</dl>
<dl>
<dd>
**routing_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**quantity:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">orders_record_operation</a>(request: OrdersRecordOperationProductionRequest) -> Result<OrdersRecordOperationProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record the `actualMinutes` spent on one operation of a draft production order; at completion the actual minutes, else the planned ones, price the operation's labor cost. Refused with 409 once the order is completed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.orders_record_operation(
&OrdersRecordOperationProductionRequest {
id: "id".to_string(),
actual_minutes: "121.00".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**actual_minutes:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">quality_checks_add</a>(request: QualityChecksAddProductionRequest) -> Result<QualityChecksAddProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Add a pending quality check to a draft production order (409 once the order is completed). The order cannot complete while a check is pending.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.quality_checks_add(
&QualityChecksAddProductionRequest {
order_id: "orderId".to_string(),
name: "name".to_string(),
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**order_id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">quality_checks_record</a>(request: QualityChecksRecordProductionRequest) -> Result<QualityChecksRecordProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record the result of a quality check as `passed` or `failed`, with the time and the actor (409 once the order is completed). Only a `pending` check blocks `production/orders/complete`; a `failed` one does not.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.quality_checks_record(
&QualityChecksRecordProductionRequest {
id: "id".to_string(),
result: QualityChecksRecordProductionRequestResult::Passed,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**result:** `QualityChecksRecordProductionRequestResult`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">quality_checks_list</a>(request: QualityChecksListProductionRequest) -> Result<QualityChecksListProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List quality checks. Filterable by `orderId`, `result` and `name`; sortable by `createdAt` and `name`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.quality_checks_list(
&QualityChecksListProductionRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<QualityChecksListProductionRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<QualityChecksListProductionRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">orders_complete</a>(request: OrdersCompleteProductionRequest) -> Result<OrdersCompleteProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Complete a draft production order on the order's date. An `assembly` consumes the components FIFO from the warehouse (line quantity × order quantity, increased by `scrapPercent`), prices each operation at its actual or planned minutes × `costPerHour`, receives the finished item at material cost + labor cost less the share of `scrappedQuantity`, and, when there is labor, scrap or a component stock account other than the finished one, posts a journal entry debiting the finished stock account (and the `production.scrap` rule account for the scrapped share) and crediting the component stock accounts and the work centers' cost accounts (or the `production.laborApplied` rule account); a `disassembly` consumes the finished item and receives the components at its cost shared by quantity. `componentsAccountCode` and `finishedAccountCode` default to the chart's production accounts. Refused with 409 when the order is already completed, a quality check is still pending or the accounting period is locked, and with 422 when the BOM has no lines, `scrappedQuantity` is given on a disassembly or exceeds the finished quantity, the assembly cost is zero, stock is insufficient, a received item needs lot or serial tracking, or a posting account is missing. Emits `stock.changed`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.orders_complete(
&OrdersCompleteProductionRequest {
id: "id".to_string(),
scrapped_quantity: None,
components_account_code: None,
finished_account_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**scrapped_quantity:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**components_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**finished_account_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">orders_get</a>(request: OrdersGetProductionRequest) -> Result<OrdersGetProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one production order with its operations and quality checks.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.orders_get(
&OrdersGetProductionRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.production.<a href="/src/api/resources/production/client.rs">orders_list</a>(request: OrdersListProductionRequest) -> Result<OrdersListProductionResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List production orders without operations and quality checks. Filterable by `bomId`, `warehouseId`, `status` and `type`; sortable by `date` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.production
.orders_list(
&OrdersListProductionRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<OrdersListProductionRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<OrdersListProductionRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## ecommerce
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">orders_create</a>(request: OrdersCreateEcommerceRequest) -> Result<OrdersCreateEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a sales order from an online channel in status `new`. The customer is `partnerId` or `partner` details: with an `email` the existing partner with that e-mail is reused, otherwise a new partner is created; without either the call is refused with 422. `currency` defaults to the company's invoice currency, and `shipToCountryCode` and `marketplace` are kept for the VAT treatment of the invoice at fulfilment. A second order with the same `channel` and `externalRef` is refused with 409. Emits `sales_order.created`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.orders_create(
&OrdersCreateEcommerceRequest {
lines: vec![OrdersCreateEcommerceRequestLinesItem {
description: "description".to_string(),
quantity: "121.0000".to_string(),
unit_price_excl_vat: "121.0000".to_string(),
..Default::default()
}],
channel: None,
external_ref: None,
partner_id: None,
partner: None,
warehouse_id: None,
currency: None,
ship_to_country_code: None,
marketplace: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**channel:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**external_ref:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner:** `Option<OrdersCreateEcommerceRequestPartner>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**ship_to_country_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**marketplace:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<OrdersCreateEcommerceRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">orders_get</a>(request: OrdersGetEcommerceRequest) -> Result<OrdersGetEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one sales order with its lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.orders_get(
&OrdersGetEcommerceRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">orders_list</a>(request: OrdersListEcommerceRequest) -> Result<OrdersListEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List sales orders without their lines. Filterable by `channel`, `externalRef`, `partnerId` and `status`; sortable by `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.orders_list(
&OrdersListEcommerceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<OrdersListEcommerceRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<OrdersListEcommerceRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">orders_reserve</a>(request: OrdersReserveEcommerceRequest) -> Result<OrdersReserveEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Reserve stock for a `new` order in `warehouseId` (default: the order's warehouse; 422 when neither is set). Each product line, and each product component of a set line, is checked against the warehouse's on-hand quantity less the existing reservations; when any item is short the call is refused with 422 and nothing is reserved. Otherwise a reservation is written per stock line, `stock.changed` (change type `reserve`) is emitted for each, and the order becomes `reserved`. An order in another status is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.orders_reserve(
&OrdersReserveEcommerceRequest {
id: "id".to_string(),
warehouse_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">orders_fulfill</a>(request: OrdersFulfillEcommerceRequest) -> Result<OrdersFulfillEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Fulfil a `new` or `reserved` order: its reservations are released, the stock lines are consumed FIFO from the order's warehouse on `date` (default: the company's today), the cost of goods sold is posted as a journal entry debiting `cogsAccountCode` and crediting the stock accounts of the consumed layers (`inventoryAccountCode` when a layer has none), and a draft sale invoice for the order lines is created and linked as `invoiceId`, ready for `sales/invoices/issue`. With a `shipToCountryCode` on the order the invoice's VAT scheme is resolved for goods shipped there, as a marketplace sale when `marketplace` is set. Account codes default to the company's chart. Refused with 422 when the stock lines have no warehouse or stock is insufficient (unless the company allows negative stock), with 409 when the accounting period is locked or the order is already `fulfilled` or `cancelled`. Emits `sales_order.fulfilled` and `stock.changed`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.orders_fulfill(
&OrdersFulfillEcommerceRequest {
id: "id".to_string(),
date: None,
cogs_account_code: None,
inventory_account_code: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cogs_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**inventory_account_code:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">orders_cancel</a>(request: OrdersCancelEcommerceRequest) -> Result<OrdersCancelEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cancel an order that is not fulfilled: its stock reservations are released, `stock.changed` (change type `release`) is emitted for each, and the status becomes `cancelled`. A fulfilled order is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.orders_cancel(
&OrdersCancelEcommerceRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">products_list</a>(request: ProductsListEcommerceRequest) -> Result<ProductsListEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's items as a shop catalogue, in order of last update, with price and stock. `price` is the item's price in `priceListId` when given, else its own sale price, and `currency` that of the price list, else the company's invoice currency; `vatRatePercent` falls back to the rate of the item's VAT classifier. For a product `onHand`, `reserved` and `available` are summed over all warehouses or over `warehouseId` only; for a set `available` is the number of sets its product components can still make; for a service they are null. With `updatedSince` only items changed after that time are returned, deleted ones included (`deleted: true`), so a shop can sync incrementally; without it only live items are listed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.products_list(
&ProductsListEcommerceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**price_list_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**updated_since:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.ecommerce.<a href="/src/api/resources/ecommerce/client.rs">stock_list</a>(request: StockListEcommerceRequest) -> Result<StockListEcommerceResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Stock position per item and warehouse: `onHand`, `reserved` and their difference `available`, for all warehouses or `warehouseId` only. Only items with a positive quantity on hand are returned.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.ecommerce
.stock_list(
&StockListEcommerceRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## cash
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">orders_create</a>(request: OrdersCreateCashRequest) -> Result<OrdersCreateCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a numbered cash receipt (series `KPO`) or cash disbursement (`KIO`) and posts it in the base currency between the cash account (`cashAccountCode`, default the cash account of the company's chart) and `counterAccountCode`; a receipt debits the cash account, a disbursement credits it. Linked to an invoice - `saleInvoiceId` for a receipt against an issued invoice or advance invoice or a disbursement against an issued credit note, `purchaseInvoiceId` for a disbursement against a registered purchase invoice - the counter account is the receivable or payable account of the posting rules, the invoice's paid amount and payment status (`partial` or `paid`) are updated, and `sale_invoice.paid` or `purchase_invoice.paid` is emitted when the invoice becomes fully paid. Answers 422 when both invoice ids are given, a receipt names a purchase invoice, `counterAccountCode` differs from the invoice's account, or the invoice is in another currency or belongs to another partner; 409 when `amount` exceeds the invoice's remaining amount or the accounting period of `date` is locked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.orders_create(
&OrdersCreateCashRequest {
r#type: OrdersCreateCashRequestType::Receipt,
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
amount: "121.0000".to_string(),
purpose: "purpose".to_string(),
counter_account_code: None,
cash_account_code: None,
sale_invoice_id: None,
purchase_invoice_id: None,
series: None,
partner_id: None,
employee_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**type_:** `OrdersCreateCashRequestType`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**purpose:** `String`
</dd>
</dl>
<dl>
<dd>
**counter_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cash_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sale_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**purchase_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**series:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**employee_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">orders_get</a>(request: OrdersGetCashRequest) -> Result<OrdersGetCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns one cash order.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.orders_get(
&OrdersGetCashRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">orders_list</a>(request: OrdersListCashRequest) -> Result<OrdersListCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists cash orders. Filterable by `type`, `date`, `partnerId`, `employeeId`, `fullNumber` and `amount`; sortable by `date`, `fullNumber`, `createdAt` and `amount`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.orders_list(
&OrdersListCashRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<OrdersListCashRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<OrdersListCashRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">balance</a>(request: BalanceCashRequest) -> Result<BalanceCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns the balance of a cash account (default: the cash account of the company's chart) from the posted journal entries, up to and including `asOf` when given.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.balance(
&BalanceCashRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**cash_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**as_of:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">expense_reports_create</a>(request: ExpenseReportsCreateCashRequest) -> Result<ExpenseReportsCreateCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a numbered expense report (series `AA`) for the employee and posts it: each line's net amount is debited to its `accountCode` and the VAT total to the input VAT account of the posting rules (`purchases.vatReceivable`), or the gross amount to the line account when the company is not a VAT payer, and the total is credited to the cash advances account (`cash.advances`), which settles the employee's advance balance shown by `cash/advance-holders/balances`. Answers 422 when the total is zero or a line account is missing from the chart or not postable, and 409 when the accounting period of `date` is locked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.expense_reports_create(
&ExpenseReportsCreateCashRequest {
employee_id: "employeeId".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
lines: vec![ExpenseReportsCreateCashRequestLinesItem {
description: "description".to_string(),
account_code: "accountCode".to_string(),
net_amount: "121.00".to_string(),
..Default::default()
}],
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**employee_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<ExpenseReportsCreateCashRequestLinesItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">expense_reports_get</a>(request: ExpenseReportsGetCashRequest) -> Result<ExpenseReportsGetCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns one expense report with its lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.expense_reports_get(
&ExpenseReportsGetCashRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">expense_reports_list</a>(request: ExpenseReportsListCashRequest) -> Result<ExpenseReportsListCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists expense reports without their lines. Filterable by `employeeId` and `date`; sortable by `date` and `number`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.expense_reports_list(
&ExpenseReportsListCashRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ExpenseReportsListCashRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ExpenseReportsListCashRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.cash.<a href="/src/api/resources/cash/client.rs">advance_holders_balances</a>(request: AdvanceHoldersBalancesCashRequest) -> Result<AdvanceHoldersBalancesCashResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Returns, per employee, the cash advances issued to them (disbursements posted to the `cash.advances` account with the employee set), the amounts returned (receipts on the same account), the total settled by expense reports and the open balance (issued less returned less settled).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.cash
.advance_holders_balances(
&AdvanceHoldersBalancesCashRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## projects
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">create</a>(request: CreateProjectsRequest) -> Result<CreateProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a project; `partnerId` is the customer that `projects/time-entries/bill` invoices by default. A duplicate `code` is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.create(
&CreateProjectsRequest {
code: "code".to_string(),
name: "name".to_string(),
partner_id: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">update</a>(request: UpdateProjectsRequest) -> Result<UpdateProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a project's name, customer, `status` (`active`, `completed`, `archived`) or notes; only the fields sent are changed. An archived project accepts no new time entries.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.update(
&UpdateProjectsRequest {
id: "id".to_string(),
name: None,
partner_id: None,
status: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**status:** `Option<UpdateProjectsRequestStatus>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">get</a>(request: GetProjectsRequest) -> Result<GetProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one project.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.get(
&GetProjectsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">list</a>(request: ListProjectsRequest) -> Result<ListProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List projects. Filterable by `code`, `name`, `status` and `partnerId`; sortable by `code`, `name` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.list(
&ListProjectsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListProjectsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListProjectsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">time_entries_create</a>(request: TimeEntriesCreateProjectsRequest) -> Result<TimeEntriesCreateProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record hours worked on a project on a date, optionally for an employee and with the `hourlyRate` used when billing. `hours` must be positive (422); an archived project is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.time_entries_create(
&TimeEntriesCreateProjectsRequest {
project_id: "projectId".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
hours: "121.00".to_string(),
employee_id: None,
description: None,
billable: None,
hourly_rate: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**project_id:** `String`
</dd>
</dl>
<dl>
<dd>
**employee_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**hours:** `String`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**billable:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**hourly_rate:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">time_entries_update</a>(request: TimeEntriesUpdateProjectsRequest) -> Result<TimeEntriesUpdateProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a time entry; only the fields sent are changed. `hours` must be positive (422); an entry already billed to an invoice cannot be changed (409).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.time_entries_update(
&TimeEntriesUpdateProjectsRequest {
id: "id".to_string(),
date: None,
hours: None,
description: None,
billable: None,
hourly_rate: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**hours:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**billable:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**hourly_rate:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">time_entries_delete</a>(request: TimeEntriesDeleteProjectsRequest) -> Result<TimeEntriesDeleteProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a time entry (409 once it is billed).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.time_entries_delete(
&TimeEntriesDeleteProjectsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">time_entries_list</a>(request: TimeEntriesListProjectsRequest) -> Result<TimeEntriesListProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List time entries. Filterable by `projectId`, `employeeId`, `billable`, `billedInvoiceId` and `date`; sortable by `date`, `createdAt` and `hours`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.time_entries_list(
&TimeEntriesListProjectsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<TimeEntriesListProjectsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<TimeEntriesListProjectsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">time_entries_bill</a>(request: TimeEntriesBillProjectsRequest) -> Result<TimeEntriesBillProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft sale invoice from the project's unbilled billable time entries, optionally limited to `dateFrom` and `dateTo`, and mark them billed; needs the `sales:write` scope, and the invoice is issued with `sales/invoices/issue`. The customer is `partnerId`, else the project's partner (422 without either); each entry is priced at its own `hourlyRate`, else the call's `hourlyRate` (422 when an entry has neither); `groupBy` `rate` makes one line per rate with the summed hours, `entry` one line per entry; `itemId`, `vatRatePercent` and `vatClassifierCode` go onto every line. No matching entries is 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.time_entries_bill(
&TimeEntriesBillProjectsRequest {
project_id: "projectId".to_string(),
partner_id: None,
date_from: None,
date_to: None,
item_id: None,
hourly_rate: None,
vat_rate_percent: None,
vat_classifier_code: None,
issue_date: None,
due_date: None,
group_by: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**project_id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_to:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**item_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**hourly_rate:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_rate_percent:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_classifier_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**issue_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**due_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**group_by:** `Option<TimeEntriesBillProjectsRequestGroupBy>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.projects.<a href="/src/api/resources/projects/client.rs">report</a>(request: ReportProjectsRequest) -> Result<ReportProjectsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Profitability per project: `revenue` and `costs` from posted journal entries tagged with the project (income accounts credit less debit, expense accounts debit less credit), `profit` as their difference, and the hours from time entries (total, billable, billed, unbilled, and the unbilled amount at the entries' hourly rates). `projectId` limits the report to one project; `dateFrom` and `dateTo` limit the journal dates and the entry dates. Nothing is changed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.projects
.report(
&ReportProjectsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**project_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_to:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## transport
<details><summary><code>client.transport.<a href="/src/api/resources/transport/client.rs">waybills_create</a>(request: WaybillsCreateTransportRequest) -> Result<WaybillsCreateTransportResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a draft waybill to the consignee. The cargo lines are `lines` or, when none are given and `saleInvoiceId` is set, the product lines of that sale invoice (422 when it has none); a line without `description`, `unit` or `productCode` takes them from its item. `documentDate` defaults to the company's today and `series` to `VAZ`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.transport
.waybills_create(
&WaybillsCreateTransportRequest {
consignee_partner_id: "consigneePartnerId".to_string(),
dispatch_at: DateTime::parse_from_rfc3339("2024-01-15T09:30:00Z").unwrap(),
load_address: "loadAddress".to_string(),
unload_address: "unloadAddress".to_string(),
transporter_partner_id: None,
document_date: None,
estimated_arrival_at: None,
vehicle_plate: None,
trailer_plate: None,
driver_name: None,
driver_surname: None,
load_warehouse_id: None,
value_eur: None,
sale_invoice_id: None,
notes: None,
series: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**consignee_partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**transporter_partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**dispatch_at:** `String`
</dd>
</dl>
<dl>
<dd>
**estimated_arrival_at:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vehicle_plate:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**trailer_plate:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**driver_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**driver_surname:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**load_warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**load_address:** `String`
</dd>
</dl>
<dl>
<dd>
**unload_address:** `String`
</dd>
</dl>
<dl>
<dd>
**value_eur:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sale_invoice_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**series:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<WaybillsCreateTransportRequestLinesItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.transport.<a href="/src/api/resources/transport/client.rs">waybills_update</a>(request: WaybillsUpdateTransportRequest) -> Result<WaybillsUpdateTransportResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a draft waybill; omitted fields keep their value, the optional ones can be cleared with null, and `lines`, when given, replace all existing lines. A waybill that is already issued or cancelled is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.transport
.waybills_update(
&WaybillsUpdateTransportRequest {
id: "id".to_string(),
consignee_partner_id: None,
transporter_partner_id: None,
document_date: None,
dispatch_at: None,
estimated_arrival_at: None,
vehicle_plate: None,
trailer_plate: None,
driver_name: None,
driver_surname: None,
load_warehouse_id: None,
load_address: None,
unload_address: None,
value_eur: None,
sale_invoice_id: None,
notes: None,
series: None,
lines: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**consignee_partner_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**transporter_partner_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**document_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**dispatch_at:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**estimated_arrival_at:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vehicle_plate:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**trailer_plate:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**driver_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**driver_surname:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**load_warehouse_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**load_address:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**unload_address:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**value_eur:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**sale_invoice_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**series:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**lines:** `Option<Vec<WaybillsUpdateTransportRequestLinesItem>>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.transport.<a href="/src/api/resources/transport/client.rs">waybills_issue</a>(request: WaybillsIssueTransportRequest) -> Result<WaybillsIssueTransportResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Issue a draft waybill: it takes the next number of its `series` for the year of `documentDate` and becomes `issued`. Without a vehicle plate or without lines the call is refused with 422, a waybill that is not a draft with 409. Only issued waybills can go into the Lithuanian i.VAZ file (`declarations/lt/ivaz/generate`) and the Romanian e-Transport declaration (`declarations/ro/etransport/build`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.transport
.waybills_issue(
&WaybillsIssueTransportRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.transport.<a href="/src/api/resources/transport/client.rs">waybills_cancel</a>(request: WaybillsCancelTransportRequest) -> Result<WaybillsCancelTransportResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cancel a draft or issued waybill. An already cancelled one is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.transport
.waybills_cancel(
&WaybillsCancelTransportRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.transport.<a href="/src/api/resources/transport/client.rs">waybills_get</a>(request: WaybillsGetTransportRequest) -> Result<WaybillsGetTransportResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one waybill with its lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.transport
.waybills_get(
&WaybillsGetTransportRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.transport.<a href="/src/api/resources/transport/client.rs">waybills_list</a>(request: WaybillsListTransportRequest) -> Result<WaybillsListTransportResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List waybills with the consignee's name. Filterable by `status`, `consigneePartnerId`, `documentDate`, `fullNumber` and `dispatchAt`; sortable by `createdAt`, `dispatchAt` and `fullNumber`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.transport
.waybills_list(
&WaybillsListTransportRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<WaybillsListTransportRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<WaybillsListTransportRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## pos
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">devices_create</a>(request: DevicesCreatePosRequest) -> Result<DevicesCreatePosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Register a cash register (POS device). The serial number must be unique in the company; a repeat is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.devices_create(
&DevicesCreatePosRequest {
name: "name".to_string(),
serial_number: "serialNumber".to_string(),
model: None,
registration_number: None,
address: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**serial_number:** `String`
</dd>
</dl>
<dl>
<dd>
**model:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**registration_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">devices_update</a>(request: DevicesUpdatePosRequest) -> Result<DevicesUpdatePosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a POS device's details or set `isActive`; an inactive device accepts no new shifts or reports. A serial number already used by another device is refused with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.devices_update(
&DevicesUpdatePosRequest {
id: "id".to_string(),
is_active: None,
name: None,
serial_number: None,
model: None,
registration_number: None,
address: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**serial_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**model:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**registration_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">devices_list</a>(request: DevicesListPosRequest) -> Result<DevicesListPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List POS devices. Filterable by `name` and `serialNumber`; sortable by `name`, `serialNumber` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.devices_list(
&DevicesListPosRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<DevicesListPosRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<DevicesListPosRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">reports_create</a>(request: ReportsCreatePosRequest) -> Result<ReportsCreatePosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a daily cash register report (Z-report) and post it to the ledger in one journal entry: the cash and card takings are debited to `cashAccountCode` and `cardAccountCode`, the net of the `vatLines` is credited to `revenueAccountCode` and their VAT to `vatAccountCode`. `itemLines` write the sold products off `warehouseId` FIFO (a set is expanded to its product components) and add the cost of goods sold, debited to `cogsAccountCode` against the stock accounts. Account codes default to the company's chart. Refused with 422 when cash plus card differs from the gross total, the item lines have no warehouse or the device is inactive, with 409 when the accounting period is locked or the `reportNumber` already exists. Emits `pos_report.created` and, per item line, `stock.changed`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.reports_create(
&ReportsCreatePosRequest {
report_number: "reportNumber".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
vat_lines: vec![ReportsCreatePosRequestVatLinesItem {
vat_rate_percent: "121.00".to_string(),
net_amount: "121.0000".to_string(),
vat_amount: "121.0000".to_string(),
..Default::default()
}],
device_id: None,
warehouse_id: None,
cash_amount: None,
card_amount: None,
item_lines: None,
cash_account_code: None,
card_account_code: None,
revenue_account_code: None,
vat_account_code: None,
cogs_account_code: None,
inventory_account_code: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**report_number:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**device_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_lines:** `Vec<ReportsCreatePosRequestVatLinesItem>`
</dd>
</dl>
<dl>
<dd>
**cash_amount:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**card_amount:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**item_lines:** `Option<Vec<ReportsCreatePosRequestItemLinesItem>>`
</dd>
</dl>
<dl>
<dd>
**cash_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**card_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**revenue_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**cogs_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**inventory_account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">reports_get</a>(request: ReportsGetPosRequest) -> Result<ReportsGetPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one POS report with its VAT lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.reports_get(
&ReportsGetPosRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">reports_list</a>(request: ReportsListPosRequest) -> Result<ReportsListPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List POS reports without their VAT lines. Filterable by `date`, `reportNumber` and `deviceId`; sortable by `date`, `reportNumber` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.reports_list(
&ReportsListPosRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ReportsListPosRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ReportsListPosRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">shifts_open</a>(request: ShiftsOpenPosRequest) -> Result<ShiftsOpenPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Open a shift on a POS device with the cash float `openingCash`. A device has at most one open shift (409 for a second); an inactive device is refused with 422. Give `warehouseId` when the shift will sell stock items; they are written off that warehouse when the shift is closed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.shifts_open(
&ShiftsOpenPosRequest {
device_id: "deviceId".to_string(),
warehouse_id: None,
opening_cash: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**device_id:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**opening_cash:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">shifts_get</a>(request: ShiftsGetPosRequest) -> Result<ShiftsGetPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one POS shift.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.shifts_get(
&ShiftsGetPosRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">shifts_list</a>(request: ShiftsListPosRequest) -> Result<ShiftsListPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List POS shifts. Filterable by `deviceId` and `status`; sortable by `openedAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.shifts_list(
&ShiftsListPosRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ShiftsListPosRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ShiftsListPosRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">receipts_create</a>(request: ReceiptsCreatePosRequest) -> Result<ReceiptsCreatePosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a receipt in an open shift, numbered per shift from 1. Each line's net, VAT and gross come from its VAT-inclusive unit price; a line without `description` takes its item's name. Refused with 422 when cash plus card differs from the receipt total or a stock item is sold in a shift opened without a warehouse, with 409 when the shift is closed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.receipts_create(
&ReceiptsCreatePosRequest {
shift_id: "shiftId".to_string(),
lines: vec![ReceiptsCreatePosRequestLinesItem {
quantity: "121.0000".to_string(),
unit_price_incl_vat: "121.0000".to_string(),
vat_rate_percent: "121.00".to_string(),
..Default::default()
}],
cash_amount: None,
card_amount: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**shift_id:** `String`
</dd>
</dl>
<dl>
<dd>
**lines:** `Vec<ReceiptsCreatePosRequestLinesItem>`
</dd>
</dl>
<dl>
<dd>
**cash_amount:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**card_amount:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">receipts_list</a>(request: ReceiptsListPosRequest) -> Result<ReceiptsListPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List receipts without their lines. Filterable by `shiftId`; sortable by `number` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.receipts_list(
&ReceiptsListPosRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ReceiptsListPosRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ReceiptsListPosRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">receipts_get</a>(request: ReceiptsGetPosRequest) -> Result<ReceiptsGetPosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one receipt with its lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.receipts_get(
&ReceiptsGetPosRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.pos.<a href="/src/api/resources/pos/client.rs">shifts_close</a>(request: ShiftsClosePosRequest) -> Result<ShiftsClosePosResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Close an open shift: its receipts are summed by VAT rate and by product into one POS report, created as by `pos/reports/create` with number `reportNumber` (default `Z-<device serial>-<n>`, n being the device's closed shifts plus one) on `date` (default: the company's today), which posts the takings and the stock write-off to the ledger and emits `pos_report.created`. The response adds `expectedCash` (opening cash plus the cash receipts) and `cashDifference` (`countedCash` less expected). A shift without receipts is refused with 422, a closed one with 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.pos
.shifts_close(
&ShiftsClosePosRequest {
id: "id".to_string(),
counted_cash: "121.00".to_string(),
date: None,
report_number: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**counted_cash:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**report_number:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## calendar
<details><summary><code>client.calendar.<a href="/src/api/resources/calendar/client.rs">list</a>(request: ListCalendarRequest) -> Result<ListCalendarResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Lists, in due-date order, the filing deadlines Nordlet derives for the company from its country and profile together with the company's own events, between `from` and `to` (default 45 days back to 120 days ahead of the company's current date). Each deadline carries its submissions, whether it can be filed with `calendar/submit`, amended, or built with `calendar/download`, and whether its automation is on; `includeDone: false` leaves out the rows that are completed, submitted or accepted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.calendar
.list(
&ListCalendarRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**to:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**include_done:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.calendar.<a href="/src/api/resources/calendar/client.rs">get</a>(request: GetCalendarRequest) -> Result<GetCalendarResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Reads one calendar row by `key`: the id of a company event, or `ruleKey:period` for a filing deadline with its submissions.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.calendar
.get(
&GetCalendarRequest {
key: "key".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**key:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.calendar.<a href="/src/api/resources/calendar/client.rs">submit</a>(request: SubmitCalendarRequest) -> Result<SubmitCalendarResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
With amend: true the return is filed again as a correction of the one already submitted or accepted for the period; only returns whose format has a correction mark accept it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.calendar
.submit(
&SubmitCalendarRequest {
key: "key".to_string(),
amend: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**key:** `String`
</dd>
</dl>
<dl>
<dd>
**amend:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.calendar.<a href="/src/api/resources/calendar/client.rs">download</a>(request: DownloadCalendarRequest) -> Result<DownloadCalendarResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Builds the file of a deadline whose format Nordlet produces but whose administration takes it only through the company's own account or program. Nothing is sent and no filing is recorded.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.calendar
.download(
&DownloadCalendarRequest {
key: "key".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**key:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.calendar.<a href="/src/api/resources/calendar/client.rs">create</a>(request: CreateCalendarRequest) -> Result<CreateCalendarResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a company event (kind `custom`) with a title, a due date, notes and a done flag.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.calendar
.create(
&CreateCalendarRequest {
title: "title".to_string(),
due_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
notes: None,
done: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**title:** `String`
</dd>
</dl>
<dl>
<dd>
**due_date:** `String`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**done:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.calendar.<a href="/src/api/resources/calendar/client.rs">update</a>(request: UpdateCalendarRequest) -> Result<UpdateCalendarResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Changes a calendar row by `key`. A company event takes a new title, due date, notes or done flag; a filing deadline (`ruleKey:period`) takes only notes and done, keeps its own title and date, and gets a stored row the first time it is annotated.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.calendar
.update(
&UpdateCalendarRequest {
key: "key".to_string(),
title: None,
due_date: None,
notes: None,
done: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**key:** `String`
</dd>
</dl>
<dl>
<dd>
**title:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**due_date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**done:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.calendar.<a href="/src/api/resources/calendar/client.rs">delete</a>(request: DeleteCalendarRequest) -> Result<DeleteCalendarResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Deletes a company event by its id, or the stored notes and done mark of a filing deadline by `ruleKey:period`; the deadline itself still comes from the rules.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.calendar
.delete(
&DeleteCalendarRequest {
key: "key".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**key:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## audit
<details><summary><code>client.audit.<a href="/src/api/resources/audit/client.rs">list</a>(request: ListAuditRequest) -> Result<ListAuditResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the audit log of the company: who did what to which entity, with the recorded change in `diff`. Filterable by `action`, `entity`, `entityId`, `actorType` and `actorId`; sortable by `createdAt` and `id`, newest first by default.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.audit
.list(
&ListAuditRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListAuditRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListAuditRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## webhooks
<details><summary><code>client.webhooks.<a href="/src/api/resources/webhooks/client.rs">subscriptions_create</a>(request: SubscriptionsCreateWebhooksRequest) -> Result<SubscriptionsCreateWebhooksResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Register a webhook endpoint for the given event types (`*` for every event). The URL must be an https address that resolves to a public network (422 otherwise). The signing secret is generated unless `secret` is given, and this call is the only one that returns it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.webhooks
.subscriptions_create(
&SubscriptionsCreateWebhooksRequest {
url: "url".to_string(),
events: vec![
SubscriptionsCreateWebhooksRequestEventsItem::AgreementInvoiceGenerated,
],
secret: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**url:** `String`
</dd>
</dl>
<dl>
<dd>
**events:** `Vec<SubscriptionsCreateWebhooksRequestEventsItem>`
</dd>
</dl>
<dl>
<dd>
**secret:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.webhooks.<a href="/src/api/resources/webhooks/client.rs">subscriptions_list</a>(request: SubscriptionsListWebhooksRequest) -> Result<SubscriptionsListWebhooksResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's webhook subscriptions with their last delivery state. Filterable by `url` and `isActive`; sortable by `createdAt` and `url`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.webhooks
.subscriptions_list(
&SubscriptionsListWebhooksRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<SubscriptionsListWebhooksRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<SubscriptionsListWebhooksRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.webhooks.<a href="/src/api/resources/webhooks/client.rs">subscriptions_update</a>(request: SubscriptionsUpdateWebhooksRequest) -> Result<SubscriptionsUpdateWebhooksResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the URL, event types or `isActive` flag of a subscription; at least one field is required (400) and a new URL must be an https address that resolves to a public network (422). Setting `isActive` to true also clears `pausedAt` and `consecutiveFailures`, which is how a subscription paused after 5 failed deliveries in a row is switched back on.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.webhooks
.subscriptions_update(
&SubscriptionsUpdateWebhooksRequest {
id: "id".to_string(),
url: None,
events: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**url:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**events:** `Option<Vec<SubscriptionsUpdateWebhooksRequestEventsItem>>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.webhooks.<a href="/src/api/resources/webhooks/client.rs">subscriptions_delete</a>(request: SubscriptionsDeleteWebhooksRequest) -> Result<SubscriptionsDeleteWebhooksResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a webhook subscription.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.webhooks
.subscriptions_delete(
&SubscriptionsDeleteWebhooksRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.webhooks.<a href="/src/api/resources/webhooks/client.rs">deliveries_list</a>(request: DeliveriesListWebhooksRequest) -> Result<DeliveriesListWebhooksResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's webhook deliveries, newest first. Filterable by `status`, `eventType` and `subscriptionId`; sortable by `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.webhooks
.deliveries_list(
&DeliveriesListWebhooksRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<DeliveriesListWebhooksRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<DeliveriesListWebhooksRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.webhooks.<a href="/src/api/resources/webhooks/client.rs">deliveries_redeliver</a>(request: DeliveriesRedeliverWebhooksRequest) -> Result<DeliveriesRedeliverWebhooksResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Send a delivery again now: its status goes back to `pending` with the attempt count and last error cleared. Answers 409 when the subscription is inactive.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.webhooks
.deliveries_redeliver(
&DeliveriesRedeliverWebhooksRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## bank
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">accounts_create</a>(request: AccountsCreateBankRequest) -> Result<AccountsCreateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a bank, Stripe or broker account. `currency` defaults to the company base currency and `accountCode` to the default bank account of the chart of accounts. A `documentRef` also creates a bank agreement with that document attached. A Stripe account with an `iban` is refused with 422; an account with the same IBAN already existing answers 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.accounts_create(
&AccountsCreateBankRequest {
name: "name".to_string(),
r#type: None,
iban: None,
currency: None,
account_code: None,
document_ref: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<AccountsCreateBankRequestType>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_ref:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">accounts_list</a>(request: AccountsListBankRequest) -> Result<AccountsListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the bank accounts of the company. Filterable by name, type, iban and isActive; sortable by name and createdAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.accounts_list(
&AccountsListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<AccountsListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<AccountsListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">accounts_update</a>(request: AccountsUpdateBankRequest) -> Result<AccountsUpdateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the name, type, IBAN, ledger account code or active flag of a bank account. Setting type to stripe clears the IBAN, and sending an `iban` together with it is refused with 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.accounts_update(
&AccountsUpdateBankRequest {
id: "id".to_string(),
name: None,
r#type: None,
iban: None,
account_code: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<AccountsUpdateBankRequestType>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**account_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">transactions_import</a>(request: TransactionsImportBankRequest) -> Result<TransactionsImportBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Insert statement lines (up to 1000 per call) into a bank account as new transactions. A line without `currency` takes the account currency; a line in another currency is refused with 422. A line whose `externalId` is already on the account is skipped and counted in `skipped`. An incoming line that an active match rule (`bank/match-rules/create`) recognises is linked to its settlement batch.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.transactions_import(
&TransactionsImportBankRequest {
bank_account_id: "bankAccountId".to_string(),
transactions: vec![TransactionsImportBankRequestTransactionsItem {
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
amount: "-121.0000".to_string(),
..Default::default()
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**transactions:** `Vec<TransactionsImportBankRequestTransactionsItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">statements_import</a>(request: StatementsImportBankRequest) -> Result<StatementsImportBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Import a statement file into a bank account: camt.053 XML, MT940, a Stripe balance CSV or a Revolut Business CSV, chosen by `format` or by the type of `templateId` (an iso20022 template also takes MT940 content). Statements whose IBAN or currency differ from the account are left out; the call is refused with 422 when none remains, when a line is in another currency, when the file lacks the columns or elements the template requires or when it holds more than 50000 lines. Lines already on the account are skipped, and Stripe movements already posted through a settlement payout are skipped with a warning. With a template, the mapped fields are posted to their ledger accounts, partners are created, payments are matched to the invoices they reference, and invoices, credit notes or advance invoices are issued where the template asks for them (`invoiceMetaField`, `advanceInvoices`); `transfersCsv` posts the lender payouts and commissions of a Stripe template. Invoices issued this way are announced as `sale_invoice.issued`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.statements_import(
&StatementsImportBankRequest {
bank_account_id: "bankAccountId".to_string(),
content: "content".to_string(),
template_id: None,
format: None,
transfers_csv: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**template_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**format:** `Option<StatementsImportBankRequestFormat>`
</dd>
</dl>
<dl>
<dd>
**content:** `String`
</dd>
</dl>
<dl>
<dd>
**transfers_csv:** `Option<String>` — Stripe transfers export (plain CSV or base64) used to post lender payouts and commissions
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">transactions_list</a>(request: TransactionsListBankRequest) -> Result<TransactionsListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the bank transactions of the company. Filterable by id, bankAccountId, status, matchedDocumentId, date, amount, counterpartyIban, counterpartyName and externalId; sortable by date, createdAt and amount.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.transactions_list(
&TransactionsListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<TransactionsListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<TransactionsListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">transactions_match</a>(request: TransactionsMatchBankRequest) -> Result<TransactionsMatchBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Match one new bank transaction to a document: an issued sale invoice or advance for incoming money; an issued sale credit note, a registered purchase invoice or an approved payroll run (company currency only) for outgoing money. Posts the payment journal transaction between the bank account and the receivable, payable or net payable account, with any exchange difference on the gain or loss account, raises the paid amount of the document and sets the line to matched. `invoiceAmount` states the amount settled on an invoice in another currency; in the same currency it must equal the payment (422). Answers 409 when the line is already matched, when the amount exceeds the remaining balance of the document or when the accounting period of the line date is locked. A document that becomes fully paid is announced as `sale_invoice.paid` or `purchase_invoice.paid`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.transactions_match(
&TransactionsMatchBankRequest {
transaction_id: "transactionId".to_string(),
document_type: TransactionsMatchBankRequestDocumentType::SaleInvoice,
document_id: "documentId".to_string(),
invoice_amount: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**transaction_id:** `String`
</dd>
</dl>
<dl>
<dd>
**document_type:** `TransactionsMatchBankRequestDocumentType`
</dd>
</dl>
<dl>
<dd>
**document_id:** `String`
</dd>
</dl>
<dl>
<dd>
**invoice_amount:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">transactions_match_many</a>(request: TransactionsMatchManyBankRequest) -> Result<TransactionsMatchManyBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
The documents are issued sale invoices or advances for incoming money; issued sale credit notes, registered purchase invoices or approved payroll runs for outgoing money. Each must be in the currency of the payment, each allocation must be above zero, a document may appear once and the allocations must add up to the payment (422 otherwise). One journal transaction carries the bank entry, one entry per document and any exchange difference; the line is matched as an `invoice_allocation`. Answers 409 when the line is already matched, when an allocation exceeds the remaining balance of its document or when the accounting period of the line date is locked. Each document that becomes fully paid is announced as `sale_invoice.paid` or `purchase_invoice.paid`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.transactions_match_many(
&TransactionsMatchManyBankRequest {
transaction_id: "transactionId".to_string(),
allocations: vec![TransactionsMatchManyBankRequestAllocationsItem {
document_type:
TransactionsMatchManyBankRequestAllocationsItemDocumentType::SaleInvoice,
document_id: "documentId".to_string(),
amount: "121.0000".to_string(),
}],
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**transaction_id:** `String`
</dd>
</dl>
<dl>
<dd>
**allocations:** `Vec<TransactionsMatchManyBankRequestAllocationsItem>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">transactions_unmatch</a>(request: TransactionsUnmatchBankRequest) -> Result<TransactionsUnmatchBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Undo a match. A payment matched to an invoice, or a line posted by an import template, gets a reversing journal transaction dated date (default: today) and the invoice paid amount and payment status are restored; a line linked to a payment-provider settlement is only unlinked. The line returns to status new.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.transactions_unmatch(
&TransactionsUnmatchBankRequest {
transaction_id: "transactionId".to_string(),
date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**transaction_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">transactions_record</a>(request: TransactionsRecordBankRequest) -> Result<TransactionsRecordBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a payment that is on no imported statement: inserts a bank transaction on the account dated `date` (positive for a sale invoice, negative for a purchase invoice or payroll run, in the account currency) and matches it to the document with the checks, posting and `sale_invoice.paid` or `purchase_invoice.paid` event of `bank/transactions/match`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.transactions_record(
&TransactionsRecordBankRequest {
bank_account_id: "bankAccountId".to_string(),
date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
amount: "121.0000".to_string(),
document_type: TransactionsRecordBankRequestDocumentType::SaleInvoice,
document_id: "documentId".to_string(),
description: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `String`
</dd>
</dl>
<dl>
<dd>
**amount:** `String`
</dd>
</dl>
<dl>
<dd>
**description:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**document_type:** `TransactionsRecordBankRequestDocumentType`
</dd>
</dl>
<dl>
<dd>
**document_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">payments_export</a>(request: PaymentsExportBankRequest) -> Result<PaymentsExportBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build a SEPA credit transfer file (pain.001.001.03) that pays the remaining amount of each registered purchase invoice from the bank account on `executionDate` (default: today), to the partner's default bank account. The bank account needs an IBAN and every invoice must be in EUR and have a partner bank account on file (422 otherwise, see `partners/bank-accounts/create`); an invoice that is already paid answers 409. The file is returned as `xml`; nothing is posted or marked paid.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.payments_export(
&PaymentsExportBankRequest {
bank_account_id: "bankAccountId".to_string(),
purchase_invoice_ids: vec!["purchaseInvoiceIds".to_string()],
execution_date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**purchase_invoice_ids:** `Vec<String>`
</dd>
</dl>
<dl>
<dd>
**execution_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">import_templates_create</a>(request: ImportTemplatesCreateBankRequest) -> Result<ImportTemplatesCreateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
A template of type stripe, iso20022, revolut or bank_connection names the fields of the file or feed: a field with an `accountCode` is posted to that ledger account on import, a field with `createPartner` creates the customer, supplier or fee partner. `invoiceMetaField` is the Stripe metadata key (stripe) or the reference field (other types) by which payments are linked to invoices; with it `invoiceVatRatePercent`, `invoiceItemId` and, outside Stripe, `advanceInvoices` apply. `companyMetaField`, `lenderMetaField`, the operation types and the refund labels are for Stripe templates only. A template with the same name already existing answers 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.import_templates_create(
&ImportTemplatesCreateBankRequest {
name: "name".to_string(),
r#type: ImportTemplatesCreateBankRequestType::Stripe,
fields: None,
meta_fields: None,
invoice_meta_field: None,
invoice_vat_rate_percent: None,
company_meta_field: None,
invoice_item_id: None,
advance_invoices: None,
authorization_operation_type_id: None,
payout_operation_type_id: None,
commission_operation_type_id: None,
lender_meta_field: None,
partial_refund_label: None,
full_refund_label: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**type_:** `ImportTemplatesCreateBankRequestType`
</dd>
</dl>
<dl>
<dd>
**fields:** `Option<Vec<ImportTemplatesCreateBankRequestFieldsItem>>`
</dd>
</dl>
<dl>
<dd>
**meta_fields:** `Option<Vec<String>>`
</dd>
</dl>
<dl>
<dd>
**invoice_meta_field:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**invoice_vat_rate_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**company_meta_field:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**invoice_item_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**advance_invoices:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**authorization_operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**payout_operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**commission_operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**lender_meta_field:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**partial_refund_label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**full_refund_label:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">import_templates_update</a>(request: ImportTemplatesUpdateBankRequest) -> Result<ImportTemplatesUpdateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a company import template under the rules of `bank/import-templates/create`; a change of `type` re-checks the existing fields against the new type. Built-in templates cannot be changed. A name already used by another template answers 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.import_templates_update(
&ImportTemplatesUpdateBankRequest {
id: "id".to_string(),
name: None,
r#type: None,
fields: None,
meta_fields: None,
invoice_meta_field: None,
invoice_vat_rate_percent: None,
company_meta_field: None,
invoice_item_id: None,
advance_invoices: None,
authorization_operation_type_id: None,
payout_operation_type_id: None,
commission_operation_type_id: None,
lender_meta_field: None,
partial_refund_label: None,
full_refund_label: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**type_:** `Option<ImportTemplatesUpdateBankRequestType>`
</dd>
</dl>
<dl>
<dd>
**fields:** `Option<Vec<ImportTemplatesUpdateBankRequestFieldsItem>>`
</dd>
</dl>
<dl>
<dd>
**meta_fields:** `Option<Vec<String>>`
</dd>
</dl>
<dl>
<dd>
**invoice_meta_field:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**invoice_vat_rate_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**company_meta_field:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**invoice_item_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**advance_invoices:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**authorization_operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**payout_operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**commission_operation_type_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**lender_meta_field:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**partial_refund_label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**full_refund_label:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">import_templates_delete</a>(request: ImportTemplatesDeleteBankRequest) -> Result<ImportTemplatesDeleteBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a company import template. Built-in templates cannot be deleted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.import_templates_delete(
&ImportTemplatesDeleteBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">import_templates_get</a>(request: ImportTemplatesGetBankRequest) -> Result<ImportTemplatesGetBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one import template, a company one or a built-in one.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.import_templates_get(
&ImportTemplatesGetBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">import_templates_list_builtin</a>(request: ImportTemplatesListBuiltinBankRequest) -> Result<ImportTemplatesListBuiltinBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Today the Revolut Business template: the Revolut CSV fields, with fees, card payments and top-ups posted to the accounts of the posting rules, the sender and beneficiary names creating partners and the Reference column linking payments to invoices. The rows carry `builtin: true`, are readable with `bank/import-templates/get` and are not in `bank/import-templates/list`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.import_templates_list_builtin(
&ImportTemplatesListBuiltinBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">import_templates_list</a>(request: ImportTemplatesListBankRequest) -> Result<ImportTemplatesListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the import templates of the company (the built-in ones are under `bank/import-templates/list-builtin`). Filterable by name and type; sortable by name and createdAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.import_templates_list(
&ImportTemplatesListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ImportTemplatesListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ImportTemplatesListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">match_rules_create</a>(request: MatchRulesCreateBankRequest) -> Result<MatchRulesCreateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a rule that links incoming bank lines to the settlement batches of a payment provider when lines are imported and when a batch is posted. A line whose description, counterparty name or external id contains `pattern` (case-insensitive) is linked to the open batch of `provider` whose payout id follows `payoutIdPrefix` in the line text or, without a prefix, to the single open batch on the same bank account with the same currency and net amount and a payout date within `dateWindowDays` of the line date. `bankAccountId` limits the rule to one account.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.match_rules_create(
&MatchRulesCreateBankRequest {
name: "name".to_string(),
pattern: "pattern".to_string(),
provider: None,
payout_id_prefix: None,
bank_account_id: None,
date_window_days: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**provider:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**pattern:** `String`
</dd>
</dl>
<dl>
<dd>
**payout_id_prefix:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**bank_account_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_window_days:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">match_rules_update</a>(request: MatchRulesUpdateBankRequest) -> Result<MatchRulesUpdateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change a match rule; `payoutIdPrefix` and `bankAccountId` are cleared with null.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.match_rules_update(
&MatchRulesUpdateBankRequest {
id: "id".to_string(),
name: None,
provider: None,
pattern: None,
payout_id_prefix: None,
bank_account_id: None,
date_window_days: None,
is_active: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**provider:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**pattern:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**payout_id_prefix:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**bank_account_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**date_window_days:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_active:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">match_rules_delete</a>(request: MatchRulesDeleteBankRequest) -> Result<MatchRulesDeleteBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a match rule.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.match_rules_delete(
&MatchRulesDeleteBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">match_rules_list</a>(request: MatchRulesListBankRequest) -> Result<MatchRulesListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the match rules of the company, ordered by name.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.match_rules_list(
&MatchRulesListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">mandates_create</a>(request: MandatesCreateBankRequest) -> Result<MandatesCreateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record a SEPA direct debit mandate a partner has signed: debtor IBAN and BIC, scheme (CORE or B2B), recurrent or one-off, and the signature date. `reference` is the mandate reference written into the collection files; without one `MNDT-` followed by a generated id is used. `debtorName` defaults to the partner name. A reference already in use answers 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.mandates_create(
&MandatesCreateBankRequest {
partner_id: "partnerId".to_string(),
iban: "iban".to_string(),
signature_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
bic: None,
scheme: None,
sequence_type: None,
reference: None,
debtor_name: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**iban:** `String`
</dd>
</dl>
<dl>
<dd>
**bic:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**scheme:** `Option<MandatesCreateBankRequestScheme>`
</dd>
</dl>
<dl>
<dd>
**sequence_type:** `Option<MandatesCreateBankRequestSequenceType>`
</dd>
</dl>
<dl>
<dd>
**signature_date:** `String`
</dd>
</dl>
<dl>
<dd>
**reference:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**debtor_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">mandates_update</a>(request: MandatesUpdateBankRequest) -> Result<MandatesUpdateBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the BIC, debtor name or notes of a mandate.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.mandates_update(
&MandatesUpdateBankRequest {
id: "id".to_string(),
bic: None,
debtor_name: None,
notes: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bic:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**debtor_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**notes:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">mandates_cancel</a>(request: MandatesCancelBankRequest) -> Result<MandatesCancelBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cancel an active mandate. A mandate that is already cancelled or completed answers 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.mandates_cancel(
&MandatesCancelBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">mandates_get</a>(request: MandatesGetBankRequest) -> Result<MandatesGetBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one mandate. `expiresOn` is 36 months after the last collection, or after the signature date when nothing has been collected.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.mandates_get(
&MandatesGetBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">mandates_list</a>(request: MandatesListBankRequest) -> Result<MandatesListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the mandates of the company. Filterable by partnerId, status, scheme, reference and iban; sortable by createdAt and signatureDate.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.mandates_list(
&MandatesListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<MandatesListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<MandatesListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">direct_debits_candidates</a>(request: DirectDebitsCandidatesBankRequest) -> Result<DirectDebitsCandidatesBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the issued EUR sale invoices that are unpaid or partly paid and whose partner holds an active mandate, each with the mandate `bank/direct-debits/export` would use (the most recently signed active one). Filterable by partnerId, fullNumber, issueDate and dueDate; sortable by issueDate, dueDate, fullNumber, grossTotal and createdAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.direct_debits_candidates(
&DirectDebitsCandidatesBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<DirectDebitsCandidatesBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<DirectDebitsCandidatesBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">direct_debits_export</a>(request: DirectDebitsExportBankRequest) -> Result<DirectDebitsExportBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Build a SEPA direct debit file (pain.008.001.02) that collects the remaining amount of each issued EUR sale invoice into the bank account on `collectionDate` (default: today) under the partner's most recently signed active mandate. The bank account needs an IBAN and the company a valid `sepaCreditorId` (422, see `account/companies/update`); an invoice whose partner has no active mandate, or whose mandate expired (36 months without a collection), answers 422; an invoice already paid, or a one-off mandate asked to collect more than one invoice, answers 409. The sequence type is OOFF for a one-off mandate, FRST for the first collection under a recurrent one and RCUR after that. On success the collection count and last collection date of each mandate are advanced and a one-off mandate is completed; nothing is posted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.direct_debits_export(
&DirectDebitsExportBankRequest {
bank_account_id: "bankAccountId".to_string(),
sale_invoice_ids: vec!["saleInvoiceIds".to_string()],
collection_date: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**sale_invoice_ids:** `Vec<String>`
</dd>
</dl>
<dl>
<dd>
**collection_date:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">transactions_suggest_matches</a>(request: TransactionsSuggestMatchesBankRequest) -> Result<TransactionsSuggestMatchesBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Suggest documents for a new bank transaction: issued sale invoices and advances for incoming money; registered purchase invoices, issued sale credit notes and approved payroll runs for outgoing money. Candidates are unpaid documents whose remaining balance covers the payment (any balance when in another currency), scored by an equal remaining balance, the document number or payroll period in the payment description and a counterparty IBAN or name matching the partner or an employee on the run; the best `limit` come back with their reasons. A transaction that is already matched answers 409.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.transactions_suggest_matches(
&TransactionsSuggestMatchesBankRequest {
transaction_id: "transactionId".to_string(),
limit: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**transaction_id:** `String`
</dd>
</dl>
<dl>
<dd>
**limit:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_import</a>(request: SettlementsImportBankRequest) -> Result<SettlementsImportBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Import a Stripe payout report into settlement batches, one per payout: the itemized payout reconciliation CSV (`format` payout_reconciliation) or the unified payments export with its Transfer column (unified_payments); another CSV is refused with 422. Rows without a payout, the payout rows themselves and unsettled payments are skipped and counted. Each line is matched to an issued sale invoice through the references the report carries (the external reference of a sales order or an invoice number) or through a charge matched earlier. A payout already imported receives its new lines while the batch is in status imported and is skipped once posted; a payout mixing currencies answers 422. Emits `settlement.imported` for a new batch and `settlement.updated` for one that received lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_import(
&SettlementsImportBankRequest {
bank_account_id: "bankAccountId".to_string(),
content: "content".to_string(),
provider: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**provider:** `Option<SettlementsImportBankRequestProvider>`
</dd>
</dl>
<dl>
<dd>
**content:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_list</a>(request: SettlementsListBankRequest) -> Result<SettlementsListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the settlement batches with their line counts and the clearing figures against the bank lines. Filterable by provider, payoutId, status, currency and bankAccountId; sortable by payoutDate, createdAt and netTotal.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_list(
&SettlementsListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<SettlementsListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<SettlementsListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_get</a>(request: SettlementsGetBankRequest) -> Result<SettlementsGetBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one settlement batch with its lines, each with the invoice it is matched to and the bank line that cleared it (`clearingBooked`, `clearingDifference`, `clearingUnposted`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_get(
&SettlementsGetBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_match</a>(request: SettlementsMatchBankRequest) -> Result<SettlementsMatchBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Match a settlement line to an issued sale invoice or advance by hand (`matchStatus` manual), or clear the match with `invoiceId` null. Only lines of the categories charge, refund, dispute, dispute_reversal and partial_capture_reversal can be matched (422), and only while the batch is in status imported (409).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_match(
&SettlementsMatchBankRequest {
line_id: "lineId".to_string(),
invoice_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**line_id:** `String`
</dd>
</dl>
<dl>
<dd>
**invoice_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_commission</a>(request: SettlementsCommissionBankRequest) -> Result<SettlementsCommissionBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
A line with its own rate or amount is split with that value when the batch is posted. A line without one falls back to the commissionPercent given to the posting call, and without that the amount goes to the suspense account. Send both fields as null to clear the line back to the fallback.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_commission(
&SettlementsCommissionBankRequest {
line_id: "lineId".to_string(),
commission_percent: None,
commission_amount: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**line_id:** `String`
</dd>
</dl>
<dl>
<dd>
**commission_percent:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**commission_amount:** `Option<Option<String>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_link</a>(request: SettlementsLinkBankRequest) -> Result<SettlementsLinkBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Attach the incoming bank-statement line that carries this payout to the settlement batch.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_link(
&SettlementsLinkBankRequest {
id: "id".to_string(),
bank_transaction_id: "bankTransactionId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**bank_transaction_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_unlink</a>(request: SettlementsUnlinkBankRequest) -> Result<SettlementsUnlinkBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Detach the bank-statement line from the settlement batch and return the line to unmatched.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_unlink(
&SettlementsUnlinkBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">settlements_post</a>(request: SettlementsPostBankRequest) -> Result<SettlementsPostBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Post a settlement batch dated `date` (default: the payout date, else today): the bank account receives the net payout, the matched sale invoices are settled against the receivable (the receivable of each partner in a journal transaction of its own when invoices of several partners are settled), the provider fees, the marketplace commission and the seller payable are booked, and a payout in another currency is converted at the rate of that date with the exchange difference against each invoice's own rate on the gain or loss account. A line without a matched invoice is split by its own rate or amount, else by `commissionPercent`, else parked on the suspense account; a line already imported as a movement of a bank account is posted against that account instead. Answers 409 when the batch is already posted or the period is locked, 422 when it has no lines. The payout is linked to the bank line a match rule recognises. Emits `settlement.posted`, `sale_invoice.paid` for each invoice that becomes paid and `refund_liability.actual` for refunds of invoices carrying a refund liability.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.settlements_post(
&SettlementsPostBankRequest {
id: "id".to_string(),
date: None,
commission_percent: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**date:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**commission_percent:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">securities_import</a>(request: SecuritiesImportBankRequest) -> Result<SecuritiesImportBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Import an Interactive Brokers activity statement (CSV) into a bank account of type `broker`; refused with 422 for another account type, a file that is not an IBKR statement, a statement of a different IBKR account than the bank account already holds, or a trade older than the latest trade already imported (statements go in in date order). Rows already imported are skipped. Dividends, withholding tax, interest and fees are posted against the broker account; stock, option and futures trades are matched FIFO against the open lots and post the cost to `securities.investments` and the realised result to `securities.gain` or `securities.loss` (posting rules), one journal entry per date in the base currency at the rate of the day (422 without a rate, 409 when the date's period is locked). Deposits, corporate actions and currency conversions are stored as `not_posted` with a note.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.securities_import(
&SecuritiesImportBankRequest {
bank_account_id: "bankAccountId".to_string(),
content: "content".to_string(),
file_name: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**bank_account_id:** `String`
</dd>
</dl>
<dl>
<dd>
**content:** `String`
</dd>
</dl>
<dl>
<dd>
**file_name:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">securities_list</a>(request: SecuritiesListBankRequest) -> Result<SecuritiesListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the securities imports, newest first; filterable by `bankAccountId` and `brokerAccount`, sortable by `createdAt` and `realizedTotal`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.securities_list(
&SecuritiesListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<SecuritiesListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<SecuritiesListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">securities_get</a>(request: SecuritiesGetBankRequest) -> Result<SecuritiesGetBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one securities import with its operations in date order, each with its posting status, its amounts in the base currency and the journal transaction it was posted in.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.securities_get(
&SecuritiesGetBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">securities_operations_list</a>(request: SecuritiesOperationsListBankRequest) -> Result<SecuritiesOperationsListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the imported securities operations, newest first; filterable by `bankAccountId`, `kind`, `status`, `symbol` and `date`, sortable by `date` and `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.securities_operations_list(
&SecuritiesOperationsListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<SecuritiesOperationsListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<SecuritiesOperationsListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_banks_list</a>(request: FeedsBanksListBankRequest) -> Result<FeedsBanksListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read from the bank-feed provider configured on the API server or in platform settings (Enable Banking or an HTTP bridge, named in `provider`), for one `country` or all. Without a provider the call answers 503.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_banks_list(
&FeedsBanksListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**country:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_connections_start</a>(request: FeedsConnectionsStartBankRequest) -> Result<FeedsConnectionsStartBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Creates a pending bank connection and asks the provider for the authorization page of the bank. `url` is where the user authorizes access for `validForDays` (default 90); `reference` is the state the bank sends back and what `bank/feeds/connections/complete` takes. `redirectUrl` falls back to the one in platform settings, and the call is refused with 422 when neither is set.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_connections_start(
&FeedsConnectionsStartBankRequest {
aspsp_name: "aspspName".to_string(),
aspsp_country: "aspspCountry".to_string(),
psu_type: None,
redirect_url: None,
valid_for_days: None,
language: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**aspsp_name:** `String`
</dd>
</dl>
<dl>
<dd>
**aspsp_country:** `String`
</dd>
</dl>
<dl>
<dd>
**psu_type:** `Option<FeedsConnectionsStartBankRequestPsuType>`
</dd>
</dl>
<dl>
<dd>
**redirect_url:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**valid_for_days:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**language:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_connections_complete</a>(request: FeedsConnectionsCompleteBankRequest) -> Result<FeedsConnectionsCompleteBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Exchanges `code` for a provider session, sets the connection to active with the consent expiry the bank reports, and records every account of the session as a bank-feed account, not yet linked to a ledger account (`bank/feeds/accounts/link`). A connection that is already active answers 409. When the provider refuses the code the connection goes to status error with the message in `error`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_connections_complete(
&FeedsConnectionsCompleteBankRequest {
reference: "reference".to_string(),
code: "code".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**reference:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_connections_get</a>(request: FeedsConnectionsGetBankRequest) -> Result<FeedsConnectionsGetBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read one bank connection with its bank-feed accounts.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_connections_get(
&FeedsConnectionsGetBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_connections_list</a>(request: FeedsConnectionsListBankRequest) -> Result<FeedsConnectionsListBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the bank connections of the company, without their accounts. Filterable by status, provider and aspspCountry; sortable by createdAt and lastSyncedAt.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_connections_list(
&FeedsConnectionsListBankRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<FeedsConnectionsListBankRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<FeedsConnectionsListBankRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_connections_delete</a>(request: FeedsConnectionsDeleteBankRequest) -> Result<FeedsConnectionsDeleteBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Closes the provider session when the connection has one and a provider is configured (a failure at the bank does not stop the call), then deletes the connection and its bank-feed accounts. The ledger bank accounts and the transactions already imported stay.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_connections_delete(
&FeedsConnectionsDeleteBankRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_accounts_link</a>(request: FeedsAccountsLinkBankRequest) -> Result<FeedsAccountsLinkBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Give exactly one of `bankAccountId` (an existing ledger bank account) or `createBankAccount` (a new one with the IBAN and currency of the feed account; `accountCode` defaults to the default bank account of the chart of accounts). `syncFrom` is the date the first sync starts from; without it the first sync covers the last 90 days.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_accounts_link(
&FeedsAccountsLinkBankRequest {
id: "id".to_string(),
bank_account_id: None,
create_bank_account: None,
sync_from: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**bank_account_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**create_bank_account:** `Option<FeedsAccountsLinkBankRequestCreateBankAccount>`
</dd>
</dl>
<dl>
<dd>
**sync_from:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_accounts_configure</a>(request: FeedsAccountsConfigureBankRequest) -> Result<FeedsAccountsConfigureBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
`importTemplateId` must be a template of type bank_connection, or null to apply none. `syncSchedule` is manual, daily, weekly or monthly; every account whose schedule is not manual is synced by Nordlet when it is due. At least one of the two must be given.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_accounts_configure(
&FeedsAccountsConfigureBankRequest {
id: "id".to_string(),
import_template_id: None,
sync_schedule: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**import_template_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**sync_schedule:** `Option<FeedsAccountsConfigureBankRequestSyncSchedule>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.bank.<a href="/src/api/resources/bank/client.rs">feeds_sync</a>(request: FeedsSyncBankRequest) -> Result<FeedsSyncBankResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Fetches the transactions of every linked bank-feed account of the connection, or of `feedAccountId` alone, from `dateFrom` (default: seven days before the last sync, else the `syncFrom` of the account, else 90 days back) to `dateTo`, and inserts the new ones into the linked ledger bank account; lines already there count as `skipped`. An import template set on the account is applied as in `bank/statements/import`. Answers 409 when the connection is not active or has no session, and when the bank returns more than 20 pages for the range (keep `dateFrom` and set an earlier `dateTo`). A provider failure is written to the `error` of the connection, and one that is not retryable sets its status to error. The outcome is announced as `bank_feed.synced`, and invoices the template issues as `sale_invoice.issued`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.bank
.feeds_sync(
&FeedsSyncBankRequest {
connection_id: "connectionId".to_string(),
feed_account_id: None,
date_from: None,
date_to: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**connection_id:** `String`
</dd>
</dl>
<dl>
<dd>
**feed_account_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_from:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**date_to:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## files
<details><summary><code>client.files.<a href="/src/api/resources/files/client.rs">upload</a>(request: UploadFilesRequest) -> Result<UploadFilesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Store a base64-encoded file of up to 10 MB (413 above that) under an `entity` and optional `entityId`, and return its record with the SHA-256 of the content and its `storageKey`, which other calls take as `documentRef`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.files
.upload(
&UploadFilesRequest {
entity: "entity".to_string(),
file_name: "fileName".to_string(),
mime_type: "mimeType".to_string(),
content: "content".to_string(),
entity_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**entity:** `String`
</dd>
</dl>
<dl>
<dd>
**entity_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**file_name:** `String`
</dd>
</dl>
<dl>
<dd>
**mime_type:** `String` — Stored as the bare media type; only PNG, JPEG, GIF, WebP and PDF files are shown in the browser, every other type is downloaded
</dd>
</dl>
<dl>
<dd>
**content:** `String` — Base64-encoded file content
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.files.<a href="/src/api/resources/files/client.rs">get</a>(request: GetFilesRequest) -> Result<GetFilesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return a file record with its content, base64-encoded.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.files
.get(
&GetFilesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.files.<a href="/src/api/resources/files/client.rs">list</a>(request: ListFilesRequest) -> Result<ListFilesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's files. Filterable by `entity`, `entityId` and `fileName`; sortable by `createdAt`, `fileName` and `sizeBytes`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.files
.list(
&ListFilesRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<ListFilesRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<ListFilesRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.files.<a href="/src/api/resources/files/client.rs">delete</a>(request: DeleteFilesRequest) -> Result<DeleteFilesResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a file record and its stored content.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.files
.delete(
&DeleteFilesRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## reports
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">trial_balance</a>(request: TrialBalanceReportsRequest) -> Result<TrialBalanceReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Trial balance of the posted ledger for a period: for every account with an opening balance or movement, the balance before `fromDate`, the debit and credit turnover between `fromDate` and `toDate`, and the closing balance, with debit and credit totals. Template account names follow the `Accept-Language` header.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.trial_balance(
&TrialBalanceReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">size_category</a>(request: SizeCategoryReportsRequest) -> Result<SizeCategoryReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Classify the company's size for a calendar year as micro, small, medium or large from total assets at the year end, the net turnover of the year and the average number of employees under employment contracts, against the limits returned in `thresholds`; a category applies when at least two of its three limits are met. This is the default category of `reports/financial-statements`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.size_category(&SizeCategoryReportsRequest { year: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**year:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">financial_statements</a>(request: FinancialStatementsReportsRequest) -> Result<FinancialStatementsReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Balance sheet at `toDate` and profit and loss for the period from the posted ledger, year-end closing entries excluded, laid out by size category: `category` when given, else the one `reports/size-category` derives for the period. Micro gets the short balance sheet and profit and loss; the other categories add the balance sheet and profit and loss detail; medium and large also get the changes in equity and a cash flow summary. Line groupings follow the company's chart template.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.financial_statements(
&FinancialStatementsReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
category: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**category:** `Option<FinancialStatementsReportsRequestCategory>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">general_journal</a>(request: GeneralJournalReportsRequest) -> Result<GeneralJournalReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Posted journal transactions of a period in date order, each with its lines (account, debit, credit), paged with `page` and `pageSize` and the total count. Template account names follow the `Accept-Language` header.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.general_journal(
&GeneralJournalReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
page: None,
page_size: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">gl_detail</a>(request: GlDetailReportsRequest) -> Result<GlDetailReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Ledger card of one account for a period: the opening balance before `fromDate`, every posted line in date order with a running balance, and the closing balance.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.gl_detail(
&GlDetailReportsRequest {
account_code: "accountCode".to_string(),
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**account_code:** `String`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">partner_balances</a>(request: PartnerBalancesReportsRequest) -> Result<PartnerBalancesReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Open balance per partner: receivables from issued sale invoices and payables from registered purchase invoices that are not fully paid, credit notes reducing the balance, converted to the base currency at the document rate, with totals.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.partner_balances(
&PartnerBalancesReportsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">debt_aging</a>(request: DebtAgingReportsRequest) -> Result<DebtAgingReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Ageing of the open receivables or payables (`side`) at `asOf` (default the company's current date) per partner: not yet due, 1 to 30, 31 to 60, 61 to 90 and over 90 days past the due date. Counts documents dated on or before `asOf` and payments made up to that date.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.debt_aging(
&DebtAgingReportsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**side:** `Option<DebtAgingReportsRequestSide>`
</dd>
</dl>
<dl>
<dd>
**as_of:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">monthly_summary</a>(request: MonthlySummaryReportsRequest) -> Result<MonthlySummaryReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
One row per calendar month for the last `months` months ending with the current one: the receivable and payable balances at the end of the month and the revenue, expenses and net result posted in it, year-end closing entries excluded.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.monthly_summary(
&MonthlySummaryReportsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**months:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">stock_balance</a>(request: StockBalanceReportsRequest) -> Result<StockBalanceReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Quantity and value on hand per item and warehouse at `asOf`, summed from the stock movements dated on or before it; `warehouseId` limits the report to one warehouse. Rows with zero quantity and zero value are left out.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.stock_balance(
&StockBalanceReportsRequest {
as_of: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
warehouse_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**as_of:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">stock_movement</a>(request: StockMovementReportsRequest) -> Result<StockMovementReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Stock movement per item for a period: opening quantity and value before `fromDate`, quantities and values received and issued between `fromDate` and `toDate`, and the closing figures; `warehouseId` and `itemId` narrow the report.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.stock_movement(
&StockMovementReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
warehouse_id: None,
item_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**item_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">vat_summary</a>(request: VatSummaryReportsRequest) -> Result<VatSummaryReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
VAT of issued sale invoices (by issue date) or registered purchase invoices (by registration date) in a period, summed per VAT rate: net, VAT and gross in the base currency and the number of documents, credit notes counting negative. The rows of `reports/vat-detail` grouped by rate.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.vat_summary(
&VatSummaryReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
side: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**side:** `Option<VatSummaryReportsRequestSide>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">cash_flow</a>(request: CashFlowReportsRequest) -> Result<CashFlowReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cash flow statement of a period from the posted transactions that touch a cash account: the inflow and outflow of every counterpart account, grouped into operating, investing and financing by the account prefixes of the company's chart template, with opening and closing cash and `balanced` telling whether opening cash plus the net change equals closing cash. Template account names follow the `Accept-Language` header.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.cash_flow(
&CashFlowReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">stock_aging</a>(request: StockAgingReportsRequest) -> Result<StockAgingReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Age of the stock on hand at `asOf` per item and warehouse: the remaining quantity and value of each FIFO receipt layer, bucketed by days since the receipt (0 to 30, 31 to 60, 61 to 90, over 90), with totals; `warehouseId` limits the report to one warehouse. When movements after `asOf` exist, the layers are rebuilt by replaying the movements up to that date.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.stock_aging(
&StockAgingReportsRequest {
as_of: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
warehouse_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**as_of:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">stock_shortage</a>(request: StockShortageReportsRequest) -> Result<StockShortageReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Items whose reserved quantity exceeds the quantity on hand, per warehouse: on hand, reserved and the shortage. Only items with a reservation are checked; `warehouseId` limits the report to one warehouse.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.stock_shortage(
&StockShortageReportsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">sie</a>(request: SieReportsRequest) -> Result<SieReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Export the ledger of one financial year as an SIE file (the Swedish standard accounting interchange format, specification 4B). The file carries the chart of accounts, the opening and closing balance of every balance sheet account and the turnover of every result account for the year and the year before it, and, when asked for, every posted voucher of the year with its lines. Cost centres travel as dimension 1 and projects as dimension 6. Services that build a Swedish annual report read this file.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.sie(
&SieReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
include_transactions: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**include_transactions:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">datev</a>(request: DatevReportsRequest) -> Result<DatevReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Export the posted ledger of a period as a DATEV Buchungsstapel file (DATEV format, category 21, version 700). Every transaction becomes one or more bookings of an amount between an account and a contra account; a transaction with more than two lines is split into pairs whose totals match it. The file is semicolon separated and written in the Windows-1252 character set DATEV expects.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.datev(
&DatevReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
consultant_number: None,
client_number: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**consultant_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**client_number:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">fec</a>(request: FecReportsRequest) -> Result<FecReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Export the posted ledger of a period as a French FEC file (fichier des écritures comptables, order of 29 July 2013). One line per journal entry line, with the eighteen fields the order names, in their order, after a header line. Tab separated, UTF-8, comma as the decimal separator.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.fec(
&FecReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">eu_purchases</a>(request: EuPurchasesReportsRequest) -> Result<EuPurchasesReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Registered purchase invoices of a period (by registration date) from partners in another EU country, summed per partner country and VAT rate: net and VAT in the base currency and the number of documents, credit notes counting negative. The partner's country is the country code of its address, else the first two characters of its VAT number.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.eu_purchases(
&EuPurchasesReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">vat_detail</a>(request: VatDetailReportsRequest) -> Result<VatDetailReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
VAT of issued sale invoices (by issue date) or registered purchase invoices (by registration date) in a period, one row per document and VAT rate: net, VAT and gross in the base currency, with totals; credit notes count negative. `reports/vat-summary` groups these rows by rate.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.vat_detail(
&VatDetailReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
side: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**side:** `Option<VatDetailReportsRequestSide>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">pos_sales</a>(request: PosSalesReportsRequest) -> Result<PosSalesReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
POS reports of a period (by report date): per report the net, VAT, gross, cash and card amounts and the cost of goods sold, the net and VAT per VAT rate across the reports, and totals.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.pos_sales(
&PosSalesReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">online_sales</a>(request: OnlineSalesReportsRequest) -> Result<OnlineSalesReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Sales orders created in a period, grouped by channel and currency: the number of orders, how many are fulfilled, cancelled or still open (new or reserved), and the net and gross of the orders that are not cancelled, computed from their lines.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.online_sales(
&OnlineSalesReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">oss</a>(request: OssReportsRequest) -> Result<OssReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Issued sale invoices and credit notes of a period (by issue date) to partners in another EU country, summed per partner country and VAT rate: net and VAT in the base currency and the number of documents. The partner's country is the country code of its address, else the first two characters of its VAT number.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.oss(
&OssReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">advance_reconciliation</a>(request: AdvanceReconciliationReportsRequest) -> Result<AdvanceReconciliationReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Cash advances per employee for a period: the balance before `fromDate`, the advances paid out and returned through cash orders in the period, the amount settled by expense reports dated in the period, and the closing balance. A cash order counts as an advance when it names an employee and its counter account is the `cash.advances` posting rule.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.advance_reconciliation(
&AdvanceReconciliationReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">write_off_acts</a>(request: WriteOffActsReportsRequest) -> Result<WriteOffActsReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Stock issued by write-offs and stock takes in a period: one row per outgoing movement with item, warehouse, quantity, cost and notes, and the total cost; `warehouseId` limits the report to one warehouse.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.write_off_acts(
&WriteOffActsReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
warehouse_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**warehouse_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">cost_centers</a>(request: CostCentersReportsRequest) -> Result<CostCentersReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Income, expenses and result per cost centre for a period, from the posted journal lines assigned to a cost centre.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.cost_centers(
&CostCentersReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">cost_center_activity</a>(request: CostCenterActivityReportsRequest) -> Result<CostCenterActivityReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Posted journal lines of one cost centre for a period, summed per account: debit, credit and net. Template account names follow the `Accept-Language` header.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.cost_center_activity(
&CostCenterActivityReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
cost_center_id: "costCenterId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**cost_center_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">cost_center_items</a>(request: CostCenterItemsReportsRequest) -> Result<CostCenterItemsReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Net purchases per cost centre and item for a period, from the lines of registered purchase invoices (by registration date) that carry a cost centre, credit notes counting negative; `costCenterId` limits the report to one cost centre. A line without an item is reported under its description.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.cost_center_items(
&CostCenterItemsReportsRequest {
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
cost_center_id: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**cost_center_id:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">jobs_create</a>(request: JobsCreateReportsRequest) -> Result<JobsCreateReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Queue a report to be built in the background in one or more formats (`json`, `xlsx`, `pdf`) and stored as files; the job is returned at once with status `queued`. `reportType` is one of trial-balance, partner-balances, debt-aging, stock-balance, vat-summary, vat-detail, eu-purchases, oss, pos-sales, online-sales, advance-reconciliation, write-off-acts, cost-centers, cost-center-activity, cost-center-items and cash-flow, and `params` is the body of that report route; an unknown type or invalid params are refused with 422. Follow the job with `reports/jobs/get`, download its outputs with `files/get`, and listen for `report.completed` or `report.failed`; a report that does not finish within ten minutes fails.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.jobs_create(
&JobsCreateReportsRequest {
report_type: "reportType".to_string(),
params: None,
formats: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**report_type:** `String`
</dd>
</dl>
<dl>
<dd>
**params:** `Option<std::collections::HashMap<String, serde_json::Value>>`
</dd>
</dl>
<dl>
<dd>
**formats:** `Option<Vec<JobsCreateReportsRequestFormatsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">jobs_get</a>(request: JobsGetReportsRequest) -> Result<JobsGetReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one report job with its status (`queued`, `running`, `completed` or `failed`), the error of a failed job and the output files of a completed one.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.jobs_get(
&JobsGetReportsRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.reports.<a href="/src/api/resources/reports/client.rs">jobs_list</a>(request: JobsListReportsRequest) -> Result<JobsListReportsResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the company's report jobs, newest first; filterable by `status` and `reportType`, sortable by `createdAt`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.reports
.jobs_list(
&JobsListReportsRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**page:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sort:** `Option<Vec<JobsListReportsRequestSortItem>>`
</dd>
</dl>
<dl>
<dd>
**filter:** `Option<Vec<JobsListReportsRequestFilterItem>>`
</dd>
</dl>
<dl>
<dd>
**totals:** `Option<Vec<String>>` — Numeric fields to sum over every row matching the filter (not only the current page)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## consolidation
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">groups_create</a>(request: GroupsCreateConsolidationRequest) -> Result<GroupsCreateConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a consolidation group owned by the calling company; `presentationCurrency` defaults to the company's base currency. Members are added with `consolidation/members/add`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.groups_create(
&GroupsCreateConsolidationRequest {
name: "name".to_string(),
presentation_currency: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**presentation_currency:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">groups_list</a>(request: GroupsListConsolidationRequest) -> Result<GroupsListConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the calling company's consolidation groups with their member counts.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.groups_list(
&GroupsListConsolidationRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">groups_get</a>(request: GroupsGetConsolidationRequest) -> Result<GroupsGetConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return one consolidation group with its members, each with its ownership percentage and consolidation method.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.groups_get(
&GroupsGetConsolidationRequest {
group_id: "groupId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">groups_update</a>(request: GroupsUpdateConsolidationRequest) -> Result<GroupsUpdateConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Rename a consolidation group or change its presentation currency.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.groups_update(
&GroupsUpdateConsolidationRequest {
group_id: "groupId".to_string(),
name: None,
presentation_currency: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**presentation_currency:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">groups_delete</a>(request: GroupsDeleteConsolidationRequest) -> Result<GroupsDeleteConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a consolidation group.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.groups_delete(
&GroupsDeleteConsolidationRequest {
group_id: "groupId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">members_add</a>(request: MembersAddConsolidationRequest) -> Result<MembersAddConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Add a company to a consolidation group with its ownership percentage and method (`full`, `proportional` or `equity`), or change those of an existing member. Another company can be added only by a signed-in user who is owner, admin or accountant of it; an API key is refused with 403.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.members_add(
&MembersAddConsolidationRequest {
group_id: "groupId".to_string(),
member_company_id: "memberCompanyId".to_string(),
ownership_percent: None,
method: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**member_company_id:** `String`
</dd>
</dl>
<dl>
<dd>
**ownership_percent:** `Option<f64>`
</dd>
</dl>
<dl>
<dd>
**method:** `Option<MembersAddConsolidationRequestMethod>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">members_remove</a>(request: MembersRemoveConsolidationRequest) -> Result<MembersRemoveConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Remove a company from a consolidation group.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.members_remove(
&MembersRemoveConsolidationRequest {
group_id: "groupId".to_string(),
member_company_id: "memberCompanyId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**member_company_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">intercompany_candidates</a>(request: IntercompanyCandidatesConsolidationRequest) -> Result<IntercompanyCandidatesConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Partners in member companies that look like other members of the same group (matched on company code or VAT code), with any existing intercompany link. Confirming a candidate via intercompany/links/set enables invoice mirroring.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.intercompany_candidates(
&IntercompanyCandidatesConsolidationRequest {
group_id: "groupId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">intercompany_links_set</a>(request: IntercompanyLinksSetConsolidationRequest) -> Result<IntercompanyLinksSetConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Confirm that a partner record in one member company represents another member company of the group. Once links exist in both directions, issuing an intercompany sale invoice automatically creates the matching draft purchase invoice in the counterparty.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.intercompany_links_set(
&IntercompanyLinksSetConsolidationRequest {
group_id: "groupId".to_string(),
partner_id: "partnerId".to_string(),
counterparty_company_id: "counterpartyCompanyId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**partner_id:** `String`
</dd>
</dl>
<dl>
<dd>
**counterparty_company_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">intercompany_links_list</a>(request: IntercompanyLinksListConsolidationRequest) -> Result<IntercompanyLinksListConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the intercompany links of a group: which partner record of which member company stands for which other member company.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.intercompany_links_list(
&IntercompanyLinksListConsolidationRequest {
group_id: "groupId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">intercompany_links_remove</a>(request: IntercompanyLinksRemoveConsolidationRequest) -> Result<IntercompanyLinksRemoveConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Remove an intercompany link from a group.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.intercompany_links_remove(
&IntercompanyLinksRemoveConsolidationRequest {
group_id: "groupId".to_string(),
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">intercompany_report</a>(request: IntercompanyReportConsolidationRequest) -> Result<IntercompanyReportConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Intercompany reconciliation for a period: every issued intercompany sale invoice with its mirrored or manually recorded counterpart, unmatched documents on both sides, and per-currency totals with differences. Confirmed pairs are the basis for consolidation eliminations.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.intercompany_report(
&IntercompanyReportConsolidationRequest {
group_id: "groupId".to_string(),
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.consolidation.<a href="/src/api/resources/consolidation/client.rs">report</a>(request: ReportConsolidationRequest) -> Result<ReportConsolidationResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Consolidated financial statements of a group for a period in its presentation currency, with the consolidated trial balance and cash flow, each member's contribution and the intercompany candidates. Each member's balances are translated at the group owner's exchange rates of `toDate` and taken in full, in proportion to the ownership (`proportional`) or as an equity-method investment (`equity`); a fully consolidated member held below 100 % yields the non-controlling interest, and `eliminations` are amounts added to account codes before the statements are assembled (`balanced` tells whether they net to zero). Refused with 422 when the group has no members.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.consolidation
.report(
&ReportConsolidationRequest {
group_id: "groupId".to_string(),
from_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to_date: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
category: None,
eliminations: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**group_id:** `String`
</dd>
</dl>
<dl>
<dd>
**from_date:** `String`
</dd>
</dl>
<dl>
<dd>
**to_date:** `String`
</dd>
</dl>
<dl>
<dd>
**category:** `Option<ReportConsolidationRequestCategory>`
</dd>
</dl>
<dl>
<dd>
**eliminations:** `Option<Vec<ReportConsolidationRequestEliminationsItem>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## public
<details><summary><code>client.public.<a href="/src/api/resources/public/client.rs">integration_requests</a>(request: IntegrationRequestsPublicRequest) -> Result<IntegrationRequestsPublicResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Store a request for an integration: the integration asked for and the sender's name, company, e-mail and details. When `website` is filled in, the call answers `received` without storing anything.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.public
.integration_requests(
&IntegrationRequestsPublicRequest {
integration: "integration".to_string(),
name: "name".to_string(),
email: "email".to_string(),
company: None,
details: None,
website: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**integration:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**company:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**email:** `String`
</dd>
</dl>
<dl>
<dd>
**details:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**website:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.public.<a href="/src/api/resources/public/client.rs">pay</a>(token: String) -> Result<(), ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Redirect (302) to the company's payment page for the issued invoice that carries this payment token, rendered from the template set with `sales/invoices/payment-settings/update` with the invoice number, the amount still unpaid, the currency, the token, the invoice id and the customer name (see `sales/invoices/payment-link`). Answers 404 when the token matches no issued invoice or the company has no template, and 409 when the invoice is already paid.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client.public.pay(&"token".to_string(), None).await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**token:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## billing
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">account_get</a>(request: AccountGetBillingRequest) -> Result<AccountGetBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the signed-in user's billing account: plan, account type, status, balance, trial and payment state, the month-to-date usage of the companies the user pays for with an estimate of today's charge, the plan catalogue, and the top-up, automatic top-up and overdraft settings.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.account_get(
&AccountGetBillingRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">account_set_plan</a>(request: AccountSetPlanBillingRequest) -> Result<AccountSetPlanBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the plan of the user's flat-rate billing account; answers 409 when the account type is not `flat_rate`. With a Stripe subscription and payments configured, the subscription is moved to the new plan.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.account_set_plan(
&AccountSetPlanBillingRequest {
plan: AccountSetPlanBillingRequestPlan::Starter,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**plan:** `AccountSetPlanBillingRequestPlan`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">account_set_account_type</a>(request: AccountSetAccountTypeBillingRequest) -> Result<AccountSetAccountTypeBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Switch the user's billing account between `flat_rate` and `per_request`. With a Stripe subscription and payments configured, the subscription is moved to the plan's price for `flat_rate`; for `per_request` the plan is taken off the subscription, and a subscription that carried only the plan is cancelled, leaving the account without one. When Stripe refuses the change, the previous account type is restored.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.account_set_account_type(
&AccountSetAccountTypeBillingRequest {
account_type: AccountSetAccountTypeBillingRequestAccountType::FlatRate,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**account_type:** `AccountSetAccountTypeBillingRequestAccountType`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">account_set_auto_top_up</a>(request: AccountSetAutoTopUpBillingRequest) -> Result<AccountSetAutoTopUpBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Switch automatic top-ups on or off and set their amount. Switching them on needs a Stripe customer, which the first card top-up creates (400 otherwise); when switched on, a top-up is charged at once if the balance is at or below zero, no payment has failed and no top-up was requested in the last 24 hours.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.account_set_auto_top_up(
&AccountSetAutoTopUpBillingRequest {
enabled: true,
amount_cents: 1000000,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**enabled:** `bool`
</dd>
</dl>
<dl>
<dd>
**amount_cents:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">account_set_overdraft_cap</a>(request: AccountSetOverdraftCapBillingRequest) -> Result<AccountSetOverdraftCapBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set the overdraft cap of the user's billing account: how far usage charges may take the balance below zero before the account is suspended. A suspended account whose balance is within the new cap is activated again.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.account_set_overdraft_cap(
&AccountSetOverdraftCapBillingRequest { cap_cents: 1000000 },
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**cap_cents:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">topup_create</a>(request: TopupCreateBillingRequest) -> Result<TopupCreateBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Open a Stripe Checkout session for a one-time credit top-up of `amountCents` and return its URL; a Stripe customer is created for the user when there is none. `returnTo` chooses whether Checkout returns to the credits page or to the onboarding plan page, in `locale`. Answers 503 when online payments are not configured.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.topup_create(
&TopupCreateBillingRequest {
amount_cents: 1000000,
locale: None,
return_to: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**amount_cents:** `String`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<TopupCreateBillingRequestLocale>`
</dd>
</dl>
<dl>
<dd>
**return_to:** `Option<TopupCreateBillingRequestReturnTo>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">topup_confirm</a>(request: TopupConfirmBillingRequest) -> Result<TopupConfirmBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Confirm a paid top-up Checkout session by `sessionId` and credit the account at once instead of waiting for the Stripe webhook; a session is credited only once. Answers 404 when the session is not the user's own or is not paid.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.topup_confirm(
&TopupConfirmBillingRequest {
session_id: "sessionId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**session_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">flat_rate_create</a>(request: FlatRateCreateBillingRequest) -> Result<FlatRateCreateBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Open a Stripe Checkout session for a flat-rate subscription on `plan`, with the trial period of `trialDays` days, and return its URL; a Stripe customer is created for the user when there is none. Answers 409 when a flat-rate subscription is already active and 503 when online payments are not configured or the plan has no price.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.flat_rate_create(
&FlatRateCreateBillingRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**locale:** `Option<FlatRateCreateBillingRequestLocale>`
</dd>
</dl>
<dl>
<dd>
**plan:** `Option<FlatRateCreateBillingRequestPlan>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">flat_rate_confirm</a>(request: FlatRateConfirmBillingRequest) -> Result<FlatRateConfirmBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Confirm a completed flat-rate Checkout session by `sessionId`: the account becomes `flat_rate` on the session's plan with status `active` and the subscription attached, unless the Stripe webhook already did this. Answers 404 when the session is not the user's own or not completed.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.flat_rate_confirm(
&FlatRateConfirmBillingRequest {
session_id: "sessionId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**session_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">portal_create</a>(request: PortalCreateBillingRequest) -> Result<PortalCreateBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Open a Stripe customer portal session that returns to the credits page in `locale`, and return its URL. Answers 503 when online payments are not configured and 400 when the user has no Stripe customer yet.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.portal_create(
&PortalCreateBillingRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**locale:** `Option<PortalCreateBillingRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">transactions_list</a>(request: TransactionsListBillingRequest) -> Result<TransactionsListBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the newest credit transactions of the user's billing account, up to `limit`: trial grants, top-ups, usage charges, activations and adjustments, each with the balance after it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.transactions_list(
&TransactionsListBillingRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**limit:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.billing.<a href="/src/api/resources/billing/client.rs">usage_list</a>(request: UsageListBillingRequest) -> Result<UsageListBillingResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the daily usage records of the companies the user pays for, from `from` to `to`: one row per company, date and metric (API requests, OCR pages, file storage bytes, database bytes, sale invoices).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.billing
.usage_list(
&UsageListBillingRequest {
from: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
to: NaiveDate::parse_from_str("2026-07-01", "%Y-%m-%d").unwrap(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**from:** `String`
</dd>
</dl>
<dl>
<dd>
**to:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
## account
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">login_link_request</a>(request: LoginLinkRequestAccountRequest) -> Result<LoginLinkRequestAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a sign-in link for the e-mail address and send it; the link is valid for 15 minutes and is consumed with `account/login-link/consume`. When an unused link was requested for the same address within the last minute, the call answers `sent` without sending another. `locale` sets the language of the e-mail and of the link; `app` set to `invoice` makes the link open the invoice app instead of the Nordlet app; `acceptTerms`, `acceptDpa` and `referralCode` are stored with the link and used when the address has no account yet.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.login_link_request(
&LoginLinkRequestAccountRequest {
email: "email".to_string(),
locale: None,
accept_terms: None,
accept_dpa: None,
referral_code: None,
app: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**email:** `String`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<LoginLinkRequestAccountRequestLocale>`
</dd>
</dl>
<dl>
<dd>
**accept_terms:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**accept_dpa:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**referral_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**app:** `Option<LoginLinkRequestAccountRequestApp>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">login_link_consume</a>(request: LoginLinkConsumeAccountRequest) -> Result<LoginLinkConsumeAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Exchange a sign-in link token for a session; an unknown, used or expired token is refused with 401. When no account has the address, one is created (`isNewUser`), which is refused with 422 unless the link was requested with `acceptTerms` and `acceptDpa`; a `referralCode` on the link records who referred the new user. A link from `account/email/change-request` changes the signed-in user's address instead, refused with 409 when another account has it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.login_link_consume(
&LoginLinkConsumeAccountRequest {
token: "token".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**token:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">logout</a>(request: LogoutAccountRequest) -> Result<LogoutAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete the session the call was made with.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.logout(
&LogoutAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">me</a>(request: MeAccountRequest) -> Result<MeAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the signed-in user, their active company and role in it, the companies they belong to and their consent state. `billing` is the billing account that pays for the active company (its payer, or the user when there is none or no company), with `isPayer` saying whether that is the user; `referralPoints` is the user's current points balance.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.me(
&MeAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">members_list</a>(request: MembersListAccountRequest) -> Result<MembersListAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the members of the active company with their role.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.members_list(
&MembersListAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">members_set_role</a>(request: MembersSetRoleAccountRequest) -> Result<MembersSetRoleAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the role of a member of the active company; owners and admins may call it. Refused with 422 for the caller's own role and with 403 for the owner's, which only `account/members/transfer-ownership` changes.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.members_set_role(
&MembersSetRoleAccountRequest {
user_id: "userId".to_string(),
role: MembersSetRoleAccountRequestRole::Admin,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**user_id:** `String`
</dd>
</dl>
<dl>
<dd>
**role:** `MembersSetRoleAccountRequestRole`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">members_transfer_ownership</a>(request: MembersTransferOwnershipAccountRequest) -> Result<MembersTransferOwnershipAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Make another member the owner of the active company; the caller must be its owner and becomes an admin. Refused with 422 when `userId` is the caller. With `movePayer` the company's billing also moves to the new owner, which only the member currently paying for it may do (403).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.members_transfer_ownership(
&MembersTransferOwnershipAccountRequest {
user_id: "userId".to_string(),
move_payer: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**user_id:** `String`
</dd>
</dl>
<dl>
<dd>
**move_payer:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">members_remove</a>(request: MembersRemoveAccountRequest) -> Result<MembersRemoveAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Remove a member from the active company; owners and admins may call it. Their sessions lose this company as the active one and the API keys they created for it are revoked. Refused with 422 for the caller themself and with 403 for the owner.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.members_remove(
&MembersRemoveAccountRequest {
user_id: "userId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**user_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">invites_create</a>(request: InvitesCreateAccountRequest) -> Result<InvitesCreateAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an invitation to the active company for an e-mail address with the given role and send it by e-mail in `locale`; owners and admins may call it. The invitation is valid for 7 days and replaces an earlier pending one for the same address. Refused with 409 when the address already belongs to a member.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.invites_create(
&InvitesCreateAccountRequest {
email: "email".to_string(),
role: InvitesCreateAccountRequestRole::Admin,
locale: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**email:** `String`
</dd>
</dl>
<dl>
<dd>
**role:** `InvitesCreateAccountRequestRole`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<InvitesCreateAccountRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">invites_list</a>(request: InvitesListAccountRequest) -> Result<InvitesListAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the pending invitations of the active company; `expired` marks those past their expiry.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.invites_list(
&InvitesListAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">invites_revoke</a>(request: InvitesRevokeAccountRequest) -> Result<InvitesRevokeAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete a pending invitation of the active company.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.invites_revoke(
&InvitesRevokeAccountRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">invites_get</a>(request: InvitesGetAccountRequest) -> Result<InvitesGetAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Read a pending invitation by its token: the invited address, role and company name, whether it has expired and whether an account with that address already exists (`userExists`), in which case `account/invites/accept` must be called signed in as that account.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.invites_get(
&InvitesGetAccountRequest {
token: "token".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**token:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">invites_accept</a>(request: InvitesAcceptAccountRequest) -> Result<InvitesAcceptAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Accept an invitation and return a session with the invited company active. When the address has no account, one is created with `name` and `locale`, which is refused with 422 unless `acceptTerms` and `acceptDpa` are true; when it has one, the call must be made signed in as that account (401 otherwise). An expired invitation is refused with 422.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.invites_accept(
&InvitesAcceptAccountRequest {
token: "token".to_string(),
name: None,
locale: None,
accept_terms: None,
accept_dpa: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**token:** `String`
</dd>
</dl>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<InvitesAcceptAccountRequestLocale>`
</dd>
</dl>
<dl>
<dd>
**accept_terms:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**accept_dpa:** `Option<bool>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">locale_set</a>(request: LocaleSetAccountRequest) -> Result<LocaleSetAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set the user's language: with an active company it is stored on their membership of that company (`scope` = `membership`), otherwise on the user (`scope` = `user`).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.locale_set(
&LocaleSetAccountRequest {
locale: LocaleSetAccountRequestLocale::En,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**locale:** `LocaleSetAccountRequestLocale`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">companies_create</a>(request: CompaniesCreateAccountRequest) -> Result<CompaniesCreateAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a company with the caller as its owner and payer, seed its chart of accounts from the template of `countryCode`, and make it the active company of the session. `timeZone` defaults to the country's, `isVatPayer` to true and `defaultInvoiceCurrency` to the base currency. Refused with 422 when `baseCurrency` is not a supported currency.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.companies_create(
&CompaniesCreateAccountRequest {
name: "name".to_string(),
code: None,
vat_code: None,
sme_exemption_number: None,
is_vat_payer: None,
vat_period: None,
fiscal_year_end_month: None,
time_zone: None,
filing_options: None,
address: None,
email: None,
phone: None,
iban: None,
bank_name: None,
peppol_id: None,
sepa_creditor_id: None,
default_invoice_currency: None,
legal_form: None,
registry_name: None,
incorporated_on: None,
share_capital: None,
accounts_kept_by: None,
bookkeeper_name: None,
auditor_name: None,
auditor_registration_number: None,
audit_required: None,
country_code: None,
base_currency: None,
is_sandbox: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sme_exemption_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**is_vat_payer:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**vat_period:** `Option<CompaniesCreateAccountRequestVatPeriod>`
</dd>
</dl>
<dl>
<dd>
**fiscal_year_end_month:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**time_zone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**filing_options:** `Option<std::collections::HashMap<String, String>>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<CompaniesCreateAccountRequestAddress>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**bank_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**peppol_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**sepa_creditor_id:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**default_invoice_currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**legal_form:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**registry_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**incorporated_on:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**share_capital:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**accounts_kept_by:** `Option<CompaniesCreateAccountRequestAccountsKeptBy>`
</dd>
</dl>
<dl>
<dd>
**bookkeeper_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**auditor_name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**auditor_registration_number:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**audit_required:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**country_code:** `Option<CompaniesCreateAccountRequestCountryCode>` — Jurisdiction the company is registered in (immutable after creation)
</dd>
</dl>
<dl>
<dd>
**base_currency:** `Option<String>` — Currency the ledger is kept in; defaults to the national currency of countryCode (immutable after creation)
</dd>
</dl>
<dl>
<dd>
**is_sandbox:** `Option<bool>` — Sandbox companies hold test data and are purged immediately on delete (immutable after creation)
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">companies_select</a>(request: CompaniesSelectAccountRequest) -> Result<CompaniesSelectAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Make one of the caller's companies the active company of the session. Refused with 403 when the caller is not a member and with 422 when the company is archived or deleted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.companies_select(
&CompaniesSelectAccountRequest {
company_id: "companyId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**company_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">companies_profile</a>(request: CompaniesProfileAccountRequest) -> Result<CompaniesProfileAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the profile of the active company.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.companies_profile(
&CompaniesProfileAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">companies_update</a>(request: CompaniesUpdateAccountRequest) -> Result<CompaniesUpdateAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Change the profile of the active company; owners and admins may call it. Only the fields sent are changed, and the nullable ones can be sent as null to clear them. `logo` stores a base64-encoded image as a file of the company and sets `logoFileId`. The country, base currency and sandbox flag are fixed at creation.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.companies_update(
&CompaniesUpdateAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**vat_code:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**sme_exemption_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**is_vat_payer:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**vat_period:** `Option<Option<CompaniesUpdateAccountRequestVatPeriod>>`
</dd>
</dl>
<dl>
<dd>
**fiscal_year_end_month:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**time_zone:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**filing_options:** `Option<Option<std::collections::HashMap<String, Option<String>>>>`
</dd>
</dl>
<dl>
<dd>
**address:** `Option<CompaniesUpdateAccountRequestAddress>`
</dd>
</dl>
<dl>
<dd>
**email:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**phone:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**iban:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**bank_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**peppol_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**sepa_creditor_id:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**default_invoice_currency:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**legal_form:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**registry_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**incorporated_on:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**share_capital:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**accounts_kept_by:** `Option<Option<CompaniesUpdateAccountRequestAccountsKeptBy>>`
</dd>
</dl>
<dl>
<dd>
**bookkeeper_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**auditor_name:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**auditor_registration_number:** `Option<Option<String>>`
</dd>
</dl>
<dl>
<dd>
**audit_required:** `Option<bool>`
</dd>
</dl>
<dl>
<dd>
**logo:** `Option<CompaniesUpdateAccountRequestLogo>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">companies_archive</a>(request: CompaniesArchiveAccountRequest) -> Result<CompaniesArchiveAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set the company named by `companyId` to `archived`; the caller must be its owner. Every session that had it active loses it. Refused with 409 unless the company is active; `account/companies/activate` reverses it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.companies_archive(
&CompaniesArchiveAccountRequest {
company_id: "companyId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**company_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">companies_delete</a>(request: CompaniesDeleteAccountRequest) -> Result<CompaniesDeleteAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set the company named by `companyId` to `deleted`; the caller must be its owner, and every session that had it active loses it. A sandbox company is purged at once; any other is purged by the scheduled purge after `purgeAfter` (10 days) and can be restored until then with `account/companies/activate`. Refused with 409 when it is already deleted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.companies_delete(
&CompaniesDeleteAccountRequest {
company_id: "companyId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**company_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">companies_activate</a>(request: CompaniesActivateAccountRequest) -> Result<CompaniesActivateAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set an archived or deleted company named by `companyId` back to `active`; the caller must be its owner. Refused with 409 when it is already active.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.companies_activate(
&CompaniesActivateAccountRequest {
company_id: "companyId".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**company_id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">api_keys_create</a>(request: ApiKeysCreateAccountRequest) -> Result<ApiKeysCreateAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create an API key for the active company and return the key itself once; owners, admins and developers may call it. `scopes` defaults to the caller's own scopes and may not exceed them (403); without `expiresInDays` the key does not expire.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.api_keys_create(
&APIKeysCreateAccountRequest {
name: "name".to_string(),
scopes: None,
expires_in_days: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `String`
</dd>
</dl>
<dl>
<dd>
**scopes:** `Option<Vec<String>>`
</dd>
</dl>
<dl>
<dd>
**expires_in_days:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">api_keys_list</a>(request: ApiKeysListAccountRequest) -> Result<ApiKeysListAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the API keys of the active company, including expired and revoked ones.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.api_keys_list(
&APIKeysListAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">api_keys_rotate</a>(request: ApiKeysRotateAccountRequest) -> Result<ApiKeysRotateAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Create a new key with the name and scopes of the key `id` and return it once; the old key keeps working for `overlapHours` and then expires, and its `replacedByKeyId` points to the new one. `expiresInDays` applies to the new key. Refused with 409 when the old key is revoked.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.api_keys_rotate(
&APIKeysRotateAccountRequest {
id: "id".to_string(),
overlap_hours: None,
expires_in_days: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
<dl>
<dd>
**overlap_hours:** `Option<String>`
</dd>
</dl>
<dl>
<dd>
**expires_in_days:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">api_keys_revoke</a>(request: ApiKeysRevokeAccountRequest) -> Result<ApiKeysRevokeAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Revoke an API key of the active company at once.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.api_keys_revoke(
&APIKeysRevokeAccountRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">consent_accept</a>(request: ConsentAcceptAccountRequest) -> Result<ConsentAcceptAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Record the signed-in user's acceptance of the current Terms of Service and Data Processing Agreement versions and return the consent state.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.consent_accept(
&ConsentAcceptAccountRequest {
accept_terms: true,
accept_dpa: true,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**accept_terms:** `bool`
</dd>
</dl>
<dl>
<dd>
**accept_dpa:** `bool`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">profile_update</a>(request: ProfileUpdateAccountRequest) -> Result<ProfileUpdateAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Set the signed-in user's name; null or a blank string clears it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.profile_update(
&ProfileUpdateAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**name:** `Option<String>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">email_change_request</a>(request: EmailChangeRequestAccountRequest) -> Result<EmailChangeRequestAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Send a confirmation link to `newEmail`; the address changes when that link is consumed with `account/login-link/consume`. When an unused link was sent to the address within the last minute, the call answers `sent` without sending another. Refused with 422 when it is already the user's address and with 409 when another account has it.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.email_change_request(
&EmailChangeRequestAccountRequest {
new_email: "newEmail".to_string(),
locale: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**new_email:** `String`
</dd>
</dl>
<dl>
<dd>
**locale:** `Option<EmailChangeRequestAccountRequestLocale>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">sessions_list</a>(request: SessionsListAccountRequest) -> Result<SessionsListAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the signed-in user's sessions that have not expired; `current` marks the one the call was made with.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.sessions_list(
&SessionsListAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">sessions_revoke</a>(request: SessionsRevokeAccountRequest) -> Result<SessionsRevokeAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete one of the signed-in user's sessions.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.sessions_revoke(
&SessionsRevokeAccountRequest {
id: "id".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**id:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">sessions_revoke_others</a>(request: SessionsRevokeOthersAccountRequest) -> Result<SessionsRevokeOthersAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Delete every session of the signed-in user except the one the call was made with, and return how many were deleted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.sessions_revoke_others(
&SessionsRevokeOthersAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">export</a>(request: ExportAccountRequest) -> Result<ExportAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the user's profile, consent state, memberships, unexpired sessions, billing account, credit transactions and the audit entries they made in their companies (the most recent 5000 of each of the last two).
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.export(
&ExportAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">delete</a>(request: DeleteAccountRequest) -> Result<DeleteAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Removes the user: sessions, sign-in links, memberships and pending invitations are deleted at once; the email and name are replaced by an anonymous placeholder immediately and the remaining row is removed after 30 days. Refused while the user still owns or pays for a company that is not deleted.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.delete(
&DeleteAccountRequest {
confirm_email: "confirmEmail".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**confirm_email:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">referral_get</a>(request: ReferralGetAccountRequest) -> Result<ReferralGetAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the user's referral code (allocated on first call) and sign-up link, their points balance, the number of accounts they referred and the last 50 points entries. `rates.perEur` is the points the referrer earns per euro a referred user tops up, `rates.pointCents` the credit one point converts to with `account/referral/convert`.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.referral_get(
&ReferralGetAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">referral_convert</a>(request: ReferralConvertAccountRequest) -> Result<ReferralConvertAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Convert `points` of the user's referral points into credit on their billing account at `rates.pointCents` per point, booked as an `adjustment` credit transaction; a billing account past its trial is set to active when the new balance allows. Refused with 422 when the user has fewer points than requested.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.referral_convert(&ReferralConvertAccountRequest { points: 1000000 }, None)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**points:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">table_settings_get</a>(request: TableSettingsGetAccountRequest) -> Result<TableSettingsGetAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Return the signed-in user's saved column list and page size for the table `tableKey`; both are null when nothing is saved.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.table_settings_get(
&TableSettingsGetAccountRequest {
table_key: "tableKey".to_string(),
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**table_key:** `String`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">table_settings_set</a>(request: TableSettingsSetAccountRequest) -> Result<TableSettingsSetAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
Save the signed-in user's column list and page size for the table `tableKey`; only the fields sent are changed, and null clears one.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.table_settings_set(
&TableSettingsSetAccountRequest {
table_key: "tableKey".to_string(),
columns: None,
page_size: None,
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
#### ⚙️ Parameters
<dl>
<dd>
<dl>
<dd>
**table_key:** `String`
</dd>
</dl>
<dl>
<dd>
**columns:** `Option<Option<Vec<String>>>`
</dd>
</dl>
<dl>
<dd>
**page_size:** `Option<Option<f64>>`
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>
<details><summary><code>client.account.<a href="/src/api/resources/account/client.rs">table_settings_list</a>(request: TableSettingsListAccountRequest) -> Result<TableSettingsListAccountResponse, ApiError></code></summary>
<dl>
<dd>
#### 📝 Description
<dl>
<dd>
<dl>
<dd>
List the signed-in user's saved table settings.
</dd>
</dl>
</dd>
</dl>
#### 🔌 Usage
<dl>
<dd>
<dl>
<dd>
```rust
use nordlet::prelude::*;
#[tokio::main]
async fn main() {
let config = ClientConfig {
token: Some("<token>".to_string()),
..Default::default()
};
let client = ApiClient::new(config).expect("Failed to build client");
client
.account
.table_settings_list(
&TableSettingsListAccountRequest {
..Default::default()
},
None,
)
.await;
}
```
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
</details>