@vercel/sdk
Version:
<p align="center"> <a href="https://vercel.com"> <img src="https://assets.vercel.com/image/upload/v1588805858/repositories/vercel/logo.png" height="96"> <h3 align="center">Vercel</h3> </a> <p align="center">Develop. Preview. Ship.</p> </p>
81 lines • 3.21 kB
TypeScript
import * as z from "zod/v3";
import { ClosedEnum } from "../types/enums.js";
import { Result as SafeParseResult } from "../types/fp.js";
import { SDKValidationError } from "./sdkvalidationerror.js";
/**
* Custom environments available on the project. This list can include environments where the connector is not enabled.
*/
export type CustomEnvironments = {
/**
* Stable custom environment ID.
*/
id: string;
/**
* Current human-readable custom environment slug.
*/
slug: string;
};
/**
* Vercel project connected to the connector.
*/
export type Project = {
/**
* Same Vercel project ID as the connection's top-level `projectId`.
*/
id: string;
/**
* Current Vercel project name.
*/
name: string;
/**
* Custom environments available on the project. This list can include environments where the connector is not enabled.
*/
customEnvironments?: Array<CustomEnvironments> | undefined;
};
export declare const EnabledEnvironments2: {
readonly Development: "development";
readonly Preview: "preview";
readonly Production: "production";
};
export type EnabledEnvironments2 = ClosedEnum<typeof EnabledEnvironments2>;
export type EnabledEnvironments = string | EnabledEnvironments2;
/**
* A connection between a connector and a Vercel project, including the environments where the connector is enabled.
*/
export type ConnectProjectConnection = {
/**
* Stable `scl_` connector ID, even when the request used a UID.
*/
connectorId: string;
/**
* Vercel project connected to the connector.
*/
project: Project;
/**
* Environments where the connector is enabled for the project.
*/
enabledEnvironments: Array<string | EnabledEnvironments2>;
/**
* Time when the project connection was created, in epoch milliseconds.
*/
createdAt: number;
/**
* Time when the project connection was last updated, in epoch milliseconds.
*/
updatedAt: number;
};
/** @internal */
export declare const CustomEnvironments$inboundSchema: z.ZodType<CustomEnvironments, z.ZodTypeDef, unknown>;
export declare function customEnvironmentsFromJSON(jsonString: string): SafeParseResult<CustomEnvironments, SDKValidationError>;
/** @internal */
export declare const Project$inboundSchema: z.ZodType<Project, z.ZodTypeDef, unknown>;
export declare function projectFromJSON(jsonString: string): SafeParseResult<Project, SDKValidationError>;
/** @internal */
export declare const EnabledEnvironments2$inboundSchema: z.ZodNativeEnum<typeof EnabledEnvironments2>;
/** @internal */
export declare const EnabledEnvironments$inboundSchema: z.ZodType<EnabledEnvironments, z.ZodTypeDef, unknown>;
export declare function enabledEnvironmentsFromJSON(jsonString: string): SafeParseResult<EnabledEnvironments, SDKValidationError>;
/** @internal */
export declare const ConnectProjectConnection$inboundSchema: z.ZodType<ConnectProjectConnection, z.ZodTypeDef, unknown>;
export declare function connectProjectConnectionFromJSON(jsonString: string): SafeParseResult<ConnectProjectConnection, SDKValidationError>;
//# sourceMappingURL=connectprojectconnection.d.ts.map