pub struct Recipient {Show 14 fields
pub id: RecipientId,
pub active_account: Option<BankAccount>,
pub cards: List<Card>,
pub created: Option<Timestamp>,
pub default_card: Option<Expandable<Card>>,
pub deleted: bool,
pub description: Option<String>,
pub email: Option<String>,
pub livemode: Option<bool>,
pub metadata: Metadata,
pub migrated_to: Option<Expandable<Account>>,
pub name: Option<String>,
pub rolled_back_from: Option<Expandable<Account>>,
pub type_: Option<RecipientType>,
}
Expand description
The resource representing a Stripe “TransferRecipient”.
Fields
id: RecipientId
Unique identifier for the object.
active_account: Option<BankAccount>
Hash describing the current account on the recipient, if there is one.
cards: List<Card>
created: Option<Timestamp>
Time at which the object was created.
Measured in seconds since the Unix epoch.
default_card: Option<Expandable<Card>>
The default card to use for creating transfers to this recipient.
deleted: bool
description: Option<String>
An arbitrary string attached to the object.
Often useful for displaying to users.
email: Option<String>
livemode: Option<bool>
Has the value true
if the object exists in live mode or the value false
if the object exists in test mode.
metadata: Metadata
Set of key-value pairs that you can attach to an object.
This can be useful for storing additional information about the object in a structured format.
migrated_to: Option<Expandable<Account>>
The ID of the Custom account this recipient was migrated to.
If set, the recipient can no longer be updated, nor can transfers be made to it: use the Custom account instead.
name: Option<String>
Full, legal name of the recipient.
rolled_back_from: Option<Expandable<Account>>
type_: Option<RecipientType>
Type of the recipient, one of individual
or corporation
.
Implementations
sourceimpl Recipient
impl Recipient
sourcepub fn list(
client: &Client,
params: &ListRecipients<'_>
) -> Response<List<Recipient>>
pub fn list(
client: &Client,
params: &ListRecipients<'_>
) -> Response<List<Recipient>>
Returns a list of your recipients.
The recipients are returned sorted by creation date, with the most recently created recipients appearing first.
sourcepub fn create(
client: &Client,
params: CreateRecipient<'_>
) -> Response<Recipient>
pub fn create(
client: &Client,
params: CreateRecipient<'_>
) -> Response<Recipient>
Creates a new Recipient
object and verifies the recipient’s identity.
Also verifies the recipient’s bank account information or debit card, if either is provided.
sourcepub fn retrieve(
client: &Client,
id: &RecipientId,
expand: &[&str]
) -> Response<Recipient>
pub fn retrieve(
client: &Client,
id: &RecipientId,
expand: &[&str]
) -> Response<Recipient>
Retrieves the details of an existing recipient.
You need only supply the unique recipient identifier that was returned upon recipient creation.
sourcepub fn update(
client: &Client,
id: &RecipientId,
params: UpdateRecipient<'_>
) -> Response<Recipient>
pub fn update(
client: &Client,
id: &RecipientId,
params: UpdateRecipient<'_>
) -> Response<Recipient>
Updates the specified recipient by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
If you update the name or tax ID, the identity verification will automatically be rerun. If you update the bank account, the bank account validation will automatically be rerun.
sourcepub fn delete(
client: &Client,
id: &RecipientId
) -> Response<Deleted<RecipientId>>
pub fn delete(
client: &Client,
id: &RecipientId
) -> Response<Deleted<RecipientId>>
Permanently deletes a recipient.
It cannot be undone.
Trait Implementations
sourceimpl<'de> Deserialize<'de> for Recipient
impl<'de> Deserialize<'de> for Recipient
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for Recipient
impl Send for Recipient
impl Sync for Recipient
impl Unpin for Recipient
impl UnwindSafe for Recipient
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more