@beliq/sdk 0.7.1 → 0.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +24 -0
- package/README.md +15 -8
- package/dist/helpers.d.cts +2 -2
- package/dist/helpers.d.ts +2 -2
- package/dist/index.d.cts +9 -6
- package/dist/index.d.ts +9 -6
- package/dist/{types-l-8PFJA8.d.cts → types-B-aV1djO.d.cts} +20 -0
- package/dist/{types-l-8PFJA8.d.ts → types-B-aV1djO.d.ts} +20 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,30 @@
|
|
|
4
4
|
resolves 0.4.x and never reaches 0.5.0. Additive spec syncs ship as patches for
|
|
5
5
|
that reason, and a minor is reserved for a change that needs consumers to opt in.
|
|
6
6
|
|
|
7
|
+
## 0.7.2 - 2026-11-07
|
|
8
|
+
|
|
9
|
+
- `ValidationResult` has `rulesetSupersededOn`, from the API document
|
|
10
|
+
0.26.0: the ISO date the authority made the successor of a ruleset the
|
|
11
|
+
request selected mandatory, when that date is on or before the day of the
|
|
12
|
+
verdict, and the earliest such date when there are several. Each such
|
|
13
|
+
ruleset also adds a `RULESET_SUPERSEDED` warning that names it, its
|
|
14
|
+
version, the successor and the date. `valid` is still the verdict of the
|
|
15
|
+
version that ran. The field is optional, so no code needs to change.
|
|
16
|
+
- The vendored `openapi.json` is document `0.26.0` of the API, up from
|
|
17
|
+
`0.24.0`. Document `0.25.0` added the `x-beliq-idempotent-replay`
|
|
18
|
+
response header on `generate`, `validate`, `parse` and `convert`, which
|
|
19
|
+
the client does not read. The generated types also carry the API's
|
|
20
|
+
description of `subLines`: at most 64 levels deep, a limit beliq set and
|
|
21
|
+
no format rule.
|
|
22
|
+
- The README and the option comments say that beliq does not charge a
|
|
23
|
+
repeat of a charged `generate`, `validate`, `parse` or `convert` request
|
|
24
|
+
again within 15 minutes of the charge, up to 10 repeats, and that every
|
|
25
|
+
retry sends the same request. A `maxRetries` above 10 can be charged again,
|
|
26
|
+
and so can every attempt when beliq cannot read or write its record of
|
|
27
|
+
charged requests. They also say why a `504` and this client's
|
|
28
|
+
own timeout stay unretried: a repeat runs the same document again from
|
|
29
|
+
the start. No code changes.
|
|
30
|
+
|
|
7
31
|
## 0.7.1 - 2026-11-06
|
|
8
32
|
|
|
9
33
|
- `validate` takes a `ruleset` option, sent as the `Beliq-Ruleset` header: a
|
package/README.md
CHANGED
|
@@ -143,13 +143,20 @@ What a retry costs:
|
|
|
143
143
|
- The unit of an `ENGINE_UNAVAILABLE` is refunded, within the cap that page
|
|
144
144
|
names.
|
|
145
145
|
- A test key's sandbox units are never refunded.
|
|
146
|
-
- A connection lost after the request was sent can mean beliq already
|
|
147
|
-
|
|
148
|
-
request
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
146
|
+
- A connection lost after the request was sent can mean beliq already ran the
|
|
147
|
+
request and charged it. beliq does not charge a repeat of a charged
|
|
148
|
+
`generate`, `validate`, `parse` or `convert` request again within 15 minutes
|
|
149
|
+
of the charge, up to 10 repeats, and every retry sends the same request. The
|
|
150
|
+
15 minutes and the 10 repeats are beliq's own choice; no standard sets them.
|
|
151
|
+
The answer to such a repeat carries `x-beliq-idempotent-replay: true`. A
|
|
152
|
+
`maxRetries` above 10 can be charged again. When beliq cannot read or write
|
|
153
|
+
its record of charged requests, it charges every attempt.
|
|
154
|
+
https://docs.beliq.eu/api-reference/errors/#repeated-requests-are-not-charged-again
|
|
155
|
+
says what makes two requests the same.
|
|
156
|
+
|
|
157
|
+
`504` and this client's own timeout are deliberately **not** retried: both can
|
|
158
|
+
mean the work is still running on beliq's side, and a retry runs the same
|
|
159
|
+
document again from the start, so it would likely run out of time again.
|
|
153
160
|
|
|
154
161
|
A `429` carrying `QUOTA_EXCEEDED` is not retried either. `RATE_LIMITED` and
|
|
155
162
|
`ACCOUNT_THROTTLED` clear on their own, but a spent monthly allowance only returns
|
|
@@ -195,7 +202,7 @@ const result = await beliq.validate(xml, { ruleset: 'previous' });
|
|
|
195
202
|
console.log(result.rulesetChannel, result.rulesetFellBack, result.rulesetArtifacts);
|
|
196
203
|
```
|
|
197
204
|
|
|
198
|
-
The result says what applied. `rulesetChannel` and `rulesetFellBack` say which channel: `rulesetFellBack: true` means the format had nothing for `previous` to reach, so the latest rules ran. Under exact pins `rulesetChannel` reads `latest`, whatever version a pin ran. `rulesetArtifacts` and the per-format version fields, such as `schematronVersion`, say which rules ran,
|
|
205
|
+
The result says what applied. `rulesetChannel` and `rulesetFellBack` say which channel: `rulesetFellBack: true` means the format had nothing for `previous` to reach, so the latest rules ran. Under exact pins `rulesetChannel` reads `latest`, whatever version a pin ran. `rulesetArtifacts` and the per-format version fields, such as `schematronVersion`, say which rules ran, `rulesetSunsetsOn` says until when a retained ruleset is served, and `rulesetSupersededOn` from when the authority made the successor of a ruleset the request selected mandatory, with a `RULESET_SUPERSEDED` warning per such ruleset; `valid` is still the verdict of the version that ran. `GET /v1/rulesets` gives each format's `previousChannel`: what `previous` reaches for it today.
|
|
199
206
|
|
|
200
207
|
The API answers a malformed value with a 400 `VALIDATION_ERROR` before any quota is used. It answers a pin to a version it no longer serves with a 422 `VALIDATION_ERROR`, and that request uses up a document. The API's `Beliq-Ruleset-Resolved` response header is not returned: it is built from the request, so for pins it repeats the pins sent even when a pinned artifact did not run. `rulesetArtifacts` says what ran.
|
|
201
208
|
|
package/dist/helpers.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { P as PlainObject } from './types-
|
|
1
|
+
import { P as PlainObject } from './types-B-aV1djO.cjs';
|
|
2
2
|
import { ValidationResult } from './index.cjs';
|
|
3
|
-
export { D as DEFAULT_BASE_URL, a as DocumentInput, G as GeneratePreset, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, i as compactQuery, j as decodeUtf8, k as isPlainObject, l as isProfileAllowedForStandard, m as mergeDeep, p as profilesForStandard, s as sniffContentType, t as toBytes } from './types-
|
|
3
|
+
export { D as DEFAULT_BASE_URL, a as DocumentInput, G as GeneratePreset, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, i as compactQuery, j as decodeUtf8, k as isPlainObject, l as isProfileAllowedForStandard, m as mergeDeep, p as profilesForStandard, s as sniffContentType, t as toBytes } from './types-B-aV1djO.cjs';
|
|
4
4
|
|
|
5
5
|
type Operation = 'me' | 'generate' | 'validate' | 'parse' | 'convert';
|
|
6
6
|
/** 'json' => parse the `{ success, data }` envelope; 'binary' => return raw bytes. */
|
package/dist/helpers.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { P as PlainObject } from './types-
|
|
1
|
+
import { P as PlainObject } from './types-B-aV1djO.js';
|
|
2
2
|
import { ValidationResult } from './index.js';
|
|
3
|
-
export { D as DEFAULT_BASE_URL, a as DocumentInput, G as GeneratePreset, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, i as compactQuery, j as decodeUtf8, k as isPlainObject, l as isProfileAllowedForStandard, m as mergeDeep, p as profilesForStandard, s as sniffContentType, t as toBytes } from './types-
|
|
3
|
+
export { D as DEFAULT_BASE_URL, a as DocumentInput, G as GeneratePreset, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, i as compactQuery, j as decodeUtf8, k as isPlainObject, l as isProfileAllowedForStandard, m as mergeDeep, p as profilesForStandard, s as sniffContentType, t as toBytes } from './types-B-aV1djO.js';
|
|
4
4
|
|
|
5
5
|
type Operation = 'me' | 'generate' | 'validate' | 'parse' | 'convert';
|
|
6
6
|
/** 'json' => parse the `{ success, data }` envelope; 'binary' => return raw bytes. */
|
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { A as AccountInfo, S as Standard, I as Invoice, n as GenerateProfile, F as FacturxProfile, V as ValidationResult, R as RulesetArtifact, a as DocumentInput, o as ValidateFormat, q as RulesetChannel, r as ParseFormat, u as ParseResult, C as ConvertTargetFormat, v as ConvertSourceFormat, w as ApiErrorCode } from './types-
|
|
1
|
+
import { A as AccountInfo, S as Standard, I as Invoice, n as GenerateProfile, F as FacturxProfile, V as ValidationResult, R as RulesetArtifact, a as DocumentInput, o as ValidateFormat, q as RulesetChannel, r as ParseFormat, u as ParseResult, C as ConvertTargetFormat, v as ConvertSourceFormat, w as ApiErrorCode } from './types-B-aV1djO.cjs';
|
|
2
2
|
import { PlainObject } from './helpers.cjs';
|
|
3
|
-
export { x as ApiError, D as DEFAULT_BASE_URL, y as DEFAULT_MAX_RETRIES, z as DEFAULT_RETRY_BUDGET_MS, B as DEFAULT_TIMEOUT_MS, E as GenerateBody, G as GeneratePreset, H as GenerateResponse, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, J as ParseWarning, K as ParseWarningCode, M as Severity, N as ValidationFormat, O as ValidationIssue, l as isProfileAllowedForStandard, p as profilesForStandard } from './types-
|
|
3
|
+
export { x as ApiError, D as DEFAULT_BASE_URL, y as DEFAULT_MAX_RETRIES, z as DEFAULT_RETRY_BUDGET_MS, B as DEFAULT_TIMEOUT_MS, E as GenerateBody, G as GeneratePreset, H as GenerateResponse, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, J as ParseWarning, K as ParseWarningCode, M as Severity, N as ValidationFormat, O as ValidationIssue, l as isProfileAllowedForStandard, p as profilesForStandard } from './types-B-aV1djO.cjs';
|
|
4
4
|
|
|
5
5
|
interface BeliqOptions {
|
|
6
6
|
/** API key from the beliq dashboard (API Keys). */
|
|
@@ -16,8 +16,8 @@ interface BeliqOptions {
|
|
|
16
16
|
* the full Schematron rule set over a document, so a generate or validate can
|
|
17
17
|
* take tens of seconds legitimately. Set well above the latency you expect:
|
|
18
18
|
* a deadline shorter than the server's own means giving up on work that is
|
|
19
|
-
* still running, and this client does not retry its own timeout, since
|
|
20
|
-
*
|
|
19
|
+
* still running, and this client does not retry its own timeout, since a
|
|
20
|
+
* repeat runs the same document again from the start. 0 disables the deadline.
|
|
21
21
|
*/
|
|
22
22
|
timeoutMs?: number;
|
|
23
23
|
/**
|
|
@@ -82,8 +82,11 @@ interface ValidateOptions extends DocumentOptions {
|
|
|
82
82
|
*
|
|
83
83
|
* The result says what applied: `rulesetChannel` and `rulesetFellBack` which
|
|
84
84
|
* channel, `rulesetArtifacts` and the per-format version fields which rules
|
|
85
|
-
* ran,
|
|
86
|
-
*
|
|
85
|
+
* ran, `rulesetSunsetsOn` until when a retained ruleset is served, and
|
|
86
|
+
* `rulesetSupersededOn` from when the authority made the successor of a
|
|
87
|
+
* selected ruleset mandatory, with a `RULESET_SUPERSEDED` warning per such
|
|
88
|
+
* ruleset. Under exact pins `rulesetChannel` reads `latest`, whatever version
|
|
89
|
+
* a pin ran.
|
|
87
90
|
* The API answers a malformed value with a 400 `VALIDATION_ERROR` before any
|
|
88
91
|
* quota is used, and a pin to a version it no longer serves with a 422
|
|
89
92
|
* `VALIDATION_ERROR`, which uses up a document.
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { A as AccountInfo, S as Standard, I as Invoice, n as GenerateProfile, F as FacturxProfile, V as ValidationResult, R as RulesetArtifact, a as DocumentInput, o as ValidateFormat, q as RulesetChannel, r as ParseFormat, u as ParseResult, C as ConvertTargetFormat, v as ConvertSourceFormat, w as ApiErrorCode } from './types-
|
|
1
|
+
import { A as AccountInfo, S as Standard, I as Invoice, n as GenerateProfile, F as FacturxProfile, V as ValidationResult, R as RulesetArtifact, a as DocumentInput, o as ValidateFormat, q as RulesetChannel, r as ParseFormat, u as ParseResult, C as ConvertTargetFormat, v as ConvertSourceFormat, w as ApiErrorCode } from './types-B-aV1djO.js';
|
|
2
2
|
import { PlainObject } from './helpers.js';
|
|
3
|
-
export { x as ApiError, D as DEFAULT_BASE_URL, y as DEFAULT_MAX_RETRIES, z as DEFAULT_RETRY_BUDGET_MS, B as DEFAULT_TIMEOUT_MS, E as GenerateBody, G as GeneratePreset, H as GenerateResponse, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, J as ParseWarning, K as ParseWarningCode, M as Severity, N as ValidationFormat, O as ValidationIssue, l as isProfileAllowedForStandard, p as profilesForStandard } from './types-
|
|
3
|
+
export { x as ApiError, D as DEFAULT_BASE_URL, y as DEFAULT_MAX_RETRIES, z as DEFAULT_RETRY_BUDGET_MS, B as DEFAULT_TIMEOUT_MS, E as GenerateBody, G as GeneratePreset, H as GenerateResponse, L as LIVE_CONVERT_SOURCE_FORMATS, b as LIVE_CONVERT_TARGET_FORMATS, c as LIVE_GENERATE_PRESETS, d as LIVE_GENERATE_STANDARDS, e as LIVE_PARSE_FORMATS, f as LIVE_PROFILES, g as LIVE_PROFILES_BY_STANDARD, h as LIVE_VALIDATE_FORMATS, J as ParseWarning, K as ParseWarningCode, M as Severity, N as ValidationFormat, O as ValidationIssue, l as isProfileAllowedForStandard, p as profilesForStandard } from './types-B-aV1djO.js';
|
|
4
4
|
|
|
5
5
|
interface BeliqOptions {
|
|
6
6
|
/** API key from the beliq dashboard (API Keys). */
|
|
@@ -16,8 +16,8 @@ interface BeliqOptions {
|
|
|
16
16
|
* the full Schematron rule set over a document, so a generate or validate can
|
|
17
17
|
* take tens of seconds legitimately. Set well above the latency you expect:
|
|
18
18
|
* a deadline shorter than the server's own means giving up on work that is
|
|
19
|
-
* still running, and this client does not retry its own timeout, since
|
|
20
|
-
*
|
|
19
|
+
* still running, and this client does not retry its own timeout, since a
|
|
20
|
+
* repeat runs the same document again from the start. 0 disables the deadline.
|
|
21
21
|
*/
|
|
22
22
|
timeoutMs?: number;
|
|
23
23
|
/**
|
|
@@ -82,8 +82,11 @@ interface ValidateOptions extends DocumentOptions {
|
|
|
82
82
|
*
|
|
83
83
|
* The result says what applied: `rulesetChannel` and `rulesetFellBack` which
|
|
84
84
|
* channel, `rulesetArtifacts` and the per-format version fields which rules
|
|
85
|
-
* ran,
|
|
86
|
-
*
|
|
85
|
+
* ran, `rulesetSunsetsOn` until when a retained ruleset is served, and
|
|
86
|
+
* `rulesetSupersededOn` from when the authority made the successor of a
|
|
87
|
+
* selected ruleset mandatory, with a `RULESET_SUPERSEDED` warning per such
|
|
88
|
+
* ruleset. Under exact pins `rulesetChannel` reads `latest`, whatever version
|
|
89
|
+
* a pin ran.
|
|
87
90
|
* The API answers a malformed value with a 400 `VALIDATION_ERROR` before any
|
|
88
91
|
* quota is used, and a pin to a version it no longer serves with a 422
|
|
89
92
|
* `VALIDATION_ERROR`, which uses up a document.
|
|
@@ -157,6 +157,7 @@ interface components {
|
|
|
157
157
|
startDate?: string;
|
|
158
158
|
endDate?: string;
|
|
159
159
|
};
|
|
160
|
+
/** @description Lines nested under this line, at most 64 levels deep with the top-level line as level 1. The 64 is Beliq's own limit, not a format rule. A deeper tree is refused with 422 `VALIDATION_ERROR` before the body is checked against this schema, and no quota unit is spent. */
|
|
160
161
|
subLines?: components["schemas"]["InvoiceLine"][];
|
|
161
162
|
};
|
|
162
163
|
};
|
|
@@ -483,6 +484,7 @@ interface operations {
|
|
|
483
484
|
startDate?: string;
|
|
484
485
|
endDate?: string;
|
|
485
486
|
};
|
|
487
|
+
/** @description Lines nested under this line, at most 64 levels deep with the top-level line as level 1. The 64 is Beliq's own limit, not a format rule. A deeper tree is refused with 422 `VALIDATION_ERROR` before the body is checked against this schema, and no quota unit is spent. */
|
|
486
488
|
subLines?: components["schemas"]["InvoiceLine"][];
|
|
487
489
|
}[];
|
|
488
490
|
taxSummary?: {
|
|
@@ -642,6 +644,8 @@ interface operations {
|
|
|
642
644
|
"x-ruleset-artifacts"?: string;
|
|
643
645
|
/** @description How the returned PDF was built: "hybrid" (PDF/A-3 with the XML embedded) or "visualization" (rendered pages only, no XML embedded). */
|
|
644
646
|
"x-pdf-kind"?: string;
|
|
647
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
648
|
+
"x-beliq-idempotent-replay"?: string;
|
|
645
649
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
646
650
|
"x-beliq-livemode"?: string;
|
|
647
651
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
|
@@ -707,6 +711,11 @@ interface operations {
|
|
|
707
711
|
* @description ISO date the retained ruleset serving this request stops being served. Present only when a retained ruleset ran (never on a default request); the earliest date when several ran. After it an exact pin 422s. It bounds the pin, not the channel: `previous` stops reaching the version on this date or on the authority's mandatory date for the successor, whichever comes first.
|
|
708
712
|
*/
|
|
709
713
|
rulesetSunsetsOn?: string;
|
|
714
|
+
/**
|
|
715
|
+
* Format: date
|
|
716
|
+
* @description ISO date the authority made the successor of a ruleset this request selected mandatory, when that date is on or before the day of the verdict; the earliest date when several were. Each such ruleset also adds a `RULESET_SUPERSEDED` warning naming it, its version, the successor and the date. Absent when none was. `valid` is still the verdict of the version that ran.
|
|
717
|
+
*/
|
|
718
|
+
rulesetSupersededOn?: string;
|
|
710
719
|
/** @description Present only when the document sent to `POST /v1/validate` was a PDF: which embedded file the verdict is about, and that the PDF around it was not checked. */
|
|
711
720
|
pdfInput?: {
|
|
712
721
|
/**
|
|
@@ -982,6 +991,8 @@ interface operations {
|
|
|
982
991
|
"x-ruleset-artifacts"?: string;
|
|
983
992
|
/** @description The ruleset selection that actually applied. Set when the request carried a Beliq-Ruleset header, or carried none and the API key's organisation has "previous" as its default channel. Reveals a "previous"→"latest" fallback. */
|
|
984
993
|
"beliq-ruleset-resolved"?: string;
|
|
994
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
995
|
+
"x-beliq-idempotent-replay"?: string;
|
|
985
996
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
986
997
|
"x-beliq-livemode"?: string;
|
|
987
998
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
|
@@ -1040,6 +1051,11 @@ interface operations {
|
|
|
1040
1051
|
* @description ISO date the retained ruleset serving this request stops being served. Present only when a retained ruleset ran (never on a default request); the earliest date when several ran. After it an exact pin 422s. It bounds the pin, not the channel: `previous` stops reaching the version on this date or on the authority's mandatory date for the successor, whichever comes first.
|
|
1041
1052
|
*/
|
|
1042
1053
|
rulesetSunsetsOn?: string;
|
|
1054
|
+
/**
|
|
1055
|
+
* Format: date
|
|
1056
|
+
* @description ISO date the authority made the successor of a ruleset this request selected mandatory, when that date is on or before the day of the verdict; the earliest date when several were. Each such ruleset also adds a `RULESET_SUPERSEDED` warning naming it, its version, the successor and the date. Absent when none was. `valid` is still the verdict of the version that ran.
|
|
1057
|
+
*/
|
|
1058
|
+
rulesetSupersededOn?: string;
|
|
1043
1059
|
/** @description Present only when the document sent to `POST /v1/validate` was a PDF: which embedded file the verdict is about, and that the PDF around it was not checked. */
|
|
1044
1060
|
pdfInput?: {
|
|
1045
1061
|
/**
|
|
@@ -1281,6 +1297,8 @@ interface operations {
|
|
|
1281
1297
|
"x-ruleset-sha256"?: string;
|
|
1282
1298
|
/** @description One-line verdict, e.g. "pass · 0 err · 1 warn". */
|
|
1283
1299
|
"x-validation"?: string;
|
|
1300
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
1301
|
+
"x-beliq-idempotent-replay"?: string;
|
|
1284
1302
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
1285
1303
|
"x-beliq-livemode"?: string;
|
|
1286
1304
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
|
@@ -1589,6 +1607,8 @@ interface operations {
|
|
|
1589
1607
|
"x-output-envelope"?: string;
|
|
1590
1608
|
/** @description Compact JSON naming the ruleset/artifact versions pinned for the produced format. */
|
|
1591
1609
|
"x-version-block"?: string;
|
|
1610
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
1611
|
+
"x-beliq-idempotent-replay"?: string;
|
|
1592
1612
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
1593
1613
|
"x-beliq-livemode"?: string;
|
|
1594
1614
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
|
@@ -157,6 +157,7 @@ interface components {
|
|
|
157
157
|
startDate?: string;
|
|
158
158
|
endDate?: string;
|
|
159
159
|
};
|
|
160
|
+
/** @description Lines nested under this line, at most 64 levels deep with the top-level line as level 1. The 64 is Beliq's own limit, not a format rule. A deeper tree is refused with 422 `VALIDATION_ERROR` before the body is checked against this schema, and no quota unit is spent. */
|
|
160
161
|
subLines?: components["schemas"]["InvoiceLine"][];
|
|
161
162
|
};
|
|
162
163
|
};
|
|
@@ -483,6 +484,7 @@ interface operations {
|
|
|
483
484
|
startDate?: string;
|
|
484
485
|
endDate?: string;
|
|
485
486
|
};
|
|
487
|
+
/** @description Lines nested under this line, at most 64 levels deep with the top-level line as level 1. The 64 is Beliq's own limit, not a format rule. A deeper tree is refused with 422 `VALIDATION_ERROR` before the body is checked against this schema, and no quota unit is spent. */
|
|
486
488
|
subLines?: components["schemas"]["InvoiceLine"][];
|
|
487
489
|
}[];
|
|
488
490
|
taxSummary?: {
|
|
@@ -642,6 +644,8 @@ interface operations {
|
|
|
642
644
|
"x-ruleset-artifacts"?: string;
|
|
643
645
|
/** @description How the returned PDF was built: "hybrid" (PDF/A-3 with the XML embedded) or "visualization" (rendered pages only, no XML embedded). */
|
|
644
646
|
"x-pdf-kind"?: string;
|
|
647
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
648
|
+
"x-beliq-idempotent-replay"?: string;
|
|
645
649
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
646
650
|
"x-beliq-livemode"?: string;
|
|
647
651
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
|
@@ -707,6 +711,11 @@ interface operations {
|
|
|
707
711
|
* @description ISO date the retained ruleset serving this request stops being served. Present only when a retained ruleset ran (never on a default request); the earliest date when several ran. After it an exact pin 422s. It bounds the pin, not the channel: `previous` stops reaching the version on this date or on the authority's mandatory date for the successor, whichever comes first.
|
|
708
712
|
*/
|
|
709
713
|
rulesetSunsetsOn?: string;
|
|
714
|
+
/**
|
|
715
|
+
* Format: date
|
|
716
|
+
* @description ISO date the authority made the successor of a ruleset this request selected mandatory, when that date is on or before the day of the verdict; the earliest date when several were. Each such ruleset also adds a `RULESET_SUPERSEDED` warning naming it, its version, the successor and the date. Absent when none was. `valid` is still the verdict of the version that ran.
|
|
717
|
+
*/
|
|
718
|
+
rulesetSupersededOn?: string;
|
|
710
719
|
/** @description Present only when the document sent to `POST /v1/validate` was a PDF: which embedded file the verdict is about, and that the PDF around it was not checked. */
|
|
711
720
|
pdfInput?: {
|
|
712
721
|
/**
|
|
@@ -982,6 +991,8 @@ interface operations {
|
|
|
982
991
|
"x-ruleset-artifacts"?: string;
|
|
983
992
|
/** @description The ruleset selection that actually applied. Set when the request carried a Beliq-Ruleset header, or carried none and the API key's organisation has "previous" as its default channel. Reveals a "previous"→"latest" fallback. */
|
|
984
993
|
"beliq-ruleset-resolved"?: string;
|
|
994
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
995
|
+
"x-beliq-idempotent-replay"?: string;
|
|
985
996
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
986
997
|
"x-beliq-livemode"?: string;
|
|
987
998
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
|
@@ -1040,6 +1051,11 @@ interface operations {
|
|
|
1040
1051
|
* @description ISO date the retained ruleset serving this request stops being served. Present only when a retained ruleset ran (never on a default request); the earliest date when several ran. After it an exact pin 422s. It bounds the pin, not the channel: `previous` stops reaching the version on this date or on the authority's mandatory date for the successor, whichever comes first.
|
|
1041
1052
|
*/
|
|
1042
1053
|
rulesetSunsetsOn?: string;
|
|
1054
|
+
/**
|
|
1055
|
+
* Format: date
|
|
1056
|
+
* @description ISO date the authority made the successor of a ruleset this request selected mandatory, when that date is on or before the day of the verdict; the earliest date when several were. Each such ruleset also adds a `RULESET_SUPERSEDED` warning naming it, its version, the successor and the date. Absent when none was. `valid` is still the verdict of the version that ran.
|
|
1057
|
+
*/
|
|
1058
|
+
rulesetSupersededOn?: string;
|
|
1043
1059
|
/** @description Present only when the document sent to `POST /v1/validate` was a PDF: which embedded file the verdict is about, and that the PDF around it was not checked. */
|
|
1044
1060
|
pdfInput?: {
|
|
1045
1061
|
/**
|
|
@@ -1281,6 +1297,8 @@ interface operations {
|
|
|
1281
1297
|
"x-ruleset-sha256"?: string;
|
|
1282
1298
|
/** @description One-line verdict, e.g. "pass · 0 err · 1 warn". */
|
|
1283
1299
|
"x-validation"?: string;
|
|
1300
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
1301
|
+
"x-beliq-idempotent-replay"?: string;
|
|
1284
1302
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
1285
1303
|
"x-beliq-livemode"?: string;
|
|
1286
1304
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
|
@@ -1589,6 +1607,8 @@ interface operations {
|
|
|
1589
1607
|
"x-output-envelope"?: string;
|
|
1590
1608
|
/** @description Compact JSON naming the ruleset/artifact versions pinned for the produced format. */
|
|
1591
1609
|
"x-version-block"?: string;
|
|
1610
|
+
/** @description "true" when this request repeats one your organisation sent in the same mode and was charged for in the last 15 minutes: the same route, query, Content-Type, Accept, ruleset selection and body, and for generate the same stored PDF template. The request was computed again and not charged. One charge covers 10 such repeats; the 11th is charged and starts a new 15 minutes. The window, what makes two requests the same and the cap are a choice Beliq made; no standard sets them. Absent when the request was charged. */
|
|
1611
|
+
"x-beliq-idempotent-replay"?: string;
|
|
1592
1612
|
/** @description "true" for a live key, "false" for a test key. Test-mode documents are watermarked and do not draw on the live monthly quota. */
|
|
1593
1613
|
"x-beliq-livemode"?: string;
|
|
1594
1614
|
/** @description Correlation id for this request. Quote it in a support request; it is the key the API, the engine, and error tracking all record. */
|
package/package.json
CHANGED