class GoCardlessPro::Resources::Creditor
Each [payment](core-endpoints-payments) taken through the API is linked to a “creditor”, to whom the payment is then paid out. In most cases your organisation will have a single “creditor”, but the API also supports collecting payments on behalf of others.
Currently, for Anti Money Laundering reasons, any creditors you add must be directly related to your organisation.
Attributes
address_line1[R]
address_line2[R]
address_line3[R]
can_create_refunds[R]
city[R]
country_code[R]
created_at[R]
custom_payment_pages_enabled[R]
fx_payout_currency[R]
id[R]
logo_url[R]
mandate_imports_enabled[R]
merchant_responsible_for_notifications[R]
name[R]
postal_code[R]
region[R]
scheme_identifiers[R]
verification_status[R]
Public Class Methods
new(object, response = nil)
click to toggle source
Initialize a creditor resource instance @param object [Hash] an object returned from the API
# File lib/gocardless_pro/resources/creditor.rb, line 44 def initialize(object, response = nil) @object = object @address_line1 = object['address_line1'] @address_line2 = object['address_line2'] @address_line3 = object['address_line3'] @can_create_refunds = object['can_create_refunds'] @city = object['city'] @country_code = object['country_code'] @created_at = object['created_at'] @custom_payment_pages_enabled = object['custom_payment_pages_enabled'] @fx_payout_currency = object['fx_payout_currency'] @id = object['id'] @links = object['links'] @logo_url = object['logo_url'] @mandate_imports_enabled = object['mandate_imports_enabled'] @merchant_responsible_for_notifications = object['merchant_responsible_for_notifications'] @name = object['name'] @postal_code = object['postal_code'] @region = object['region'] @scheme_identifiers = object['scheme_identifiers'] @verification_status = object['verification_status'] @response = response end
Public Instance Methods
api_response()
click to toggle source
# File lib/gocardless_pro/resources/creditor.rb, line 69 def api_response ApiResponse.new(@response) end
links()
click to toggle source
Return the links that the resource has
# File lib/gocardless_pro/resources/creditor.rb, line 74 def links @creditor_links ||= Links.new(@links) end
to_h()
click to toggle source
Provides the creditor resource as a hash of all its readable attributes
# File lib/gocardless_pro/resources/creditor.rb, line 79 def to_h @object end