Class: PostfinancecheckoutRubySdk::LegalOrganizationFormsService
- Inherits:
-
Object
- Object
- PostfinancecheckoutRubySdk::LegalOrganizationFormsService
- Defined in:
- lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#get_legal_organization_forms(opts = {}) ⇒ LegalOrganizationFormListResponse
List all legal organization forms.
-
#get_legal_organization_forms_id(id, opts = {}) ⇒ LegalOrganizationForm
Retrieve a legal organization form.
-
#get_legal_organization_forms_id_with_http_info(id, opts = {}) ⇒ Array<(LegalOrganizationForm, Integer, Hash)>
LegalOrganizationForm data, response status code and response headers.
-
#get_legal_organization_forms_search(opts = {}) ⇒ LegalOrganizationFormSearchResponse
Search legal organization forms.
-
#get_legal_organization_forms_search_with_http_info(opts = {}) ⇒ Array<(LegalOrganizationFormSearchResponse, Integer, Hash)>
LegalOrganizationFormSearchResponse data, response status code and response headers.
-
#get_legal_organization_forms_with_http_info(opts = {}) ⇒ Array<(LegalOrganizationFormListResponse, Integer, Hash)>
LegalOrganizationFormListResponse data, response status code and response headers.
-
#initialize(api_client = ApiClient.default) ⇒ LegalOrganizationFormsService
constructor
A new instance of LegalOrganizationFormsService.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ LegalOrganizationFormsService
Returns a new instance of LegalOrganizationFormsService.
28 29 30 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 28 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
25 26 27 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 25 def api_client @api_client end |
Instance Method Details
#get_legal_organization_forms(opts = {}) ⇒ LegalOrganizationFormListResponse
List all legal organization forms
39 40 41 42 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 39 def get_legal_organization_forms(opts = {}) data, _status_code, _headers = get_legal_organization_forms_with_http_info(opts) data end |
#get_legal_organization_forms_id(id, opts = {}) ⇒ LegalOrganizationForm
Retrieve a legal organization form
123 124 125 126 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 123 def get_legal_organization_forms_id(id, opts = {}) data, _status_code, _headers = get_legal_organization_forms_id_with_http_info(id, opts) data end |
#get_legal_organization_forms_id_with_http_info(id, opts = {}) ⇒ Array<(LegalOrganizationForm, Integer, Hash)>
Returns LegalOrganizationForm data, response status code and response headers.
134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 134 def get_legal_organization_forms_id_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LegalOrganizationFormsService.get_legal_organization_forms_id ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling LegalOrganizationFormsService.get_legal_organization_forms_id" end # resource path local_var_path = '/legal-organization-forms/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) unless opts[:'expand'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # connection timeout connection_timeout = @api_client.config.timeout # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'LegalOrganizationForm' = opts.merge( :operation => :"LegalOrganizationFormsService.get_legal_organization_forms_id", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET.to_sym.downcase, local_var_path, , connection_timeout) if @api_client.config.debugging @api_client.config.logger.debug "API called: LegalOrganizationFormsService#get_legal_organization_forms_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}\nConnection Timeout: #{connection_timeout}" end return data, status_code, headers end |
#get_legal_organization_forms_search(opts = {}) ⇒ LegalOrganizationFormSearchResponse
Search legal organization forms
191 192 193 194 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 191 def get_legal_organization_forms_search(opts = {}) data, _status_code, _headers = get_legal_organization_forms_search_with_http_info(opts) data end |
#get_legal_organization_forms_search_with_http_info(opts = {}) ⇒ Array<(LegalOrganizationFormSearchResponse, Integer, Hash)>
Returns LegalOrganizationFormSearchResponse data, response status code and response headers.
205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 205 def get_legal_organization_forms_search_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LegalOrganizationFormsService.get_legal_organization_forms_search ...' end if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100 fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling LegalOrganizationFormsService.get_legal_organization_forms_search, must be smaller than or equal to 100.' end if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1 fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling LegalOrganizationFormsService.get_legal_organization_forms_search, must be greater than or equal to 1.' end if @api_client.config.client_side_validation && !opts[:'offset'].nil? && opts[:'offset'] > 10000 fail ArgumentError, 'invalid value for "opts[:"offset"]" when calling LegalOrganizationFormsService.get_legal_organization_forms_search, must be smaller than or equal to 10000.' end # resource path local_var_path = '/legal-organization-forms/search' # query parameters query_params = opts[:query_params] || {} query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) unless opts[:'expand'].nil? query_params[:'limit'] = opts[:'limit'] unless opts[:'limit'].nil? query_params[:'offset'] = opts[:'offset'] unless opts[:'offset'].nil? query_params[:'order'] = opts[:'order'] unless opts[:'order'].nil? query_params[:'query'] = opts[:'query'] unless opts[:'query'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # connection timeout connection_timeout = @api_client.config.timeout # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'LegalOrganizationFormSearchResponse' = opts.merge( :operation => :"LegalOrganizationFormsService.get_legal_organization_forms_search", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET.to_sym.downcase, local_var_path, , connection_timeout) if @api_client.config.debugging @api_client.config.logger.debug "API called: LegalOrganizationFormsService#get_legal_organization_forms_search\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}\nConnection Timeout: #{connection_timeout}" end return data, status_code, headers end |
#get_legal_organization_forms_with_http_info(opts = {}) ⇒ Array<(LegalOrganizationFormListResponse, Integer, Hash)>
Returns LegalOrganizationFormListResponse data, response status code and response headers.
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
# File 'lib/postfinancecheckout-ruby-sdk/service/legal_organization_forms_service.rb', line 53 def get_legal_organization_forms_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LegalOrganizationFormsService.get_legal_organization_forms ...' end if @api_client.config.client_side_validation && !opts[:'after'].nil? && opts[:'after'] < 1 fail ArgumentError, 'invalid value for "opts[:"after"]" when calling LegalOrganizationFormsService.get_legal_organization_forms, must be greater than or equal to 1.' end if @api_client.config.client_side_validation && !opts[:'before'].nil? && opts[:'before'] < 1 fail ArgumentError, 'invalid value for "opts[:"before"]" when calling LegalOrganizationFormsService.get_legal_organization_forms, must be greater than or equal to 1.' end if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100 fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling LegalOrganizationFormsService.get_legal_organization_forms, must be smaller than or equal to 100.' end if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1 fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling LegalOrganizationFormsService.get_legal_organization_forms, must be greater than or equal to 1.' end # resource path local_var_path = '/legal-organization-forms' # query parameters query_params = opts[:query_params] || {} query_params[:'after'] = opts[:'after'] unless opts[:'after'].nil? query_params[:'before'] = opts[:'before'] unless opts[:'before'].nil? query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) unless opts[:'expand'].nil? query_params[:'limit'] = opts[:'limit'] unless opts[:'limit'].nil? query_params[:'order'] = opts[:'order'] unless opts[:'order'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # connection timeout connection_timeout = @api_client.config.timeout # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'LegalOrganizationFormListResponse' = opts.merge( :operation => :"LegalOrganizationFormsService.get_legal_organization_forms", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET.to_sym.downcase, local_var_path, , connection_timeout) if @api_client.config.debugging @api_client.config.logger.debug "API called: LegalOrganizationFormsService#get_legal_organization_forms\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}\nConnection Timeout: #{connection_timeout}" end return data, status_code, headers end |