UNPKG

@unkey/api

Version:

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

28 lines 1.91 kB
import { UnkeyCore } from "../core.js"; import { RequestOptions } from "../lib/sdks.js"; import * as components from "../models/components/index.js"; import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js"; import * as errors from "../models/errors/index.js"; import { ResponseValidationError } from "../models/errors/responsevalidationerror.js"; import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; import { UnkeyError } from "../models/errors/unkeyerror.js"; import { APIPromise } from "../types/async.js"; import { Result } from "../types/fp.js"; /** * Get API namespace * * @remarks * Retrieve basic information about an API namespace including its ID and name. * * Use this to verify an API exists before performing operations, get the human-readable name when you only have the API ID, or confirm access to a specific namespace. For detailed key information, use the `listKeys` endpoint instead. * * **Required Permissions** * * Your root key must have one of the following permissions: * - `api.*.read_api` (to read any API) * - `api.<api_id>.read_api` (to read a specific API) * * If set, this operation will use {@link Security.rootKey} from the global security. */ export declare function apisGetApi(client: UnkeyCore, request: components.V2ApisGetApiRequestBody, options?: RequestOptions): APIPromise<Result<components.V2ApisGetApiResponseBody, errors.BadRequestErrorResponse | errors.UnauthorizedErrorResponse | errors.ForbiddenErrorResponse | errors.NotFoundErrorResponse | errors.TooManyRequestsErrorResponse | errors.InternalServerErrorResponse | UnkeyError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>; //# sourceMappingURL=apisGetApi.d.ts.map