@botpress/api 0.15.12 → 0.16.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/src/gen/state.ts CHANGED
@@ -16,6 +16,7 @@ export type State = opapi.State<
16
16
  | "Event"
17
17
  | "Message"
18
18
  | "State"
19
+ | "Task"
19
20
  | "File"
20
21
  | "Table"
21
22
  | "Column"
@@ -29,6 +30,7 @@ export type State = opapi.State<
29
30
  | "state"
30
31
  | "hub"
31
32
  | "action"
33
+ | "task"
32
34
  | "bot"
33
35
  | "integration"
34
36
  | "workspace"
@@ -1533,6 +1535,308 @@ export const state = {
1533
1535
  },
1534
1536
  parameters: {},
1535
1537
  },
1538
+ getTask: {
1539
+ name: "getTask",
1540
+ description:
1541
+ "Retrieves the [Task](#schema_task) object for a valid identifier.",
1542
+ method: "get",
1543
+ path: "/v1/chat/tasks/{id}",
1544
+ parameters: {
1545
+ id: {
1546
+ in: "path",
1547
+ type: "string",
1548
+ description: "Task id",
1549
+ },
1550
+ },
1551
+ section: "task",
1552
+ response: {
1553
+ description:
1554
+ "Returns a [Task](#schema_task) object if a valid identifier was provided. Returns [an error](#errors) otherwise",
1555
+ schema: {
1556
+ type: "object",
1557
+ properties: {
1558
+ task: {
1559
+ $ref: "#/components/schemas/Task",
1560
+ },
1561
+ },
1562
+ required: ["task"],
1563
+ title: "getTaskResponse",
1564
+ additionalProperties: false,
1565
+ },
1566
+ },
1567
+ },
1568
+ createTask: {
1569
+ name: "createTask",
1570
+ description:
1571
+ "Creates a new [Task](#schema_task). When creating a new [Task](#schema_task), the required tags must be provided. See the specific integration for more details.",
1572
+ method: "post",
1573
+ path: "/v1/chat/tasks",
1574
+ requestBody: {
1575
+ description: "Task data",
1576
+ schema: {
1577
+ type: "object",
1578
+ properties: {
1579
+ title: {
1580
+ type: "string",
1581
+ description: "Title describing the task",
1582
+ },
1583
+ instruction: {
1584
+ type: "string",
1585
+ description:
1586
+ "All the notes related to the execution of the current task",
1587
+ },
1588
+ type: {
1589
+ type: "string",
1590
+ description: "Type of the task",
1591
+ },
1592
+ data: {
1593
+ type: "object",
1594
+ additionalProperties: true,
1595
+ description: "Content related to the task",
1596
+ },
1597
+ parentTaskId: {
1598
+ type: "string",
1599
+ description:
1600
+ "Parent task id is the parent task that created this task",
1601
+ },
1602
+ conversationId: {
1603
+ type: "string",
1604
+ description: "Conversation id related to this task",
1605
+ },
1606
+ userId: {
1607
+ type: "string",
1608
+ description: "Specific user related to this task",
1609
+ },
1610
+ timeoutAt: {
1611
+ type: "string",
1612
+ format: "date-time",
1613
+ description:
1614
+ "The timeout date where the task should be failed in the ISO 8601 format",
1615
+ },
1616
+ tags: {
1617
+ type: "object",
1618
+ additionalProperties: {
1619
+ type: "string",
1620
+ maxLength: 500,
1621
+ },
1622
+ description: "Tags for the [Task](#schema_task)",
1623
+ },
1624
+ },
1625
+ required: ["title", "type", "conversationId"],
1626
+ title: "createTaskBody",
1627
+ additionalProperties: false,
1628
+ },
1629
+ },
1630
+ section: "task",
1631
+ response: {
1632
+ description:
1633
+ "Returns a [Task](#schema_task) object if creation succeeds. Returns [an error](#errors) otherwise",
1634
+ status: 201,
1635
+ schema: {
1636
+ type: "object",
1637
+ properties: {
1638
+ task: {
1639
+ $ref: "#/components/schemas/Task",
1640
+ },
1641
+ },
1642
+ required: ["task"],
1643
+ title: "createTaskResponse",
1644
+ additionalProperties: false,
1645
+ },
1646
+ },
1647
+ parameters: {},
1648
+ },
1649
+ updateTask: {
1650
+ name: "updateTask",
1651
+ description:
1652
+ "Update a [Task](#schema_task) object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.",
1653
+ method: "put",
1654
+ path: "/v1/chat/tasks/{id}",
1655
+ parameters: {
1656
+ id: {
1657
+ in: "path",
1658
+ type: "string",
1659
+ description: "Task id",
1660
+ },
1661
+ },
1662
+ requestBody: {
1663
+ description: "Task data",
1664
+ schema: {
1665
+ type: "object",
1666
+ properties: {
1667
+ title: {
1668
+ type: "string",
1669
+ description: "Title describing the task",
1670
+ },
1671
+ instruction: {
1672
+ type: "string",
1673
+ description:
1674
+ "All the notes related to the execution of the current task",
1675
+ },
1676
+ data: {
1677
+ type: "object",
1678
+ additionalProperties: true,
1679
+ description: "Content related to the task",
1680
+ },
1681
+ timeoutAt: {
1682
+ type: "string",
1683
+ format: "date-time",
1684
+ description:
1685
+ "The timeout date where the task should be failed in the ISO 8601 format",
1686
+ },
1687
+ status: {
1688
+ type: "string",
1689
+ enum: [
1690
+ "pending",
1691
+ "in_progress",
1692
+ "failed",
1693
+ "completed",
1694
+ "blocked",
1695
+ "paused",
1696
+ ],
1697
+ description: "Status of the task",
1698
+ },
1699
+ tags: {
1700
+ type: "object",
1701
+ additionalProperties: {
1702
+ type: "string",
1703
+ maxLength: 500,
1704
+ },
1705
+ description: "Tags for the [Task](#schema_task)",
1706
+ },
1707
+ },
1708
+ title: "updateTaskBody",
1709
+ additionalProperties: false,
1710
+ },
1711
+ },
1712
+ section: "task",
1713
+ response: {
1714
+ description:
1715
+ "Returns an updated [Task](#schema_task) object if a valid identifier was provided. Returns [an error](#errors) otherwise",
1716
+ schema: {
1717
+ type: "object",
1718
+ properties: {
1719
+ task: {
1720
+ $ref: "#/components/schemas/Task",
1721
+ },
1722
+ },
1723
+ required: ["task"],
1724
+ title: "updateTaskResponse",
1725
+ additionalProperties: false,
1726
+ },
1727
+ },
1728
+ },
1729
+ deleteTask: {
1730
+ name: "deleteTask",
1731
+ description:
1732
+ "Permanently deletes a [Task](#schema_task). It cannot be undone.",
1733
+ method: "delete",
1734
+ path: "/v1/chat/tasks/{id}",
1735
+ parameters: {
1736
+ id: {
1737
+ in: "path",
1738
+ type: "string",
1739
+ description: "Task id",
1740
+ },
1741
+ },
1742
+ section: "task",
1743
+ response: {
1744
+ description: "Returns the [Task](#schema_task) object that was deleted",
1745
+ schema: {
1746
+ type: "object",
1747
+ title: "deleteTaskResponse",
1748
+ additionalProperties: false,
1749
+ },
1750
+ },
1751
+ },
1752
+ listTasks: {
1753
+ name: "listTasks",
1754
+ description:
1755
+ "Retrieves a list of [Task](#schema_task) you've previously created. The tasks are returned in sorted order, with the most recent appearing first. The list can be filtered using [Tags](#tags).",
1756
+ method: "get",
1757
+ path: "/v1/chat/tasks",
1758
+ parameters: {
1759
+ nextToken: {
1760
+ in: "query",
1761
+ description:
1762
+ "Provide the `meta.nextToken` value provided in the last API response to retrieve the next page of results",
1763
+ type: "string",
1764
+ },
1765
+ tags: {
1766
+ in: "query",
1767
+ type: "object",
1768
+ schema: {
1769
+ type: "object",
1770
+ additionalProperties: {
1771
+ type: "string",
1772
+ },
1773
+ },
1774
+ description: "Filter by tags",
1775
+ },
1776
+ conversationId: {
1777
+ in: "query",
1778
+ type: "string",
1779
+ description: "Conversation id",
1780
+ },
1781
+ userId: {
1782
+ in: "query",
1783
+ type: "string",
1784
+ description: "User id",
1785
+ },
1786
+ parentTaskId: {
1787
+ in: "query",
1788
+ type: "string",
1789
+ description: "Parent task id",
1790
+ },
1791
+ status: {
1792
+ in: "query",
1793
+ type: "string",
1794
+ description: "Status",
1795
+ enum: [
1796
+ "pending",
1797
+ "in_progress",
1798
+ "failed",
1799
+ "completed",
1800
+ "blocked",
1801
+ "paused",
1802
+ ],
1803
+ },
1804
+ type: {
1805
+ in: "query",
1806
+ type: "string",
1807
+ description: "Type",
1808
+ },
1809
+ },
1810
+ section: "task",
1811
+ response: {
1812
+ description: "Returns a list of [Task](#schema_task) objects",
1813
+ schema: {
1814
+ type: "object",
1815
+ properties: {
1816
+ tasks: {
1817
+ type: "array",
1818
+ items: {
1819
+ $ref: "#/components/schemas/Task",
1820
+ },
1821
+ },
1822
+ meta: {
1823
+ type: "object",
1824
+ properties: {
1825
+ nextToken: {
1826
+ type: "string",
1827
+ description:
1828
+ "The token to use to retrieve the next page of results, passed as a query string parameter (value should be URL-encoded) to this API endpoint.",
1829
+ },
1830
+ },
1831
+ additionalProperties: false,
1832
+ },
1833
+ },
1834
+ required: ["tasks", "meta"],
1835
+ title: "listTasksResponse",
1836
+ additionalProperties: false,
1837
+ },
1838
+ },
1839
+ },
1536
1840
  runVrl: {
1537
1841
  name: "runVrl",
1538
1842
  description: "Run a VRL script",
@@ -2096,6 +2400,26 @@ export const state = {
2096
2400
  additionalProperties: false,
2097
2401
  },
2098
2402
  },
2403
+ subscriptions: {
2404
+ type: "object",
2405
+ properties: {
2406
+ events: {
2407
+ type: "object",
2408
+ additionalProperties: {
2409
+ type: "object",
2410
+ additionalProperties: {
2411
+ readOnly: true,
2412
+ },
2413
+ },
2414
+ nullable: true,
2415
+ description:
2416
+ 'Events that the bot is currently subscribed on (ex: "slack:reactionAdded"). If null, the bot is subscribed to all events.',
2417
+ },
2418
+ },
2419
+ required: ["events"],
2420
+ description: "Subscriptions of the bot",
2421
+ additionalProperties: false,
2422
+ },
2099
2423
  configuration: {
2100
2424
  type: "object",
2101
2425
  properties: {
@@ -2495,6 +2819,24 @@ export const state = {
2495
2819
  additionalProperties: false,
2496
2820
  },
2497
2821
  },
2822
+ subscriptions: {
2823
+ type: "object",
2824
+ properties: {
2825
+ events: {
2826
+ type: "object",
2827
+ additionalProperties: {
2828
+ type: "object",
2829
+ additionalProperties: {
2830
+ readOnly: true,
2831
+ },
2832
+ nullable: true,
2833
+ },
2834
+ nullable: true,
2835
+ },
2836
+ },
2837
+ required: ["events"],
2838
+ additionalProperties: false,
2839
+ },
2498
2840
  code: {
2499
2841
  type: "string",
2500
2842
  description: "JavaScript code of the bot",
@@ -3520,6 +3862,36 @@ export const state = {
3520
3862
  spendingLimit: {
3521
3863
  type: "number",
3522
3864
  },
3865
+ about: {
3866
+ default: "",
3867
+ type: "string",
3868
+ },
3869
+ profilePicture: {
3870
+ default: "",
3871
+ type: "string",
3872
+ },
3873
+ contactEmail: {
3874
+ default: "",
3875
+ type: "string",
3876
+ },
3877
+ website: {
3878
+ default: "",
3879
+ type: "string",
3880
+ },
3881
+ socialAccounts: {
3882
+ default: [],
3883
+ type: "array",
3884
+ items: {
3885
+ type: "string",
3886
+ },
3887
+ },
3888
+ isPublic: {
3889
+ type: "boolean",
3890
+ },
3891
+ handle: {
3892
+ default: "",
3893
+ type: "string",
3894
+ },
3523
3895
  },
3524
3896
  required: [
3525
3897
  "id",
@@ -3597,6 +3969,36 @@ export const state = {
3597
3969
  spendingLimit: {
3598
3970
  type: "number",
3599
3971
  },
3972
+ about: {
3973
+ default: "",
3974
+ type: "string",
3975
+ },
3976
+ profilePicture: {
3977
+ default: "",
3978
+ type: "string",
3979
+ },
3980
+ contactEmail: {
3981
+ default: "",
3982
+ type: "string",
3983
+ },
3984
+ website: {
3985
+ default: "",
3986
+ type: "string",
3987
+ },
3988
+ socialAccounts: {
3989
+ default: [],
3990
+ type: "array",
3991
+ items: {
3992
+ type: "string",
3993
+ },
3994
+ },
3995
+ isPublic: {
3996
+ type: "boolean",
3997
+ },
3998
+ handle: {
3999
+ default: "",
4000
+ type: "string",
4001
+ },
3600
4002
  },
3601
4003
  required: [
3602
4004
  "id",
@@ -3984,9 +4386,37 @@ export const state = {
3984
4386
  minimum: 5,
3985
4387
  maximum: 1000,
3986
4388
  },
4389
+ about: {
4390
+ type: "string",
4391
+ },
4392
+ profilePicture: {
4393
+ type: "string",
4394
+ },
4395
+ contactEmail: {
4396
+ type: "string",
4397
+ },
4398
+ website: {
4399
+ type: "string",
4400
+ },
4401
+ socialAccounts: {
4402
+ type: "array",
4403
+ items: {
4404
+ type: "string",
4405
+ },
4406
+ maxItems: 5,
4407
+ },
4408
+ isPublic: {
4409
+ type: "boolean",
4410
+ },
4411
+ handle: {
4412
+ type: "string",
4413
+ minLength: 1,
4414
+ maxLength: 64,
4415
+ pattern: "^[0-9a-z][a-z0-9-]+[0-9a-z]$",
4416
+ },
3987
4417
  },
3988
- title: "updateWorkspaceBody",
3989
4418
  additionalProperties: false,
4419
+ title: "updateWorkspaceBody",
3990
4420
  },
3991
4421
  },
3992
4422
  response: {
@@ -4030,6 +4460,36 @@ export const state = {
4030
4460
  spendingLimit: {
4031
4461
  type: "number",
4032
4462
  },
4463
+ about: {
4464
+ default: "",
4465
+ type: "string",
4466
+ },
4467
+ profilePicture: {
4468
+ default: "",
4469
+ type: "string",
4470
+ },
4471
+ contactEmail: {
4472
+ default: "",
4473
+ type: "string",
4474
+ },
4475
+ website: {
4476
+ default: "",
4477
+ type: "string",
4478
+ },
4479
+ socialAccounts: {
4480
+ default: [],
4481
+ type: "array",
4482
+ items: {
4483
+ type: "string",
4484
+ },
4485
+ },
4486
+ isPublic: {
4487
+ type: "boolean",
4488
+ },
4489
+ handle: {
4490
+ default: "",
4491
+ type: "string",
4492
+ },
4033
4493
  },
4034
4494
  required: [
4035
4495
  "id",
@@ -4049,6 +4509,57 @@ export const state = {
4049
4509
  },
4050
4510
  },
4051
4511
  },
4512
+ checkHandleAvailability: {
4513
+ name: "checkHandleAvailability",
4514
+ description: "Check if a workspace handle is available",
4515
+ section: "workspace",
4516
+ method: "put",
4517
+ disableDefaultParameters: {
4518
+ "x-workspace-id": true,
4519
+ },
4520
+ path: "/v1/admin/workspaces/handle-availability",
4521
+ requestBody: {
4522
+ description: "Workspace handle availability",
4523
+ schema: {
4524
+ type: "object",
4525
+ properties: {
4526
+ handle: {
4527
+ type: "string",
4528
+ minLength: 1,
4529
+ maxLength: 50,
4530
+ pattern: "^[a-z0-9-_]+$",
4531
+ },
4532
+ },
4533
+ required: ["handle"],
4534
+ title: "checkHandleAvailabilityBody",
4535
+ additionalProperties: false,
4536
+ },
4537
+ },
4538
+ response: {
4539
+ description: "Success",
4540
+ schema: {
4541
+ type: "object",
4542
+ properties: {
4543
+ available: {
4544
+ type: "boolean",
4545
+ },
4546
+ suggestions: {
4547
+ type: "array",
4548
+ items: {
4549
+ type: "string",
4550
+ },
4551
+ },
4552
+ usedBy: {
4553
+ type: "string",
4554
+ },
4555
+ },
4556
+ required: ["available", "suggestions"],
4557
+ title: "checkHandleAvailabilityResponse",
4558
+ additionalProperties: false,
4559
+ },
4560
+ },
4561
+ parameters: {},
4562
+ },
4052
4563
  listWorkspaces: {
4053
4564
  name: "listWorkspaces",
4054
4565
  description: "List workspaces the user has access to",
@@ -4094,23 +4605,53 @@ export const state = {
4094
4605
  botCount: {
4095
4606
  type: "number",
4096
4607
  },
4097
- accountType: {
4608
+ accountType: {
4609
+ type: "string",
4610
+ enum: ["free", "premium"],
4611
+ },
4612
+ billingVersion: {
4613
+ type: "string",
4614
+ enum: ["v1", "v2"],
4615
+ },
4616
+ plan: {
4617
+ type: "string",
4618
+ enum: ["community", "team", "enterprise"],
4619
+ },
4620
+ blocked: {
4621
+ type: "boolean",
4622
+ },
4623
+ spendingLimit: {
4624
+ type: "number",
4625
+ },
4626
+ about: {
4627
+ default: "",
4628
+ type: "string",
4629
+ },
4630
+ profilePicture: {
4631
+ default: "",
4098
4632
  type: "string",
4099
- enum: ["free", "premium"],
4100
4633
  },
4101
- billingVersion: {
4634
+ contactEmail: {
4635
+ default: "",
4102
4636
  type: "string",
4103
- enum: ["v1", "v2"],
4104
4637
  },
4105
- plan: {
4638
+ website: {
4639
+ default: "",
4106
4640
  type: "string",
4107
- enum: ["community", "team", "enterprise"],
4108
4641
  },
4109
- blocked: {
4642
+ socialAccounts: {
4643
+ default: [],
4644
+ type: "array",
4645
+ items: {
4646
+ type: "string",
4647
+ },
4648
+ },
4649
+ isPublic: {
4110
4650
  type: "boolean",
4111
4651
  },
4112
- spendingLimit: {
4113
- type: "number",
4652
+ handle: {
4653
+ default: "",
4654
+ type: "string",
4114
4655
  },
4115
4656
  },
4116
4657
  required: [
@@ -4219,6 +4760,36 @@ export const state = {
4219
4760
  spendingLimit: {
4220
4761
  type: "number",
4221
4762
  },
4763
+ about: {
4764
+ default: "",
4765
+ type: "string",
4766
+ },
4767
+ profilePicture: {
4768
+ default: "",
4769
+ type: "string",
4770
+ },
4771
+ contactEmail: {
4772
+ default: "",
4773
+ type: "string",
4774
+ },
4775
+ website: {
4776
+ default: "",
4777
+ type: "string",
4778
+ },
4779
+ socialAccounts: {
4780
+ default: [],
4781
+ type: "array",
4782
+ items: {
4783
+ type: "string",
4784
+ },
4785
+ },
4786
+ isPublic: {
4787
+ type: "boolean",
4788
+ },
4789
+ handle: {
4790
+ default: "",
4791
+ type: "string",
4792
+ },
4222
4793
  },
4223
4794
  required: [
4224
4795
  "id",
@@ -4406,6 +4977,9 @@ export const state = {
4406
4977
  email: {
4407
4978
  type: "string",
4408
4979
  },
4980
+ createdAt: {
4981
+ type: "string",
4982
+ },
4409
4983
  role: {
4410
4984
  type: "string",
4411
4985
  enum: [
@@ -4418,7 +4992,7 @@ export const state = {
4418
4992
  ],
4419
4993
  },
4420
4994
  },
4421
- required: ["id", "email", "role"],
4995
+ required: ["id", "email", "createdAt", "role"],
4422
4996
  },
4423
4997
  },
4424
4998
  meta: {
@@ -4508,6 +5082,9 @@ export const state = {
4508
5082
  email: {
4509
5083
  type: "string",
4510
5084
  },
5085
+ createdAt: {
5086
+ type: "string",
5087
+ },
4511
5088
  role: {
4512
5089
  type: "string",
4513
5090
  enum: [
@@ -4520,7 +5097,7 @@ export const state = {
4520
5097
  ],
4521
5098
  },
4522
5099
  },
4523
- required: ["id", "email", "role"],
5100
+ required: ["id", "email", "createdAt", "role"],
4524
5101
  title: "createWorkspaceMemberResponse",
4525
5102
  additionalProperties: false,
4526
5103
  },
@@ -4576,6 +5153,9 @@ export const state = {
4576
5153
  email: {
4577
5154
  type: "string",
4578
5155
  },
5156
+ createdAt: {
5157
+ type: "string",
5158
+ },
4579
5159
  role: {
4580
5160
  type: "string",
4581
5161
  enum: [
@@ -4588,7 +5168,7 @@ export const state = {
4588
5168
  ],
4589
5169
  },
4590
5170
  },
4591
- required: ["id", "email", "role"],
5171
+ required: ["id", "email", "createdAt", "role"],
4592
5172
  title: "updateWorkspaceMemberResponse",
4593
5173
  additionalProperties: false,
4594
5174
  },
@@ -5983,7 +6563,7 @@ export const state = {
5983
6563
  title: "Botpress API",
5984
6564
  description: "API for Botpress Cloud",
5985
6565
  server: "https://api.botpress.cloud",
5986
- version: "0.15.12",
6566
+ version: "0.16.2",
5987
6567
  prefix: "v1",
5988
6568
  },
5989
6569
  errors: [
@@ -6120,6 +6700,8 @@ export const state = {
6120
6700
  patchStateBody: true,
6121
6701
  callActionBody: true,
6122
6702
  configureIntegrationBody: true,
6703
+ createTaskBody: true,
6704
+ updateTaskBody: true,
6123
6705
  runVrlBody: true,
6124
6706
  createPersonalAccessTokenBody: true,
6125
6707
  setAccountPreferenceBody: true,
@@ -6130,6 +6712,7 @@ export const state = {
6130
6712
  chargeWorkspaceUnpaidInvoicesBody: true,
6131
6713
  createWorkspaceBody: true,
6132
6714
  updateWorkspaceBody: true,
6715
+ checkHandleAvailabilityBody: true,
6133
6716
  changeWorkspacePlanBody: true,
6134
6717
  createWorkspaceMemberBody: true,
6135
6718
  updateWorkspaceMemberBody: true,
@@ -6170,6 +6753,11 @@ export const state = {
6170
6753
  patchStateResponse: true,
6171
6754
  callActionResponse: true,
6172
6755
  configureIntegrationResponse: true,
6756
+ getTaskResponse: true,
6757
+ createTaskResponse: true,
6758
+ updateTaskResponse: true,
6759
+ deleteTaskResponse: true,
6760
+ listTasksResponse: true,
6173
6761
  runVrlResponse: true,
6174
6762
  getAccountResponse: true,
6175
6763
  listPersonalAccessTokensResponse: true,
@@ -6204,6 +6792,7 @@ export const state = {
6204
6792
  getWorkspaceQuotaResponse: true,
6205
6793
  listWorkspaceQuotasResponse: true,
6206
6794
  updateWorkspaceResponse: true,
6795
+ checkHandleAvailabilityResponse: true,
6207
6796
  listWorkspacesResponse: true,
6208
6797
  changeWorkspacePlanResponse: true,
6209
6798
  deleteWorkspaceResponse: true,
@@ -6243,6 +6832,7 @@ export const state = {
6243
6832
  Event: true,
6244
6833
  Message: true,
6245
6834
  State: true,
6835
+ Task: true,
6246
6836
  File: true,
6247
6837
  Table: true,
6248
6838
  Column: true,
@@ -6581,12 +7171,50 @@ export const state = {
6581
7171
  type: "object",
6582
7172
  additionalProperties: true,
6583
7173
  },
7174
+ failedAttempts: {
7175
+ type: "number",
7176
+ description:
7177
+ "The number of times the recurring event failed to run. This counter resets once the recurring event runs successfully.",
7178
+ },
7179
+ lastFailureReason: {
7180
+ type: "string",
7181
+ maxLength: 2000,
7182
+ description:
7183
+ "The reason why the recurring event failed to run in the last attempt.",
7184
+ nullable: true,
7185
+ },
6584
7186
  },
6585
- required: ["schedule", "type", "payload"],
7187
+ required: [
7188
+ "schedule",
7189
+ "type",
7190
+ "payload",
7191
+ "failedAttempts",
7192
+ "lastFailureReason",
7193
+ ],
6586
7194
  additionalProperties: false,
6587
7195
  },
6588
7196
  description: "Recurring events",
6589
7197
  },
7198
+ subscriptions: {
7199
+ type: "object",
7200
+ properties: {
7201
+ events: {
7202
+ type: "object",
7203
+ additionalProperties: {
7204
+ type: "object",
7205
+ additionalProperties: {
7206
+ readOnly: true,
7207
+ },
7208
+ },
7209
+ nullable: true,
7210
+ description:
7211
+ 'Events that the bot is currently subscribed on (ex: "slack:reactionAdded"). If null, the bot is subscribed to all events.',
7212
+ },
7213
+ },
7214
+ required: ["events"],
7215
+ description: "Subscriptions of the bot",
7216
+ additionalProperties: false,
7217
+ },
6590
7218
  name: {
6591
7219
  type: "string",
6592
7220
  description: "Name of the [Bot](#schema_bot)",
@@ -6648,6 +7276,7 @@ export const state = {
6648
7276
  "configuration",
6649
7277
  "events",
6650
7278
  "recurringEvents",
7279
+ "subscriptions",
6651
7280
  "name",
6652
7281
  "dev",
6653
7282
  "alwaysAlive",
@@ -7100,6 +7729,36 @@ export const state = {
7100
7729
  spendingLimit: {
7101
7730
  type: "number",
7102
7731
  },
7732
+ about: {
7733
+ default: "",
7734
+ type: "string",
7735
+ },
7736
+ profilePicture: {
7737
+ default: "",
7738
+ type: "string",
7739
+ },
7740
+ contactEmail: {
7741
+ default: "",
7742
+ type: "string",
7743
+ },
7744
+ website: {
7745
+ default: "",
7746
+ type: "string",
7747
+ },
7748
+ socialAccounts: {
7749
+ default: [],
7750
+ type: "array",
7751
+ items: {
7752
+ type: "string",
7753
+ },
7754
+ },
7755
+ isPublic: {
7756
+ type: "boolean",
7757
+ },
7758
+ handle: {
7759
+ default: "",
7760
+ type: "string",
7761
+ },
7103
7762
  },
7104
7763
  required: [
7105
7764
  "id",
@@ -7132,6 +7791,9 @@ export const state = {
7132
7791
  email: {
7133
7792
  type: "string",
7134
7793
  },
7794
+ createdAt: {
7795
+ type: "string",
7796
+ },
7135
7797
  role: {
7136
7798
  type: "string",
7137
7799
  enum: [
@@ -7144,7 +7806,7 @@ export const state = {
7144
7806
  ],
7145
7807
  },
7146
7808
  },
7147
- required: ["id", "email", "role"],
7809
+ required: ["id", "email", "createdAt", "role"],
7148
7810
  additionalProperties: false,
7149
7811
  },
7150
7812
  },
@@ -7376,6 +8038,12 @@ export const state = {
7376
8038
  maxLength: 36,
7377
8039
  description: "ID of the [Conversation](#schema_conversation)",
7378
8040
  },
8041
+ currentTaskId: {
8042
+ type: "string",
8043
+ minLength: 28,
8044
+ maxLength: 36,
8045
+ description: "Id of the current [Task](#schema_task)",
8046
+ },
7379
8047
  createdAt: {
7380
8048
  type: "string",
7381
8049
  format: "date-time",
@@ -7469,8 +8137,25 @@ export const state = {
7469
8137
  description:
7470
8138
  "ID of the [Message](#schema_message) to link the event to.",
7471
8139
  },
8140
+ status: {
8141
+ type: "string",
8142
+ enum: ["pending", "processed", "ignored", "failed"],
8143
+ },
8144
+ failureReason: {
8145
+ type: "string",
8146
+ maxLength: 2000,
8147
+ description: "Reason why the event failed to be processed",
8148
+ nullable: true,
8149
+ },
7472
8150
  },
7473
- required: ["id", "createdAt", "type", "payload"],
8151
+ required: [
8152
+ "id",
8153
+ "createdAt",
8154
+ "type",
8155
+ "payload",
8156
+ "status",
8157
+ "failureReason",
8158
+ ],
7474
8159
  description: "The event object represents an action or an occurrence.",
7475
8160
  additionalProperties: false,
7476
8161
  },
@@ -7619,6 +8304,114 @@ export const state = {
7619
8304
  additionalProperties: false,
7620
8305
  },
7621
8306
  },
8307
+ Task: {
8308
+ section: "task",
8309
+ schema: {
8310
+ type: "object",
8311
+ properties: {
8312
+ id: {
8313
+ type: "string",
8314
+ minLength: 28,
8315
+ maxLength: 36,
8316
+ description: "ID of the [Conversation](#schema_conversation)",
8317
+ },
8318
+ title: {
8319
+ type: "string",
8320
+ maxLength: 64,
8321
+ description: "Title describing the task",
8322
+ },
8323
+ instruction: {
8324
+ type: "string",
8325
+ maxLength: 256,
8326
+ description:
8327
+ "All the notes related to the execution of the current task",
8328
+ },
8329
+ type: {
8330
+ type: "string",
8331
+ description: "Type of the task",
8332
+ },
8333
+ data: {
8334
+ type: "object",
8335
+ additionalProperties: true,
8336
+ description: "Content related to the task",
8337
+ },
8338
+ status: {
8339
+ type: "string",
8340
+ enum: [
8341
+ "pending",
8342
+ "in_progress",
8343
+ "failed",
8344
+ "completed",
8345
+ "blocked",
8346
+ "paused",
8347
+ ],
8348
+ description: "Status of the task",
8349
+ },
8350
+ parentTaskId: {
8351
+ type: "string",
8352
+ minLength: 28,
8353
+ maxLength: 36,
8354
+ description:
8355
+ "Parent task id is the parent task that created this task",
8356
+ },
8357
+ conversationId: {
8358
+ type: "string",
8359
+ minLength: 28,
8360
+ maxLength: 36,
8361
+ description: "Conversation id related to this task",
8362
+ },
8363
+ userId: {
8364
+ type: "string",
8365
+ minLength: 28,
8366
+ maxLength: 36,
8367
+ description: "Specific user related to this task",
8368
+ },
8369
+ timeoutAt: {
8370
+ type: "string",
8371
+ format: "date-time",
8372
+ description:
8373
+ "The timeout date where the task should be failed in the ISO 8601 format",
8374
+ },
8375
+ createdAt: {
8376
+ type: "string",
8377
+ format: "date-time",
8378
+ description: "Creation date of the task in ISO 8601 format",
8379
+ },
8380
+ updatedAt: {
8381
+ type: "string",
8382
+ format: "date-time",
8383
+ description: "Updating date of the task in ISO 8601 format",
8384
+ },
8385
+ failureReason: {
8386
+ type: "string",
8387
+ maxLength: 2000,
8388
+ description: "If the task fails this is the reason behind it",
8389
+ },
8390
+ tags: {
8391
+ type: "object",
8392
+ additionalProperties: {
8393
+ type: "string",
8394
+ },
8395
+ description:
8396
+ "Set of [Tags](/docs/developers/concepts/tags) that you can attach to a [Task](#schema_task). Individual keys can be unset by posting an empty value to them.",
8397
+ },
8398
+ },
8399
+ required: [
8400
+ "id",
8401
+ "title",
8402
+ "instruction",
8403
+ "type",
8404
+ "data",
8405
+ "status",
8406
+ "timeoutAt",
8407
+ "createdAt",
8408
+ "updatedAt",
8409
+ "tags",
8410
+ ],
8411
+ description: "Task definition",
8412
+ additionalProperties: false,
8413
+ },
8414
+ },
7622
8415
  File: {
7623
8416
  section: "file",
7624
8417
  schema: {
@@ -7683,58 +8476,76 @@ export const state = {
7683
8476
  description:
7684
8477
  "The 'factor' multiplies the row's data storage limit by 4KB and its quota count, but can only be set at table creation and not modified later. For instance, a factor of 2 increases storage to 8KB but counts as 2 rows in your quota. The default factor is 1.",
7685
8478
  },
7686
- columns: {
7687
- type: "array",
7688
- items: {
7689
- type: "object",
8479
+ schema: {
8480
+ type: "object",
8481
+ properties: {
8482
+ $schema: {
8483
+ type: "string",
8484
+ },
7690
8485
  properties: {
7691
- id: {
7692
- type: "string",
7693
- description: "Unique identifier for the column.",
7694
- },
7695
- name: {
7696
- type: "string",
7697
- minLength: 1,
7698
- maxLength: 30,
7699
- description:
7700
- "Name of the column, must be within length limits.",
7701
- },
7702
- description: {
7703
- type: "string",
7704
- description: "Optional descriptive text about the column.",
7705
- },
7706
- searchable: {
7707
- type: "boolean",
7708
- description:
7709
- "Indicates if the column is vectorized and searchable.",
7710
- },
7711
- type: {
7712
- type: "string",
7713
- enum: ["string", "number", "boolean", "date", "object"],
7714
- description:
7715
- 'Specifies the data type of the column. Use "object" for complex data structures.',
8486
+ type: "object",
8487
+ additionalProperties: {
8488
+ type: "object",
8489
+ properties: {
8490
+ type: {
8491
+ type: "string",
8492
+ enum: ["string", "number", "boolean", "object", "null"],
8493
+ },
8494
+ format: {
8495
+ type: "string",
8496
+ enum: ["date-time"],
8497
+ },
8498
+ description: {
8499
+ type: "string",
8500
+ },
8501
+ nullable: {
8502
+ default: true,
8503
+ type: "boolean",
8504
+ },
8505
+ "x-zui": {
8506
+ type: "object",
8507
+ properties: {
8508
+ index: {
8509
+ type: "integer",
8510
+ },
8511
+ searchable: {
8512
+ type: "boolean",
8513
+ description:
8514
+ "Indicates if the column is vectorized and searchable.",
8515
+ },
8516
+ typings: {
8517
+ type: "string",
8518
+ description:
8519
+ 'TypeScript typings for the column. Recommended if the type is "object", ex: "\\{ foo: string; bar: number \\}"',
8520
+ },
8521
+ },
8522
+ required: ["index"],
8523
+ additionalProperties: false,
8524
+ },
8525
+ },
8526
+ required: ["type", "x-zui"],
8527
+ additionalProperties: false,
7716
8528
  },
7717
- typings: {
8529
+ description: "List of keys/columns in the table.",
8530
+ },
8531
+ additionalProperties: {
8532
+ type: "boolean",
8533
+ enum: [false],
8534
+ },
8535
+ required: {
8536
+ type: "array",
8537
+ items: {
7718
8538
  type: "string",
7719
- description:
7720
- 'TypeScript typings for the column. Recommended if the type is "object", ex: "\\{ foo: string; bar: number \\}"',
7721
- },
7722
- schema: {
7723
- type: "object",
7724
- properties: {},
7725
- additionalProperties: true,
7726
8539
  },
8540
+ description: "Array of required properties.",
8541
+ },
8542
+ type: {
8543
+ type: "string",
8544
+ enum: ["object"],
7727
8545
  },
7728
- required: ["name", "type"],
7729
8546
  },
7730
- maxItems: 20,
7731
- description: "Array of columns in the table.",
7732
- },
7733
- schema: {
7734
- type: "object",
7735
- additionalProperties: true,
7736
- description:
7737
- "Provide an object or a JSON schema to define the columns of the table. A maximum of 20 keys in the object/schema is allowed.",
8547
+ required: ["$schema", "properties", "additionalProperties", "type"],
8548
+ additionalProperties: false,
7738
8549
  },
7739
8550
  tags: {
7740
8551
  type: "object",
@@ -7753,7 +8564,7 @@ export const state = {
7753
8564
  description: "Timestamp of the last table update.",
7754
8565
  },
7755
8566
  },
7756
- required: ["id", "name", "columns", "schema"],
8567
+ required: ["id", "name", "schema"],
7757
8568
  additionalProperties: false,
7758
8569
  },
7759
8570
  },
@@ -7919,6 +8730,19 @@ export const state = {
7919
8730
  name: "action",
7920
8731
  operations: ["callAction"],
7921
8732
  },
8733
+ {
8734
+ description: "",
8735
+ title: "Task",
8736
+ name: "task",
8737
+ operations: [
8738
+ "getTask",
8739
+ "createTask",
8740
+ "updateTask",
8741
+ "deleteTask",
8742
+ "listTasks",
8743
+ ],
8744
+ schema: "Task",
8745
+ },
7922
8746
  {
7923
8747
  title: "Bot",
7924
8748
  description: "",
@@ -7971,6 +8795,7 @@ export const state = {
7971
8795
  "getWorkspaceQuota",
7972
8796
  "listWorkspaceQuotas",
7973
8797
  "updateWorkspace",
8798
+ "checkHandleAvailability",
7974
8799
  "listWorkspaces",
7975
8800
  "changeWorkspacePlan",
7976
8801
  "deleteWorkspace",