attio-js
Version:
Developer-friendly & type-safe JS/TS SDK based on the official OpenAPI spec of Attio.
230 lines • 11.8 kB
TypeScript
import * as z from "zod";
import { ClosedEnum } from "../../types/enums.js";
import { Result as SafeParseResult } from "../../types/fp.js";
import { List, List$Outbound } from "../components/list.js";
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
/**
* The level of access granted to all members of the workspace for this list. Pass `null` to keep the list private and only grant access to specific workspace members.
*/
export declare const PatchV2ListsListWorkspaceAccess: {
readonly FullAccess: "full-access";
readonly ReadAndWrite: "read-and-write";
readonly ReadOnly: "read-only";
};
/**
* The level of access granted to all members of the workspace for this list. Pass `null` to keep the list private and only grant access to specific workspace members.
*/
export type PatchV2ListsListWorkspaceAccess = ClosedEnum<typeof PatchV2ListsListWorkspaceAccess>;
/**
* The level of access to the list.
*/
export declare const PatchV2ListsListLevel: {
readonly FullAccess: "full-access";
readonly ReadAndWrite: "read-and-write";
readonly ReadOnly: "read-only";
};
/**
* The level of access to the list.
*/
export type PatchV2ListsListLevel = ClosedEnum<typeof PatchV2ListsListLevel>;
export type PatchV2ListsListWorkspaceMemberAccess = {
/**
* A UUID to identify the workspace member to grant access to.
*/
workspaceMemberId: string;
/**
* The level of access to the list.
*/
level: PatchV2ListsListLevel;
};
export type PatchV2ListsListData = {
/**
* The human-readable name of the list.
*/
name?: string | undefined;
/**
* A unique, human-readable slug to access the list through API calls. Should be formatted in snake case.
*/
apiSlug?: string | undefined;
/**
* The level of access granted to all members of the workspace for this list. Pass `null` to keep the list private and only grant access to specific workspace members.
*/
workspaceAccess?: PatchV2ListsListWorkspaceAccess | null | undefined;
/**
* The level of access granted to specific workspace members for this list. Pass an empty array to grant access to no workspace members.
*/
workspaceMemberAccess?: Array<PatchV2ListsListWorkspaceMemberAccess> | undefined;
};
export type PatchV2ListsListRequestBody = {
data: PatchV2ListsListData;
};
export type PatchV2ListsListRequest = {
list: string;
requestBody: PatchV2ListsListRequestBody;
};
/**
* Success
*/
export type PatchV2ListsListResponse = {
data: List;
};
/** @internal */
export declare const PatchV2ListsListWorkspaceAccess$inboundSchema: z.ZodNativeEnum<typeof PatchV2ListsListWorkspaceAccess>;
/** @internal */
export declare const PatchV2ListsListWorkspaceAccess$outboundSchema: z.ZodNativeEnum<typeof PatchV2ListsListWorkspaceAccess>;
/**
* @internal
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
*/
export declare namespace PatchV2ListsListWorkspaceAccess$ {
/** @deprecated use `PatchV2ListsListWorkspaceAccess$inboundSchema` instead. */
const inboundSchema: z.ZodNativeEnum<{
readonly FullAccess: "full-access";
readonly ReadAndWrite: "read-and-write";
readonly ReadOnly: "read-only";
}>;
/** @deprecated use `PatchV2ListsListWorkspaceAccess$outboundSchema` instead. */
const outboundSchema: z.ZodNativeEnum<{
readonly FullAccess: "full-access";
readonly ReadAndWrite: "read-and-write";
readonly ReadOnly: "read-only";
}>;
}
/** @internal */
export declare const PatchV2ListsListLevel$inboundSchema: z.ZodNativeEnum<typeof PatchV2ListsListLevel>;
/** @internal */
export declare const PatchV2ListsListLevel$outboundSchema: z.ZodNativeEnum<typeof PatchV2ListsListLevel>;
/**
* @internal
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
*/
export declare namespace PatchV2ListsListLevel$ {
/** @deprecated use `PatchV2ListsListLevel$inboundSchema` instead. */
const inboundSchema: z.ZodNativeEnum<{
readonly FullAccess: "full-access";
readonly ReadAndWrite: "read-and-write";
readonly ReadOnly: "read-only";
}>;
/** @deprecated use `PatchV2ListsListLevel$outboundSchema` instead. */
const outboundSchema: z.ZodNativeEnum<{
readonly FullAccess: "full-access";
readonly ReadAndWrite: "read-and-write";
readonly ReadOnly: "read-only";
}>;
}
/** @internal */
export declare const PatchV2ListsListWorkspaceMemberAccess$inboundSchema: z.ZodType<PatchV2ListsListWorkspaceMemberAccess, z.ZodTypeDef, unknown>;
/** @internal */
export type PatchV2ListsListWorkspaceMemberAccess$Outbound = {
workspace_member_id: string;
level: string;
};
/** @internal */
export declare const PatchV2ListsListWorkspaceMemberAccess$outboundSchema: z.ZodType<PatchV2ListsListWorkspaceMemberAccess$Outbound, z.ZodTypeDef, PatchV2ListsListWorkspaceMemberAccess>;
/**
* @internal
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
*/
export declare namespace PatchV2ListsListWorkspaceMemberAccess$ {
/** @deprecated use `PatchV2ListsListWorkspaceMemberAccess$inboundSchema` instead. */
const inboundSchema: z.ZodType<PatchV2ListsListWorkspaceMemberAccess, z.ZodTypeDef, unknown>;
/** @deprecated use `PatchV2ListsListWorkspaceMemberAccess$outboundSchema` instead. */
const outboundSchema: z.ZodType<PatchV2ListsListWorkspaceMemberAccess$Outbound, z.ZodTypeDef, PatchV2ListsListWorkspaceMemberAccess>;
/** @deprecated use `PatchV2ListsListWorkspaceMemberAccess$Outbound` instead. */
type Outbound = PatchV2ListsListWorkspaceMemberAccess$Outbound;
}
export declare function patchV2ListsListWorkspaceMemberAccessToJSON(patchV2ListsListWorkspaceMemberAccess: PatchV2ListsListWorkspaceMemberAccess): string;
export declare function patchV2ListsListWorkspaceMemberAccessFromJSON(jsonString: string): SafeParseResult<PatchV2ListsListWorkspaceMemberAccess, SDKValidationError>;
/** @internal */
export declare const PatchV2ListsListData$inboundSchema: z.ZodType<PatchV2ListsListData, z.ZodTypeDef, unknown>;
/** @internal */
export type PatchV2ListsListData$Outbound = {
name?: string | undefined;
api_slug?: string | undefined;
workspace_access?: string | null | undefined;
workspace_member_access?: Array<PatchV2ListsListWorkspaceMemberAccess$Outbound> | undefined;
};
/** @internal */
export declare const PatchV2ListsListData$outboundSchema: z.ZodType<PatchV2ListsListData$Outbound, z.ZodTypeDef, PatchV2ListsListData>;
/**
* @internal
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
*/
export declare namespace PatchV2ListsListData$ {
/** @deprecated use `PatchV2ListsListData$inboundSchema` instead. */
const inboundSchema: z.ZodType<PatchV2ListsListData, z.ZodTypeDef, unknown>;
/** @deprecated use `PatchV2ListsListData$outboundSchema` instead. */
const outboundSchema: z.ZodType<PatchV2ListsListData$Outbound, z.ZodTypeDef, PatchV2ListsListData>;
/** @deprecated use `PatchV2ListsListData$Outbound` instead. */
type Outbound = PatchV2ListsListData$Outbound;
}
export declare function patchV2ListsListDataToJSON(patchV2ListsListData: PatchV2ListsListData): string;
export declare function patchV2ListsListDataFromJSON(jsonString: string): SafeParseResult<PatchV2ListsListData, SDKValidationError>;
/** @internal */
export declare const PatchV2ListsListRequestBody$inboundSchema: z.ZodType<PatchV2ListsListRequestBody, z.ZodTypeDef, unknown>;
/** @internal */
export type PatchV2ListsListRequestBody$Outbound = {
data: PatchV2ListsListData$Outbound;
};
/** @internal */
export declare const PatchV2ListsListRequestBody$outboundSchema: z.ZodType<PatchV2ListsListRequestBody$Outbound, z.ZodTypeDef, PatchV2ListsListRequestBody>;
/**
* @internal
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
*/
export declare namespace PatchV2ListsListRequestBody$ {
/** @deprecated use `PatchV2ListsListRequestBody$inboundSchema` instead. */
const inboundSchema: z.ZodType<PatchV2ListsListRequestBody, z.ZodTypeDef, unknown>;
/** @deprecated use `PatchV2ListsListRequestBody$outboundSchema` instead. */
const outboundSchema: z.ZodType<PatchV2ListsListRequestBody$Outbound, z.ZodTypeDef, PatchV2ListsListRequestBody>;
/** @deprecated use `PatchV2ListsListRequestBody$Outbound` instead. */
type Outbound = PatchV2ListsListRequestBody$Outbound;
}
export declare function patchV2ListsListRequestBodyToJSON(patchV2ListsListRequestBody: PatchV2ListsListRequestBody): string;
export declare function patchV2ListsListRequestBodyFromJSON(jsonString: string): SafeParseResult<PatchV2ListsListRequestBody, SDKValidationError>;
/** @internal */
export declare const PatchV2ListsListRequest$inboundSchema: z.ZodType<PatchV2ListsListRequest, z.ZodTypeDef, unknown>;
/** @internal */
export type PatchV2ListsListRequest$Outbound = {
list: string;
RequestBody: PatchV2ListsListRequestBody$Outbound;
};
/** @internal */
export declare const PatchV2ListsListRequest$outboundSchema: z.ZodType<PatchV2ListsListRequest$Outbound, z.ZodTypeDef, PatchV2ListsListRequest>;
/**
* @internal
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
*/
export declare namespace PatchV2ListsListRequest$ {
/** @deprecated use `PatchV2ListsListRequest$inboundSchema` instead. */
const inboundSchema: z.ZodType<PatchV2ListsListRequest, z.ZodTypeDef, unknown>;
/** @deprecated use `PatchV2ListsListRequest$outboundSchema` instead. */
const outboundSchema: z.ZodType<PatchV2ListsListRequest$Outbound, z.ZodTypeDef, PatchV2ListsListRequest>;
/** @deprecated use `PatchV2ListsListRequest$Outbound` instead. */
type Outbound = PatchV2ListsListRequest$Outbound;
}
export declare function patchV2ListsListRequestToJSON(patchV2ListsListRequest: PatchV2ListsListRequest): string;
export declare function patchV2ListsListRequestFromJSON(jsonString: string): SafeParseResult<PatchV2ListsListRequest, SDKValidationError>;
/** @internal */
export declare const PatchV2ListsListResponse$inboundSchema: z.ZodType<PatchV2ListsListResponse, z.ZodTypeDef, unknown>;
/** @internal */
export type PatchV2ListsListResponse$Outbound = {
data: List$Outbound;
};
/** @internal */
export declare const PatchV2ListsListResponse$outboundSchema: z.ZodType<PatchV2ListsListResponse$Outbound, z.ZodTypeDef, PatchV2ListsListResponse>;
/**
* @internal
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
*/
export declare namespace PatchV2ListsListResponse$ {
/** @deprecated use `PatchV2ListsListResponse$inboundSchema` instead. */
const inboundSchema: z.ZodType<PatchV2ListsListResponse, z.ZodTypeDef, unknown>;
/** @deprecated use `PatchV2ListsListResponse$outboundSchema` instead. */
const outboundSchema: z.ZodType<PatchV2ListsListResponse$Outbound, z.ZodTypeDef, PatchV2ListsListResponse>;
/** @deprecated use `PatchV2ListsListResponse$Outbound` instead. */
type Outbound = PatchV2ListsListResponse$Outbound;
}
export declare function patchV2ListsListResponseToJSON(patchV2ListsListResponse: PatchV2ListsListResponse): string;
export declare function patchV2ListsListResponseFromJSON(jsonString: string): SafeParseResult<PatchV2ListsListResponse, SDKValidationError>;
//# sourceMappingURL=patchv2listslist.d.ts.map