@athenaintel/sdk 4.3.2244 → 4.3.2246

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 (62) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/assets/client/Client.d.ts +19 -1
  3. package/dist/cjs/api/resources/assets/client/Client.js +86 -1
  4. package/dist/cjs/api/resources/assets/client/requests/CreateAssetRequestIn.d.ts +2 -0
  5. package/dist/cjs/api/resources/assets/client/requests/GetAccessAssetsRequest.d.ts +12 -0
  6. package/dist/cjs/api/resources/assets/client/requests/GetAccessAssetsRequest.js +3 -0
  7. package/dist/cjs/api/resources/assets/client/requests/index.d.ts +1 -0
  8. package/dist/cjs/api/resources/databases/client/Client.d.ts +77 -4
  9. package/dist/cjs/api/resources/databases/client/Client.js +296 -4
  10. package/dist/cjs/api/resources/databases/client/requests/DatabaseComputeSettingsUpdateRequestIn.d.ts +12 -0
  11. package/dist/cjs/api/resources/databases/client/requests/DatabaseComputeSettingsUpdateRequestIn.js +3 -0
  12. package/dist/cjs/api/resources/databases/client/requests/GetSettingsDatabasesRequest.d.ts +9 -0
  13. package/dist/cjs/api/resources/databases/client/requests/GetSettingsDatabasesRequest.js +3 -0
  14. package/dist/cjs/api/resources/databases/client/requests/WakeDatabasesRequest.d.ts +9 -0
  15. package/dist/cjs/api/resources/databases/client/requests/WakeDatabasesRequest.js +3 -0
  16. package/dist/cjs/api/resources/databases/client/requests/index.d.ts +3 -0
  17. package/dist/cjs/api/resources/tools/resources/sheets/client/requests/UpdateSheetCellRequest.d.ts +3 -0
  18. package/dist/cjs/api/types/AssetAccessOut.d.ts +28 -0
  19. package/dist/cjs/api/types/AssetAccessOut.js +14 -0
  20. package/dist/cjs/api/types/AssetAccessSourceOut.d.ts +32 -0
  21. package/dist/cjs/api/types/AssetAccessSourceOut.js +22 -0
  22. package/dist/cjs/api/types/DatabaseComputeSettingsResponseOut.d.ts +9 -0
  23. package/dist/cjs/api/types/DatabaseComputeSettingsResponseOut.js +3 -0
  24. package/dist/cjs/api/types/DatabaseStatusResponse.d.ts +2 -0
  25. package/dist/cjs/api/types/DatabaseWakeResponseOut.d.ts +19 -0
  26. package/dist/cjs/api/types/DatabaseWakeResponseOut.js +12 -0
  27. package/dist/cjs/api/types/index.d.ts +4 -0
  28. package/dist/cjs/api/types/index.js +4 -0
  29. package/dist/cjs/version.d.ts +1 -1
  30. package/dist/cjs/version.js +1 -1
  31. package/dist/esm/BaseClient.mjs +2 -2
  32. package/dist/esm/api/resources/assets/client/Client.d.mts +19 -1
  33. package/dist/esm/api/resources/assets/client/Client.mjs +86 -1
  34. package/dist/esm/api/resources/assets/client/requests/CreateAssetRequestIn.d.mts +2 -0
  35. package/dist/esm/api/resources/assets/client/requests/GetAccessAssetsRequest.d.mts +12 -0
  36. package/dist/esm/api/resources/assets/client/requests/GetAccessAssetsRequest.mjs +2 -0
  37. package/dist/esm/api/resources/assets/client/requests/index.d.mts +1 -0
  38. package/dist/esm/api/resources/databases/client/Client.d.mts +77 -4
  39. package/dist/esm/api/resources/databases/client/Client.mjs +296 -4
  40. package/dist/esm/api/resources/databases/client/requests/DatabaseComputeSettingsUpdateRequestIn.d.mts +12 -0
  41. package/dist/esm/api/resources/databases/client/requests/DatabaseComputeSettingsUpdateRequestIn.mjs +2 -0
  42. package/dist/esm/api/resources/databases/client/requests/GetSettingsDatabasesRequest.d.mts +9 -0
  43. package/dist/esm/api/resources/databases/client/requests/GetSettingsDatabasesRequest.mjs +2 -0
  44. package/dist/esm/api/resources/databases/client/requests/WakeDatabasesRequest.d.mts +9 -0
  45. package/dist/esm/api/resources/databases/client/requests/WakeDatabasesRequest.mjs +2 -0
  46. package/dist/esm/api/resources/databases/client/requests/index.d.mts +3 -0
  47. package/dist/esm/api/resources/tools/resources/sheets/client/requests/UpdateSheetCellRequest.d.mts +3 -0
  48. package/dist/esm/api/types/AssetAccessOut.d.mts +28 -0
  49. package/dist/esm/api/types/AssetAccessOut.mjs +11 -0
  50. package/dist/esm/api/types/AssetAccessSourceOut.d.mts +32 -0
  51. package/dist/esm/api/types/AssetAccessSourceOut.mjs +19 -0
  52. package/dist/esm/api/types/DatabaseComputeSettingsResponseOut.d.mts +9 -0
  53. package/dist/esm/api/types/DatabaseComputeSettingsResponseOut.mjs +2 -0
  54. package/dist/esm/api/types/DatabaseStatusResponse.d.mts +2 -0
  55. package/dist/esm/api/types/DatabaseWakeResponseOut.d.mts +19 -0
  56. package/dist/esm/api/types/DatabaseWakeResponseOut.mjs +9 -0
  57. package/dist/esm/api/types/index.d.mts +4 -0
  58. package/dist/esm/api/types/index.mjs +4 -0
  59. package/dist/esm/version.d.mts +1 -1
  60. package/dist/esm/version.mjs +1 -1
  61. package/package.json +1 -1
  62. package/reference.md +275 -5
package/reference.md CHANGED
@@ -648,7 +648,7 @@ await client.assets.convertExcelToSheet({
648
648
  <dl>
649
649
  <dd>
650
650
 
651
- Create a new asset such as a spreadsheet, document, folder, database, computer, user interface, skill, collab agent, or generic doc (admin-only) in your workspace with your current permissions. Computer assets return 202 after durable submission, which commits the asset and initialization delivery intent together. Runtime provisioning continues asynchronously. Inspect the returned asset ID for progress instead of repeating creation. Computers accept the same configuration as the Athena UI's creation dialog: template, provider, cpu, memory (GiB), disk (GiB) and env_vars. Sizes must be offered by the environment's computer resource policy, and only admins may pick a size other than the template default (403 otherwise). In capability enforce mode, computer creation requires computer.create and returns 403 when denied.
651
+ Create a new asset such as a spreadsheet, document, folder, database, computer, user interface, skill, collab agent, or generic doc (admin-only) in your workspace with your current permissions. Computer assets return 202 after durable submission, which commits the asset and initialization delivery intent together. Runtime provisioning continues asynchronously. Inspect the returned asset ID for progress instead of repeating creation. Computers accept the same configuration as the Athena UI's creation dialog: template, provider, cpu, memory (GiB), disk (GiB) and env_vars. Sizes must be offered by the environment's computer resource policy, and only admins may pick a size other than the template default (403 otherwise). In capability enforce mode, computer creation requires computer.create and returns 403 when denied. Databases accept suspend_timeout_seconds, the auto-suspend window from the database's Settings in Athena: 0 keeps the database running (it never suspends, and keeps using capacity), otherwise 60 to 86400 seconds. A database is provisioned in the background: poll GET /api/v0/databases/{asset_id}/compute-status until it reports running or suspended.
652
652
  </dd>
653
653
  </dl>
654
654
  </dd>
@@ -973,6 +973,71 @@ await client.assets.rename({
973
973
  </dl>
974
974
 
975
975
 
976
+ </dd>
977
+ </dl>
978
+ </details>
979
+
980
+ <details><summary><code>client.assets.<a href="/src/api/resources/assets/client/Client.ts">getAccess</a>({ ...params }) -> AthenaIntelligence.AssetAccessOut</code></summary>
981
+ <dl>
982
+ <dd>
983
+
984
+ #### 📝 Description
985
+
986
+ <dl>
987
+ <dd>
988
+
989
+ <dl>
990
+ <dd>
991
+
992
+ Read the access that you, or another user, have on an asset, and every grant that gives it. The level is what Athena's permission checks decide for the user in the asset's own workspace, whichever workspace is active for your key: 'view' can open the asset, 'edit' can also change it and manage its sharing, 'owner' created it and can edit it, and 'none' cannot open it. Each source names one grant: 'owner', 'direct' (shared with the user), 'group' (shared with a workspace group the user belongs to), 'workspace' (shared with the whole workspace), 'drive' (a role on the drive) or 'other' (access the share list does not hold, for example an environment admin). A folder's sharing reaches each asset inside it as that asset's own share, so a 'workspace' source on a sub-folder shows that a share of its parent folder reached it. Without user_id the route reads your own access; you need view access to the asset and membership in its workspace. To read another user's access, pass their user_id; you need edit access to the asset, as for sharing it. A user who is not a member of the asset's workspace, or who does not exist, reads as 'none' with is_member false. A suspended member reads as 'none' with no sources, and is_member still reports their membership. When a permission check cannot be answered (for example on an asset in a drive while the authorization service is unavailable), the route answers 503 and never a level. The route never changes a permission.
993
+ </dd>
994
+ </dl>
995
+ </dd>
996
+ </dl>
997
+
998
+ #### 🔌 Usage
999
+
1000
+ <dl>
1001
+ <dd>
1002
+
1003
+ <dl>
1004
+ <dd>
1005
+
1006
+ ```typescript
1007
+ await client.assets.getAccess({
1008
+ asset_id: "asset_92492920-d118-42d3-95b4-00eccfe0754f"
1009
+ });
1010
+
1011
+ ```
1012
+ </dd>
1013
+ </dl>
1014
+ </dd>
1015
+ </dl>
1016
+
1017
+ #### ⚙️ Parameters
1018
+
1019
+ <dl>
1020
+ <dd>
1021
+
1022
+ <dl>
1023
+ <dd>
1024
+
1025
+ **request:** `AthenaIntelligence.GetAccessAssetsRequest`
1026
+
1027
+ </dd>
1028
+ </dl>
1029
+
1030
+ <dl>
1031
+ <dd>
1032
+
1033
+ **requestOptions:** `AssetsClient.RequestOptions`
1034
+
1035
+ </dd>
1036
+ </dl>
1037
+ </dd>
1038
+ </dl>
1039
+
1040
+
976
1041
  </dd>
977
1042
  </dl>
978
1043
  </details>
@@ -2462,10 +2527,13 @@ Check if a database is running, suspended, or starting up. Poll this endpoint to
2462
2527
 
2463
2528
  **Status Values:**
2464
2529
  - `running` - Database is active and accepting connections
2465
- - `suspended` - Database is suspended (scale-to-zero), will auto-resume on first query
2466
- - `starting` - Database is waking up
2467
- - `failed` - Database failed to start
2468
- - `unknown` - Status could not be determined
2530
+ - `suspended` - Database is suspended (scale-to-zero). It wakes on `POST /databases/{asset_id}/wake` or on the first SQL request. When `reason` is `ComputeUnschedulable`, no node could host its compute size: waking it only restarts the same wait
2531
+ - `starting` - Database is waking up, or its compute is being recreated
2532
+ - `creating` - Database is being created; it has no compute yet
2533
+ - `failed` - Database failed to start, or its creation failed (`message` says which)
2534
+ - `unknown` - Status could not be determined (the control plane did not answer); retry
2535
+
2536
+ A database suspends (scales to zero) after `suspend_timeout_seconds` without activity; `GET`/`PATCH /databases/{asset_id}/settings` read and set that window, and 0 keeps it running. Reading the compute status or the settings never wakes a suspended database. Two things do: `POST /databases/{asset_id}/wake`, which answers at once while the compute starts, or any request that runs SQL on it, such as `POST /databases/{asset_id}/sql`, which waits for the compute up to 120 seconds; if the compute is still starting then, the answer is 503 with `Retry-After` and the statement did not run. A cold start usually takes 30 seconds to 2 minutes.
2469
2537
  </dd>
2470
2538
  </dl>
2471
2539
  </dd>
@@ -2962,6 +3030,141 @@ await client.databases.getTableSchema({
2962
3030
  </dl>
2963
3031
 
2964
3032
 
3033
+ </dd>
3034
+ </dl>
3035
+ </details>
3036
+
3037
+ <details><summary><code>client.databases.<a href="/src/api/resources/databases/client/Client.ts">getSettings</a>({ ...params }) -> AthenaIntelligence.DatabaseComputeSettingsResponseOut</code></summary>
3038
+ <dl>
3039
+ <dd>
3040
+
3041
+ #### 📝 Description
3042
+
3043
+ <dl>
3044
+ <dd>
3045
+
3046
+ <dl>
3047
+ <dd>
3048
+
3049
+ Read the database's auto-suspend window, the same setting as auto-suspend in the database's Settings in Athena. Reading never wakes the database.
3050
+
3051
+ A database suspends (scales to zero) after `suspend_timeout_seconds` without activity; `GET`/`PATCH /databases/{asset_id}/settings` read and set that window, and 0 keeps it running. Reading the compute status or the settings never wakes a suspended database. Two things do: `POST /databases/{asset_id}/wake`, which answers at once while the compute starts, or any request that runs SQL on it, such as `POST /databases/{asset_id}/sql`, which waits for the compute up to 120 seconds; if the compute is still starting then, the answer is 503 with `Retry-After` and the statement did not run. A cold start usually takes 30 seconds to 2 minutes.
3052
+ </dd>
3053
+ </dl>
3054
+ </dd>
3055
+ </dl>
3056
+
3057
+ #### 🔌 Usage
3058
+
3059
+ <dl>
3060
+ <dd>
3061
+
3062
+ <dl>
3063
+ <dd>
3064
+
3065
+ ```typescript
3066
+ await client.databases.getSettings({
3067
+ asset_id: "asset_id"
3068
+ });
3069
+
3070
+ ```
3071
+ </dd>
3072
+ </dl>
3073
+ </dd>
3074
+ </dl>
3075
+
3076
+ #### ⚙️ Parameters
3077
+
3078
+ <dl>
3079
+ <dd>
3080
+
3081
+ <dl>
3082
+ <dd>
3083
+
3084
+ **request:** `AthenaIntelligence.GetSettingsDatabasesRequest`
3085
+
3086
+ </dd>
3087
+ </dl>
3088
+
3089
+ <dl>
3090
+ <dd>
3091
+
3092
+ **requestOptions:** `DatabasesClient.RequestOptions`
3093
+
3094
+ </dd>
3095
+ </dl>
3096
+ </dd>
3097
+ </dl>
3098
+
3099
+
3100
+ </dd>
3101
+ </dl>
3102
+ </details>
3103
+
3104
+ <details><summary><code>client.databases.<a href="/src/api/resources/databases/client/Client.ts">updateSettings</a>({ ...params }) -> AthenaIntelligence.DatabaseComputeSettingsResponseOut</code></summary>
3105
+ <dl>
3106
+ <dd>
3107
+
3108
+ #### 📝 Description
3109
+
3110
+ <dl>
3111
+ <dd>
3112
+
3113
+ <dl>
3114
+ <dd>
3115
+
3116
+ Set the database's auto-suspend window: 0 keeps the database running (it never suspends, and keeps using compute capacity), otherwise 60 to 86400 seconds. The same setting, values and edit-access rule as auto-suspend in the database's Settings in Athena; the change applies at once and does not restart or wake the database.
3117
+
3118
+ A database suspends (scales to zero) after `suspend_timeout_seconds` without activity; `GET`/`PATCH /databases/{asset_id}/settings` read and set that window, and 0 keeps it running. Reading the compute status or the settings never wakes a suspended database. Two things do: `POST /databases/{asset_id}/wake`, which answers at once while the compute starts, or any request that runs SQL on it, such as `POST /databases/{asset_id}/sql`, which waits for the compute up to 120 seconds; if the compute is still starting then, the answer is 503 with `Retry-After` and the statement did not run. A cold start usually takes 30 seconds to 2 minutes.
3119
+ </dd>
3120
+ </dl>
3121
+ </dd>
3122
+ </dl>
3123
+
3124
+ #### 🔌 Usage
3125
+
3126
+ <dl>
3127
+ <dd>
3128
+
3129
+ <dl>
3130
+ <dd>
3131
+
3132
+ ```typescript
3133
+ await client.databases.updateSettings({
3134
+ asset_id: "asset_id",
3135
+ suspend_timeout_seconds: 3600
3136
+ });
3137
+
3138
+ ```
3139
+ </dd>
3140
+ </dl>
3141
+ </dd>
3142
+ </dl>
3143
+
3144
+ #### ⚙️ Parameters
3145
+
3146
+ <dl>
3147
+ <dd>
3148
+
3149
+ <dl>
3150
+ <dd>
3151
+
3152
+ **request:** `AthenaIntelligence.DatabaseComputeSettingsUpdateRequestIn`
3153
+
3154
+ </dd>
3155
+ </dl>
3156
+
3157
+ <dl>
3158
+ <dd>
3159
+
3160
+ **requestOptions:** `DatabasesClient.RequestOptions`
3161
+
3162
+ </dd>
3163
+ </dl>
3164
+ </dd>
3165
+ </dl>
3166
+
3167
+
2965
3168
  </dd>
2966
3169
  </dl>
2967
3170
  </details>
@@ -3028,6 +3231,73 @@ await client.databases.executeSql({
3028
3231
  </dl>
3029
3232
 
3030
3233
 
3234
+ </dd>
3235
+ </dl>
3236
+ </details>
3237
+
3238
+ <details><summary><code>client.databases.<a href="/src/api/resources/databases/client/Client.ts">wake</a>({ ...params }) -> AthenaIntelligence.DatabaseWakeResponseOut</code></summary>
3239
+ <dl>
3240
+ <dd>
3241
+
3242
+ #### 📝 Description
3243
+
3244
+ <dl>
3245
+ <dd>
3246
+
3247
+ <dl>
3248
+ <dd>
3249
+
3250
+ Start a suspended database's compute and answer at once, without waiting for it to run. Poll `GET /databases/{asset_id}/compute-status` until it reports `running`. Waking a running database resets its idle clock and answers 200 with `running`, so it is safe to call before every batch of work. The same action as Resume Database in Athena; it needs edit access to the database.
3251
+
3252
+ A database suspends (scales to zero) after `suspend_timeout_seconds` without activity; `GET`/`PATCH /databases/{asset_id}/settings` read and set that window, and 0 keeps it running. Reading the compute status or the settings never wakes a suspended database. Two things do: `POST /databases/{asset_id}/wake`, which answers at once while the compute starts, or any request that runs SQL on it, such as `POST /databases/{asset_id}/sql`, which waits for the compute up to 120 seconds; if the compute is still starting then, the answer is 503 with `Retry-After` and the statement did not run. A cold start usually takes 30 seconds to 2 minutes.
3253
+ </dd>
3254
+ </dl>
3255
+ </dd>
3256
+ </dl>
3257
+
3258
+ #### 🔌 Usage
3259
+
3260
+ <dl>
3261
+ <dd>
3262
+
3263
+ <dl>
3264
+ <dd>
3265
+
3266
+ ```typescript
3267
+ await client.databases.wake({
3268
+ asset_id: "asset_id"
3269
+ });
3270
+
3271
+ ```
3272
+ </dd>
3273
+ </dl>
3274
+ </dd>
3275
+ </dl>
3276
+
3277
+ #### ⚙️ Parameters
3278
+
3279
+ <dl>
3280
+ <dd>
3281
+
3282
+ <dl>
3283
+ <dd>
3284
+
3285
+ **request:** `AthenaIntelligence.WakeDatabasesRequest`
3286
+
3287
+ </dd>
3288
+ </dl>
3289
+
3290
+ <dl>
3291
+ <dd>
3292
+
3293
+ **requestOptions:** `DatabasesClient.RequestOptions`
3294
+
3295
+ </dd>
3296
+ </dl>
3297
+ </dd>
3298
+ </dl>
3299
+
3300
+
3031
3301
  </dd>
3032
3302
  </dl>
3033
3303
  </details>