@talonic/docs 0.21.0 → 0.21.1

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.
Files changed (3) hide show
  1. package/dist/seo.js +242 -7
  2. package/openapi.json +242 -7
  3. package/package.json +1 -1
package/dist/seo.js CHANGED
@@ -173,6 +173,14 @@ var openapi_default = {
173
173
  {
174
174
  name: "Webhooks",
175
175
  description: "Outbound HMAC-signed event webhooks \u2014 configure endpoints and read the event catalog, delivery format, signature scheme, and retry policy."
176
+ },
177
+ {
178
+ name: "Events",
179
+ description: "The tenant event feed \u2014 the timeline of everything that happened (extractions, run completions, review verdicts, delivery outcomes). The same rows webhooks fan out from, so missed webhook deliveries can be reconciled against this feed."
180
+ },
181
+ {
182
+ name: "Provenance",
183
+ description: "Document-level provenance \u2014 deterministic (subject, predicate, object) claims synthesized from captured fields and spans, each carrying its evidence quote and grounded flag."
176
184
  }
177
185
  ],
178
186
  paths: {
@@ -369,6 +377,9 @@ var openapi_default = {
369
377
  "401": {
370
378
  $ref: "#/components/responses/Unauthorized"
371
379
  },
380
+ "402": {
381
+ $ref: "#/components/responses/InsufficientCredits"
382
+ },
372
383
  "403": {
373
384
  $ref: "#/components/responses/Forbidden"
374
385
  },
@@ -9407,17 +9418,102 @@ var openapi_default = {
9407
9418
  }
9408
9419
  }
9409
9420
  },
9421
+ "/v1/billing/packs": {
9422
+ get: {
9423
+ operationId: "getBillingPacks",
9424
+ summary: "List purchasable credit packs",
9425
+ description: "The self-serve credit-purchase catalog: flat prepaid packs\n(1,000 credits = 1 EUR, no volume bonuses). Buy via the checkout URL\nfrom `GET /v1/billing/upgrade-link`.\n",
9426
+ tags: [
9427
+ "Billing"
9428
+ ],
9429
+ responses: {
9430
+ "200": {
9431
+ description: "Credit pack catalog.",
9432
+ content: {
9433
+ "application/json": {
9434
+ schema: {
9435
+ type: "object",
9436
+ required: [
9437
+ "currency",
9438
+ "packs"
9439
+ ],
9440
+ properties: {
9441
+ currency: {
9442
+ type: "string",
9443
+ example: "EUR"
9444
+ },
9445
+ packs: {
9446
+ type: "array",
9447
+ items: {
9448
+ type: "object",
9449
+ required: [
9450
+ "key",
9451
+ "eur",
9452
+ "credits"
9453
+ ],
9454
+ properties: {
9455
+ key: {
9456
+ type: "string",
9457
+ example: "50"
9458
+ },
9459
+ lookupKey: {
9460
+ type: "string",
9461
+ example: "credits_pack_50"
9462
+ },
9463
+ eur: {
9464
+ type: "number",
9465
+ example: 50
9466
+ },
9467
+ credits: {
9468
+ type: "integer",
9469
+ example: 5e4
9470
+ }
9471
+ }
9472
+ }
9473
+ }
9474
+ }
9475
+ }
9476
+ }
9477
+ }
9478
+ },
9479
+ "401": {
9480
+ $ref: "#/components/responses/Unauthorized"
9481
+ },
9482
+ "429": {
9483
+ $ref: "#/components/responses/RateLimitExceeded"
9484
+ }
9485
+ }
9486
+ }
9487
+ },
9410
9488
  "/v1/billing/upgrade-link": {
9411
9489
  get: {
9412
9490
  operationId: "getBillingUpgradeLink",
9413
- summary: "Get an upgrade link",
9414
- description: 'Returns a URL the agent can hand to a human to upgrade the plan or add\npayment. When a hosted billing portal exists this is a portal session\nURL; until then it is a deep link into the dashboard billing settings\n(`provider: "dashboard"`). A human must complete the upgrade.\n',
9491
+ summary: "Get a buy-credits link",
9492
+ description: 'Returns a URL the agent hands to a human to buy prepaid credits. With\nbilling configured this is a real Stripe hosted-Checkout session\n(`provider: "stripe"`) for the selected pack; credits are available\nseconds after the human completes payment. Falls back to a dashboard\nbilling deep link (`provider: "dashboard"`) on deployments without\nStripe. A human must complete the payment either way.\n',
9415
9493
  tags: [
9416
9494
  "Billing"
9417
9495
  ],
9496
+ parameters: [
9497
+ {
9498
+ name: "pack",
9499
+ in: "query",
9500
+ required: false,
9501
+ schema: {
9502
+ type: "string",
9503
+ enum: [
9504
+ "10",
9505
+ "50",
9506
+ "250",
9507
+ "1000"
9508
+ ],
9509
+ default: "50"
9510
+ },
9511
+ description: "Credit pack to check out (see `GET /v1/billing/packs`)."
9512
+ }
9513
+ ],
9418
9514
  responses: {
9419
9515
  "200": {
9420
- description: "Upgrade link.",
9516
+ description: "Buy-credits link.",
9421
9517
  content: {
9422
9518
  "application/json": {
9423
9519
  schema: {
@@ -9431,16 +9527,20 @@ var openapi_default = {
9431
9527
  url: {
9432
9528
  type: "string",
9433
9529
  format: "uri",
9434
- example: "https://app.talonic.com/settings/billing?upgrade=1"
9530
+ example: "https://checkout.stripe.com/c/pay/cs_test_..."
9435
9531
  },
9436
9532
  provider: {
9437
9533
  type: "string",
9438
- description: "'dashboard' (deep link) or 'stripe' (portal session) once a portal exists.",
9439
- example: "dashboard"
9534
+ description: "'stripe' (hosted Checkout session) or 'dashboard' (deep link fallback).",
9535
+ example: "stripe"
9440
9536
  },
9441
9537
  requires_human: {
9442
9538
  type: "boolean"
9443
9539
  },
9540
+ pack: {
9541
+ type: "object",
9542
+ description: "The selected pack (stripe provider only)."
9543
+ },
9444
9544
  message: {
9445
9545
  type: "string"
9446
9546
  }
@@ -17362,6 +17462,99 @@ var openapi_default = {
17362
17462
  }
17363
17463
  }
17364
17464
  },
17465
+ "/v1/events": {
17466
+ get: {
17467
+ tags: [
17468
+ "Events"
17469
+ ],
17470
+ summary: "List tenant events",
17471
+ description: "Newest-first feed of platform events (document.extracted, run.*.completed/failed, result.flagged/approved/rejected, delivery.item.*, case.resolved). Alias of /v1/delivery/events at the API root.\n",
17472
+ operationId: "listEvents",
17473
+ security: [
17474
+ {
17475
+ BearerAuth: []
17476
+ }
17477
+ ],
17478
+ parameters: [
17479
+ {
17480
+ name: "event_type",
17481
+ in: "query",
17482
+ required: false,
17483
+ schema: {
17484
+ type: "string"
17485
+ },
17486
+ description: "Filter by event type, e.g. document.extracted"
17487
+ },
17488
+ {
17489
+ name: "limit",
17490
+ in: "query",
17491
+ required: false,
17492
+ schema: {
17493
+ type: "integer",
17494
+ default: 50,
17495
+ maximum: 200
17496
+ }
17497
+ },
17498
+ {
17499
+ name: "offset",
17500
+ in: "query",
17501
+ required: false,
17502
+ schema: {
17503
+ type: "integer",
17504
+ default: 0
17505
+ }
17506
+ }
17507
+ ],
17508
+ responses: {
17509
+ "200": {
17510
+ description: "{ data: [{ id, event_type, payload, created_at }], total, limit, offset }"
17511
+ }
17512
+ }
17513
+ }
17514
+ },
17515
+ "/v1/documents/{id}/claims": {
17516
+ get: {
17517
+ tags: [
17518
+ "Provenance"
17519
+ ],
17520
+ summary: "List a document's provenance claims",
17521
+ description: "Deterministic atomic (subject, predicate, object) claims synthesized from the document's captured fields + provenance spans (no LLM). Each claim carries its evidence quote, grounded flag, and confidence. Field-level span detail lives on GET /v1/field-reviews/{docId}/{fieldKey}.\n",
17522
+ operationId: "listDocumentClaims",
17523
+ security: [
17524
+ {
17525
+ BearerAuth: []
17526
+ }
17527
+ ],
17528
+ parameters: [
17529
+ {
17530
+ name: "id",
17531
+ in: "path",
17532
+ required: true,
17533
+ schema: {
17534
+ type: "string",
17535
+ format: "uuid"
17536
+ }
17537
+ },
17538
+ {
17539
+ name: "grounded",
17540
+ in: "query",
17541
+ required: false,
17542
+ schema: {
17543
+ type: "boolean"
17544
+ },
17545
+ description: "true = only span-backed claims"
17546
+ }
17547
+ ],
17548
+ responses: {
17549
+ "200": {
17550
+ description: "{ data: [{ subject, predicate, object, qualifier, evidence, segment_id, grounded, confidence, origin }], total }"
17551
+ },
17552
+ "404": {
17553
+ description: "Document not found or not owned by the caller."
17554
+ }
17555
+ }
17556
+ }
17557
+ },
17365
17558
  "/v1/webhooks/events": {
17366
17559
  get: {
17367
17560
  tags: [
@@ -18528,7 +18721,7 @@ var openapi_default = {
18528
18721
  statusCode: 429,
18529
18722
  code: "QUOTA_EXCEEDED",
18530
18723
  error: "Too Many Requests",
18531
- message: "Daily extract request limit (50) reached. Resets at midnight UTC.",
18724
+ message: "Daily extract request ceiling reached. Resets at midnight UTC. Spend is governed by credits, not this abuse ceiling.",
18532
18725
  retryable: true,
18533
18726
  timestamp: "2026-04-25T23:45:00.000Z",
18534
18727
  path: "/v1/extract"
@@ -18536,6 +18729,48 @@ var openapi_default = {
18536
18729
  }
18537
18730
  }
18538
18731
  },
18732
+ InsufficientCredits: {
18733
+ description: "Insufficient credits (402). The body is the agent-actionable contract:\n`buy_credits_url` is where a human completes a purchase (see also\n`GET /v1/billing/upgrade-link` for a direct Stripe Checkout link), and\n`pricing_url` is the machine-readable rate catalog. Free workspaces\nreceive 5,000 credits monthly; purchased credits top up the same\nbalance.\n",
18734
+ content: {
18735
+ "application/json": {
18736
+ schema: {
18737
+ type: "object",
18738
+ required: [
18739
+ "error",
18740
+ "message",
18741
+ "required_credits",
18742
+ "balance_credits"
18743
+ ],
18744
+ properties: {
18745
+ error: {
18746
+ type: "string",
18747
+ example: "insufficient_credits"
18748
+ },
18749
+ message: {
18750
+ type: "string"
18751
+ },
18752
+ required_credits: {
18753
+ type: "integer",
18754
+ example: 100
18755
+ },
18756
+ balance_credits: {
18757
+ type: "integer",
18758
+ example: 0
18759
+ },
18760
+ buy_credits_url: {
18761
+ type: "string",
18762
+ format: "uri",
18763
+ example: "https://app.talonic.com/settings/billing?buy=1"
18764
+ },
18765
+ pricing_url: {
18766
+ type: "string",
18767
+ example: "/v1/pricing"
18768
+ }
18769
+ }
18770
+ }
18771
+ }
18772
+ }
18773
+ },
18539
18774
  InternalServerError: {
18540
18775
  description: "An unexpected error occurred.",
18541
18776
  content: {
package/openapi.json CHANGED
@@ -172,6 +172,14 @@
172
172
  {
173
173
  "name": "Webhooks",
174
174
  "description": "Outbound HMAC-signed event webhooks — configure endpoints and read the event catalog, delivery format, signature scheme, and retry policy."
175
+ },
176
+ {
177
+ "name": "Events",
178
+ "description": "The tenant event feed — the timeline of everything that happened (extractions, run completions, review verdicts, delivery outcomes). The same rows webhooks fan out from, so missed webhook deliveries can be reconciled against this feed."
179
+ },
180
+ {
181
+ "name": "Provenance",
182
+ "description": "Document-level provenance — deterministic (subject, predicate, object) claims synthesized from captured fields and spans, each carrying its evidence quote and grounded flag."
175
183
  }
176
184
  ],
177
185
  "paths": {
@@ -368,6 +376,9 @@
368
376
  "401": {
369
377
  "$ref": "#/components/responses/Unauthorized"
370
378
  },
379
+ "402": {
380
+ "$ref": "#/components/responses/InsufficientCredits"
381
+ },
371
382
  "403": {
372
383
  "$ref": "#/components/responses/Forbidden"
373
384
  },
@@ -9387,17 +9398,102 @@
9387
9398
  }
9388
9399
  }
9389
9400
  },
9401
+ "/v1/billing/packs": {
9402
+ "get": {
9403
+ "operationId": "getBillingPacks",
9404
+ "summary": "List purchasable credit packs",
9405
+ "description": "The self-serve credit-purchase catalog: flat prepaid packs\n(1,000 credits = 1 EUR, no volume bonuses). Buy via the checkout URL\nfrom `GET /v1/billing/upgrade-link`.\n",
9406
+ "tags": [
9407
+ "Billing"
9408
+ ],
9409
+ "responses": {
9410
+ "200": {
9411
+ "description": "Credit pack catalog.",
9412
+ "content": {
9413
+ "application/json": {
9414
+ "schema": {
9415
+ "type": "object",
9416
+ "required": [
9417
+ "currency",
9418
+ "packs"
9419
+ ],
9420
+ "properties": {
9421
+ "currency": {
9422
+ "type": "string",
9423
+ "example": "EUR"
9424
+ },
9425
+ "packs": {
9426
+ "type": "array",
9427
+ "items": {
9428
+ "type": "object",
9429
+ "required": [
9430
+ "key",
9431
+ "eur",
9432
+ "credits"
9433
+ ],
9434
+ "properties": {
9435
+ "key": {
9436
+ "type": "string",
9437
+ "example": "50"
9438
+ },
9439
+ "lookupKey": {
9440
+ "type": "string",
9441
+ "example": "credits_pack_50"
9442
+ },
9443
+ "eur": {
9444
+ "type": "number",
9445
+ "example": 50
9446
+ },
9447
+ "credits": {
9448
+ "type": "integer",
9449
+ "example": 50000
9450
+ }
9451
+ }
9452
+ }
9453
+ }
9454
+ }
9455
+ }
9456
+ }
9457
+ }
9458
+ },
9459
+ "401": {
9460
+ "$ref": "#/components/responses/Unauthorized"
9461
+ },
9462
+ "429": {
9463
+ "$ref": "#/components/responses/RateLimitExceeded"
9464
+ }
9465
+ }
9466
+ }
9467
+ },
9390
9468
  "/v1/billing/upgrade-link": {
9391
9469
  "get": {
9392
9470
  "operationId": "getBillingUpgradeLink",
9393
- "summary": "Get an upgrade link",
9394
- "description": "Returns a URL the agent can hand to a human to upgrade the plan or add\npayment. When a hosted billing portal exists this is a portal session\nURL; until then it is a deep link into the dashboard billing settings\n(`provider: \"dashboard\"`). A human must complete the upgrade.\n",
9471
+ "summary": "Get a buy-credits link",
9472
+ "description": "Returns a URL the agent hands to a human to buy prepaid credits. With\nbilling configured this is a real Stripe hosted-Checkout session\n(`provider: \"stripe\"`) for the selected pack; credits are available\nseconds after the human completes payment. Falls back to a dashboard\nbilling deep link (`provider: \"dashboard\"`) on deployments without\nStripe. A human must complete the payment either way.\n",
9395
9473
  "tags": [
9396
9474
  "Billing"
9397
9475
  ],
9476
+ "parameters": [
9477
+ {
9478
+ "name": "pack",
9479
+ "in": "query",
9480
+ "required": false,
9481
+ "schema": {
9482
+ "type": "string",
9483
+ "enum": [
9484
+ "10",
9485
+ "50",
9486
+ "250",
9487
+ "1000"
9488
+ ],
9489
+ "default": "50"
9490
+ },
9491
+ "description": "Credit pack to check out (see `GET /v1/billing/packs`)."
9492
+ }
9493
+ ],
9398
9494
  "responses": {
9399
9495
  "200": {
9400
- "description": "Upgrade link.",
9496
+ "description": "Buy-credits link.",
9401
9497
  "content": {
9402
9498
  "application/json": {
9403
9499
  "schema": {
@@ -9411,16 +9507,20 @@
9411
9507
  "url": {
9412
9508
  "type": "string",
9413
9509
  "format": "uri",
9414
- "example": "https://app.talonic.com/settings/billing?upgrade=1"
9510
+ "example": "https://checkout.stripe.com/c/pay/cs_test_..."
9415
9511
  },
9416
9512
  "provider": {
9417
9513
  "type": "string",
9418
- "description": "'dashboard' (deep link) or 'stripe' (portal session) once a portal exists.",
9419
- "example": "dashboard"
9514
+ "description": "'stripe' (hosted Checkout session) or 'dashboard' (deep link fallback).",
9515
+ "example": "stripe"
9420
9516
  },
9421
9517
  "requires_human": {
9422
9518
  "type": "boolean"
9423
9519
  },
9520
+ "pack": {
9521
+ "type": "object",
9522
+ "description": "The selected pack (stripe provider only)."
9523
+ },
9424
9524
  "message": {
9425
9525
  "type": "string"
9426
9526
  }
@@ -17342,6 +17442,99 @@
17342
17442
  }
17343
17443
  }
17344
17444
  },
17445
+ "/v1/events": {
17446
+ "get": {
17447
+ "tags": [
17448
+ "Events"
17449
+ ],
17450
+ "summary": "List tenant events",
17451
+ "description": "Newest-first feed of platform events (document.extracted, run.*.completed/failed, result.flagged/approved/rejected, delivery.item.*, case.resolved). Alias of /v1/delivery/events at the API root.\n",
17452
+ "operationId": "listEvents",
17453
+ "security": [
17454
+ {
17455
+ "BearerAuth": []
17456
+ }
17457
+ ],
17458
+ "parameters": [
17459
+ {
17460
+ "name": "event_type",
17461
+ "in": "query",
17462
+ "required": false,
17463
+ "schema": {
17464
+ "type": "string"
17465
+ },
17466
+ "description": "Filter by event type, e.g. document.extracted"
17467
+ },
17468
+ {
17469
+ "name": "limit",
17470
+ "in": "query",
17471
+ "required": false,
17472
+ "schema": {
17473
+ "type": "integer",
17474
+ "default": 50,
17475
+ "maximum": 200
17476
+ }
17477
+ },
17478
+ {
17479
+ "name": "offset",
17480
+ "in": "query",
17481
+ "required": false,
17482
+ "schema": {
17483
+ "type": "integer",
17484
+ "default": 0
17485
+ }
17486
+ }
17487
+ ],
17488
+ "responses": {
17489
+ "200": {
17490
+ "description": "{ data: [{ id, event_type, payload, created_at }], total, limit, offset }"
17491
+ }
17492
+ }
17493
+ }
17494
+ },
17495
+ "/v1/documents/{id}/claims": {
17496
+ "get": {
17497
+ "tags": [
17498
+ "Provenance"
17499
+ ],
17500
+ "summary": "List a document's provenance claims",
17501
+ "description": "Deterministic atomic (subject, predicate, object) claims synthesized from the document's captured fields + provenance spans (no LLM). Each claim carries its evidence quote, grounded flag, and confidence. Field-level span detail lives on GET /v1/field-reviews/{docId}/{fieldKey}.\n",
17502
+ "operationId": "listDocumentClaims",
17503
+ "security": [
17504
+ {
17505
+ "BearerAuth": []
17506
+ }
17507
+ ],
17508
+ "parameters": [
17509
+ {
17510
+ "name": "id",
17511
+ "in": "path",
17512
+ "required": true,
17513
+ "schema": {
17514
+ "type": "string",
17515
+ "format": "uuid"
17516
+ }
17517
+ },
17518
+ {
17519
+ "name": "grounded",
17520
+ "in": "query",
17521
+ "required": false,
17522
+ "schema": {
17523
+ "type": "boolean"
17524
+ },
17525
+ "description": "true = only span-backed claims"
17526
+ }
17527
+ ],
17528
+ "responses": {
17529
+ "200": {
17530
+ "description": "{ data: [{ subject, predicate, object, qualifier, evidence, segment_id, grounded, confidence, origin }], total }"
17531
+ },
17532
+ "404": {
17533
+ "description": "Document not found or not owned by the caller."
17534
+ }
17535
+ }
17536
+ }
17537
+ },
17345
17538
  "/v1/webhooks/events": {
17346
17539
  "get": {
17347
17540
  "tags": [
@@ -18508,7 +18701,7 @@
18508
18701
  "statusCode": 429,
18509
18702
  "code": "QUOTA_EXCEEDED",
18510
18703
  "error": "Too Many Requests",
18511
- "message": "Daily extract request limit (50) reached. Resets at midnight UTC.",
18704
+ "message": "Daily extract request ceiling reached. Resets at midnight UTC. Spend is governed by credits, not this abuse ceiling.",
18512
18705
  "retryable": true,
18513
18706
  "timestamp": "2026-04-25T23:45:00.000Z",
18514
18707
  "path": "/v1/extract"
@@ -18516,6 +18709,48 @@
18516
18709
  }
18517
18710
  }
18518
18711
  },
18712
+ "InsufficientCredits": {
18713
+ "description": "Insufficient credits (402). The body is the agent-actionable contract:\n`buy_credits_url` is where a human completes a purchase (see also\n`GET /v1/billing/upgrade-link` for a direct Stripe Checkout link), and\n`pricing_url` is the machine-readable rate catalog. Free workspaces\nreceive 5,000 credits monthly; purchased credits top up the same\nbalance.\n",
18714
+ "content": {
18715
+ "application/json": {
18716
+ "schema": {
18717
+ "type": "object",
18718
+ "required": [
18719
+ "error",
18720
+ "message",
18721
+ "required_credits",
18722
+ "balance_credits"
18723
+ ],
18724
+ "properties": {
18725
+ "error": {
18726
+ "type": "string",
18727
+ "example": "insufficient_credits"
18728
+ },
18729
+ "message": {
18730
+ "type": "string"
18731
+ },
18732
+ "required_credits": {
18733
+ "type": "integer",
18734
+ "example": 100
18735
+ },
18736
+ "balance_credits": {
18737
+ "type": "integer",
18738
+ "example": 0
18739
+ },
18740
+ "buy_credits_url": {
18741
+ "type": "string",
18742
+ "format": "uri",
18743
+ "example": "https://app.talonic.com/settings/billing?buy=1"
18744
+ },
18745
+ "pricing_url": {
18746
+ "type": "string",
18747
+ "example": "/v1/pricing"
18748
+ }
18749
+ }
18750
+ }
18751
+ }
18752
+ }
18753
+ },
18519
18754
  "InternalServerError": {
18520
18755
  "description": "An unexpected error occurred.",
18521
18756
  "content": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@talonic/docs",
3
- "version": "0.21.0",
3
+ "version": "0.21.1",
4
4
  "description": "Talonic documentation components — API Reference & Platform Guide",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,