StatusCode class

Status Codes

Constructors

StatusCode()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

ACCEPTED → const int
The request has been received but not yet acted upon. It is non-committal, meaning that there is no way in HTTP to later send an asynchronous response indicating the outcome of processing the request. It is intended for cases where another process or server handles the request, or for batch processing.
BAD_GATEWAY → const int
This error response means that the server, while working as a gateway to get a response needed to handle the request, got an invalid response.
BAD_REQUEST → const int
This response means that server could not understand the request due to invalid syntax.
CONFLICT → const int
This response is sent when a request conflicts with the current state of the server.
CONTINUE → const int
This interim response indicates that everything so far is OK and that the client should continue with the request or ignore it if it is already finished.
CREATED → const int
The request has succeeded and a new resource has been created as a result of it. This is typically the response sent after a PUT request.
EXPECTATION_FAILED → const int
This response code means the expectation indicated by the Expect request header field can't be met by the server.
FAILED_DEPENDENCY → const int
The request failed due to failure of a previous request.
FORBIDDEN → const int
The client does not have access rights to the content, i.e. they are unauthorized, so server is rejecting to give proper response. Unlike 401, the client's identity is known to the server.
GATEWAY_TIMEOUT → const int
This error response is given when the server is acting as a gateway and cannot get a response in time.
GONE → const int
This response would be sent when the requested content has been permenantly deleted from server, with no forwarding address.
HTTP_VERSION_NOT_SUPPORTED → const int
The HTTP version used in the request is not supported by the server.
IM_A_TEAPOT → const int
Any attempt to brew coffee with a teapot should result in the error code "418 I'm a teapot".
INSUFFICIENT_SPACE_ON_RESOURCE → const int
The 507 (Insufficient Storage) status code means the method could not be performed on the resource because the server is unable to store the representation needed to successfully complete the request.
INSUFFICIENT_STORAGE → const int
The server has an internal configuration error: the chosen variant resource is configured to engage in transparent content negotiation itself, and is therefore not a proper end point in the negotiation process.
INTERNAL_SERVER_ERROR → const int
The server encountered an unexpected condition that prevented it from fulfilling the request.
LENGTH_REQUIRED → const int
The server rejected the request because the Content-Length header field is not defined and the server requires it.
LOCKED → const int
The resource that is being accessed is locked.
METHOD_FAILURE → const int
@deprecated A deprecated response used by the Spring Framework when a method has failed.
METHOD_NOT_ALLOWED → const int
The request method is known by the server but has been disabled and cannot be used. For example, an API may forbid DELETE-ing a resource. The two mandatory methods, GET and HEAD, must never be disabled and should not return this error code.
MOVED_PERMANENTLY → const int
This response code means that URI of requested resource has been changed. Probably, new URI would be given in the response.
MOVED_TEMPORARILY → const int
This response code means that URI of requested resource has been changed temporarily. New changes in the URI might be made in the future. Therefore, this same URI should be used by the client in future requests.
MULTI_STATUS → const int
A Multi-Status response conveys information about multiple resources in situations where multiple status codes might be appropriate.
MULTIPLE_CHOICES → const int
The request has more than one possible responses. User-agent or user should choose one of them.
NETWORK_AUTHENTICATION_REQUIRED → const int
The 511 status code indicates that the client needs to authenticate to gain network access.
NO_CONTENT → const int
There is no content to send for this request, but the headers may be useful. The user-agent may update its cached headers for this resource with the new ones.
NON_AUTHORITATIVE_INFORMATION → const int
This response code means returned meta-information set is not exact set as available from the origin server, but collected from a local or a third party copy.
NOT_ACCEPTABLE → const int
This response is sent when the web server, after performing server-driven content negotiation, doesn't find any content following the criteria given by the user agent.
NOT_FOUND → const int
The server can not find requested resource.
NOT_IMPLEMENTED → const int
The request method is not supported by the server and cannot be handled.
NOT_MODIFIED → const int
This is used for caching purposes. It is telling to client that response has not been modified. So, client can continue to use same cached version of response.
OK → const int
The request has succeeded. The meaning of a success varies depending on the HTTP method:
PARTIAL_CONTENT → const int
This response code is used because of range header sent by the client to separate download into multiple streams.
PAYMENT_REQUIRED → const int
This response code is reserved for future use. Initial aim for creating this code was using it for digital payment systems however this is not used currently.
PERMANENT_REDIRECT → const int
This means that the resource is now permanently located at another URI, specified by the Location: HTTP Response header.
PRECONDITION_FAILED → const int
The client has indicated preconditions in its headers which the server does not meet.
PRECONDITION_REQUIRED → const int
The origin server requires the request to be conditional.
PROCESSING → const int
This code indicates that the server has received and is processing the request, but no response is available yet.
PROXY_AUTHENTICATION_REQUIRED → const int
This is similar to 401 but authentication is needed to be done by a proxy.
REQUEST_HEADER_FIELDS_TOO_LARGE → const int
The server is unwilling to process the request because its header fields are too large. The request MAY be resubmitted after reducing the size of the request header fields.
REQUEST_TIMEOUT → const int
This response is sent on an idle connection by some servers, even without any previous request by the client.
REQUEST_TOO_LONG → const int
Request entity is larger than limits defined by server; the server might close the connection or return an Retry-After header field.
REQUEST_URI_TOO_LONG → const int
The URI requested by the client is longer than the server is willing to interpret.
REQUESTED_RANGE_NOT_SATISFIABLE → const int
The range specified by the Range header field in the request can't be fulfilled; it's possible that the range is outside the size of the target URI's data.
RESET_CONTENT → const int
This response code is sent after accomplishing request to tell user agent reset document view which sent this request.
SEE_OTHER → const int
Server sent this response to directing client to get requested resource to another URI with an GET request.
SERVICE_UNAVAILABLE → const int
The server is not ready to handle the request.
SWITCHING_PROTOCOLS → const int
This code is sent in response to an Upgrade request header by the client, and indicates the protocol the server is switching too.
TEMPORARY_REDIRECT → const int
Server sent this response to directing client to get requested resource to another URI with same method that used prior request.
TOO_MANY_REQUESTS → const int
The user has sent too many requests in a given amount of time ("rate limiting").
UNAUTHORIZED → const int
Although the HTTP standard specifies "unauthorized", semantically this response means "unauthenticated". That is, the client must authenticate itself to get the requested response.
The user-agent requested a resource that cannot legally be provided, such as a web page censored by a government.
UNPROCESSABLE_ENTITY → const int
The request was well-formed but was unable to be followed due to semantic errors.
UNSUPPORTED_MEDIA_TYPE → const int
The media format of the requested data is not supported by the server, so the server is rejecting the request.
USE_PROXY → const int
@deprecated Was defined in a previous version of the HTTP specification to indicate that a requested response must be accessed by a proxy.