クラス: MCPAuthAuthServerError
リモート認可 (Authorization) サーバーで問題が発生した場合にスローされるエラーです。
継承
コンストラクター
コンストラクター
new MCPAuthAuthServerError(code: AuthServerErrorCode, cause?: unknown): MCPAuthAuthServerError;
パラメーター
code
cause?
unknown
戻り値
MCPAuthAuthServerError
オーバーライド
プロパティ
cause?
readonly optional cause: unknown;
継承元
code
readonly code: AuthServerErrorCode;
スネークケース形式のエラーコードです。
継承元
message
message: string;
継承元
name
name: string = 'MCPAuthAuthServerError';
オーバーライド
stack?
optional stack: string;
継承元
prepareStackTrace()?
static optional prepareStackTrace: (err: Error, stackTraces: CallSite[]) => any;
スタックトレースのフォーマットをカスタマイズするためのオプションのオーバーライド
パラメーター
err
Error
stackTraces
CallSite
[]
戻り値
any
参照
https://v8.dev/docs/stack-trace-api#customizing-stack-traces
継承元
MCPAuthError
.prepareStackTrace
stackTraceLimit
static stackTraceLimit: number;
継承元
メソッド
toJson()
toJson(showCause: boolean): Record<string, unknown>;
エラーを HTTP レスポンスに適した JSON 形式に変換します。
パラメーター
showCause
boolean
= false
JSON レスポンスにエラーの原因を含めるかどうかを指定します。
デフォルトは false
です。
戻り値
Record
<string
, unknown
>
継承元
captureStackTrace()
static captureStackTrace(targetObject: object, constructorOpt?: Function): void;
ターゲットオブジェクトに .stack プロパティを作成します
パラメーター
targetObject
object
constructorOpt?
Function
戻り値
void