Enum a2::response::ErrorReason[][src]

pub enum ErrorReason {
Show 28 variants BadCollapseId, BadDeviceToken, BadExpirationDate, BadMessageId, BadPriority, BadTopic, DeviceTokenNotForTopic, DuplicateHeaders, IdleTimeout, MissingDeviceToken, MissingTopic, PayloadEmpty, TopicDisallowed, BadCertificate, BadCertificateEnvironment, ExpiredProviderToken, Forbidden, InvalidProviderToken, MissingProviderToken, BadPath, MethodNotAllowed, Unregistered, PayloadTooLarge, TooManyProviderTokenUpdates, TooManyRequests, InternalServerError, ServiceUnavailable, Shutdown,
}
Expand description

A description what went wrong with the push notification.

Variants

BadCollapseId

The collapse identifier exceeds the maximum allowed size.

BadDeviceToken

The specified device token was bad. Verify that the request contains a valid token and that the token matches the environment.

BadExpirationDate

The apns_expiration in NotificationOptions is bad.

BadMessageId

The apns_id in NotificationOptions is bad.

BadPriority

The apns_priority in NotificationOptions is bad.

BadTopic

The apns_topic in NotificationOptions is bad.

DeviceTokenNotForTopic

The device token does not match the specified topic.

DuplicateHeaders

One or more headers were repeated.

IdleTimeout

Idle time out.

MissingDeviceToken

The device token is not specified in the payload.

MissingTopic

The apns_topic of the NotificationOptions was not specified and was required. The apns_topic header is mandatory when the client is connected using the CertificateConnector and the included PKCS12 file includes multiple topics, or when using the TokenConnector.

PayloadEmpty

The message payload was empty.

TopicDisallowed

Pushing to this topic is not allowed.

BadCertificate

The certificate was bad.

BadCertificateEnvironment

The client certificate was for the wrong environment.

ExpiredProviderToken

The provider token is stale and a new token should be generated.

Forbidden

The specified action is not allowed.

InvalidProviderToken

The provider token is not valid or the token signature could not be verified.

MissingProviderToken

No provider certificate was used to connect to APNs and Authorization header was missing or no provider token was specified.

BadPath

The request path value is bad.

MethodNotAllowed

The request method was not POST.

Unregistered

The device token is inactive for the specified topic. You should stop sending notifications to this token.

PayloadTooLarge

The message payload was too large (4096 bytes)

TooManyProviderTokenUpdates

The provider token is being updated too often.

TooManyRequests

Too many requests were made consecutively to the same device token.

InternalServerError

An internal server error occurred.

ServiceUnavailable

The service is unavailable.

Shutdown

The server is shutting down.

Trait Implementations

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Formats the value using the given formatter. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

Converts the given value to a String. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more