@timbro/invoices 0.13.0 → 0.14.0
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/README.md +26 -2
- package/dist/admin.d.ts +1 -1
- package/dist/admin.d.ts.map +1 -1
- package/dist/fiscal-engine-runtime.manifest.json +21 -16
- package/dist/fiscal-engine-runtime.provenance.json +22 -17
- package/dist/generated/certification-api-contract.d.ts +1 -1
- package/dist/generated/certification-api-contract.d.ts.map +1 -1
- package/dist/generated/certification-api-contract.js +1 -1
- package/dist/generated/hosted/types.gen.d.ts +40 -5
- package/dist/generated/hosted/types.gen.d.ts.map +1 -1
- package/dist/generated/hosted/zod-response.gen.d.ts +28 -14
- package/dist/generated/hosted/zod-response.gen.d.ts.map +1 -1
- package/dist/generated/hosted/zod-response.gen.js +90 -0
- package/dist/generated/hosted/zod.gen.d.ts +10 -5
- package/dist/generated/hosted/zod.gen.d.ts.map +1 -1
- package/dist/generated/hosted/zod.gen.js +90 -0
- package/dist/generated/index.d.ts +3 -3
- package/dist/generated/index.d.ts.map +1 -1
- package/dist/generated/index.js +2 -2
- package/dist/generated/invoice-api-contract.d.ts +242 -13
- package/dist/generated/invoice-api-contract.d.ts.map +1 -1
- package/dist/generated/invoice-api-contract.js +370 -13
- package/dist/generated/problem-catalog.d.ts.map +1 -1
- package/dist/generated/problem-catalog.js +13 -0
- package/dist/generated/sdk.gen.d.ts +4 -2
- package/dist/generated/sdk.gen.d.ts.map +1 -1
- package/dist/generated/sdk.gen.js +70 -2
- package/dist/generated/types.gen.d.ts +200 -15
- package/dist/generated/types.gen.d.ts.map +1 -1
- package/dist/generated/zod-response.gen.d.ts +668 -305
- package/dist/generated/zod-response.gen.d.ts.map +1 -1
- package/dist/generated/zod-response.gen.js +95 -7
- package/dist/generated/zod.gen.d.ts +15673 -591
- package/dist/generated/zod.gen.d.ts.map +1 -1
- package/dist/generated/zod.gen.js +329 -22
- package/dist/hosted-tenant.d.ts +12 -1
- package/dist/hosted-tenant.d.ts.map +1 -1
- package/dist/hosted-tenant.js +13 -1
- package/dist/problem-contract.d.ts +5 -1
- package/dist/problem-contract.d.ts.map +1 -1
- package/dist/timbro_fiscal_engine_bg.wasm +0 -0
- package/package.json +1 -1
|
@@ -530,7 +530,7 @@ export const zFiscalLineTotal = z.object({
|
|
|
530
530
|
/**
|
|
531
531
|
* One ordinary fiscal line whose profile admits only the legal-tip code.
|
|
532
532
|
*/
|
|
533
|
-
export const zFiscalNumberAuthorizationKnowledge = z.enum(["verified", "reported"]);
|
|
533
|
+
export const zFiscalNumberAuthorizationKnowledge = z.enum(["verified", "reported", "disputed"]);
|
|
534
534
|
/**
|
|
535
535
|
* Origin of a fiscal-number authorization fact.
|
|
536
536
|
*/
|
|
@@ -538,6 +538,7 @@ export const zFiscalNumberAuthorizationSourceKind = z.enum([
|
|
|
538
538
|
"official_source_manifest",
|
|
539
539
|
"operator_attested",
|
|
540
540
|
"caller_reported",
|
|
541
|
+
"dgii_response",
|
|
541
542
|
]);
|
|
542
543
|
/**
|
|
543
544
|
* Lifecycle state of a fiscal-number authorization fact.
|
|
@@ -683,11 +684,17 @@ export const zHealthReadyResponse = z.object({
|
|
|
683
684
|
schema_version: z.int().gte(1).lte(2147483647).nullable(),
|
|
684
685
|
status: zHealthStatus,
|
|
685
686
|
});
|
|
687
|
+
export const zHostedCertificateImportEnvironment = z.enum([
|
|
688
|
+
"sandbox",
|
|
689
|
+
"certification",
|
|
690
|
+
"production",
|
|
691
|
+
]);
|
|
686
692
|
export const zHostedImportResponse = z.object({
|
|
687
693
|
certificate_subject_common_name: z
|
|
688
694
|
.string()
|
|
689
695
|
.refine((text) => Array.from(text).length <= 256)
|
|
690
696
|
.nullable(),
|
|
697
|
+
environments: z.array(zHostedCertificateImportEnvironment),
|
|
691
698
|
object: z.string(),
|
|
692
699
|
signer_subject_serial_number: z.string(),
|
|
693
700
|
});
|
|
@@ -707,6 +714,10 @@ export const zHostedReceiverUrls = z.object({
|
|
|
707
714
|
commercial_approval_url: z.string(),
|
|
708
715
|
reception_url: z.string(),
|
|
709
716
|
});
|
|
717
|
+
/**
|
|
718
|
+
* What the repair did to the binding's Source connection.
|
|
719
|
+
*/
|
|
720
|
+
export const zHostedSourceConnectionRepairOutcome = z.enum(["reconnected", "already_connected"]);
|
|
710
721
|
export const zHostedTenantResource = z.object({
|
|
711
722
|
hosted_tenant_binding_id: z.uuid(),
|
|
712
723
|
legal_issuer_id: z.uuid(),
|
|
@@ -2496,7 +2507,7 @@ export const zIssuanceBlocker = z.enum([
|
|
|
2496
2507
|
"authorization_exhausted",
|
|
2497
2508
|
"authorization_conflicting",
|
|
2498
2509
|
"authorization_document_type_mismatch",
|
|
2499
|
-
"
|
|
2510
|
+
"sequence_rejected_by_dgii",
|
|
2500
2511
|
"authorization_expired",
|
|
2501
2512
|
"authorization_range_overlap",
|
|
2502
2513
|
"fiscal_number_capacity_exhausted",
|
|
@@ -2512,7 +2523,7 @@ export const zIssuanceReadinessReason = z.enum([
|
|
|
2512
2523
|
"signing_certificate_not_yet_valid",
|
|
2513
2524
|
"authorization_missing",
|
|
2514
2525
|
"authorization_not_active",
|
|
2515
|
-
"
|
|
2526
|
+
"sequence_rejected_by_dgii",
|
|
2516
2527
|
"authorization_not_observed",
|
|
2517
2528
|
"range_exhausted",
|
|
2518
2529
|
"authorization_expiration_invalid",
|
|
@@ -2729,7 +2740,12 @@ export const zNotReceivedReason = z.enum([
|
|
|
2729
2740
|
/**
|
|
2730
2741
|
* Numbering values resolved before deterministic fiscal-document construction.
|
|
2731
2742
|
*/
|
|
2743
|
+
export const zNumberingConfirmation = z.enum(["confirmed", "not_yet_confirmed"]);
|
|
2744
|
+
/**
|
|
2745
|
+
* The range Timbro assigns the next fiscal number of this type from.
|
|
2746
|
+
*/
|
|
2732
2747
|
export const zNumberingRange = z.object({
|
|
2748
|
+
confirmation: zNumberingConfirmation,
|
|
2733
2749
|
expiresOn: z.iso.date().nullable(),
|
|
2734
2750
|
remaining: z.int().gte(1).lte(9999999999),
|
|
2735
2751
|
});
|
|
@@ -3113,6 +3129,12 @@ export const zReleasedHostedTenant = z.object({
|
|
|
3113
3129
|
release_id: z.uuid(),
|
|
3114
3130
|
state: z.string(),
|
|
3115
3131
|
});
|
|
3132
|
+
export const zRepairedHostedTenantSourceConnection = z.object({
|
|
3133
|
+
environment: zFiscalEnvironment,
|
|
3134
|
+
hosted_tenant_binding_id: z.uuid(),
|
|
3135
|
+
outcome: zHostedSourceConnectionRepairOutcome,
|
|
3136
|
+
source_connection_id: z.uuid(),
|
|
3137
|
+
});
|
|
3116
3138
|
export const zRequirementId = z.enum([
|
|
3117
3139
|
"organization_identity",
|
|
3118
3140
|
"legal_issuer_identity",
|
|
@@ -3324,6 +3346,74 @@ export const zSourceFiscalOperationPage = z.object({
|
|
|
3324
3346
|
* Government classification retained as caller-declared Source context.
|
|
3325
3347
|
*/
|
|
3326
3348
|
export const zSourceItemKind = z.enum(["good", "service"]);
|
|
3349
|
+
/**
|
|
3350
|
+
* A DGII e-CF unit of measure: a readable lowercase name on the Source and Invoice wire,
|
|
3351
|
+
* the official numeric catalog code in fiscal documents.
|
|
3352
|
+
*/
|
|
3353
|
+
export const zSourceMeasurementUnit = z.enum([
|
|
3354
|
+
"barrel",
|
|
3355
|
+
"bag",
|
|
3356
|
+
"jar",
|
|
3357
|
+
"bundle",
|
|
3358
|
+
"bottle",
|
|
3359
|
+
"box",
|
|
3360
|
+
"cigarette_pack",
|
|
3361
|
+
"centimetre",
|
|
3362
|
+
"cylinder",
|
|
3363
|
+
"set",
|
|
3364
|
+
"container",
|
|
3365
|
+
"day",
|
|
3366
|
+
"dozen",
|
|
3367
|
+
"bale",
|
|
3368
|
+
"gallon",
|
|
3369
|
+
"degree",
|
|
3370
|
+
"gram",
|
|
3371
|
+
"bulk",
|
|
3372
|
+
"hour",
|
|
3373
|
+
"crate",
|
|
3374
|
+
"kilogram",
|
|
3375
|
+
"kilowatt_hour",
|
|
3376
|
+
"pound",
|
|
3377
|
+
"litre",
|
|
3378
|
+
"lot",
|
|
3379
|
+
"metre",
|
|
3380
|
+
"square_metre",
|
|
3381
|
+
"cubic_metre",
|
|
3382
|
+
"million_btu",
|
|
3383
|
+
"minute",
|
|
3384
|
+
"package",
|
|
3385
|
+
"pair",
|
|
3386
|
+
"foot",
|
|
3387
|
+
"piece",
|
|
3388
|
+
"roll",
|
|
3389
|
+
"envelope",
|
|
3390
|
+
"second",
|
|
3391
|
+
"tank",
|
|
3392
|
+
"ton",
|
|
3393
|
+
"tube",
|
|
3394
|
+
"yard",
|
|
3395
|
+
"square_yard",
|
|
3396
|
+
"unit",
|
|
3397
|
+
"element",
|
|
3398
|
+
"thousand",
|
|
3399
|
+
"sack",
|
|
3400
|
+
"tin",
|
|
3401
|
+
"display",
|
|
3402
|
+
"drum",
|
|
3403
|
+
"ration",
|
|
3404
|
+
"quintal",
|
|
3405
|
+
"gross_register_tonnage",
|
|
3406
|
+
"square_foot",
|
|
3407
|
+
"passenger",
|
|
3408
|
+
"inch",
|
|
3409
|
+
"boat_berth_stay",
|
|
3410
|
+
"tray",
|
|
3411
|
+
"hectare",
|
|
3412
|
+
"millilitre",
|
|
3413
|
+
"milligram",
|
|
3414
|
+
"ounce",
|
|
3415
|
+
"troy_ounce",
|
|
3416
|
+
]);
|
|
3327
3417
|
export const zInvoiceItemResource = z.object({
|
|
3328
3418
|
additionalTaxCodes: z.array(z.string()),
|
|
3329
3419
|
adjustments: zInvoiceLinePriceAdjustmentsResource.nullable(),
|
|
@@ -3334,13 +3424,10 @@ export const zInvoiceItemResource = z.object({
|
|
|
3334
3424
|
legalTip: z.boolean(),
|
|
3335
3425
|
quantity: z.string().regex(/^(?=[0-9.]*[1-9])[0-9]{1,16}(\.[0-9]{1,2})?$/),
|
|
3336
3426
|
tax: zInvoiceTax,
|
|
3337
|
-
unit:
|
|
3427
|
+
unit: zSourceMeasurementUnit,
|
|
3338
3428
|
unitPrice: z.string().regex(/^[0-9]{1,16}(\.[0-9]{1,4})?$/),
|
|
3339
3429
|
withholding: zInvoiceItemWithholding.nullable(),
|
|
3340
3430
|
});
|
|
3341
|
-
/**
|
|
3342
|
-
* Common semantic measurement units mapped to official DGII catalog codes by fiscal-document.
|
|
3343
|
-
*/
|
|
3344
3431
|
export const zSourcePaymentMethod = z.enum([
|
|
3345
3432
|
"cash",
|
|
3346
3433
|
"bank_transfer",
|
|
@@ -5162,6 +5249,7 @@ export const zWorkspaceFiscalOperationResource = z.object({
|
|
|
5162
5249
|
*/
|
|
5163
5250
|
export const zCreateHostedTenantResponse = zHostedTenantResource;
|
|
5164
5251
|
export const zReleaseHostedTenantResponse = zReleasedHostedTenant;
|
|
5252
|
+
export const zRepairHostedTenantSourceConnectionResponse = zRepairedHostedTenantSourceConnection;
|
|
5165
5253
|
export const zCreateHostedTenantWebhookSecretRotationResponse = zHostedWebhookSecretRotation;
|
|
5166
5254
|
export const zUploadHostedCertificationTestSetResponse = zCertificationTestSetResource;
|
|
5167
5255
|
export const zRetrieveHostedCertificationTestSetResponse = zCurrentCertificationTestSet;
|