ApiResponse.methodNotAllowed constructor

ApiResponse.methodNotAllowed()

Method not allowed response (405)

Implementation

factory ApiResponse.methodNotAllowed() {
  return ApiResponse.json(
    {'error': 'Method not allowed'},
    statusCode: 405,
  );
}