checkr-official 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/History.txt +4 -0
- data/README.md +12 -4
- data/VERSION +1 -1
- data/lib/checkr/api_class.rb +11 -6
- data/lib/checkr/document.rb +3 -0
- data/samples/candidate.md +195 -0
- data/samples/country_criminal_search.md +60 -0
- data/samples/document.md +109 -0
- data/samples/geo.md +150 -0
- data/samples/motor_vehicle_report.md +136 -0
- data/samples/national_criminal_search.md +56 -0
- data/samples/report.md +158 -0
- data/samples/sex_offender_search.md +58 -0
- data/samples/ssn_trace.md +136 -0
- data/samples/subscription.md +143 -0
- data/samples/terrorist_watchlist_search.md +118 -0
- data/test/checkr/document_list_test.rb +36 -0
- data/test/checkr/document_test.rb +9 -4
- data/test/checkr/report_test.rb +5 -0
- data/test/test_data.rb +1 -0
- metadata +14 -1
data/samples/geo.md
ADDED
@@ -0,0 +1,150 @@
|
|
1
|
+
# Geo
|
2
|
+
|
3
|
+
## The Geo Object
|
4
|
+
|
5
|
+
### Example Response
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
|
9
|
+
```
|
10
|
+
|
11
|
+
|
12
|
+
|
13
|
+
## Create a new Geo
|
14
|
+
|
15
|
+
### Definition
|
16
|
+
|
17
|
+
```ruby
|
18
|
+
Checkr::Geo.create
|
19
|
+
```
|
20
|
+
|
21
|
+
### Example Request
|
22
|
+
|
23
|
+
```ruby
|
24
|
+
require 'checkr' # Note the gem is named checkr-official
|
25
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
26
|
+
|
27
|
+
geo = Checkr::Geo.create({
|
28
|
+
:name => "San Francisco",
|
29
|
+
:state => "CA"
|
30
|
+
})
|
31
|
+
```
|
32
|
+
|
33
|
+
### Example Response
|
34
|
+
|
35
|
+
```ruby
|
36
|
+
#<Checkr::Geo:0x3fd90aafbb58 id=5647cff4050585829088f3d7> JSON: {
|
37
|
+
"name": "San Francisco",
|
38
|
+
"state": "CA",
|
39
|
+
"id": "5647cff4050585829088f3d7",
|
40
|
+
"object": "geo",
|
41
|
+
"uri": "/v1/geos/5647cff4050585829088f3d7",
|
42
|
+
"created_at": "2015-03-24T21:03:30Z"
|
43
|
+
}
|
44
|
+
```
|
45
|
+
|
46
|
+
|
47
|
+
|
48
|
+
## Retrieve an existing Geo
|
49
|
+
|
50
|
+
### Definition
|
51
|
+
|
52
|
+
```ruby
|
53
|
+
Checkr::Geo.retrieve({GEO_ID})
|
54
|
+
```
|
55
|
+
|
56
|
+
### Example Request
|
57
|
+
|
58
|
+
```ruby
|
59
|
+
require 'checkr' # Note the gem is named checkr-official
|
60
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
61
|
+
|
62
|
+
geo = Checkr::Geo.retrieve("5647cff4050585829088f3d7")
|
63
|
+
```
|
64
|
+
|
65
|
+
### Example Response
|
66
|
+
|
67
|
+
```ruby
|
68
|
+
#<Checkr::Geo:0x3fd909ae0610 id=5647cff4050585829088f3d7> JSON: {
|
69
|
+
"name": "San Francisco",
|
70
|
+
"state": "CA",
|
71
|
+
"id": "5647cff4050585829088f3d7",
|
72
|
+
"object": "geo",
|
73
|
+
"uri": "/v1/geos/5647cff4050585829088f3d7",
|
74
|
+
"created_at": "2015-03-24T21:03:30Z"
|
75
|
+
}
|
76
|
+
```
|
77
|
+
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
## Delete an existing Geo
|
82
|
+
|
83
|
+
### Definition
|
84
|
+
|
85
|
+
```ruby
|
86
|
+
geo = Checkr::Geo.retrieve({GEO_ID})
|
87
|
+
geo.delete
|
88
|
+
```
|
89
|
+
|
90
|
+
### Example Request
|
91
|
+
|
92
|
+
```ruby
|
93
|
+
require 'checkr' # Note the gem is named checkr-official
|
94
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
95
|
+
|
96
|
+
geo = Checkr::Geo.retrieve("5647cff4050585829088f3d7")
|
97
|
+
geo.delete
|
98
|
+
```
|
99
|
+
|
100
|
+
### Example Response
|
101
|
+
|
102
|
+
```ruby
|
103
|
+
#<Checkr::Geo:0x3fd90c139dd4 id=5647cff4050585829088f3d7> JSON: {
|
104
|
+
"name": "San Francisco",
|
105
|
+
"state": "CA",
|
106
|
+
"id": "5647cff4050585829088f3d7",
|
107
|
+
"object": "geo",
|
108
|
+
"uri": "/v1/geos/5647cff4050585829088f3d7",
|
109
|
+
"created_at": "2015-03-24T21:03:30Z"
|
110
|
+
}
|
111
|
+
```
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
## List existing Geos
|
117
|
+
|
118
|
+
### Definition
|
119
|
+
|
120
|
+
```ruby
|
121
|
+
Checkr::Geo.all
|
122
|
+
```
|
123
|
+
|
124
|
+
### Example Request
|
125
|
+
|
126
|
+
```ruby
|
127
|
+
require 'checkr' # Note the gem is named checkr-official
|
128
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
129
|
+
|
130
|
+
geos = Checkr::Geo.all
|
131
|
+
```
|
132
|
+
|
133
|
+
### Example Response
|
134
|
+
|
135
|
+
```ruby
|
136
|
+
#<Checkr::APIList:0x3fd90c175b54> JSON: {
|
137
|
+
"object": "list",
|
138
|
+
"data": [
|
139
|
+
#<Checkr::Geo:0x3fd90c17567c id=87f5bb4983eade22c55f4731> JSON: {
|
140
|
+
"name": "San Francisco",
|
141
|
+
"state": "CA",
|
142
|
+
"id": "87f5bb4983eade22c55f4731",
|
143
|
+
"object": "geo",
|
144
|
+
"uri": "/v1/geos/87f5bb4983eade22c55f4731",
|
145
|
+
"created_at": "2015-03-24T21:05:48Z"
|
146
|
+
},
|
147
|
+
...
|
148
|
+
]
|
149
|
+
}
|
150
|
+
```
|
@@ -0,0 +1,136 @@
|
|
1
|
+
# Motor Vehicle Report
|
2
|
+
|
3
|
+
## The Motor Vehicle Report Object
|
4
|
+
|
5
|
+
### Example Response
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
#<Checkr::MotorVehicleReport:0x3fd90c0e05f4 id=539fd88c101897f7cd000007> JSON: {
|
9
|
+
"status": "consider",
|
10
|
+
"completed_at": "2014-01-18T12:35:30Z",
|
11
|
+
"turnaround_time": 90,
|
12
|
+
"full_name": "John Alfred Smith",
|
13
|
+
"license_number": "F2111132",
|
14
|
+
"license_state": "CA",
|
15
|
+
"previous_license_number": null,
|
16
|
+
"previous_license_state": null,
|
17
|
+
"license_status": "valid",
|
18
|
+
"license_type": "non-commercial",
|
19
|
+
"license_class": "C",
|
20
|
+
"expiration_date": "2016-07-24",
|
21
|
+
"issued_date": "2006-12-03",
|
22
|
+
"first_issued_date": "2000-01-14",
|
23
|
+
"inferred_issued_date": null,
|
24
|
+
"restrictions": null,
|
25
|
+
"accidents": [
|
26
|
+
{
|
27
|
+
"accident_date": "2009-04-12",
|
28
|
+
"description": "property damage",
|
29
|
+
"city": null,
|
30
|
+
"county": "SAN FRANCISCO",
|
31
|
+
"state": null,
|
32
|
+
"order_number": "33-435932",
|
33
|
+
"points": null,
|
34
|
+
"vehicle_speed": null,
|
35
|
+
"reinstatement_date": null,
|
36
|
+
"action_taken": "police report filed",
|
37
|
+
"ticket_number": null,
|
38
|
+
"enforcing_agency": "San Francisco PD",
|
39
|
+
"jurisdiction": null,
|
40
|
+
"severity": null,
|
41
|
+
"violation_number": null,
|
42
|
+
"license_plate": "6UM6938",
|
43
|
+
"fine_amount": null,
|
44
|
+
"acd_code": null,
|
45
|
+
"state_code": null,
|
46
|
+
"additional_info": null,
|
47
|
+
"injury_accident": false,
|
48
|
+
"fatality_accident": false,
|
49
|
+
"fatality_count": 0,
|
50
|
+
"injury_count": 0,
|
51
|
+
"vehicles_involved_count": 1,
|
52
|
+
"report_number": null,
|
53
|
+
"policy_number": null
|
54
|
+
}
|
55
|
+
],
|
56
|
+
"violations": [
|
57
|
+
{
|
58
|
+
"type": "conviction",
|
59
|
+
"issued_date": "2011-11-14",
|
60
|
+
"conviction_date": "2010-04-11",
|
61
|
+
"description": "speeding 15-19 mph",
|
62
|
+
"points": 0,
|
63
|
+
"city": null,
|
64
|
+
"county": "SANTA CLARA",
|
65
|
+
"state": "California",
|
66
|
+
"ticket_number": "2D55555",
|
67
|
+
"disposition": null,
|
68
|
+
"category": null,
|
69
|
+
"avd_category_id": null,
|
70
|
+
"court_name": null,
|
71
|
+
"acd_code": null,
|
72
|
+
"state_code": null,
|
73
|
+
"docket": null,
|
74
|
+
"additional_info": null
|
75
|
+
}
|
76
|
+
],
|
77
|
+
"id": "539fd88c101897f7cd000007",
|
78
|
+
"object": "motor_vehicle_report",
|
79
|
+
"uri": "/v1/motor_vehicle_reports/539fd88c101897f7cd000007",
|
80
|
+
"created_at": "2014-01-18T12:34:00Z"
|
81
|
+
}
|
82
|
+
```
|
83
|
+
|
84
|
+
|
85
|
+
|
86
|
+
## Retrieve an existing Motor Vehicle Report
|
87
|
+
|
88
|
+
### Definition
|
89
|
+
|
90
|
+
```ruby
|
91
|
+
Checkr::MotorVehicleReport.retrieve({MOTOR_VEHICLE_REPORT_ID})
|
92
|
+
```
|
93
|
+
|
94
|
+
### Example Request
|
95
|
+
|
96
|
+
```ruby
|
97
|
+
require 'checkr' # Note the gem is named checkr-official
|
98
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
99
|
+
|
100
|
+
mvr = Checkr::MotorVehicleReport.retrieve("539fd88c101897f7cd000007")
|
101
|
+
```
|
102
|
+
|
103
|
+
### Example Response
|
104
|
+
|
105
|
+
```ruby
|
106
|
+
#<Checkr::MotorVehicleReport:0x3fd909bd7550 id=539fd88c101897f7cd000007> JSON: {
|
107
|
+
"status": "pending",
|
108
|
+
"completed_at": null,
|
109
|
+
"turnaround_time": null,
|
110
|
+
"full_name": "",
|
111
|
+
"license_number": null,
|
112
|
+
"license_state": null,
|
113
|
+
"previous_license_number": null,
|
114
|
+
"previous_license_state": null,
|
115
|
+
"license_status": null,
|
116
|
+
"license_type": null,
|
117
|
+
"license_class": null,
|
118
|
+
"expiration_date": null,
|
119
|
+
"issued_date": null,
|
120
|
+
"first_issued_date": null,
|
121
|
+
"inferred_issued_date": null,
|
122
|
+
"restrictions": [
|
123
|
+
|
124
|
+
],
|
125
|
+
"accidents": [
|
126
|
+
|
127
|
+
],
|
128
|
+
"violations": [
|
129
|
+
|
130
|
+
],
|
131
|
+
"id": "539fd88c101897f7cd000007",
|
132
|
+
"object": "test_motor_vehicle_report",
|
133
|
+
"uri": "/v1/motor_vehicle_reports/539fd88c101897f7cd000007",
|
134
|
+
"created_at": "2014-06-17T05:56:28Z"
|
135
|
+
}
|
136
|
+
```
|
@@ -0,0 +1,56 @@
|
|
1
|
+
# National Criminal Search
|
2
|
+
|
3
|
+
## The National Criminal Search Object
|
4
|
+
|
5
|
+
### Example Response
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
#<Checkr::NationalCriminalSearch:0x3fd909bad78c id=539fd88c101897f7cd000006> JSON: {
|
9
|
+
"status": "pending",
|
10
|
+
"completed_at": null,
|
11
|
+
"turnaround_time": null,
|
12
|
+
"records": [
|
13
|
+
|
14
|
+
],
|
15
|
+
"id": "539fd88c101897f7cd000006",
|
16
|
+
"object": "test_national_criminal_search",
|
17
|
+
"uri": "/v1/national_criminal_searches/539fd88c101897f7cd000006",
|
18
|
+
"created_at": "2014-06-17T05:56:28Z"
|
19
|
+
}
|
20
|
+
```
|
21
|
+
|
22
|
+
|
23
|
+
|
24
|
+
## Retrieve an existing National Criminal Search
|
25
|
+
|
26
|
+
### Definition
|
27
|
+
|
28
|
+
```ruby
|
29
|
+
Checkr::NationalCriminalSearch.retrieve({NATIONAL_CRIMINAL_SEARCH_ID})
|
30
|
+
```
|
31
|
+
|
32
|
+
### Example Request
|
33
|
+
|
34
|
+
```ruby
|
35
|
+
require 'checkr' # Note the gem is named checkr-official
|
36
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
37
|
+
|
38
|
+
ncs = Checkr::NationalCriminalSearch.retrieve("539fd88c101897f7cd000006")
|
39
|
+
```
|
40
|
+
|
41
|
+
### Example Response
|
42
|
+
|
43
|
+
```ruby
|
44
|
+
#<Checkr::NationalCriminalSearch:0x3fd909bad78c id=539fd88c101897f7cd000006> JSON: {
|
45
|
+
"status": "pending",
|
46
|
+
"completed_at": null,
|
47
|
+
"turnaround_time": null,
|
48
|
+
"records": [
|
49
|
+
|
50
|
+
],
|
51
|
+
"id": "539fd88c101897f7cd000006",
|
52
|
+
"object": "test_national_criminal_search",
|
53
|
+
"uri": "/v1/national_criminal_searches/539fd88c101897f7cd000006",
|
54
|
+
"created_at": "2014-06-17T05:56:28Z"
|
55
|
+
}
|
56
|
+
```
|
data/samples/report.md
ADDED
@@ -0,0 +1,158 @@
|
|
1
|
+
# Report
|
2
|
+
|
3
|
+
## The Report Object
|
4
|
+
|
5
|
+
### Example Response
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
#<Checkr::Report:0x3fd909f15938 id=4722c07dd9a10c3985ae432a> JSON: {
|
9
|
+
"status": "pending",
|
10
|
+
"values": null,
|
11
|
+
"completed_at": null,
|
12
|
+
"turnaround_time": null,
|
13
|
+
"package": "driver_plus",
|
14
|
+
"candidate": {"documents":{"object":"list","data":[]},"id":"e44aa283528e6fde7d542194"},
|
15
|
+
"ssn_trace": {"id":"53ab44eb0189e72f1500003b"},
|
16
|
+
"sex_offender_search": {"id":"53ab44eb0189e72f15000046"},
|
17
|
+
"national_criminal_search": {"id":"53ab44eb0189e72f15000044"},
|
18
|
+
"terrorist_watchlist_search": {"id":"54aa27ef3662630006000000"},
|
19
|
+
"county_criminal_searches": {"object":"list","data":[{"id":"539fdcf335644a0ef4000001"},{"id":"54aa27f1316231009c000000"},{"id":"5508ba3b66366305a2000000"}]},
|
20
|
+
"motor_vehicle_report": {"id":"53ab44eb0189e72f15000045"},
|
21
|
+
"id": "4722c07dd9a10c3985ae432a",
|
22
|
+
"object": "test_report",
|
23
|
+
"uri": "/v1/reports/4722c07dd9a10c3985ae432a",
|
24
|
+
"created_at": "2014-06-17T05:56:28Z"
|
25
|
+
}
|
26
|
+
```
|
27
|
+
|
28
|
+
|
29
|
+
|
30
|
+
## Create a new Report
|
31
|
+
|
32
|
+
### Definition
|
33
|
+
|
34
|
+
```ruby
|
35
|
+
Checkr::Report.create
|
36
|
+
```
|
37
|
+
|
38
|
+
### Example Request
|
39
|
+
|
40
|
+
```ruby
|
41
|
+
require 'checkr' # Note the gem is named checkr-official
|
42
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
43
|
+
|
44
|
+
candidate = Checkr::Candidate.retrieve("e44aa283528e6fde7d542194")
|
45
|
+
report = Checkr::Report.create({
|
46
|
+
:package => "driver_plus",
|
47
|
+
:candidate_id => candidate.id
|
48
|
+
})
|
49
|
+
```
|
50
|
+
|
51
|
+
### Example Response
|
52
|
+
|
53
|
+
```ruby
|
54
|
+
#<Checkr::Report:0x3fd909d5cee8 id=3fe1e58b1697d6fed2c65c0e> JSON: {
|
55
|
+
"status": "pending",
|
56
|
+
"values": null,
|
57
|
+
"completed_at": null,
|
58
|
+
"turnaround_time": null,
|
59
|
+
"package": "driver_plus",
|
60
|
+
"candidate": {"documents":{"object":"list","data":[]},"id":"e44aa283528e6fde7d542194"},
|
61
|
+
"ssn_trace": {"id":"5511cdbf613766000b840400"},
|
62
|
+
"sex_offender_search": {"id":"5511cdbf613766000b8d0400"},
|
63
|
+
"national_criminal_search": {"id":"5511cdbf613766000b8b0400"},
|
64
|
+
"terrorist_watchlist_search": {"id":"5511cdbf613766000b8e0400"},
|
65
|
+
"county_criminal_searches": {"object":"list","data":[]},
|
66
|
+
"motor_vehicle_report": {"id":"5511cdbf613766000b8c0400"},
|
67
|
+
"id": "3fe1e58b1697d6fed2c65c0e",
|
68
|
+
"object": "test_report",
|
69
|
+
"uri": "/v1/reports/3fe1e58b1697d6fed2c65c0e",
|
70
|
+
"created_at": "2015-03-24T20:49:03Z"
|
71
|
+
}
|
72
|
+
```
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
## Retrieve an existing Report
|
77
|
+
|
78
|
+
### Definition
|
79
|
+
|
80
|
+
```ruby
|
81
|
+
Checkr::Report.retrieve({REPORT_ID})
|
82
|
+
```
|
83
|
+
|
84
|
+
### Example Request
|
85
|
+
|
86
|
+
```ruby
|
87
|
+
require 'checkr' # Note the gem is named checkr-official
|
88
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
89
|
+
|
90
|
+
report = Checkr::Report.retrieve("4722c07dd9a10c3985ae432a")
|
91
|
+
```
|
92
|
+
|
93
|
+
### Example Response
|
94
|
+
|
95
|
+
```ruby
|
96
|
+
#<Checkr::Report:0x3fd909a57edc id=4722c07dd9a10c3985ae432a> JSON: {
|
97
|
+
"status": "pending",
|
98
|
+
"values": null,
|
99
|
+
"completed_at": null,
|
100
|
+
"turnaround_time": null,
|
101
|
+
"package": "driver_plus",
|
102
|
+
"candidate": {"documents":{"object":"list","data":[]},"id":"e44aa283528e6fde7d542194"},
|
103
|
+
"ssn_trace": {"id":"53ab44eb0189e72f1500003b"},
|
104
|
+
"sex_offender_search": {"id":"53ab44eb0189e72f15000046"},
|
105
|
+
"national_criminal_search": {"id":"53ab44eb0189e72f15000044"},
|
106
|
+
"terrorist_watchlist_search": {"id":"54aa27ef3662630006000000"},
|
107
|
+
"county_criminal_searches": {"object":"list","data":[{"id":"539fdcf335644a0ef4000001"},{"id":"54aa27f1316231009c000000"},{"id":"5508ba3b66366305a2000000"}]},
|
108
|
+
"motor_vehicle_report": {"id":"53ab44eb0189e72f15000045"},
|
109
|
+
"id": "4722c07dd9a10c3985ae432a",
|
110
|
+
"object": "test_report",
|
111
|
+
"uri": "/v1/reports/4722c07dd9a10c3985ae432a",
|
112
|
+
"created_at": "2014-06-17T05:56:28Z"
|
113
|
+
}
|
114
|
+
```
|
115
|
+
|
116
|
+
## Update an existing Report
|
117
|
+
|
118
|
+
### Definition
|
119
|
+
|
120
|
+
```ruby
|
121
|
+
report = Checkr::Report.retrieve({REPORT_ID})
|
122
|
+
report.package = {NEW_PACKAGE}
|
123
|
+
report.save
|
124
|
+
```
|
125
|
+
|
126
|
+
### Example Request
|
127
|
+
|
128
|
+
```ruby
|
129
|
+
require 'checkr' # Note the gem is named checkr-official
|
130
|
+
Checkr.api_key = "83ebeabdec09f6670863766f792ead24d61fe3f9"
|
131
|
+
|
132
|
+
report = Checkr::Report.retrieve("4722c07dd9a10c3985ae432a")
|
133
|
+
report.package = "driver_plus"
|
134
|
+
report.save
|
135
|
+
```
|
136
|
+
|
137
|
+
### Example Response
|
138
|
+
|
139
|
+
```ruby
|
140
|
+
#<Checkr::Report:0x3fd909d21cf8 id=4722c07dd9a10c3985ae432a> JSON: {
|
141
|
+
"status": "pending",
|
142
|
+
"values": null,
|
143
|
+
"completed_at": null,
|
144
|
+
"turnaround_time": null,
|
145
|
+
"package": "driver_plus",
|
146
|
+
"candidate": {"documents":{"object":"list","data":[]},"id":"e44aa283528e6fde7d542194"},
|
147
|
+
"ssn_trace": {"id":"53ab44eb0189e72f1500003b"},
|
148
|
+
"sex_offender_search": {"id":"53ab44eb0189e72f15000046"},
|
149
|
+
"national_criminal_search": {"id":"53ab44eb0189e72f15000044"},
|
150
|
+
"terrorist_watchlist_search": {"id":"54aa27ef3662630006000000"},
|
151
|
+
"county_criminal_searches": {"object":"list","data":[{"id":"539fdcf335644a0ef4000001"},{"id":"54aa27f1316231009c000000"},{"id":"5508ba3b66366305a2000000"}]},
|
152
|
+
"motor_vehicle_report": {"id":"53ab44eb0189e72f15000045"},
|
153
|
+
"id": "4722c07dd9a10c3985ae432a",
|
154
|
+
"object": "test_report",
|
155
|
+
"uri": "/v1/reports/4722c07dd9a10c3985ae432a",
|
156
|
+
"created_at": "2014-06-17T05:56:28Z"
|
157
|
+
}
|
158
|
+
```
|