UNPKG

@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>

46 lines 1.96 kB
/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { remap as remap$ } from "../lib/primitives.js"; import { safeParse } from "../lib/schemas.js"; import * as types from "../types/primitives.js"; /** @internal */ export const RevokeInstallationCredentialRequestBody$outboundSchema = z.object({ token: z.string(), clientSecret: z.string(), clientId: z.string().optional(), }).transform((v) => { return remap$(v, { clientSecret: "client_secret", clientId: "client_id", }); }); export function revokeInstallationCredentialRequestBodyToJSON(revokeInstallationCredentialRequestBody) { return JSON.stringify(RevokeInstallationCredentialRequestBody$outboundSchema.parse(revokeInstallationCredentialRequestBody)); } /** @internal */ export const RevokeInstallationCredentialRequest$outboundSchema = z.object({ integrationConfigurationId: z.string(), requestBody: z.lazy(() => RevokeInstallationCredentialRequestBody$outboundSchema).optional(), }).transform((v) => { return remap$(v, { requestBody: "RequestBody", }); }); export function revokeInstallationCredentialRequestToJSON(revokeInstallationCredentialRequest) { return JSON.stringify(RevokeInstallationCredentialRequest$outboundSchema.parse(revokeInstallationCredentialRequest)); } /** @internal */ export const RevokeInstallationCredentialResponseBody$inboundSchema = z.object({ revoked: types.boolean(), already_revoked: types.boolean(), }).transform((v) => { return remap$(v, { "already_revoked": "alreadyRevoked", }); }); export function revokeInstallationCredentialResponseBodyFromJSON(jsonString) { return safeParse(jsonString, (x) => RevokeInstallationCredentialResponseBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'RevokeInstallationCredentialResponseBody' from JSON`); } //# sourceMappingURL=revokeinstallationcredentialop.js.map