Class: ThePlaidApi::EntityWatchlistCode

Inherits:
Object
  • Object
show all
Defined in:
lib/the_plaid_api/models/entity_watchlist_code.rb

Overview

Shorthand identifier for a specific screening list for entities. ‘AU_CON`: Australia Department of Foreign Affairs and Trade Consolidated List `CA_CON`: Government of Canada Consolidated List of Sanctions `EU_CON`: European External Action Service Consolidated List `IZ_SOE`: State Owned Enterprise List `IZ_UNC`: United Nations Consolidated Sanctions `IZ_WBK`: World Bank Listing of Ineligible Firms and Individuals `US_CAP`: US OFAC Correspondent Account or Payable-Through Account Sanctions `US_FSE`: US OFAC Foreign Sanctions Evaders `US_MBS`: US Non-SDN Menu-Based Sanctions `US_SDN`: US Specially Designated Nationals List `US_SSI`: US OFAC Sectoral Sanctions Identifications `US_CMC`: US OFAC Non-SDN Chinese Military-Industrial Complex List `US_UVL`: Bureau of Industry and Security Unverified List `US_SAM`: US System for Award Management Exclusion List `US_TEL`: US Terrorist Exclusion List `UK_HMC`: UK HM Treasury Consolidated List

Constant Summary collapse

ENTITY_WATCHLIST_CODE =
[
  # TODO: Write general description for CA_CON
  CA_CON = 'CA_CON'.freeze,

  # TODO: Write general description for EU_CON
  EU_CON = 'EU_CON'.freeze,

  # TODO: Write general description for IZ_SOE
  IZ_SOE = 'IZ_SOE'.freeze,

  # TODO: Write general description for IZ_UNC
  IZ_UNC = 'IZ_UNC'.freeze,

  # TODO: Write general description for IZ_WBK
  IZ_WBK = 'IZ_WBK'.freeze,

  # TODO: Write general description for US_CAP
  US_CAP = 'US_CAP'.freeze,

  # TODO: Write general description for US_FSE
  US_FSE = 'US_FSE'.freeze,

  # TODO: Write general description for US_MBS
  US_MBS = 'US_MBS'.freeze,

  # TODO: Write general description for US_SDN
  US_SDN = 'US_SDN'.freeze,

  # TODO: Write general description for US_SSI
  US_SSI = 'US_SSI'.freeze,

  # TODO: Write general description for US_CMC
  US_CMC = 'US_CMC'.freeze,

  # TODO: Write general description for US_UVL
  US_UVL = 'US_UVL'.freeze,

  # TODO: Write general description for US_SAM
  US_SAM = 'US_SAM'.freeze,

  # TODO: Write general description for US_TEL
  US_TEL = 'US_TEL'.freeze,

  # TODO: Write general description for AU_CON
  AU_CON = 'AU_CON'.freeze,

  # TODO: Write general description for UK_HMC
  UK_HMC = 'UK_HMC'.freeze
].freeze

Class Method Summary collapse

Class Method Details

.from_value(value, default_value = CA_CON) ⇒ Object



78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
# File 'lib/the_plaid_api/models/entity_watchlist_code.rb', line 78

def self.from_value(value, default_value = CA_CON)
  return default_value if value.nil?

  str = value.to_s.strip

  case str.downcase
  when 'ca_con' then CA_CON
  when 'eu_con' then EU_CON
  when 'iz_soe' then IZ_SOE
  when 'iz_unc' then IZ_UNC
  when 'iz_wbk' then IZ_WBK
  when 'us_cap' then US_CAP
  when 'us_fse' then US_FSE
  when 'us_mbs' then US_MBS
  when 'us_sdn' then US_SDN
  when 'us_ssi' then US_SSI
  when 'us_cmc' then US_CMC
  when 'us_uvl' then US_UVL
  when 'us_sam' then US_SAM
  when 'us_tel' then US_TEL
  when 'au_con' then AU_CON
  when 'uk_hmc' then UK_HMC
  else
    default_value
  end
end

.validate(value) ⇒ Object



72
73
74
75
76
# File 'lib/the_plaid_api/models/entity_watchlist_code.rb', line 72

def self.validate(value)
  return false if value.nil?

  ENTITY_WATCHLIST_CODE.include?(value)
end