Class: Increase::Resources::BeneficialOwners

Inherits:
Object
  • Object
show all
Defined in:
lib/increase/resources/beneficial_owners.rb

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ BeneficialOwners

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of BeneficialOwners.

Parameters:



146
147
148
# File 'lib/increase/resources/beneficial_owners.rb', line 146

def initialize(client:)
  @client = client
end

Instance Method Details

#archive(entity_beneficial_owner_id, request_options: {}) ⇒ Increase::Models::EntityBeneficialOwner

Archive a Beneficial Owner

Parameters:

  • entity_beneficial_owner_id (String)

    The identifier of the Beneficial Owner to archive.

  • request_options (Increase::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



134
135
136
137
138
139
140
141
# File 'lib/increase/resources/beneficial_owners.rb', line 134

def archive(entity_beneficial_owner_id, params = {})
  @client.request(
    method: :post,
    path: ["entity_beneficial_owners/%1$s/archive", entity_beneficial_owner_id],
    model: Increase::EntityBeneficialOwner,
    options: params[:request_options]
  )
end

#create(entity_id:, individual:, prongs:, company_title: nil, request_options: {}) ⇒ Increase::Models::EntityBeneficialOwner

Some parameter documentations has been truncated, see Models::BeneficialOwnerCreateParams for more details.

Create a beneficial owner

Parameters:

Returns:

See Also:



26
27
28
29
30
31
32
33
34
35
# File 'lib/increase/resources/beneficial_owners.rb', line 26

def create(params)
  parsed, options = Increase::BeneficialOwnerCreateParams.dump_request(params)
  @client.request(
    method: :post,
    path: "entity_beneficial_owners",
    body: parsed,
    model: Increase::EntityBeneficialOwner,
    options: options
  )
end

#list(entity_id:, cursor: nil, idempotency_key: nil, limit: nil, request_options: {}) ⇒ Increase::Internal::Page<Increase::Models::EntityBeneficialOwner>

Some parameter documentations has been truncated, see Models::BeneficialOwnerListParams for more details.

List Beneficial Owners

Parameters:

  • entity_id (String)

    The identifier of the Entity to list beneficial owners for. Only ‘corporation` e

  • cursor (String)

    Return the page of entries after this one.

  • idempotency_key (String)

    Filter records to the one with the specified ‘idempotency_key` you chose for tha

  • limit (Integer)

    Limit the size of the list that is returned. The default (and maximum) is 100 ob

  • request_options (Increase::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



110
111
112
113
114
115
116
117
118
119
120
121
# File 'lib/increase/resources/beneficial_owners.rb', line 110

def list(params)
  parsed, options = Increase::BeneficialOwnerListParams.dump_request(params)
  query = Increase::Internal::Util.encode_query_params(parsed)
  @client.request(
    method: :get,
    path: "entity_beneficial_owners",
    query: query,
    page: Increase::Internal::Page,
    model: Increase::EntityBeneficialOwner,
    options: options
  )
end

#retrieve(entity_beneficial_owner_id, request_options: {}) ⇒ Increase::Models::EntityBeneficialOwner

Retrieve a Beneficial Owner

Parameters:

  • entity_beneficial_owner_id (String)

    The identifier of the Beneficial Owner to retrieve.

  • request_options (Increase::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



48
49
50
51
52
53
54
55
# File 'lib/increase/resources/beneficial_owners.rb', line 48

def retrieve(entity_beneficial_owner_id, params = {})
  @client.request(
    method: :get,
    path: ["entity_beneficial_owners/%1$s", entity_beneficial_owner_id],
    model: Increase::EntityBeneficialOwner,
    options: params[:request_options]
  )
end

#update(entity_beneficial_owner_id, address: nil, confirmed_no_us_tax_id: nil, identification: nil, name: nil, request_options: {}) ⇒ Increase::Models::EntityBeneficialOwner

Some parameter documentations has been truncated, see Models::BeneficialOwnerUpdateParams for more details.

Update a Beneficial Owner

Parameters:

Returns:

See Also:



79
80
81
82
83
84
85
86
87
88
# File 'lib/increase/resources/beneficial_owners.rb', line 79

def update(entity_beneficial_owner_id, params = {})
  parsed, options = Increase::BeneficialOwnerUpdateParams.dump_request(params)
  @client.request(
    method: :patch,
    path: ["entity_beneficial_owners/%1$s", entity_beneficial_owner_id],
    body: parsed,
    model: Increase::EntityBeneficialOwner,
    options: options
  )
end