Module send_access

Source
Expand description

The SendAccess module handles send access token requests and responses. We use a custom extension OAuth2 grant type to request send access tokens outside the context of a Bitwarden user. This will be used by the send portion of the Bitwarden web app to allow users to access send access functionality without needing to log in to a Bitwarden account. Sends can be anonymous, password protected, or email protected. If you request an access token for an anonymous send by id, no credentials are required. If you request an access token for a password protected send, you must provide a correct password hash. If you request an access token for an email protected send, you must provide the email address and a one-time passcode (OTP) sent to that email address.

Modules§

access_token_request 🔒
access_token_response 🔒
api
Submodule containing the Send Access API request and response types.
client 🔒

Structs§

SendAccessClient
The SendAccessClient is used to interact with the Bitwarden API to get send access tokens.
SendAccessTokenRequest
A request structure for requesting a send access token from the API.
SendAccessTokenResponse
A send access token which can be used to access a send.
SendEmailCredentials
Credentials for sending an OTP to the user’s email address. This is used when the send requires email verification with an OTP.
SendEmailOtpCredentials
Credentials for getting a send access token using an email and OTP.
SendPasswordCredentials
Credentials for sending password secured access requests. Clone auto implements the standard lib’s Clone trait, allowing us to create copies of this struct.
UnexpectedIdentityError
Any unexpected error that occurs when making requests to identity. This could be local/transport/decoding failure from the HTTP client (DNS/TLS/connect/read timeout, connection reset, or JSON decode failure on a success response) or non-2xx response with an unexpected body or status. Used when decoding the server’s error payload into SendAccessTokenApiErrorResponse fails, or for 5xx responses where no structured error is available.

Enums§

SendAccessCredentials
The credentials used for send access requests.
SendAccessTokenError
Represents errors that can occur when requesting a send access token. It includes expected and unexpected API errors.