Merge pull request #15171 from Budibase/fix/type-fixes
API typing fixes
This commit is contained in:
commit
cf98669c2a
|
@ -9,7 +9,7 @@ import {
|
||||||
RemovePermissionRequest,
|
RemovePermissionRequest,
|
||||||
RemovePermissionResponse,
|
RemovePermissionResponse,
|
||||||
FetchResourcePermissionInfoResponse,
|
FetchResourcePermissionInfoResponse,
|
||||||
FetchBuiltinPermissionsRequest,
|
FetchBuiltinPermissionsResponse,
|
||||||
FetchPermissionLevelsRequest,
|
FetchPermissionLevelsRequest,
|
||||||
} from "@budibase/types"
|
} from "@budibase/types"
|
||||||
import {
|
import {
|
||||||
|
@ -22,7 +22,7 @@ import { PermissionUpdateType } from "../../sdk/app/permissions"
|
||||||
const SUPPORTED_LEVELS = CURRENTLY_SUPPORTED_LEVELS
|
const SUPPORTED_LEVELS = CURRENTLY_SUPPORTED_LEVELS
|
||||||
|
|
||||||
export function fetchBuiltin(
|
export function fetchBuiltin(
|
||||||
ctx: UserCtx<void, FetchBuiltinPermissionsRequest>
|
ctx: UserCtx<void, FetchBuiltinPermissionsResponse>
|
||||||
) {
|
) {
|
||||||
ctx.body = Object.values(permissions.getBuiltinPermissions())
|
ctx.body = Object.values(permissions.getBuiltinPermissions())
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import { BuiltinPermission, PermissionLevel } from "../../../sdk"
|
import { BuiltinPermission, PermissionLevel } from "../../../sdk"
|
||||||
|
|
||||||
export type FetchBuiltinPermissionsRequest = BuiltinPermission[]
|
export type FetchBuiltinPermissionsResponse = BuiltinPermission[]
|
||||||
|
|
||||||
export type FetchPermissionLevelsRequest = string[]
|
export type FetchPermissionLevelsRequest = string[]
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import { DevInfo, User } from "../../../documents"
|
import { DevInfo, User } from "../../../documents"
|
||||||
|
|
||||||
export interface GenerateAPIKeyRequest {
|
export interface GenerateAPIKeyRequest {
|
||||||
userId: string
|
userId?: string
|
||||||
}
|
}
|
||||||
export interface GenerateAPIKeyResponse extends DevInfo {}
|
export interface GenerateAPIKeyResponse extends DevInfo {}
|
||||||
|
|
||||||
|
|
|
@ -28,6 +28,7 @@ export interface App extends Document {
|
||||||
upgradableVersion?: string
|
upgradableVersion?: string
|
||||||
snippets?: Snippet[]
|
snippets?: Snippet[]
|
||||||
creationVersion?: string
|
creationVersion?: string
|
||||||
|
updatedBy?: string
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface AppInstance {
|
export interface AppInstance {
|
||||||
|
|
Loading…
Reference in New Issue