Documentation
¶
Index ¶
- Variables
- func SetKey(key string)
- func SetKeyEnv() (err error)
- func SetVersion(version int)
- type Answer
- type Candidate
- type CandidateClient
- func (self *CandidateClient) Create(params *CandidateParams) (*Candidate, error)
- func (self *CandidateClient) Delete(id string) (*Candidate, error)
- func (self *CandidateClient) History(id string) ([]*Candidate, error)
- func (self *CandidateClient) Hits(id string) ([]*Candidate, error)
- func (self *CandidateClient) List() ([]*Candidate, error)
- func (self *CandidateClient) ListN(count, offset int) ([]*Candidate, error)
- func (self *CandidateClient) Retrieve(id string) (*Candidate, error)
- func (self *CandidateClient) Update(id string, params *CandidateParams) (*Candidate, error)
- type CandidateParams
- type Company
- type CompanyClient
- type CompanyDetails
- type CompanyParams
- type Error
- type Match
- type Person
- type PersonClient
- type PersonDetails
- type PersonParams
- type Question
- type QuestionSet
- type QuestionSetClient
- func (self *QuestionSetClient) Create(personId string) (*QuestionSet, error)
- func (self *QuestionSetClient) List() ([]*QuestionSet, error)
- func (self *QuestionSetClient) ListN(count, offset int) ([]*QuestionSet, error)
- func (self *QuestionSetClient) Retrieve(id string) (*QuestionSet, error)
- func (self *QuestionSetClient) Score(id string, params *ScoreParams) (*QuestionSet, error)
- type ScoreAnswer
- type ScoreParams
- type Watchlist
- type WatchlistClient
- type WatchlistParams
Constants ¶
This section is empty.
Variables ¶
View Source
var ( People = new(PersonClient) Companies = new(CompanyClient) Candidates = new(CandidateClient) QuestionSets = new(QuestionSetClient) Watchlists = new(WatchlistClient) )
Functions ¶
func SetKey ¶
func SetKey(key string)
Sets the BlockScore API key to use for authenticating API requests.
func SetVersion ¶
func SetVersion(version int)
Sets the version of the BlockScore API to use. Note: This library is designed to only work with v4 and newer.
Types ¶
type Candidate ¶
type Candidate struct {
Object string `json:"object"`
Id string `json:"id"`
CreatedAt int64 `json:"created_at"`
UpdatedAt int64 `json:"updated_at"`
Livemode bool `json:"livemode"`
Note string `json:"note"`
Ssn string `json:"ssn"`
Passport string `json:"passport"`
DateOfBirth string `json:"date_of_birth"`
NameFirst string `json:"name_first"`
NameMiddle string `json:"name_middle"`
NameLast string `json:"name_last"`
AddressStreet1 string `json:"address_street1"`
AddressStreet2 string `json:"address_street2"`
AddressCity string `json:"address_city"`
AddressSubdivison string `json:"address_subdivision"`
AddressPostalCode string `json:"address_postal_code"`
AddressCountryCode string `json:"address_country_code"`
}
type CandidateClient ¶
type CandidateClient struct{}
func (*CandidateClient) Create ¶
func (self *CandidateClient) Create(params *CandidateParams) (*Candidate, error)
func (*CandidateClient) History ¶
func (self *CandidateClient) History(id string) ([]*Candidate, error)
func (*CandidateClient) List ¶
func (self *CandidateClient) List() ([]*Candidate, error)
func (*CandidateClient) ListN ¶
func (self *CandidateClient) ListN(count, offset int) ([]*Candidate, error)
func (*CandidateClient) Retrieve ¶
func (self *CandidateClient) Retrieve(id string) (*Candidate, error)
func (*CandidateClient) Update ¶
func (self *CandidateClient) Update(id string, params *CandidateParams) (*Candidate, error)
type CandidateParams ¶
type CandidateParams struct {
NameFirst string `json:"name_first,omitempty"`
NameMiddle string `json:"name_middle,omitempty"`
NameLast string `json:"name_last,omitempty"`
Note string `json:"note,omitempty"`
Ssn string `json:"ssn,omitempty"`
Passport string `json:"passport,omitempty"`
DateOfBirth string `json:"date_of_birth,omitempty"`
AddressStreet1 string `json:"address_street1,omitempty"`
AddressStreet2 string `json:"address_street2,omitempty"`
AddressCity string `json:"address_city,omitempty"`
AddressSubdivison string `json:"address_subdivision,omitempty"`
AddressPostalCode string `json:"address_postal_code,omitempty"`
AddressCountryCode string `json:"address_country_code,omitempty"`
}
type Company ¶
type Company struct {
Object string `json:"object"`
Id string `json:"id"`
CreatedAt int64 `json:"created_at"`
UpdatedAt int64 `json:"updated_at"`
Status string `json:"status"`
Livemode bool `json:"livemode"`
EntityName string `json:"entity_name"`
TaxId string `json:"tax_id"`
IncorporationDate string `json:"incorporation_date"`
IncorporationState string `json:"incorporation_state"`
IncorporationCountryCode string `json:"incorporation_country_code"`
IncorporationType string `json:"incorporation_type"`
Dbas string `json:"dbas"`
RegistrationNumber string `json:"registration_number"`
Email string `json:"email"`
Url string `json:"url"`
PhoneNumber string `json:"phone_number"`
IPAddress string `json:"ip_address"`
Note string `json:"note"`
AddressStreet1 string `json:"address_street1"`
AddressStreet2 string `json:"address_street2"`
AddressCity string `json:"address_city"`
AddressSubdivision string `json:"address_subdivision"`
AddressPostalCode string `json:"address_postal_code"`
AddressCountryCode string `json:"address_country_code"`
Details CompanyDetails `json:"details"`
}
type CompanyClient ¶
type CompanyClient struct{}
func (*CompanyClient) Create ¶
func (self *CompanyClient) Create(params *CompanyParams) (*Company, error)
func (*CompanyClient) List ¶
func (self *CompanyClient) List() ([]*Company, error)
type CompanyDetails ¶
type CompanyParams ¶
type CompanyParams struct {
EntityName string `json:"entity_name"`
TaxId string `json:"tax_id"`
IncorporationState string `json:"incorporation_state"` // optional
IncorporationCountryCode string `json:"incorporation_country_code"`
IncorporationType string `json:"incorporation_type"`
IncorporationDay int64 `json:"incorporation_day"` // optional
IncorporationMonth int64 `json:"incorporation_month"` // optional
IncorporationYear int64 `json:"incorporation_year"` // optional
Dbas string `json:"dbas"` // optional
RegistrationNumber string `json:"registration_number"` // optional
Email string `json:"email"` // optional
Url string `json:"url"` // optional
PhoneNumber string `json:"phone_number"` // optional
IPAddress string `json:"ip_address"` // optional
Note string `json:"note"` // optional
AddressStreet1 string `json:"address_street1"`
AddressStreet2 string `json:"address_street2"`
AddressCity string `json:"address_city"`
AddressSubdivision string `json:"address_subdivision"`
AddressPostalCode string `json:"address_postal_code"`
AddressCountryCode string `json:"address_country_code"`
}
type Error ¶
type Error struct {
Code int
Detail struct {
Code string `json:"code"`
Message string `json:"message"`
Param string `json:"param"`
Type string `json:"type"`
} `json:"error"`
}
Error encapsulates an error returned by the BlockScore REST API.
type Match ¶
type Match struct {
WatchlistName string `json:"watchlist_name"`
MatchingInfo []string `json:"matching_info"`
NameFull string `json:"name_full"`
AlternateNames string `json:"alternate_names"`
DateOfBirth string `json:"date_of_birth"`
Ssn string `json:"ssn"`
Passport string `json:"passport"`
AddressRaw string `json:"address_raw"`
AddressStreet1 string `json:"address_street1"`
AddressCity string `json:"address_city"`
AddressState string `json:"address_state"`
AddressPostalCode string `json:"address_postal_code"`
AddressCountryCode string `json:"address_country_code"`
}
type Person ¶
type Person struct {
Object string `json:"object"`
Id string `json:"id"`
CreatedAt int64 `json:"created_at"`
UpdatedAt int64 `json:"updated_at"`
Status string `json:"status"`
Livemode bool `json:"livemode"`
PhoneNumber string `json:"phone_number"`
IPAddress string `json:"ip_address"`
BirthDay int64 `json:"birth_day"`
BirthMonth int64 `json:"birth_month"`
BirthYear int64 `json:"birth_year"`
NameFirst string `json:"name_first"`
NameMiddle string `json:"name_middle"`
NameLast string `json:"name_last"`
DocumentType string `json:"document_type"`
DocumentValue string `json:"document_value"`
AddressStreet1 string `json:"address_street1"`
AddressStreet2 string `json:"address_street2"`
AddressCity string `json:"address_city"`
AddressSubdivision string `json:"address_subdivision"`
AddressPostalCode string `json:"address_postal_code"`
AddressCountryCode string `json:"address_country_code"`
Note string `json:"note"`
Details PersonDetails `json:"details"`
QuestionSets []string `json:"question_sets"`
}
type PersonClient ¶
type PersonClient struct{}
func (*PersonClient) Create ¶
func (self *PersonClient) Create(params *PersonParams) (*Person, error)
func (*PersonClient) List ¶
func (self *PersonClient) List() ([]*Person, error)
type PersonDetails ¶
type PersonParams ¶
type PersonParams struct {
NameFirst string `json:"name_first"`
NameMiddle string `json:"name_middle"`
NameLast string `json:"name_last"`
DocumentType string `json:"document_type"`
DocumentValue string `json:"document_value"`
BirthDay int64 `json:"birth_day"`
BirthMonth int64 `json:"birth_month"`
BirthYear int64 `json:"birth_year"`
AddressStreet1 string `json:"address_street1"`
AddressStreet2 string `json:"address_street2"`
AddressCity string `json:"address_city"`
AddressSubdivision string `json:"address_subdivision"`
AddressPostalCode string `json:"address_postal_code"`
AddressCountryCode string `json:"address_country_code"`
PhoneNumber string `json:"phone_number"`
IPAddress string `json:"ip_address"`
Note string `json:"note"`
}
Options for creating People.
type QuestionSet ¶
type QuestionSet struct {
Object string `json:"object"`
Id string `json:"id"`
CreatedAt int `json:"created_at"`
UpdatedAt int `json:"updated_at"`
Livemode bool `json:"livemode"`
VerificationId string `json:"verification_id"`
Score float64 `json:"score"`
Expired bool `json:"expired"`
TimeLimit int `json:"time_limit"`
Questions []Question `json:"questions"`
}
type QuestionSetClient ¶
type QuestionSetClient struct{}
func (*QuestionSetClient) Create ¶
func (self *QuestionSetClient) Create(personId string) (*QuestionSet, error)
func (*QuestionSetClient) List ¶
func (self *QuestionSetClient) List() ([]*QuestionSet, error)
func (*QuestionSetClient) ListN ¶
func (self *QuestionSetClient) ListN(count, offset int) ([]*QuestionSet, error)
func (*QuestionSetClient) Retrieve ¶
func (self *QuestionSetClient) Retrieve(id string) (*QuestionSet, error)
func (*QuestionSetClient) Score ¶
func (self *QuestionSetClient) Score(id string, params *ScoreParams) (*QuestionSet, error)
type ScoreAnswer ¶
type ScoreParams ¶
type ScoreParams struct {
Answers []ScoreAnswer `json:"answers"`
}
type WatchlistClient ¶
type WatchlistClient struct{}
func (*WatchlistClient) Search ¶
func (self *WatchlistClient) Search(params *WatchlistParams) (*Watchlist, error)
type WatchlistParams ¶
type WatchlistParams struct {
// The ID of the Candidate you have created.
CandidateId string `json:"candidate_id"`
// Can either be `person` or `company` and will restrict the search to
// only search for people or entities on watchlists respectively.
// Optional param.
MatchType string `json:"match_type"`
}
Click to show internal directories.
Click to hide internal directories.