Class Recipient

All Implemented Interfaces:
HasId, MetadataStore<Recipient>, StripeObjectInterface

public class Recipient extends ApiResource implements HasId, MetadataStore<Recipient>
  • Constructor Details

    • Recipient

      public Recipient()
  • Method Details

    • getDefaultCard

      public String getDefaultCard()
      Get ID of expandable defaultCard object.
    • setDefaultCard

      public void setDefaultCard(String id)
    • getDefaultCardObject

      public Card getDefaultCardObject()
      Get expanded defaultCard.
    • setDefaultCardObject

      public void setDefaultCardObject(Card expandableObject)
    • getMigratedTo

      public String getMigratedTo()
      Get ID of expandable migratedTo object.
    • setMigratedTo

      public void setMigratedTo(String id)
    • getMigratedToObject

      public Account getMigratedToObject()
      Get expanded migratedTo.
    • setMigratedToObject

      public void setMigratedToObject(Account expandableObject)
    • getRolledBackFrom

      public String getRolledBackFrom()
      Get ID of expandable rolledBackFrom object.
    • setRolledBackFrom

      public void setRolledBackFrom(String id)
    • getRolledBackFromObject

      public Account getRolledBackFromObject()
      Get expanded rolledBackFrom.
    • setRolledBackFromObject

      public void setRolledBackFromObject(Account expandableObject)
    • list

      public static RecipientCollection list(Map<String,Object> params) throws StripeException
      Returns a list of your recipients. The recipients are returned sorted by creation date, with the most recently created recipients appearing first.
      Throws:
      StripeException
    • list

      public static RecipientCollection list(Map<String,Object> params, RequestOptions options) throws StripeException
      Returns a list of your recipients. The recipients are returned sorted by creation date, with the most recently created recipients appearing first.
      Throws:
      StripeException
    • list

      public static RecipientCollection list(RecipientListParams params) throws StripeException
      Returns a list of your recipients. The recipients are returned sorted by creation date, with the most recently created recipients appearing first.
      Throws:
      StripeException
    • list

      public static RecipientCollection list(RecipientListParams params, RequestOptions options) throws StripeException
      Returns a list of your recipients. The recipients are returned sorted by creation date, with the most recently created recipients appearing first.
      Throws:
      StripeException
    • create

      public static Recipient create(Map<String,Object> params) throws StripeException
      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.
      Throws:
      StripeException
    • create

      public static Recipient create(Map<String,Object> params, RequestOptions options) throws StripeException
      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.
      Throws:
      StripeException
    • create

      public static Recipient create(RecipientCreateParams params) throws StripeException
      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.
      Throws:
      StripeException
    • create

      public static Recipient create(RecipientCreateParams params, RequestOptions options) throws StripeException
      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.
      Throws:
      StripeException
    • retrieve

      public static Recipient retrieve(String id) throws StripeException
      Retrieves the details of an existing recipient. You need only supply the unique recipient identifier that was returned upon recipient creation.
      Throws:
      StripeException
    • retrieve

      public static Recipient retrieve(String id, RequestOptions options) throws StripeException
      Retrieves the details of an existing recipient. You need only supply the unique recipient identifier that was returned upon recipient creation.
      Throws:
      StripeException
    • retrieve

      public static Recipient retrieve(String id, Map<String,Object> params, RequestOptions options) throws StripeException
      Retrieves the details of an existing recipient. You need only supply the unique recipient identifier that was returned upon recipient creation.
      Throws:
      StripeException
    • retrieve

      public static Recipient retrieve(String id, RecipientRetrieveParams params, RequestOptions options) throws StripeException
      Retrieves the details of an existing recipient. You need only supply the unique recipient identifier that was returned upon recipient creation.
      Throws:
      StripeException
    • update

      public Recipient update(Map<String,Object> params) throws StripeException
      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.

      Specified by:
      update in interface MetadataStore<Recipient>
      Throws:
      StripeException
    • update

      public Recipient update(Map<String,Object> params, RequestOptions options) throws StripeException
      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.

      Specified by:
      update in interface MetadataStore<Recipient>
      Throws:
      StripeException
    • update

      public Recipient update(RecipientUpdateParams params) throws StripeException
      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.

      Throws:
      StripeException
    • update

      public Recipient update(RecipientUpdateParams params, RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • delete

      public Recipient delete() throws StripeException
      Permanently deletes a recipient. It cannot be undone.
      Throws:
      StripeException
    • delete

      public Recipient delete(RequestOptions options) throws StripeException
      Permanently deletes a recipient. It cannot be undone.
      Throws:
      StripeException
    • delete

      public Recipient delete(Map<String,Object> params) throws StripeException
      Permanently deletes a recipient. It cannot be undone.
      Throws:
      StripeException
    • delete

      public Recipient delete(Map<String,Object> params, RequestOptions options) throws StripeException
      Permanently deletes a recipient. It cannot be undone.
      Throws:
      StripeException
    • getActiveAccount

      public BankAccount getActiveAccount()
      Hash describing the current account on the recipient, if there is one.
    • getCards

      public CardCollection getCards()
    • getCreated

      public Long getCreated()
      Time at which the object was created. Measured in seconds since the Unix epoch.
    • getDeleted

      public Boolean getDeleted()
      Always true for a deleted object.
    • getDescription

      public String getDescription()
      An arbitrary string attached to the object. Often useful for displaying to users.
    • getEmail

      public String getEmail()
    • getLivemode

      public Boolean getLivemode()
      Has the value true if the object exists in live mode or the value false if the object exists in test mode.
    • getName

      public String getName()
      Full, legal name of the recipient.
    • getObject

      public String getObject()
      String representing the object's type. Objects of the same type share the same value.

      Equal to recipient.

    • getType

      public String getType()
      Type of the recipient, one of individual or corporation.
    • getVerified

      public Boolean getVerified()
      Whether the recipient has been verified. This field is non-standard, and maybe removed in the future
    • setActiveAccount

      public void setActiveAccount(BankAccount activeAccount)
      Hash describing the current account on the recipient, if there is one.
    • setCards

      public void setCards(CardCollection cards)
    • setCreated

      public void setCreated(Long created)
      Time at which the object was created. Measured in seconds since the Unix epoch.
    • setDeleted

      public void setDeleted(Boolean deleted)
      Always true for a deleted object.
    • setDescription

      public void setDescription(String description)
      An arbitrary string attached to the object. Often useful for displaying to users.
    • setEmail

      public void setEmail(String email)
    • setId

      public void setId(String id)
      Unique identifier for the object.
    • setLivemode

      public void setLivemode(Boolean livemode)
      Has the value true if the object exists in live mode or the value false if the object exists in test mode.
    • setMetadata

      public void setMetadata(Map<String,String> 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.
    • setName

      public void setName(String name)
      Full, legal name of the recipient.
    • setObject

      public void setObject(String object)
      String representing the object's type. Objects of the same type share the same value.

      Equal to recipient.

    • setType

      public void setType(String type)
      Type of the recipient, one of individual or corporation.
    • setVerified

      public void setVerified(Boolean verified)
      Whether the recipient has been verified. This field is non-standard, and maybe removed in the future
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getId

      public String getId()
      Unique identifier for the object.
      Specified by:
      getId in interface HasId
    • getMetadata

      public Map<String,String> getMetadata()
      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.
      Specified by:
      getMetadata in interface MetadataStore<Recipient>