UNPKG

@unkey/api

Version:

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

46 lines (41 loc) 1.9 kB
/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { Meta, Meta$inboundSchema } from "./meta.js"; import { V2RatelimitDeleteOverrideResponseData, V2RatelimitDeleteOverrideResponseData$inboundSchema, } from "./v2ratelimitdeleteoverrideresponsedata.js"; export type V2RatelimitDeleteOverrideResponseBody = { /** * Metadata object included in every API response. This provides context about the request and is essential for debugging, audit trails, and support inquiries. The `requestId` is particularly important when troubleshooting issues with the Unkey support team. */ meta: Meta; /** * Empty response object. A successful response indicates the override was successfully deleted. The operation is immediate - as soon as this response is received, the override no longer exists and affected identifiers have reverted to using the default rate limit for the namespace. No other data is returned as part of the deletion operation. */ data: V2RatelimitDeleteOverrideResponseData; }; /** @internal */ export const V2RatelimitDeleteOverrideResponseBody$inboundSchema: z.ZodType< V2RatelimitDeleteOverrideResponseBody, z.ZodTypeDef, unknown > = z.object({ meta: Meta$inboundSchema, data: V2RatelimitDeleteOverrideResponseData$inboundSchema, }); export function v2RatelimitDeleteOverrideResponseBodyFromJSON( jsonString: string, ): SafeParseResult<V2RatelimitDeleteOverrideResponseBody, SDKValidationError> { return safeParse( jsonString, (x) => V2RatelimitDeleteOverrideResponseBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'V2RatelimitDeleteOverrideResponseBody' from JSON`, ); }