SyncteraRubySdk::KYCVerificationDeprecatedApi
All URIs are relative to https://api.synctera.com/v0
| Method | HTTP request | Description |
|---|---|---|
| create_customer_verification_result | POST /customers/customer_id/verifications | Create a customer verification result |
| get_verification | GET /customers/customer_id/verifications/verification_id | Get verification result |
| list_verifications | GET /customers/customer_id/verifications | List verification results |
| verify_customer | POST /customers/customer_id/verify | Verify a customer's identity |
create_customer_verification_result
create_customer_verification_result(customer_id, customer_verification_result, opts)
Create a customer verification result
Create a verification result for a customer. This endpoint will be removed in API v1. Use POST /v0/verifications instead.
Examples
require 'time'
require 'synctera_ruby_sdk'
# setup authorization
SyncteraRubySdk.configure do |config|
# Configure Bearer authorization (api_key): bearerAuth
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = SyncteraRubySdk::KYCVerificationDeprecatedApi.new
customer_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The customer's unique identifier
customer_verification_result = SyncteraRubySdk::CustomerVerificationResult.new({result: 'ACCEPTED', verification_time: Time.now, verification_type: SyncteraRubySdk::VerificationType::FRAUD}) # CustomerVerificationResult | Customer verification result to create.
opts = {
idempotency_key: '7d943c51-e4ff-4e57-9558-08cab6b963c7' # String | An idempotency key is an arbitrary unique value generated by client to detect subsequent retries of the same request. It is recommended that a UUID or a similar random identifier be used as an idempotency key. A different key must be used for each request, unless it is a retry.
}
begin
# Create a customer verification result
result = api_instance.create_customer_verification_result(customer_id, customer_verification_result, opts)
p result
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->create_customer_verification_result: #{e}"
end
Using the create_customer_verification_result_with_http_info variant
This returns an Array which contains the response data, status code and headers.
, Integer, Hash)> create_customer_verification_result_with_http_info(customer_id, customer_verification_result, opts)
begin
# Create a customer verification result
data, status_code, headers = api_instance.create_customer_verification_result_with_http_info(customer_id, customer_verification_result, opts)
p status_code # => 2xx
p headers # => { ... }
p data # => <CustomerVerificationResult>
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->create_customer_verification_result_with_http_info: #{e}"
end
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| customer_id | String | The customer's unique identifier | |
| customer_verification_result | CustomerVerificationResult | Customer verification result to create. | |
| idempotency_key | String | An idempotency key is an arbitrary unique value generated by client to detect subsequent retries of the same request. It is recommended that a UUID or a similar random identifier be used as an idempotency key. A different key must be used for each request, unless it is a retry. | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json, application/problem+json
get_verification
get_verification(customer_id, verification_id)
Get verification result
Get verification result by ID. This endpoint will be removed in API v1. Use GET /v0/verifications/{verification_id} instead.
Examples
require 'time'
require 'synctera_ruby_sdk'
# setup authorization
SyncteraRubySdk.configure do |config|
# Configure Bearer authorization (api_key): bearerAuth
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = SyncteraRubySdk::KYCVerificationDeprecatedApi.new
customer_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The customer's unique identifier
verification_id = '7d943c51-e4ff-4e57-9558-08cab6b963c7' # String | Unique identifier for the verification.
begin
# Get verification result
result = api_instance.get_verification(customer_id, verification_id)
p result
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->get_verification: #{e}"
end
Using the get_verification_with_http_info variant
This returns an Array which contains the response data, status code and headers.
, Integer, Hash)> get_verification_with_http_info(customer_id, verification_id)
begin
# Get verification result
data, status_code, headers = api_instance.get_verification_with_http_info(customer_id, verification_id)
p status_code # => 2xx
p headers # => { ... }
p data # => <CustomerVerificationResult>
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->get_verification_with_http_info: #{e}"
end
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| customer_id | String | The customer's unique identifier | |
| verification_id | String | Unique identifier for the verification. |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json, application/problem+json
list_verifications
list_verifications(customer_id, opts)
List verification results
List verification results. This endpoint will be removed in API v1. Use GET /v0/verifications?customer_id={customer_id} instead.
Examples
require 'time'
require 'synctera_ruby_sdk'
# setup authorization
SyncteraRubySdk.configure do |config|
# Configure Bearer authorization (api_key): bearerAuth
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = SyncteraRubySdk::KYCVerificationDeprecatedApi.new
customer_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The customer's unique identifier
opts = {
include_history: true, # Boolean | If true, include old (inactive) records as well.
limit: 100, # Integer |
page_token: 'a8937a0d' # String |
}
begin
# List verification results
result = api_instance.list_verifications(customer_id, opts)
p result
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->list_verifications: #{e}"
end
Using the list_verifications_with_http_info variant
This returns an Array which contains the response data, status code and headers.
, Integer, Hash)> list_verifications_with_http_info(customer_id, opts)
begin
# List verification results
data, status_code, headers = api_instance.list_verifications_with_http_info(customer_id, opts)
p status_code # => 2xx
p headers # => { ... }
p data # => <CustomerVerificationResultList>
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->list_verifications_with_http_info: #{e}"
end
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| customer_id | String | The customer's unique identifier | |
| include_history | Boolean | If true, include old (inactive) records as well. | [optional][default to false] |
| limit | Integer | [optional][default to 100] | |
| page_token | String | [optional] |
Return type
CustomerVerificationResultList
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json, application/problem+json
verify_customer
verify_customer(customer_id, customer_verification, opts)
Verify a customer's identity
Initiate identity verification for a customer and run the specified identity checks. Verifying a personal customer requires that the following fields already be set: * first_name * last_name * dob * email * phone_number * legal_address * ssn This endpoint will be removed in API v1. Use POST /v0/verifications/verify instead.
Examples
require 'time'
require 'synctera_ruby_sdk'
# setup authorization
SyncteraRubySdk.configure do |config|
# Configure Bearer authorization (api_key): bearerAuth
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = SyncteraRubySdk::KYCVerificationDeprecatedApi.new
customer_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The customer's unique identifier
customer_verification = SyncteraRubySdk::CustomerVerification.new({customer_consent: false}) # CustomerVerification | Customer verification request.
opts = {
idempotency_key: '7d943c51-e4ff-4e57-9558-08cab6b963c7' # String | An idempotency key is an arbitrary unique value generated by client to detect subsequent retries of the same request. It is recommended that a UUID or a similar random identifier be used as an idempotency key. A different key must be used for each request, unless it is a retry.
}
begin
# Verify a customer's identity
result = api_instance.verify_customer(customer_id, customer_verification, opts)
p result
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->verify_customer: #{e}"
end
Using the verify_customer_with_http_info variant
This returns an Array which contains the response data, status code and headers.
, Integer, Hash)> verify_customer_with_http_info(customer_id, customer_verification, opts)
begin
# Verify a customer's identity
data, status_code, headers = api_instance.verify_customer_with_http_info(customer_id, customer_verification, opts)
p status_code # => 2xx
p headers # => { ... }
p data # => <CustomerVerifyResponse>
rescue SyncteraRubySdk::ApiError => e
puts "Error when calling KYCVerificationDeprecatedApi->verify_customer_with_http_info: #{e}"
end
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| customer_id | String | The customer's unique identifier | |
| customer_verification | CustomerVerification | Customer verification request. | |
| idempotency_key | String | An idempotency key is an arbitrary unique value generated by client to detect subsequent retries of the same request. It is recommended that a UUID or a similar random identifier be used as an idempotency key. A different key must be used for each request, unless it is a retry. | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json, application/problem+json