Sha256: d092f9c68120dcbd9142a53af6a69364e1401ffe92a52ae5cd65c43ef7d98fb7

Contents?: true

Size: 1.62 KB

Versions: 12

Compression:

Stored size: 1.62 KB

Contents

# File generated from our OpenAPI spec
# frozen_string_literal: true

module Stripe
  # This is an object representing a person associated with a Stripe account.
  #
  # A platform cannot access a Standard or Express account's persons after the account starts onboarding, such as after generating an account link for the account.
  # See the [Standard onboarding](https://stripe.com/docs/connect/standard-accounts) or [Express onboarding documentation](https://stripe.com/docs/connect/express-accounts) for information about platform prefilling and account onboarding steps.
  #
  # Related guide: [Handling identity verification with the API](https://stripe.com/docs/connect/identity-verification-api#person-information)
  class Person < APIResource
    extend Stripe::APIOperations::List
    include Stripe::APIOperations::Save

    OBJECT_NAME = "person"

    def resource_url
      if !respond_to?(:account) || account.nil?
        raise NotImplementedError,
              "Persons cannot be accessed without an account ID."
      end
      "#{Account.resource_url}/#{CGI.escape(account)}/persons/#{CGI.escape(id)}"
    end

    def self.retrieve(_id, _opts = {})
      raise NotImplementedError,
            "Persons cannot be retrieved without an account ID. Retrieve a " \
            "person using `Account.retrieve_person('account_id', 'person_id')`"
    end

    def self.update(_id, _params = nil, _opts = nil)
      raise NotImplementedError,
            "Persons cannot be updated without an account ID. Update a " \
            "person using `Account.update_person('account_id', 'person_id', " \
            "update_params)`"
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
stripe-9.4.0.pre.beta.1 lib/stripe/resources/person.rb
stripe-9.3.0 lib/stripe/resources/person.rb
stripe-9.3.0.pre.beta.1 lib/stripe/resources/person.rb
stripe-9.2.0 lib/stripe/resources/person.rb
stripe-9.2.0.pre.beta.1 lib/stripe/resources/person.rb
stripe-9.1.0 lib/stripe/resources/person.rb
stripe-9.0.0.pre.beta.1 lib/stripe/resources/person.rb
stripe-9.0.0 lib/stripe/resources/person.rb
stripe-8.8.0.pre.beta.1 lib/stripe/resources/person.rb
stripe-8.7.0 lib/stripe/resources/person.rb
stripe-8.7.0.pre.beta.3 lib/stripe/resources/person.rb
stripe-8.7.0.pre.beta.2 lib/stripe/resources/person.rb