Documentation / @zerotal/core / index / MethodNotAllowedError
Class: MethodNotAllowedError
Defined in: errors/HttpError.ts:52
405 Method Not Allowed — the route exists but not for this HTTP method.
Param
allowed
Methods the route does accept; populates the Allow header.
Extends
Constructors
Constructor
new MethodNotAllowedError(
allowed?,message?):MethodNotAllowedError
Defined in: errors/HttpError.ts:53
Parameters
allowed?
string[] = []
message?
string = "Method Not Allowed"
Returns
MethodNotAllowedError
Overrides
Properties
headers?
optionalheaders?:Record<string,string>
Defined in: errors/HttpError.ts:15
Inherited from
code
readonlycode:string
Defined in: errors/ZerotalError.ts:18
Inherited from
status
readonlystatus:number=500
Defined in: errors/ZerotalError.ts:19
Inherited from
context?
readonlyoptionalcontext?:Record<string,unknown>
Defined in: errors/ZerotalError.ts:20