pub struct SubaccountServiceClient<T> { /* private fields */ }Expand description
Client for this service.
Generic over T: ClientTransport. For gRPC (HTTP/2), use
Http2Connection — it has honest poll_ready and composes with
tower::balance for multi-connection load balancing. For Connect
over HTTP/1.1 (or unknown protocol), use HttpClient.
§Working with the response
Unary calls return UnaryResponse<OwnedView<FooView>>.
view() borrows the response
message, so field access is zero-copy:
let resp = client.list_subaccounts(request).await?;
let name: &str = resp.view().name; // borrow into the response bufferIf you need the owned struct (e.g. to store or pass by value), use
into_owned():
let owned = client.list_subaccounts(request).await?.into_owned();into_view() keeps the
zero-copy decoded body (an OwnedView) without copying; field access on it
goes through .reborrow(). Streaming responses yield one
StreamMessage per received message from
.message().await — read fields zero-copy through the generated accessor
methods (msg.name()) or .view(), or convert with .to_owned_message().
Implementations§
Source§impl<T> SubaccountServiceClient<T>
impl<T> SubaccountServiceClient<T>
Sourcepub fn new(transport: T, config: ClientConfig) -> Self
pub fn new(transport: T, config: ClientConfig) -> Self
Create a new client with the given transport and configuration.
Sourcepub fn config(&self) -> &ClientConfig
pub fn config(&self) -> &ClientConfig
Get the client configuration.
Sourcepub fn config_mut(&mut self) -> &mut ClientConfig
pub fn config_mut(&mut self) -> &mut ClientConfig
Get a mutable reference to the client configuration.
Sourcepub async fn list_subaccounts(
&self,
request: ListSubaccountsRequest,
) -> Result<UnaryResponse<OwnedView<ListSubaccountsResponseView<'static>>>, ConnectError>
pub async fn list_subaccounts( &self, request: ListSubaccountsRequest, ) -> Result<UnaryResponse<OwnedView<ListSubaccountsResponseView<'static>>>, ConnectError>
Call the ListSubaccounts RPC. Sends a request to /auth.v1.SubaccountService/ListSubaccounts.
Sourcepub async fn list_subaccounts_with_options(
&self,
request: ListSubaccountsRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<ListSubaccountsResponseView<'static>>>, ConnectError>
pub async fn list_subaccounts_with_options( &self, request: ListSubaccountsRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<ListSubaccountsResponseView<'static>>>, ConnectError>
Call the ListSubaccounts RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn create_subaccount(
&self,
request: CreateSubaccountRequest,
) -> Result<UnaryResponse<OwnedView<CreateSubaccountResponseView<'static>>>, ConnectError>
pub async fn create_subaccount( &self, request: CreateSubaccountRequest, ) -> Result<UnaryResponse<OwnedView<CreateSubaccountResponseView<'static>>>, ConnectError>
Call the CreateSubaccount RPC. Sends a request to /auth.v1.SubaccountService/CreateSubaccount.
Sourcepub async fn create_subaccount_with_options(
&self,
request: CreateSubaccountRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<CreateSubaccountResponseView<'static>>>, ConnectError>
pub async fn create_subaccount_with_options( &self, request: CreateSubaccountRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<CreateSubaccountResponseView<'static>>>, ConnectError>
Call the CreateSubaccount RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn update_subaccount(
&self,
request: UpdateSubaccountRequest,
) -> Result<UnaryResponse<OwnedView<UpdateSubaccountResponseView<'static>>>, ConnectError>
pub async fn update_subaccount( &self, request: UpdateSubaccountRequest, ) -> Result<UnaryResponse<OwnedView<UpdateSubaccountResponseView<'static>>>, ConnectError>
Call the UpdateSubaccount RPC. Sends a request to /auth.v1.SubaccountService/UpdateSubaccount.
Sourcepub async fn update_subaccount_with_options(
&self,
request: UpdateSubaccountRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<UpdateSubaccountResponseView<'static>>>, ConnectError>
pub async fn update_subaccount_with_options( &self, request: UpdateSubaccountRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<UpdateSubaccountResponseView<'static>>>, ConnectError>
Call the UpdateSubaccount RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn set_subaccount_member_mfa_requirement(
&self,
request: SetSubaccountMemberMFARequirementRequest,
) -> Result<UnaryResponse<OwnedView<SetSubaccountMemberMFARequirementResponseView<'static>>>, ConnectError>
pub async fn set_subaccount_member_mfa_requirement( &self, request: SetSubaccountMemberMFARequirementRequest, ) -> Result<UnaryResponse<OwnedView<SetSubaccountMemberMFARequirementResponseView<'static>>>, ConnectError>
Call the SetSubaccountMemberMFARequirement RPC. Sends a request to /auth.v1.SubaccountService/SetSubaccountMemberMFARequirement.
Sourcepub async fn set_subaccount_member_mfa_requirement_with_options(
&self,
request: SetSubaccountMemberMFARequirementRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<SetSubaccountMemberMFARequirementResponseView<'static>>>, ConnectError>
pub async fn set_subaccount_member_mfa_requirement_with_options( &self, request: SetSubaccountMemberMFARequirementRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<SetSubaccountMemberMFARequirementResponseView<'static>>>, ConnectError>
Call the SetSubaccountMemberMFARequirement RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn list_subaccount_members(
&self,
request: ListSubaccountMembersRequest,
) -> Result<UnaryResponse<OwnedView<ListSubaccountMembersResponseView<'static>>>, ConnectError>
pub async fn list_subaccount_members( &self, request: ListSubaccountMembersRequest, ) -> Result<UnaryResponse<OwnedView<ListSubaccountMembersResponseView<'static>>>, ConnectError>
Call the ListSubaccountMembers RPC. Sends a request to /auth.v1.SubaccountService/ListSubaccountMembers.
Sourcepub async fn list_subaccount_members_with_options(
&self,
request: ListSubaccountMembersRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<ListSubaccountMembersResponseView<'static>>>, ConnectError>
pub async fn list_subaccount_members_with_options( &self, request: ListSubaccountMembersRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<ListSubaccountMembersResponseView<'static>>>, ConnectError>
Call the ListSubaccountMembers RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn remove_subaccount_member(
&self,
request: RemoveSubaccountMemberRequest,
) -> Result<UnaryResponse<OwnedView<RemoveSubaccountMemberResponseView<'static>>>, ConnectError>
pub async fn remove_subaccount_member( &self, request: RemoveSubaccountMemberRequest, ) -> Result<UnaryResponse<OwnedView<RemoveSubaccountMemberResponseView<'static>>>, ConnectError>
Call the RemoveSubaccountMember RPC. Sends a request to /auth.v1.SubaccountService/RemoveSubaccountMember.
Sourcepub async fn remove_subaccount_member_with_options(
&self,
request: RemoveSubaccountMemberRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<RemoveSubaccountMemberResponseView<'static>>>, ConnectError>
pub async fn remove_subaccount_member_with_options( &self, request: RemoveSubaccountMemberRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<RemoveSubaccountMemberResponseView<'static>>>, ConnectError>
Call the RemoveSubaccountMember RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn update_subaccount_member_role(
&self,
request: UpdateSubaccountMemberRoleRequest,
) -> Result<UnaryResponse<OwnedView<UpdateSubaccountMemberRoleResponseView<'static>>>, ConnectError>
pub async fn update_subaccount_member_role( &self, request: UpdateSubaccountMemberRoleRequest, ) -> Result<UnaryResponse<OwnedView<UpdateSubaccountMemberRoleResponseView<'static>>>, ConnectError>
Call the UpdateSubaccountMemberRole RPC. Sends a request to /auth.v1.SubaccountService/UpdateSubaccountMemberRole.
Sourcepub async fn update_subaccount_member_role_with_options(
&self,
request: UpdateSubaccountMemberRoleRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<UpdateSubaccountMemberRoleResponseView<'static>>>, ConnectError>
pub async fn update_subaccount_member_role_with_options( &self, request: UpdateSubaccountMemberRoleRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<UpdateSubaccountMemberRoleResponseView<'static>>>, ConnectError>
Call the UpdateSubaccountMemberRole RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn invite_subaccount_member(
&self,
request: InviteSubaccountMemberRequest,
) -> Result<UnaryResponse<OwnedView<InviteSubaccountMemberResponseView<'static>>>, ConnectError>
pub async fn invite_subaccount_member( &self, request: InviteSubaccountMemberRequest, ) -> Result<UnaryResponse<OwnedView<InviteSubaccountMemberResponseView<'static>>>, ConnectError>
Call the InviteSubaccountMember RPC. Sends a request to /auth.v1.SubaccountService/InviteSubaccountMember.
Sourcepub async fn invite_subaccount_member_with_options(
&self,
request: InviteSubaccountMemberRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<InviteSubaccountMemberResponseView<'static>>>, ConnectError>
pub async fn invite_subaccount_member_with_options( &self, request: InviteSubaccountMemberRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<InviteSubaccountMemberResponseView<'static>>>, ConnectError>
Call the InviteSubaccountMember RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn list_subaccount_invites(
&self,
request: ListSubaccountInvitesRequest,
) -> Result<UnaryResponse<OwnedView<ListSubaccountInvitesResponseView<'static>>>, ConnectError>
pub async fn list_subaccount_invites( &self, request: ListSubaccountInvitesRequest, ) -> Result<UnaryResponse<OwnedView<ListSubaccountInvitesResponseView<'static>>>, ConnectError>
Call the ListSubaccountInvites RPC. Sends a request to /auth.v1.SubaccountService/ListSubaccountInvites.
Sourcepub async fn list_subaccount_invites_with_options(
&self,
request: ListSubaccountInvitesRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<ListSubaccountInvitesResponseView<'static>>>, ConnectError>
pub async fn list_subaccount_invites_with_options( &self, request: ListSubaccountInvitesRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<ListSubaccountInvitesResponseView<'static>>>, ConnectError>
Call the ListSubaccountInvites RPC with explicit per-call options. Options override ClientConfig defaults.
Sourcepub async fn respond_subaccount_invite(
&self,
request: RespondSubaccountInviteRequest,
) -> Result<UnaryResponse<OwnedView<RespondSubaccountInviteResponseView<'static>>>, ConnectError>
pub async fn respond_subaccount_invite( &self, request: RespondSubaccountInviteRequest, ) -> Result<UnaryResponse<OwnedView<RespondSubaccountInviteResponseView<'static>>>, ConnectError>
Call the RespondSubaccountInvite RPC. Sends a request to /auth.v1.SubaccountService/RespondSubaccountInvite.
Sourcepub async fn respond_subaccount_invite_with_options(
&self,
request: RespondSubaccountInviteRequest,
options: CallOptions,
) -> Result<UnaryResponse<OwnedView<RespondSubaccountInviteResponseView<'static>>>, ConnectError>
pub async fn respond_subaccount_invite_with_options( &self, request: RespondSubaccountInviteRequest, options: CallOptions, ) -> Result<UnaryResponse<OwnedView<RespondSubaccountInviteResponseView<'static>>>, ConnectError>
Call the RespondSubaccountInvite RPC with explicit per-call options. Options override ClientConfig defaults.
Trait Implementations§
Source§impl<T: Clone> Clone for SubaccountServiceClient<T>
impl<T: Clone> Clone for SubaccountServiceClient<T>
Source§fn clone(&self) -> SubaccountServiceClient<T>
fn clone(&self) -> SubaccountServiceClient<T>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more