UNPKG

@unkey/api

Version:

Developer-friendly & type-safe Typescript SDK specifically catered to leverage *@unkey/api* API.

39 lines 1.71 kB
import * as z from "zod/v3"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; export type Permission = { /** * The unique identifier for this permission within Unkey's system. * * @remarks * Generated automatically when the permission is created and used to reference this permission in API operations. * Always begins with 'perm_' followed by alphanumeric characters and underscores. */ id: string; /** * The human-readable name for this permission that describes its purpose. * * @remarks * Should be descriptive enough for developers to understand what access it grants. * Use clear, semantic names that reflect the resources or actions being permitted. * Names must be unique within your workspace to avoid confusion and conflicts. */ name: string; /** * The unique URL-safe identifier for this permission. */ slug: string; /** * Optional detailed explanation of what this permission grants access to. * * @remarks * Helps team members understand the scope and implications of granting this permission. * Include information about what resources can be accessed and what actions can be performed. * Not visible to end users - this is for internal documentation and team clarity. */ description?: string | undefined; }; /** @internal */ export declare const Permission$inboundSchema: z.ZodType<Permission, z.ZodTypeDef, unknown>; export declare function permissionFromJSON(jsonString: string): SafeParseResult<Permission, SDKValidationError>; //# sourceMappingURL=permission.d.ts.map