Class: TencentCloud::Ocr::V20181119::Client

Inherits:
Common::AbstractClient
  • Object
show all
Defined in:
lib/v20181119/client.rb

Instance Method Summary collapse

Constructor Details

#initialize(credential, region, profile = nil) ⇒ Client

Returns a new instance of Client.



24
25
26
27
28
29
# File 'lib/v20181119/client.rb', line 24

def initialize(credential, region, profile = nil)
    api_version = '2018-11-19'
    api_endpoint = 'ocr.tencentcloudapi.com'
    sdk_version = 'OCR_' + File.read(File.expand_path('../VERSION', __dir__)).strip
    super(credential, region, api_version, api_endpoint, sdk_version, profile)
end

Instance Method Details

#AdvertiseOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::AdvertiseOCRResponse

Parameters:

  • request:

    Request instance for AdvertiseOCR.



39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# File 'lib/v20181119/client.rb', line 39

def AdvertiseOCR(request)
  body = send_request('AdvertiseOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = AdvertiseOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ArithmeticOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ArithmeticOCRResponse

Parameters:

  • request:

    Request instance for ArithmeticOCR.



65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# File 'lib/v20181119/client.rb', line 65

def ArithmeticOCR(request)
  body = send_request('ArithmeticOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ArithmeticOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#BankCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::BankCardOCRResponse

Parameters:

  • request:

    Request instance for BankCardOCR.



91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
# File 'lib/v20181119/client.rb', line 91

def BankCardOCR(request)
  body = send_request('BankCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = BankCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#BankSlipOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::BankSlipOCRResponse

Parameters:

  • request:

    Request instance for BankSlipOCR.



117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
# File 'lib/v20181119/client.rb', line 117

def BankSlipOCR(request)
  body = send_request('BankSlipOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = BankSlipOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#BizLicenseOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::BizLicenseOCRResponse

Parameters:

  • request:

    Request instance for BizLicenseOCR.



143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
# File 'lib/v20181119/client.rb', line 143

def BizLicenseOCR(request)
  body = send_request('BizLicenseOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = BizLicenseOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#BusinessCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::BusinessCardOCRResponse

Parameters:

  • request:

    Request instance for BusinessCardOCR.



196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
# File 'lib/v20181119/client.rb', line 196

def BusinessCardOCR(request)
  body = send_request('BusinessCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = BusinessCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#BusInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::BusInvoiceOCRResponse

Parameters:

  • request:

    Request instance for BusInvoiceOCR.



170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
# File 'lib/v20181119/client.rb', line 170

def BusInvoiceOCR(request)
  body = send_request('BusInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = BusInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#CarInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::CarInvoiceOCRResponse

Parameters:

  • request:

    Request instance for CarInvoiceOCR.



222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
# File 'lib/v20181119/client.rb', line 222

def CarInvoiceOCR(request)
  body = send_request('CarInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = CarInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ClassifyDetectOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ClassifyDetectOCRResponse

Parameters:

  • request:

    Request instance for ClassifyDetectOCR.



248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
# File 'lib/v20181119/client.rb', line 248

def ClassifyDetectOCR(request)
  body = send_request('ClassifyDetectOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ClassifyDetectOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ClassifyStoreName(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ClassifyStoreNameResponse

Parameters:

  • request:

    Request instance for ClassifyStoreName.



273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
# File 'lib/v20181119/client.rb', line 273

def ClassifyStoreName(request)
  body = send_request('ClassifyStoreName', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ClassifyStoreNameResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#DescribeExtractDocAgentJob(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::DescribeExtractDocAgentJobResponse

Parameters:

  • request:

    Request instance for DescribeExtractDocAgentJob.



297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
# File 'lib/v20181119/client.rb', line 297

def DescribeExtractDocAgentJob(request)
  body = send_request('DescribeExtractDocAgentJob', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = DescribeExtractDocAgentJobResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#DriverLicenseOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::DriverLicenseOCRResponse

Parameters:

  • request:

    Request instance for DriverLicenseOCR.



331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
# File 'lib/v20181119/client.rb', line 331

def DriverLicenseOCR(request)
  body = send_request('DriverLicenseOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = DriverLicenseOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#DutyPaidProofOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::DutyPaidProofOCRResponse

Parameters:

  • request:

    Request instance for DutyPaidProofOCR.



358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
# File 'lib/v20181119/client.rb', line 358

def DutyPaidProofOCR(request)
  body = send_request('DutyPaidProofOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = DutyPaidProofOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#EduPaperOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::EduPaperOCRResponse

Parameters:

  • request:

    Request instance for EduPaperOCR.



384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
# File 'lib/v20181119/client.rb', line 384

def EduPaperOCR(request)
  body = send_request('EduPaperOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = EduPaperOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#EnglishOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::EnglishOCRResponse

Parameters:

  • request:

    Request instance for EnglishOCR.



410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
# File 'lib/v20181119/client.rb', line 410

def EnglishOCR(request)
  body = send_request('EnglishOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = EnglishOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#EnterpriseLicenseOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::EnterpriseLicenseOCRResponse

Parameters:

  • request:

    Request instance for EnterpriseLicenseOCR.



436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
# File 'lib/v20181119/client.rb', line 436

def EnterpriseLicenseOCR(request)
  body = send_request('EnterpriseLicenseOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = EnterpriseLicenseOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#EstateCertOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::EstateCertOCRResponse

Parameters:

  • request:

    Request instance for EstateCertOCR.



462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
# File 'lib/v20181119/client.rb', line 462

def EstateCertOCR(request)
  body = send_request('EstateCertOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = EstateCertOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ExtractDocAgent(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ExtractDocAgentResponse

Parameters:

  • request:

    Request instance for ExtractDocAgent.



486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
# File 'lib/v20181119/client.rb', line 486

def ExtractDocAgent(request)
  body = send_request('ExtractDocAgent', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ExtractDocAgentResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ExtractDocBasic(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ExtractDocBasicResponse

Parameters:

  • request:

    Request instance for ExtractDocBasic.



514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
# File 'lib/v20181119/client.rb', line 514

def ExtractDocBasic(request)
  body = send_request('ExtractDocBasic', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ExtractDocBasicResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ExtractDocMulti(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ExtractDocMultiResponse

Parameters:

  • request:

    Request instance for ExtractDocMulti.



542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
# File 'lib/v20181119/client.rb', line 542

def ExtractDocMulti(request)
  body = send_request('ExtractDocMulti', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ExtractDocMultiResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ExtractDocMultiPro(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ExtractDocMultiProResponse

Parameters:

  • request:

    Request instance for ExtractDocMultiPro.



568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
# File 'lib/v20181119/client.rb', line 568

def ExtractDocMultiPro(request)
  body = send_request('ExtractDocMultiPro', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ExtractDocMultiProResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#FinanBillOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::FinanBillOCRResponse

Parameters:

  • request:

    Request instance for FinanBillOCR.



595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
# File 'lib/v20181119/client.rb', line 595

def FinanBillOCR(request)
  body = send_request('FinanBillOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = FinanBillOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#FinanBillSliceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::FinanBillSliceOCRResponse

Parameters:

  • request:

    Request instance for FinanBillSliceOCR.



622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
# File 'lib/v20181119/client.rb', line 622

def FinanBillSliceOCR(request)
  body = send_request('FinanBillSliceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = FinanBillSliceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#FlightInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::FlightInvoiceOCRResponse

Parameters:

  • request:

    Request instance for FlightInvoiceOCR.



649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
# File 'lib/v20181119/client.rb', line 649

def FlightInvoiceOCR(request)
  body = send_request('FlightInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = FlightInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#FormulaOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::FormulaOCRResponse

Parameters:

  • request:

    Request instance for FormulaOCR.



675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
# File 'lib/v20181119/client.rb', line 675

def FormulaOCR(request)
  body = send_request('FormulaOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = FormulaOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#GeneralAccurateOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::GeneralAccurateOCRResponse

Parameters:

  • request:

    Request instance for GeneralAccurateOCR.



753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
# File 'lib/v20181119/client.rb', line 753

def GeneralAccurateOCR(request)
  body = send_request('GeneralAccurateOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = GeneralAccurateOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#GeneralBasicOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::GeneralBasicOCRResponse

Parameters:

  • request:

    Request instance for GeneralBasicOCR.



832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
# File 'lib/v20181119/client.rb', line 832

def GeneralBasicOCR(request)
  body = send_request('GeneralBasicOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = GeneralBasicOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#GeneralEfficientOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::GeneralEfficientOCRResponse

Parameters:

  • request:

    Request instance for GeneralEfficientOCR.



918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
# File 'lib/v20181119/client.rb', line 918

def GeneralEfficientOCR(request)
  body = send_request('GeneralEfficientOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = GeneralEfficientOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#GeneralFastOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::GeneralFastOCRResponse

Parameters:

  • request:

    Request instance for GeneralFastOCR.



944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
# File 'lib/v20181119/client.rb', line 944

def GeneralFastOCR(request)
  body = send_request('GeneralFastOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = GeneralFastOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#GeneralHandwritingOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::GeneralHandwritingOCRResponse

Parameters:

  • request:

    Request instance for GeneralHandwritingOCR.



972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
# File 'lib/v20181119/client.rb', line 972

def GeneralHandwritingOCR(request)
  body = send_request('GeneralHandwritingOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = GeneralHandwritingOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#GetOCRResult(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::GetOCRResultResponse

Parameters:

  • request:

    Request instance for GetOCRResult.



996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
# File 'lib/v20181119/client.rb', line 996

def GetOCRResult(request)
  body = send_request('GetOCRResult', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = GetOCRResultResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#GetOCRToken(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::GetOCRTokenResponse

Parameters:

  • request:

    Request instance for GetOCRToken.



1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'lib/v20181119/client.rb', line 1020

def GetOCRToken(request)
  body = send_request('GetOCRToken', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = GetOCRTokenResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#HandwritingEssayOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::HandwritingEssayOCRResponse

Parameters:

  • request:

    Request instance for HandwritingEssayOCR.



1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
# File 'lib/v20181119/client.rb', line 1072

def HandwritingEssayOCR(request)
  body = send_request('HandwritingEssayOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = HandwritingEssayOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#HKIDCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::HKIDCardOCRResponse

Parameters:

  • request:

    Request instance for HKIDCardOCR.



1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
# File 'lib/v20181119/client.rb', line 1046

def HKIDCardOCR(request)
  body = send_request('HKIDCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = HKIDCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#HmtResidentPermitOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::HmtResidentPermitOCRResponse

Parameters:

  • request:

    Request instance for HmtResidentPermitOCR.



1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
# File 'lib/v20181119/client.rb', line 1098

def HmtResidentPermitOCR(request)
  body = send_request('HmtResidentPermitOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = HmtResidentPermitOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#IDCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::IDCardOCRResponse

Parameters:

  • request:

    Request instance for IDCardOCR.



1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
# File 'lib/v20181119/client.rb', line 1171

def IDCardOCR(request)
  body = send_request('IDCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = IDCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ImageEnhancement(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ImageEnhancementResponse

Parameters:

  • request:

    Request instance for ImageEnhancement.



1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
# File 'lib/v20181119/client.rb', line 1197

def ImageEnhancement(request)
  body = send_request('ImageEnhancement', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ImageEnhancementResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#InsuranceBillOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::InsuranceBillOCRResponse

Parameters:

  • request:

    Request instance for InsuranceBillOCR.



1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
# File 'lib/v20181119/client.rb', line 1223

def InsuranceBillOCR(request)
  body = send_request('InsuranceBillOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = InsuranceBillOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#InvoiceGeneralOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::InvoiceGeneralOCRResponse

Parameters:

  • request:

    Request instance for InvoiceGeneralOCR.



1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
# File 'lib/v20181119/client.rb', line 1250

def InvoiceGeneralOCR(request)
  body = send_request('InvoiceGeneralOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = InvoiceGeneralOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#LicensePlateOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::LicensePlateOCRResponse

Parameters:

  • request:

    Request instance for LicensePlateOCR.



1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
# File 'lib/v20181119/client.rb', line 1276

def LicensePlateOCR(request)
  body = send_request('LicensePlateOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = LicensePlateOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#MainlandPermitOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::MainlandPermitOCRResponse

Parameters:

  • request:

    Request instance for MainlandPermitOCR.



1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
# File 'lib/v20181119/client.rb', line 1354

def MainlandPermitOCR(request)
  body = send_request('MainlandPermitOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = MainlandPermitOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#MixedInvoiceDetect(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::MixedInvoiceDetectResponse

Parameters:

  • request:

    Request instance for MixedInvoiceDetect.



1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
# File 'lib/v20181119/client.rb', line 1379

def MixedInvoiceDetect(request)
  body = send_request('MixedInvoiceDetect', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = MixedInvoiceDetectResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#MixedInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::MixedInvoiceOCRResponse

Parameters:

  • request:

    Request instance for MixedInvoiceOCR.



1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
# File 'lib/v20181119/client.rb', line 1405

def MixedInvoiceOCR(request)
  body = send_request('MixedInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = MixedInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#MLIDCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::MLIDCardOCRResponse

Parameters:

  • request:

    Request instance for MLIDCardOCR.



1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
# File 'lib/v20181119/client.rb', line 1301

def MLIDCardOCR(request)
  body = send_request('MLIDCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = MLIDCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#MLIDPassportOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::MLIDPassportOCRResponse

Parameters:

  • request:

    Request instance for MLIDPassportOCR.



1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
# File 'lib/v20181119/client.rb', line 1328

def MLIDPassportOCR(request)
  body = send_request('MLIDPassportOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = MLIDPassportOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#PassportOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::PassportOCRResponse

Parameters:

  • request:

    Request instance for PassportOCR.



1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
# File 'lib/v20181119/client.rb', line 1433

def PassportOCR(request)
  body = send_request('PassportOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = PassportOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#PermitOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::PermitOCRResponse

Parameters:

  • request:

    Request instance for PermitOCR.



1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
# File 'lib/v20181119/client.rb', line 1459

def PermitOCR(request)
  body = send_request('PermitOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = PermitOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#QrcodeOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::QrcodeOCRResponse

Parameters:

  • request:

    Request instance for QrcodeOCR.



1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
# File 'lib/v20181119/client.rb', line 1485

def QrcodeOCR(request)
  body = send_request('QrcodeOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = QrcodeOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#QuestionOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::QuestionOCRResponse

Parameters:

  • request:

    Request instance for QuestionOCR.



1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
# File 'lib/v20181119/client.rb', line 1511

def QuestionOCR(request)
  body = send_request('QuestionOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = QuestionOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#QuestionSplitLayoutOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::QuestionSplitLayoutOCRResponse

Parameters:

  • request:

    Request instance for QuestionSplitLayoutOCR.



1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
# File 'lib/v20181119/client.rb', line 1537

def QuestionSplitLayoutOCR(request)
  body = send_request('QuestionSplitLayoutOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = QuestionSplitLayoutOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#QuestionSplitOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::QuestionSplitOCRResponse

Parameters:

  • request:

    Request instance for QuestionSplitOCR.



1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
# File 'lib/v20181119/client.rb', line 1563

def QuestionSplitOCR(request)
  body = send_request('QuestionSplitOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = QuestionSplitOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#QuotaInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::QuotaInvoiceOCRResponse

Parameters:

  • request:

    Request instance for QuotaInvoiceOCR.



1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
# File 'lib/v20181119/client.rb', line 1590

def QuotaInvoiceOCR(request)
  body = send_request('QuotaInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = QuotaInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeContainerOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeContainerOCRResponse

Parameters:

  • request:

    Request instance for RecognizeContainerOCR.



1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
# File 'lib/v20181119/client.rb', line 1615

def RecognizeContainerOCR(request)
  body = send_request('RecognizeContainerOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeContainerOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeEncryptedIDCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeEncryptedIDCardOCRResponse

Parameters:

  • request:

    Request instance for RecognizeEncryptedIDCardOCR.



1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
# File 'lib/v20181119/client.rb', line 1690

def RecognizeEncryptedIDCardOCR(request)
  body = send_request('RecognizeEncryptedIDCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeEncryptedIDCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeFormulaOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeFormulaOCRResponse

Parameters:

  • request:

    Request instance for RecognizeFormulaOCR.



1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
# File 'lib/v20181119/client.rb', line 1716

def RecognizeFormulaOCR(request)
  body = send_request('RecognizeFormulaOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeFormulaOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeGeneralCardWarn(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeGeneralCardWarnResponse

Parameters:

  • request:

    Request instance for RecognizeGeneralCardWarn.



1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
# File 'lib/v20181119/client.rb', line 1742

def RecognizeGeneralCardWarn(request)
  body = send_request('RecognizeGeneralCardWarn', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeGeneralCardWarnResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeGeneralInvoice(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeGeneralInvoiceResponse

Parameters:

  • request:

    Request instance for RecognizeGeneralInvoice.



1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
# File 'lib/v20181119/client.rb', line 1972

def RecognizeGeneralInvoice(request)
  body = send_request('RecognizeGeneralInvoice', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeGeneralInvoiceResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeHealthCodeOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeHealthCodeOCRResponse

Parameters:

  • request:

    Request instance for RecognizeHealthCodeOCR.



2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
# File 'lib/v20181119/client.rb', line 2000

def RecognizeHealthCodeOCR(request)
  body = send_request('RecognizeHealthCodeOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeHealthCodeOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeMedicalInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeMedicalInvoiceOCRResponse

Parameters:

  • request:

    Request instance for RecognizeMedicalInvoiceOCR.



2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
# File 'lib/v20181119/client.rb', line 2026

def RecognizeMedicalInvoiceOCR(request)
  body = send_request('RecognizeMedicalInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeMedicalInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeOnlineTaxiItineraryOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeOnlineTaxiItineraryOCRResponse

Parameters:

  • request:

    Request instance for RecognizeOnlineTaxiItineraryOCR.



2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
# File 'lib/v20181119/client.rb', line 2052

def RecognizeOnlineTaxiItineraryOCR(request)
  body = send_request('RecognizeOnlineTaxiItineraryOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeOnlineTaxiItineraryOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeStoreName(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeStoreNameResponse

Parameters:

  • request:

    Request instance for RecognizeStoreName.



2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
# File 'lib/v20181119/client.rb', line 2077

def RecognizeStoreName(request)
  body = send_request('RecognizeStoreName', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeStoreNameResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeTableAccurateOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeTableAccurateOCRResponse

Parameters:

  • request:

    Request instance for RecognizeTableAccurateOCR.



2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
# File 'lib/v20181119/client.rb', line 2103

def RecognizeTableAccurateOCR(request)
  body = send_request('RecognizeTableAccurateOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeTableAccurateOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeTableMultiOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeTableMultiOCRResponse

Parameters:

  • request:

    Request instance for RecognizeTableMultiOCR.



2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
# File 'lib/v20181119/client.rb', line 2129

def RecognizeTableMultiOCR(request)
  body = send_request('RecognizeTableMultiOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeTableMultiOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeTableOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeTableOCRResponse

Parameters:

  • request:

    Request instance for RecognizeTableOCR.



2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
# File 'lib/v20181119/client.rb', line 2155

def RecognizeTableOCR(request)
  body = send_request('RecognizeTableOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeTableOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeThaiIDCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeThaiIDCardOCRResponse

Parameters:

  • request:

    Request instance for RecognizeThaiIDCardOCR.



2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
# File 'lib/v20181119/client.rb', line 2182

def RecognizeThaiIDCardOCR(request)
  body = send_request('RecognizeThaiIDCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeThaiIDCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeTravelCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeTravelCardOCRResponse

Parameters:

  • request:

    Request instance for RecognizeTravelCardOCR.



2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
# File 'lib/v20181119/client.rb', line 2210

def RecognizeTravelCardOCR(request)
  body = send_request('RecognizeTravelCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeTravelCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RecognizeValidIDCardOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RecognizeValidIDCardOCRResponse

Parameters:

  • request:

    Request instance for RecognizeValidIDCardOCR.



2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
# File 'lib/v20181119/client.rb', line 2236

def RecognizeValidIDCardOCR(request)
  body = send_request('RecognizeValidIDCardOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RecognizeValidIDCardOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ResidenceBookletOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ResidenceBookletOCRResponse

Parameters:

  • request:

    Request instance for ResidenceBookletOCR.



2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
# File 'lib/v20181119/client.rb', line 2262

def ResidenceBookletOCR(request)
  body = send_request('ResidenceBookletOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ResidenceBookletOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RideHailingDriverLicenseOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RideHailingDriverLicenseOCRResponse

Parameters:

  • request:

    Request instance for RideHailingDriverLicenseOCR.



2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
# File 'lib/v20181119/client.rb', line 2288

def RideHailingDriverLicenseOCR(request)
  body = send_request('RideHailingDriverLicenseOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RideHailingDriverLicenseOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#RideHailingTransportLicenseOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::RideHailingTransportLicenseOCRResponse

Parameters:

  • request:

    Request instance for RideHailingTransportLicenseOCR.



2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
# File 'lib/v20181119/client.rb', line 2314

def RideHailingTransportLicenseOCR(request)
  body = send_request('RideHailingTransportLicenseOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = RideHailingTransportLicenseOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#SealOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::SealOCRResponse

Parameters:

  • request:

    Request instance for SealOCR.



2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
# File 'lib/v20181119/client.rb', line 2340

def SealOCR(request)
  body = send_request('SealOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = SealOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#ShipInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::ShipInvoiceOCRResponse

Parameters:

  • request:

    Request instance for ShipInvoiceOCR.



2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
# File 'lib/v20181119/client.rb', line 2367

def ShipInvoiceOCR(request)
  body = send_request('ShipInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ShipInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#SmartStructuralOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::SmartStructuralOCRResponse

Parameters:

  • request:

    Request instance for SmartStructuralOCR.



2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
# File 'lib/v20181119/client.rb', line 2393

def SmartStructuralOCR(request)
  body = send_request('SmartStructuralOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = SmartStructuralOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#SubmitExtractDocAgentJob(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::SubmitExtractDocAgentJobResponse

Parameters:

  • request:

    Request instance for SubmitExtractDocAgentJob.



2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
# File 'lib/v20181119/client.rb', line 2417

def SubmitExtractDocAgentJob(request)
  body = send_request('SubmitExtractDocAgentJob', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = SubmitExtractDocAgentJobResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#TableOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::TableOCRResponse

Parameters:

  • request:

    Request instance for TableOCR.



2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
# File 'lib/v20181119/client.rb', line 2445

def TableOCR(request)
  body = send_request('TableOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = TableOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#TaxiInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::TaxiInvoiceOCRResponse

Parameters:

  • request:

    Request instance for TaxiInvoiceOCR.



2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
# File 'lib/v20181119/client.rb', line 2471

def TaxiInvoiceOCR(request)
  body = send_request('TaxiInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = TaxiInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#TextDetect(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::TextDetectResponse

Parameters:

  • request:

    Request instance for TextDetect.



2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
# File 'lib/v20181119/client.rb', line 2497

def TextDetect(request)
  body = send_request('TextDetect', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = TextDetectResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#TollInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::TollInvoiceOCRResponse

Parameters:

  • request:

    Request instance for TollInvoiceOCR.



2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
# File 'lib/v20181119/client.rb', line 2524

def TollInvoiceOCR(request)
  body = send_request('TollInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = TollInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#TrainTicketOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::TrainTicketOCRResponse

Parameters:

  • request:

    Request instance for TrainTicketOCR.



2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
# File 'lib/v20181119/client.rb', line 2550

def TrainTicketOCR(request)
  body = send_request('TrainTicketOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = TrainTicketOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#VatInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::VatInvoiceOCRResponse

Parameters:

  • request:

    Request instance for VatInvoiceOCR.



2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
# File 'lib/v20181119/client.rb', line 2576

def VatInvoiceOCR(request)
  body = send_request('VatInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VatInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#VatInvoiceVerifyNew(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::VatInvoiceVerifyNewResponse

Parameters:

  • request:

    Request instance for VatInvoiceVerifyNew.



2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
# File 'lib/v20181119/client.rb', line 2602

def VatInvoiceVerifyNew(request)
  body = send_request('VatInvoiceVerifyNew', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VatInvoiceVerifyNewResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#VatRollInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::VatRollInvoiceOCRResponse

Parameters:

  • request:

    Request instance for VatRollInvoiceOCR.



2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
# File 'lib/v20181119/client.rb', line 2629

def VatRollInvoiceOCR(request)
  body = send_request('VatRollInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VatRollInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#VehicleLicenseOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::VehicleLicenseOCRResponse

Parameters:

  • request:

    Request instance for VehicleLicenseOCR.



2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
# File 'lib/v20181119/client.rb', line 2661

def VehicleLicenseOCR(request)
  body = send_request('VehicleLicenseOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VehicleLicenseOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#VehicleRegCertOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::VehicleRegCertOCRResponse

Parameters:

  • request:

    Request instance for VehicleRegCertOCR.



2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
# File 'lib/v20181119/client.rb', line 2687

def VehicleRegCertOCR(request)
  body = send_request('VehicleRegCertOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VehicleRegCertOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#VerifyOfdVatInvoiceOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::VerifyOfdVatInvoiceOCRResponse

Parameters:

  • request:

    Request instance for VerifyOfdVatInvoiceOCR.



2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
# File 'lib/v20181119/client.rb', line 2711

def VerifyOfdVatInvoiceOCR(request)
  body = send_request('VerifyOfdVatInvoiceOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VerifyOfdVatInvoiceOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#VinOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::VinOCRResponse

Parameters:

  • request:

    Request instance for VinOCR.



2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
# File 'lib/v20181119/client.rb', line 2736

def VinOCR(request)
  body = send_request('VinOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VinOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end

#WaybillOCR(request) ⇒ Object

@rtype: :class:Tencentcloud::ocr::V20181119::WaybillOCRResponse

Parameters:

  • request:

    Request instance for WaybillOCR.



2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
# File 'lib/v20181119/client.rb', line 2762

def WaybillOCR(request)
  body = send_request('WaybillOCR', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = WaybillOCRResponse.new
    model.deserialize(response['Response'])
    model
  else
    code = response['Response']['Error']['Code']
    message = response['Response']['Error']['Message']
    reqid = response['Response']['RequestId']
    raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
  end
rescue TencentCloud::Common::TencentCloudSDKException => e
  raise e
rescue StandardError => e
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end