lemma-sdk 0.2.40 → 0.2.42

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 (130) hide show
  1. package/README.md +10 -3
  2. package/dist/browser/lemma-client.js +95 -68
  3. package/dist/index.d.ts +1 -1
  4. package/dist/namespaces/conversations.d.ts +6 -0
  5. package/dist/namespaces/conversations.js +2 -0
  6. package/dist/namespaces/files.js +12 -21
  7. package/dist/namespaces/resources.d.ts +21 -5
  8. package/dist/openapi_client/index.d.ts +21 -15
  9. package/dist/openapi_client/index.js +5 -5
  10. package/dist/openapi_client/models/AgentResponse.d.ts +3 -2
  11. package/dist/openapi_client/models/BillingHistoryResponse.d.ts +8 -0
  12. package/dist/openapi_client/models/BillingInvoiceResponse.d.ts +29 -0
  13. package/dist/openapi_client/models/BillingInvoiceStatus.d.ts +10 -0
  14. package/dist/openapi_client/models/BillingInvoiceStatus.js +15 -0
  15. package/dist/openapi_client/models/BillingScope.d.ts +7 -0
  16. package/dist/openapi_client/models/BillingScope.js +12 -0
  17. package/dist/openapi_client/models/ConversationResponse.d.ts +6 -0
  18. package/dist/openapi_client/models/ConversationStatus.d.ts +11 -0
  19. package/dist/openapi_client/models/ConversationStatus.js +16 -0
  20. package/dist/openapi_client/models/ConversationType.d.ts +7 -0
  21. package/dist/openapi_client/models/ConversationType.js +12 -0
  22. package/dist/openapi_client/models/CreateAgentRequest.d.ts +3 -2
  23. package/dist/openapi_client/models/CreateConversationRequest.d.ts +4 -0
  24. package/dist/openapi_client/models/CreateDeskRequest.d.ts +1 -0
  25. package/dist/openapi_client/models/CreateFolderRequest.d.ts +1 -2
  26. package/dist/openapi_client/models/CreateFunctionRequest.d.ts +9 -4
  27. package/dist/openapi_client/models/CreateInvoicePaymentUrlRequest.d.ts +7 -0
  28. package/dist/openapi_client/models/CreateInvoicePaymentUrlResponse.d.ts +8 -0
  29. package/dist/openapi_client/models/CreateScheduleRequest.d.ts +1 -0
  30. package/dist/openapi_client/models/CreateTableRequest.d.ts +1 -0
  31. package/dist/openapi_client/models/DatastoreFileUploadRequest.d.ts +1 -2
  32. package/dist/openapi_client/models/DeskResponse.d.ts +2 -0
  33. package/dist/openapi_client/models/FileResponse.d.ts +2 -2
  34. package/dist/openapi_client/models/FlowResponse.d.ts +2 -0
  35. package/dist/openapi_client/models/FunctionResponse.d.ts +13 -2
  36. package/dist/openapi_client/models/{app__modules__function__api__schemas__function_schemas__TableAccessEntry.d.ts → FunctionTableAccessEntry.d.ts} +1 -1
  37. package/dist/openapi_client/models/PodMemberAddRequest.d.ts +1 -0
  38. package/dist/openapi_client/models/PodMemberDetailResponse.d.ts +1 -0
  39. package/dist/openapi_client/models/PodMemberResponse.d.ts +1 -0
  40. package/dist/openapi_client/models/PodMemberUpdateRoleRequest.d.ts +2 -1
  41. package/dist/openapi_client/models/PodRoleCreateRequest.d.ts +6 -0
  42. package/dist/openapi_client/models/PodRoleListResponse.d.ts +7 -0
  43. package/dist/openapi_client/models/PodRoleResponse.d.ts +11 -0
  44. package/dist/openapi_client/models/ScheduleResponse.d.ts +2 -0
  45. package/dist/openapi_client/models/SendMessageRequest.d.ts +1 -0
  46. package/dist/openapi_client/models/StartSubscriptionResponse.d.ts +3 -1
  47. package/dist/openapi_client/models/StartTeamBillingRequest.d.ts +6 -0
  48. package/dist/openapi_client/models/SubscriptionResponse.d.ts +22 -0
  49. package/dist/openapi_client/models/SubscriptionWithPlanResponse.d.ts +4 -1
  50. package/dist/openapi_client/models/{app__modules__agent__domain__value_objects__TableAccessEntry.d.ts → TableAccessEntry.d.ts} +1 -1
  51. package/dist/openapi_client/models/TableAccessEntry.js +1 -0
  52. package/dist/openapi_client/models/TableResponse.d.ts +2 -0
  53. package/dist/openapi_client/models/UpdateAgentRequest.d.ts +3 -2
  54. package/dist/openapi_client/models/UpdateConversationRequest.d.ts +2 -0
  55. package/dist/openapi_client/models/UpdateDeskRequest.d.ts +2 -0
  56. package/dist/openapi_client/models/UpdateFunctionRequest.d.ts +6 -2
  57. package/dist/openapi_client/models/UpdateScheduleRequest.d.ts +1 -0
  58. package/dist/openapi_client/models/UpdateTableRequest.d.ts +2 -1
  59. package/dist/openapi_client/models/UsageLimitScopeResponse.d.ts +10 -0
  60. package/dist/openapi_client/models/UsageLimitScopeResponse.js +1 -0
  61. package/dist/openapi_client/models/UsageLimitsResponse.d.ts +11 -0
  62. package/dist/openapi_client/models/UsageLimitsResponse.js +1 -0
  63. package/dist/openapi_client/models/UsageListResponse.d.ts +10 -0
  64. package/dist/openapi_client/models/UsageListResponse.js +1 -0
  65. package/dist/openapi_client/models/UsageRecordResponse.d.ts +12 -4
  66. package/dist/openapi_client/models/UsageStatsBucketResponse.d.ts +12 -0
  67. package/dist/openapi_client/models/UsageStatsBucketResponse.js +1 -0
  68. package/dist/openapi_client/models/UsageStatsResponse.d.ts +12 -0
  69. package/dist/openapi_client/models/UsageStatsResponse.js +1 -0
  70. package/dist/openapi_client/models/UsageSummaryResponse.d.ts +3 -0
  71. package/dist/openapi_client/models/WorkflowCreateRequest.d.ts +1 -0
  72. package/dist/openapi_client/models/WorkflowUpdateRequest.d.ts +1 -0
  73. package/dist/openapi_client/models/update.d.ts +1 -2
  74. package/dist/openapi_client/services/AgentConversationsService.d.ts +5 -1
  75. package/dist/openapi_client/services/AgentConversationsService.js +5 -1
  76. package/dist/openapi_client/services/BillingSubscriptionsService.d.ts +80 -20
  77. package/dist/openapi_client/services/BillingSubscriptionsService.js +164 -27
  78. package/dist/openapi_client/services/BillingUsageService.d.ts +89 -5
  79. package/dist/openapi_client/services/BillingUsageService.js +186 -6
  80. package/dist/openapi_client/services/DesksService.d.ts +21 -4
  81. package/dist/openapi_client/services/DesksService.js +44 -2
  82. package/dist/openapi_client/services/FilesService.d.ts +11 -20
  83. package/dist/openapi_client/services/FilesService.js +11 -28
  84. package/dist/openapi_client/services/FunctionsService.d.ts +2 -2
  85. package/dist/openapi_client/services/FunctionsService.js +2 -2
  86. package/dist/openapi_client/services/PodMembersService.d.ts +10 -0
  87. package/dist/openapi_client/services/PodMembersService.js +24 -0
  88. package/dist/openapi_client/services/PodRolesService.d.ts +29 -0
  89. package/dist/openapi_client/services/PodRolesService.js +63 -0
  90. package/dist/react/AuthGuard.d.ts +0 -15
  91. package/dist/react/AuthGuard.js +128 -167
  92. package/dist/react/index.d.ts +1 -1
  93. package/dist/react/useAssistantController.d.ts +8 -4
  94. package/dist/react/useAssistantController.js +9 -6
  95. package/dist/react/useAssistantSession.d.ts +9 -0
  96. package/dist/react/useAssistantSession.js +10 -2
  97. package/dist/react/useConversationMessages.d.ts +2 -1
  98. package/dist/react/useConversationMessages.js +2 -1
  99. package/dist/react/useConversations.d.ts +7 -1
  100. package/dist/react/useConversations.js +10 -4
  101. package/dist/types.d.ts +2 -2
  102. package/package.json +1 -1
  103. package/dist/openapi_client/models/Body_upload_file_files__resource_type___resource_id__upload_post.d.ts +0 -3
  104. package/dist/openapi_client/models/FileInfo.d.ts +0 -14
  105. package/dist/openapi_client/models/FileInfo.js +0 -8
  106. package/dist/openapi_client/models/FileNamespace.d.ts +0 -4
  107. package/dist/openapi_client/models/FileNamespace.js +0 -9
  108. package/dist/openapi_client/models/FileUploadResponse.d.ts +0 -6
  109. package/dist/openapi_client/models/GrantPermissionRequest.d.ts +0 -6
  110. package/dist/openapi_client/models/PodPermissionsResponse.d.ts +0 -4
  111. package/dist/openapi_client/models/ResourceFileListResponse.d.ts +0 -6
  112. package/dist/openapi_client/models/ResourcePermissionListResponse.d.ts +0 -4
  113. package/dist/openapi_client/models/ResourcePermissionResponse.d.ts +0 -12
  114. package/dist/openapi_client/models/ResourceType.d.ts +0 -4
  115. package/dist/openapi_client/models/ResourceType.js +0 -9
  116. package/dist/openapi_client/models/SetVisibilityRequest.d.ts +0 -3
  117. package/dist/openapi_client/services/AgentFilesService.d.ts +0 -46
  118. package/dist/openapi_client/services/AgentFilesService.js +0 -103
  119. package/dist/openapi_client/services/AuthorizationService.d.ts +0 -58
  120. package/dist/openapi_client/services/AuthorizationService.js +0 -122
  121. /package/dist/openapi_client/models/{Body_upload_file_files__resource_type___resource_id__upload_post.js → BillingHistoryResponse.js} +0 -0
  122. /package/dist/openapi_client/models/{FileUploadResponse.js → BillingInvoiceResponse.js} +0 -0
  123. /package/dist/openapi_client/models/{GrantPermissionRequest.js → CreateInvoicePaymentUrlRequest.js} +0 -0
  124. /package/dist/openapi_client/models/{PodPermissionsResponse.js → CreateInvoicePaymentUrlResponse.js} +0 -0
  125. /package/dist/openapi_client/models/{ResourceFileListResponse.js → FunctionTableAccessEntry.js} +0 -0
  126. /package/dist/openapi_client/models/{ResourcePermissionListResponse.js → PodRoleCreateRequest.js} +0 -0
  127. /package/dist/openapi_client/models/{ResourcePermissionResponse.js → PodRoleListResponse.js} +0 -0
  128. /package/dist/openapi_client/models/{SetVisibilityRequest.js → PodRoleResponse.js} +0 -0
  129. /package/dist/openapi_client/models/{app__modules__agent__domain__value_objects__TableAccessEntry.js → StartTeamBillingRequest.js} +0 -0
  130. /package/dist/openapi_client/models/{app__modules__function__api__schemas__function_schemas__TableAccessEntry.js → SubscriptionResponse.js} +0 -0
package/dist/types.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { AgentModelName, AgentResponse, ColumnSchema, ConversationResponse as GeneratedConversationResponse, CreateAgentRequest, DatastoreQueryResponse, DirectoryTreeNode, DirectoryTreeResponse, FileResponse, FileNamespace, FileSearchResponse, FileSearchResultSchema, FlowRunEntity, FlowResponse, FunctionRunResponse, IconUploadResponse, OrganizationInvitationResponse, OrganizationMemberResponse, OrganizationResponse, PodConfigResponse, PodJoinRequestCreateResponse, PodMemberResponse, PodResponse, ScheduleResponse, TableResponse, UpdateAgentRequest, UserResponse, WorkflowRunWaitAssignment } from "./openapi_client/index.js";
1
+ import type { AgentModelName, AgentResponse, ColumnSchema, ConversationResponse as GeneratedConversationResponse, CreateAgentRequest, DatastoreQueryResponse, DirectoryTreeNode, DirectoryTreeResponse, FileResponse, FileSearchResponse, FileSearchResultSchema, FlowRunEntity, FlowResponse, FunctionRunResponse, IconUploadResponse, OrganizationInvitationResponse, OrganizationMemberResponse, OrganizationResponse, PodConfigResponse, PodJoinRequestCreateResponse, PodMemberResponse, PodResponse, ScheduleResponse, TableResponse, UpdateAgentRequest, UserResponse, WorkflowRunWaitAssignment } from "./openapi_client/index.js";
2
2
  /** Public ergonomic types. */
3
3
  export interface AvailableModelInfo {
4
4
  id: ConversationModel;
@@ -77,7 +77,7 @@ export type DatastoreFileSearchResponse = FileSearchResponse;
77
77
  export type DatastoreFileSearchResult = FileSearchResultSchema;
78
78
  export type DatastoreDirectoryTree = DirectoryTreeResponse;
79
79
  export type DatastoreDirectoryTreeNode = DirectoryTreeNode;
80
- export type DatastoreFileNamespace = FileNamespace | "PRIVATE" | "PERSONAL" | "POD";
80
+ export type DatastoreFileNamespace = "PRIVATE" | "PERSONAL" | "POD";
81
81
  export type Pod = PodResponse;
82
82
  export type PodConfig = PodConfigResponse;
83
83
  export type PodMember = PodMemberResponse;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lemma-sdk",
3
- "version": "0.2.40",
3
+ "version": "0.2.42",
4
4
  "description": "Official TypeScript SDK for Lemma pod-scoped APIs",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -1,3 +0,0 @@
1
- export type Body_upload_file_files__resource_type___resource_id__upload_post = {
2
- file: string;
3
- };
@@ -1,14 +0,0 @@
1
- export type FileInfo = {
2
- created?: (string | null);
3
- last_modified?: (string | null);
4
- name: string;
5
- path: string;
6
- size?: (number | null);
7
- type: FileInfo.type;
8
- };
9
- export declare namespace FileInfo {
10
- enum type {
11
- FILE = "file",
12
- DIRECTORY = "directory"
13
- }
14
- }
@@ -1,8 +0,0 @@
1
- export var FileInfo;
2
- (function (FileInfo) {
3
- let type;
4
- (function (type) {
5
- type["FILE"] = "file";
6
- type["DIRECTORY"] = "directory";
7
- })(type = FileInfo.type || (FileInfo.type = {}));
8
- })(FileInfo || (FileInfo = {}));
@@ -1,4 +0,0 @@
1
- export declare enum FileNamespace {
2
- PERSONAL = "PERSONAL",
3
- POD = "POD"
4
- }
@@ -1,9 +0,0 @@
1
- /* generated using openapi-typescript-codegen -- do not edit */
2
- /* istanbul ignore file */
3
- /* tslint:disable */
4
- /* eslint-disable */
5
- export var FileNamespace;
6
- (function (FileNamespace) {
7
- FileNamespace["PERSONAL"] = "PERSONAL";
8
- FileNamespace["POD"] = "POD";
9
- })(FileNamespace || (FileNamespace = {}));
@@ -1,6 +0,0 @@
1
- export type FileUploadResponse = {
2
- file_name: string;
3
- message: string;
4
- path: string;
5
- success: boolean;
6
- };
@@ -1,6 +0,0 @@
1
- export type GrantPermissionRequest = {
2
- effective_role: string;
3
- grantee_min_role?: (string | null);
4
- grantee_type: string;
5
- grantee_user_id?: (string | null);
6
- };
@@ -1,4 +0,0 @@
1
- export type PodPermissionsResponse = {
2
- actions: Array<string>;
3
- pod_id: string;
4
- };
@@ -1,6 +0,0 @@
1
- import type { FileInfo } from './FileInfo.js';
2
- export type ResourceFileListResponse = {
3
- items: Array<FileInfo>;
4
- limit: number;
5
- next_page_token?: (string | null);
6
- };
@@ -1,4 +0,0 @@
1
- import type { ResourcePermissionResponse } from './ResourcePermissionResponse.js';
2
- export type ResourcePermissionListResponse = {
3
- items: Array<ResourcePermissionResponse>;
4
- };
@@ -1,12 +0,0 @@
1
- export type ResourcePermissionResponse = {
2
- created_at: string;
3
- effective_role: string;
4
- granted_by_user_id: string;
5
- grantee_min_role: (string | null);
6
- grantee_type: string;
7
- grantee_user_id: (string | null);
8
- id: string;
9
- pod_id: string;
10
- resource_id: string;
11
- resource_type: string;
12
- };
@@ -1,4 +0,0 @@
1
- export declare enum ResourceType {
2
- POD = "pod",
3
- CONVERSATION = "conversation"
4
- }
@@ -1,9 +0,0 @@
1
- /* generated using openapi-typescript-codegen -- do not edit */
2
- /* istanbul ignore file */
3
- /* tslint:disable */
4
- /* eslint-disable */
5
- export var ResourceType;
6
- (function (ResourceType) {
7
- ResourceType["POD"] = "pod";
8
- ResourceType["CONVERSATION"] = "conversation";
9
- })(ResourceType || (ResourceType = {}));
@@ -1,3 +0,0 @@
1
- export type SetVisibilityRequest = {
2
- visibility: string;
3
- };
@@ -1,46 +0,0 @@
1
- import type { Body_upload_file_files__resource_type___resource_id__upload_post } from '../models/Body_upload_file_files__resource_type___resource_id__upload_post.js';
2
- import type { FileUploadResponse } from '../models/FileUploadResponse.js';
3
- import type { ResourceFileListResponse } from '../models/ResourceFileListResponse.js';
4
- import type { ResourceType } from '../models/ResourceType.js';
5
- import type { CancelablePromise } from '../core/CancelablePromise.js';
6
- export declare class AgentFilesService {
7
- /**
8
- * Delete File
9
- * @param resourceType
10
- * @param resourceId
11
- * @param filePath
12
- * @returns any Successful Response
13
- * @throws ApiError
14
- */
15
- static deleteFileFilesResourceTypeResourceIdDeleteFilePathDelete(resourceType: ResourceType, resourceId: string, filePath: string): CancelablePromise<Record<string, any>>;
16
- /**
17
- * Download File
18
- * @param resourceType
19
- * @param resourceId
20
- * @param filePath
21
- * @returns any Successful Response
22
- * @throws ApiError
23
- */
24
- static downloadFileFilesResourceTypeResourceIdDownloadFilePathGet(resourceType: ResourceType, resourceId: string, filePath: string): CancelablePromise<any>;
25
- /**
26
- * List Files
27
- * @param resourceType
28
- * @param resourceId
29
- * @param path
30
- * @param limit
31
- * @param pageToken
32
- * @returns ResourceFileListResponse Successful Response
33
- * @throws ApiError
34
- */
35
- static listFilesFilesResourceTypeResourceIdListGet(resourceType: ResourceType, resourceId: string, path?: string, limit?: number, pageToken?: (string | null)): CancelablePromise<ResourceFileListResponse>;
36
- /**
37
- * Upload File
38
- * @param resourceType
39
- * @param resourceId
40
- * @param formData
41
- * @param path
42
- * @returns FileUploadResponse Successful Response
43
- * @throws ApiError
44
- */
45
- static uploadFileFilesResourceTypeResourceIdUploadPost(resourceType: ResourceType, resourceId: string, formData: Body_upload_file_files__resource_type___resource_id__upload_post, path?: (string | null)): CancelablePromise<FileUploadResponse>;
46
- }
@@ -1,103 +0,0 @@
1
- import { OpenAPI } from '../core/OpenAPI.js';
2
- import { request as __request } from '../core/request.js';
3
- export class AgentFilesService {
4
- /**
5
- * Delete File
6
- * @param resourceType
7
- * @param resourceId
8
- * @param filePath
9
- * @returns any Successful Response
10
- * @throws ApiError
11
- */
12
- static deleteFileFilesResourceTypeResourceIdDeleteFilePathDelete(resourceType, resourceId, filePath) {
13
- return __request(OpenAPI, {
14
- method: 'DELETE',
15
- url: '/files/{resource_type}/{resource_id}/delete/{file_path}',
16
- path: {
17
- 'resource_type': resourceType,
18
- 'resource_id': resourceId,
19
- 'file_path': filePath,
20
- },
21
- errors: {
22
- 422: `Validation Error`,
23
- },
24
- });
25
- }
26
- /**
27
- * Download File
28
- * @param resourceType
29
- * @param resourceId
30
- * @param filePath
31
- * @returns any Successful Response
32
- * @throws ApiError
33
- */
34
- static downloadFileFilesResourceTypeResourceIdDownloadFilePathGet(resourceType, resourceId, filePath) {
35
- return __request(OpenAPI, {
36
- method: 'GET',
37
- url: '/files/{resource_type}/{resource_id}/download/{file_path}',
38
- path: {
39
- 'resource_type': resourceType,
40
- 'resource_id': resourceId,
41
- 'file_path': filePath,
42
- },
43
- errors: {
44
- 422: `Validation Error`,
45
- },
46
- });
47
- }
48
- /**
49
- * List Files
50
- * @param resourceType
51
- * @param resourceId
52
- * @param path
53
- * @param limit
54
- * @param pageToken
55
- * @returns ResourceFileListResponse Successful Response
56
- * @throws ApiError
57
- */
58
- static listFilesFilesResourceTypeResourceIdListGet(resourceType, resourceId, path = '', limit = 100, pageToken) {
59
- return __request(OpenAPI, {
60
- method: 'GET',
61
- url: '/files/{resource_type}/{resource_id}/list',
62
- path: {
63
- 'resource_type': resourceType,
64
- 'resource_id': resourceId,
65
- },
66
- query: {
67
- 'path': path,
68
- 'limit': limit,
69
- 'page_token': pageToken,
70
- },
71
- errors: {
72
- 422: `Validation Error`,
73
- },
74
- });
75
- }
76
- /**
77
- * Upload File
78
- * @param resourceType
79
- * @param resourceId
80
- * @param formData
81
- * @param path
82
- * @returns FileUploadResponse Successful Response
83
- * @throws ApiError
84
- */
85
- static uploadFileFilesResourceTypeResourceIdUploadPost(resourceType, resourceId, formData, path) {
86
- return __request(OpenAPI, {
87
- method: 'POST',
88
- url: '/files/{resource_type}/{resource_id}/upload',
89
- path: {
90
- 'resource_type': resourceType,
91
- 'resource_id': resourceId,
92
- },
93
- query: {
94
- 'path': path,
95
- },
96
- formData: formData,
97
- mediaType: 'multipart/form-data',
98
- errors: {
99
- 422: `Validation Error`,
100
- },
101
- });
102
- }
103
- }
@@ -1,58 +0,0 @@
1
- import type { GrantPermissionRequest } from '../models/GrantPermissionRequest.js';
2
- import type { PodPermissionsResponse } from '../models/PodPermissionsResponse.js';
3
- import type { ResourcePermissionListResponse } from '../models/ResourcePermissionListResponse.js';
4
- import type { ResourcePermissionResponse } from '../models/ResourcePermissionResponse.js';
5
- import type { SetVisibilityRequest } from '../models/SetVisibilityRequest.js';
6
- import type { CancelablePromise } from '../core/CancelablePromise.js';
7
- export declare class AuthorizationService {
8
- /**
9
- * Get My Pod Permissions
10
- * @param podId
11
- * @returns PodPermissionsResponse Successful Response
12
- * @throws ApiError
13
- */
14
- static podPermissionsMe(podId: string): CancelablePromise<PodPermissionsResponse>;
15
- /**
16
- * List Resource Permissions
17
- * List all ACL entries for a resource. Requires POD_ADMIN or being the resource creator.
18
- * @param podId
19
- * @param resourceType
20
- * @param resourceId
21
- * @returns ResourcePermissionListResponse Successful Response
22
- * @throws ApiError
23
- */
24
- static resourcePermissionsList(podId: string, resourceType: string, resourceId: string): CancelablePromise<ResourcePermissionListResponse>;
25
- /**
26
- * Grant Resource Permission
27
- * Add an ACL entry granting a user or role access to a resource.
28
- * @param podId
29
- * @param resourceType
30
- * @param resourceId
31
- * @param requestBody
32
- * @returns ResourcePermissionResponse Successful Response
33
- * @throws ApiError
34
- */
35
- static resourcePermissionsGrant(podId: string, resourceType: string, resourceId: string, requestBody: GrantPermissionRequest): CancelablePromise<ResourcePermissionResponse>;
36
- /**
37
- * Revoke Resource Permission
38
- * Remove an ACL entry for a resource.
39
- * @param podId
40
- * @param resourceType
41
- * @param resourceId
42
- * @param permissionId
43
- * @returns void
44
- * @throws ApiError
45
- */
46
- static resourcePermissionsRevoke(podId: string, resourceType: string, resourceId: string, permissionId: string): CancelablePromise<void>;
47
- /**
48
- * Set Resource Visibility
49
- * Update visibility for a resource (OWNER | RESTRICTED | POD). Requires POD_ADMIN or being the resource creator.
50
- * @param podId
51
- * @param resourceType
52
- * @param resourceId
53
- * @param requestBody
54
- * @returns void
55
- * @throws ApiError
56
- */
57
- static resourceVisibilitySet(podId: string, resourceType: string, resourceId: string, requestBody: SetVisibilityRequest): CancelablePromise<void>;
58
- }
@@ -1,122 +0,0 @@
1
- import { OpenAPI } from '../core/OpenAPI.js';
2
- import { request as __request } from '../core/request.js';
3
- export class AuthorizationService {
4
- /**
5
- * Get My Pod Permissions
6
- * @param podId
7
- * @returns PodPermissionsResponse Successful Response
8
- * @throws ApiError
9
- */
10
- static podPermissionsMe(podId) {
11
- return __request(OpenAPI, {
12
- method: 'GET',
13
- url: '/pods/{pod_id}/permissions/me',
14
- path: {
15
- 'pod_id': podId,
16
- },
17
- errors: {
18
- 422: `Validation Error`,
19
- },
20
- });
21
- }
22
- /**
23
- * List Resource Permissions
24
- * List all ACL entries for a resource. Requires POD_ADMIN or being the resource creator.
25
- * @param podId
26
- * @param resourceType
27
- * @param resourceId
28
- * @returns ResourcePermissionListResponse Successful Response
29
- * @throws ApiError
30
- */
31
- static resourcePermissionsList(podId, resourceType, resourceId) {
32
- return __request(OpenAPI, {
33
- method: 'GET',
34
- url: '/pods/{pod_id}/resources/{resource_type}/{resource_id}/permissions',
35
- path: {
36
- 'pod_id': podId,
37
- 'resource_type': resourceType,
38
- 'resource_id': resourceId,
39
- },
40
- errors: {
41
- 422: `Validation Error`,
42
- },
43
- });
44
- }
45
- /**
46
- * Grant Resource Permission
47
- * Add an ACL entry granting a user or role access to a resource.
48
- * @param podId
49
- * @param resourceType
50
- * @param resourceId
51
- * @param requestBody
52
- * @returns ResourcePermissionResponse Successful Response
53
- * @throws ApiError
54
- */
55
- static resourcePermissionsGrant(podId, resourceType, resourceId, requestBody) {
56
- return __request(OpenAPI, {
57
- method: 'POST',
58
- url: '/pods/{pod_id}/resources/{resource_type}/{resource_id}/permissions',
59
- path: {
60
- 'pod_id': podId,
61
- 'resource_type': resourceType,
62
- 'resource_id': resourceId,
63
- },
64
- body: requestBody,
65
- mediaType: 'application/json',
66
- errors: {
67
- 422: `Validation Error`,
68
- },
69
- });
70
- }
71
- /**
72
- * Revoke Resource Permission
73
- * Remove an ACL entry for a resource.
74
- * @param podId
75
- * @param resourceType
76
- * @param resourceId
77
- * @param permissionId
78
- * @returns void
79
- * @throws ApiError
80
- */
81
- static resourcePermissionsRevoke(podId, resourceType, resourceId, permissionId) {
82
- return __request(OpenAPI, {
83
- method: 'DELETE',
84
- url: '/pods/{pod_id}/resources/{resource_type}/{resource_id}/permissions/{permission_id}',
85
- path: {
86
- 'pod_id': podId,
87
- 'resource_type': resourceType,
88
- 'resource_id': resourceId,
89
- 'permission_id': permissionId,
90
- },
91
- errors: {
92
- 422: `Validation Error`,
93
- },
94
- });
95
- }
96
- /**
97
- * Set Resource Visibility
98
- * Update visibility for a resource (OWNER | RESTRICTED | POD). Requires POD_ADMIN or being the resource creator.
99
- * @param podId
100
- * @param resourceType
101
- * @param resourceId
102
- * @param requestBody
103
- * @returns void
104
- * @throws ApiError
105
- */
106
- static resourceVisibilitySet(podId, resourceType, resourceId, requestBody) {
107
- return __request(OpenAPI, {
108
- method: 'PATCH',
109
- url: '/pods/{pod_id}/resources/{resource_type}/{resource_id}/visibility',
110
- path: {
111
- 'pod_id': podId,
112
- 'resource_type': resourceType,
113
- 'resource_id': resourceId,
114
- },
115
- body: requestBody,
116
- mediaType: 'application/json',
117
- errors: {
118
- 422: `Validation Error`,
119
- },
120
- });
121
- }
122
- }