turbot 0.0.9 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +15 -0
- data/lib/turbot/command/bots.rb +11 -19
- data/lib/turbot/version.rb +1 -1
- metadata +8 -42
- data/schema/schemas/company-schema.json +0 -112
- data/schema/schemas/includes/address.json +0 -23
- data/schema/schemas/includes/base-statement.json +0 -27
- data/schema/schemas/includes/company.json +0 -14
- data/schema/schemas/includes/filing.json +0 -20
- data/schema/schemas/includes/license-data.json +0 -27
- data/schema/schemas/includes/officer.json +0 -14
- data/schema/schemas/includes/previous_name.json +0 -11
- data/schema/schemas/includes/share-parcel-data.json +0 -67
- data/schema/schemas/includes/share-parcel.json +0 -60
- data/schema/schemas/includes/subsidiary-relationship-data.json +0 -52
- data/schema/schemas/includes/total-shares.json +0 -10
- data/schema/schemas/licence-schema.json +0 -21
- data/schema/schemas/primary-data-schema.json +0 -17
- data/schema/schemas/share-parcel-schema.json +0 -21
- data/schema/schemas/subsidiary-relationship-schema.json +0 -19
checksums.yaml
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
---
|
2
|
+
!binary "U0hBMQ==":
|
3
|
+
metadata.gz: !binary |-
|
4
|
+
MDkzYjBhNWJkZGQ0OTJhN2U1NzI5Yzk5M2E5MjlkYTE0YzUxY2Q4ZA==
|
5
|
+
data.tar.gz: !binary |-
|
6
|
+
YzI4OTE4MTZiOWFmMmMyYTJmN2RlNjI3YjZkNmZmNTRjNmRhZmUwOQ==
|
7
|
+
SHA512:
|
8
|
+
metadata.gz: !binary |-
|
9
|
+
ZGRmMTEzNDU5YzIzNGFhMmYwNTllYjk5YzM5YjU1ZWVhYWRmZTFjNmJkMDgw
|
10
|
+
N2ExYzhmZGUyYzg4MGE0YjIwMDA5M2FjOGUyYzI5MmY5NDA0Yzg1ODk2N2E1
|
11
|
+
YmE4YmQ1OTI1OWNmY2I1MjVhODNkOGY5MDhiNzVhMmUyNGQzZTU=
|
12
|
+
data.tar.gz: !binary |-
|
13
|
+
MWM0Zjg1MmVhZDk5MjMzZTMxZjljN2NjZTdlNzZkZTllMjFiNzBkNzhiNTJh
|
14
|
+
MjJjZGM2YjVmNzMyNGZlM2FkNTQyMDk1YzAyNjUzZTBkM2Q3MWYwNGUxZjJj
|
15
|
+
OTBmZjU2NTRhZjMxNjEzYTNjOWVhZmQ2ZjQzMjk0NDJkY2Y2N2E=
|
data/lib/turbot/command/bots.rb
CHANGED
@@ -96,35 +96,27 @@ class Turbot::Command::Bots < Turbot::Command::Base
|
|
96
96
|
validate_arguments!
|
97
97
|
language = options[:language] || "ruby"
|
98
98
|
puts "Generating #{language} code..."
|
99
|
+
FileUtils.mkdir(bot)
|
100
|
+
case language
|
101
|
+
when "ruby"
|
102
|
+
scraper = "scraper.rb"
|
103
|
+
when "python"
|
104
|
+
scraper = "scraper.py"
|
105
|
+
end
|
99
106
|
manifest_template = File.expand_path("../../../../templates/manifest.json", __FILE__)
|
100
|
-
scraper_template = File.expand_path("../../../../templates/#{
|
107
|
+
scraper_template = File.expand_path("../../../../templates/#{scraper}", __FILE__)
|
101
108
|
license_template = File.expand_path("../../../../templates/LICENSE.txt", __FILE__)
|
102
109
|
manifest = JSON.parse(open(manifest_template).read.sub(/{{bot_id}}/, bot))
|
103
110
|
|
104
|
-
#
|
105
|
-
FileUtils.cp(scraper_template, bot)
|
106
|
-
|
107
|
-
# Same for all languages
|
111
|
+
FileUtils.cp(scraper_template, "#{bot}/#{scraper}")
|
108
112
|
FileUtils.cp(license_template, "#{bot}/LICENSE.txt")
|
109
113
|
open("#{bot}/manifest.json", "w") do |f|
|
110
|
-
f.write(
|
111
|
-
end
|
112
|
-
|
113
|
-
if language == "ruby"
|
114
|
-
FileUtils.chdir(bot)
|
115
|
-
Open3::popen3("bundle", options) do |_, stdout, stderr, wait_thread|
|
116
|
-
status = wait_thread.value.exitstatus
|
117
|
-
if status > 0
|
118
|
-
message = "Bundle failed!"
|
119
|
-
message += stderr.read()
|
120
|
-
error(message)
|
121
|
-
end
|
122
|
-
end
|
114
|
+
f.write(manifest.to_json)
|
123
115
|
end
|
124
116
|
|
125
117
|
api.create_bot(bot, manifest)
|
126
118
|
|
127
|
-
|
119
|
+
# TODO handle errors
|
128
120
|
|
129
121
|
puts "Created new bot template at #{bot}!"
|
130
122
|
end
|
data/lib/turbot/version.rb
CHANGED
metadata
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: turbot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
5
|
-
prerelease:
|
4
|
+
version: 0.0.10
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Turbot
|
@@ -14,7 +13,6 @@ dependencies:
|
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: netrc
|
16
15
|
requirement: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
16
|
requirements:
|
19
17
|
- - ~>
|
20
18
|
- !ruby/object:Gem::Version
|
@@ -22,7 +20,6 @@ dependencies:
|
|
22
20
|
type: :runtime
|
23
21
|
prerelease: false
|
24
22
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
-
none: false
|
26
23
|
requirements:
|
27
24
|
- - ~>
|
28
25
|
- !ruby/object:Gem::Version
|
@@ -30,7 +27,6 @@ dependencies:
|
|
30
27
|
- !ruby/object:Gem::Dependency
|
31
28
|
name: rest-client
|
32
29
|
requirement: !ruby/object:Gem::Requirement
|
33
|
-
none: false
|
34
30
|
requirements:
|
35
31
|
- - ~>
|
36
32
|
- !ruby/object:Gem::Version
|
@@ -38,7 +34,6 @@ dependencies:
|
|
38
34
|
type: :runtime
|
39
35
|
prerelease: false
|
40
36
|
version_requirements: !ruby/object:Gem::Requirement
|
41
|
-
none: false
|
42
37
|
requirements:
|
43
38
|
- - ~>
|
44
39
|
- !ruby/object:Gem::Version
|
@@ -46,7 +41,6 @@ dependencies:
|
|
46
41
|
- !ruby/object:Gem::Dependency
|
47
42
|
name: launchy
|
48
43
|
requirement: !ruby/object:Gem::Requirement
|
49
|
-
none: false
|
50
44
|
requirements:
|
51
45
|
- - ! '>='
|
52
46
|
- !ruby/object:Gem::Version
|
@@ -54,7 +48,6 @@ dependencies:
|
|
54
48
|
type: :runtime
|
55
49
|
prerelease: false
|
56
50
|
version_requirements: !ruby/object:Gem::Requirement
|
57
|
-
none: false
|
58
51
|
requirements:
|
59
52
|
- - ! '>='
|
60
53
|
- !ruby/object:Gem::Version
|
@@ -62,7 +55,6 @@ dependencies:
|
|
62
55
|
- !ruby/object:Gem::Dependency
|
63
56
|
name: rubyzip
|
64
57
|
requirement: !ruby/object:Gem::Requirement
|
65
|
-
none: false
|
66
58
|
requirements:
|
67
59
|
- - ! '>='
|
68
60
|
- !ruby/object:Gem::Version
|
@@ -70,7 +62,6 @@ dependencies:
|
|
70
62
|
type: :runtime
|
71
63
|
prerelease: false
|
72
64
|
version_requirements: !ruby/object:Gem::Requirement
|
73
|
-
none: false
|
74
65
|
requirements:
|
75
66
|
- - ! '>='
|
76
67
|
- !ruby/object:Gem::Version
|
@@ -78,7 +69,6 @@ dependencies:
|
|
78
69
|
- !ruby/object:Gem::Dependency
|
79
70
|
name: json-schema
|
80
71
|
requirement: !ruby/object:Gem::Requirement
|
81
|
-
none: false
|
82
72
|
requirements:
|
83
73
|
- - ! '>='
|
84
74
|
- !ruby/object:Gem::Version
|
@@ -86,7 +76,6 @@ dependencies:
|
|
86
76
|
type: :runtime
|
87
77
|
prerelease: false
|
88
78
|
version_requirements: !ruby/object:Gem::Requirement
|
89
|
-
none: false
|
90
79
|
requirements:
|
91
80
|
- - ! '>='
|
92
81
|
- !ruby/object:Gem::Version
|
@@ -94,23 +83,20 @@ dependencies:
|
|
94
83
|
- !ruby/object:Gem::Dependency
|
95
84
|
name: activesupport
|
96
85
|
requirement: !ruby/object:Gem::Requirement
|
97
|
-
none: false
|
98
86
|
requirements:
|
99
|
-
- -
|
87
|
+
- - '='
|
100
88
|
- !ruby/object:Gem::Version
|
101
|
-
version:
|
89
|
+
version: 3.2.17
|
102
90
|
type: :runtime
|
103
91
|
prerelease: false
|
104
92
|
version_requirements: !ruby/object:Gem::Requirement
|
105
|
-
none: false
|
106
93
|
requirements:
|
107
|
-
- -
|
94
|
+
- - '='
|
108
95
|
- !ruby/object:Gem::Version
|
109
|
-
version:
|
96
|
+
version: 3.2.17
|
110
97
|
- !ruby/object:Gem::Dependency
|
111
98
|
name: turbot-api
|
112
99
|
requirement: !ruby/object:Gem::Requirement
|
113
|
-
none: false
|
114
100
|
requirements:
|
115
101
|
- - ! '>='
|
116
102
|
- !ruby/object:Gem::Version
|
@@ -118,7 +104,6 @@ dependencies:
|
|
118
104
|
type: :runtime
|
119
105
|
prerelease: false
|
120
106
|
version_requirements: !ruby/object:Gem::Requirement
|
121
|
-
none: false
|
122
107
|
requirements:
|
123
108
|
- - ! '>='
|
124
109
|
- !ruby/object:Gem::Version
|
@@ -126,7 +111,6 @@ dependencies:
|
|
126
111
|
- !ruby/object:Gem::Dependency
|
127
112
|
name: excon
|
128
113
|
requirement: !ruby/object:Gem::Requirement
|
129
|
-
none: false
|
130
114
|
requirements:
|
131
115
|
- - ! '>='
|
132
116
|
- !ruby/object:Gem::Version
|
@@ -134,7 +118,6 @@ dependencies:
|
|
134
118
|
type: :runtime
|
135
119
|
prerelease: false
|
136
120
|
version_requirements: !ruby/object:Gem::Requirement
|
137
|
-
none: false
|
138
121
|
requirements:
|
139
122
|
- - ! '>='
|
140
123
|
- !ruby/object:Gem::Version
|
@@ -216,45 +199,28 @@ files:
|
|
216
199
|
- templates/manifest.json
|
217
200
|
- templates/python/scraper.py
|
218
201
|
- templates/ruby/scraper.rb
|
219
|
-
- schema/schemas/company-schema.json
|
220
|
-
- schema/schemas/includes/address.json
|
221
|
-
- schema/schemas/includes/base-statement.json
|
222
|
-
- schema/schemas/includes/company.json
|
223
|
-
- schema/schemas/includes/filing.json
|
224
|
-
- schema/schemas/includes/license-data.json
|
225
|
-
- schema/schemas/includes/officer.json
|
226
|
-
- schema/schemas/includes/previous_name.json
|
227
|
-
- schema/schemas/includes/share-parcel-data.json
|
228
|
-
- schema/schemas/includes/share-parcel.json
|
229
|
-
- schema/schemas/includes/subsidiary-relationship-data.json
|
230
|
-
- schema/schemas/includes/total-shares.json
|
231
|
-
- schema/schemas/licence-schema.json
|
232
|
-
- schema/schemas/primary-data-schema.json
|
233
|
-
- schema/schemas/share-parcel-schema.json
|
234
|
-
- schema/schemas/subsidiary-relationship-schema.json
|
235
202
|
homepage: http://turbot.com/
|
236
203
|
licenses:
|
237
204
|
- MIT
|
205
|
+
metadata: {}
|
238
206
|
post_install_message:
|
239
207
|
rdoc_options: []
|
240
208
|
require_paths:
|
241
209
|
- lib
|
242
210
|
required_ruby_version: !ruby/object:Gem::Requirement
|
243
|
-
none: false
|
244
211
|
requirements:
|
245
212
|
- - ! '>='
|
246
213
|
- !ruby/object:Gem::Version
|
247
214
|
version: 1.9.2
|
248
215
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
249
|
-
none: false
|
250
216
|
requirements:
|
251
217
|
- - ! '>='
|
252
218
|
- !ruby/object:Gem::Version
|
253
219
|
version: '0'
|
254
220
|
requirements: []
|
255
221
|
rubyforge_project:
|
256
|
-
rubygems_version:
|
222
|
+
rubygems_version: 2.2.2
|
257
223
|
signing_key:
|
258
|
-
specification_version:
|
224
|
+
specification_version: 4
|
259
225
|
summary: Client library and CLI to deploy apps on Turbot.
|
260
226
|
test_files: []
|
@@ -1,112 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"$schema": "http://json-schema.org/draft-04/schema#",
|
3
|
-
"title": "Company Schema",
|
4
|
-
"type": "object",
|
5
|
-
"description": "A company in OpenCorporates",
|
6
|
-
"properties": {
|
7
|
-
"company_number": {
|
8
|
-
"type": "string",
|
9
|
-
"minLength": 1
|
10
|
-
},
|
11
|
-
"name": {
|
12
|
-
"type": "string",
|
13
|
-
"minLength": 1
|
14
|
-
},
|
15
|
-
"jurisdiction_code": {
|
16
|
-
"type": "string",
|
17
|
-
"minLength": 2,
|
18
|
-
"maxLength": 5
|
19
|
-
},
|
20
|
-
"incorporation_date": {
|
21
|
-
"type": "date"
|
22
|
-
},
|
23
|
-
"dissolution_date": {
|
24
|
-
"type": "date"
|
25
|
-
},
|
26
|
-
"retrieved_at": {
|
27
|
-
"type": "date-time"
|
28
|
-
},
|
29
|
-
"current_status": {
|
30
|
-
"type": "string"
|
31
|
-
},
|
32
|
-
"company_type": {
|
33
|
-
"type": "string"
|
34
|
-
},
|
35
|
-
"registry_url": {
|
36
|
-
"type": "string"
|
37
|
-
},
|
38
|
-
"registered_address": {
|
39
|
-
"$ref": "includes/address.json"
|
40
|
-
},
|
41
|
-
"officers": {
|
42
|
-
"type": "array",
|
43
|
-
"items": {
|
44
|
-
"$ref": "includes/officer.json"
|
45
|
-
}
|
46
|
-
},
|
47
|
-
"share_parcels": {
|
48
|
-
"type": "array",
|
49
|
-
"items": {
|
50
|
-
"$ref": "includes/share-parcel.json"
|
51
|
-
}
|
52
|
-
},
|
53
|
-
"total_shares": {
|
54
|
-
"$ref": "includes/total-shares.json"
|
55
|
-
},
|
56
|
-
"filings": {
|
57
|
-
"type": "array",
|
58
|
-
"items": {
|
59
|
-
"$ref": "includes/filing.json"
|
60
|
-
}
|
61
|
-
},
|
62
|
-
"previous_names": {
|
63
|
-
"type": "array",
|
64
|
-
"items": {
|
65
|
-
"$ref": "includes/previous_name.json"
|
66
|
-
}
|
67
|
-
},
|
68
|
-
"branch": {
|
69
|
-
"type": ["string","null"],
|
70
|
-
"description": "A flag to denote whether a company is a branch entity. This should only be set if the company is a type of branch (otherwise should be null). In general the only option here is 'F' for a 'Foreign' branch, i.e. an out-of-jurisdiction entity that has registered as having a presence in the jurisdiction. In the US this is sometimes called a Foreign Corporation",
|
71
|
-
"enum": ["F", "L",null]
|
72
|
-
},
|
73
|
-
"all_attributes": {
|
74
|
-
"type": "object",
|
75
|
-
"description": "Other arbitrary attributes for a given company",
|
76
|
-
"properties": {
|
77
|
-
"jurisdiction_of_origin": {
|
78
|
-
"type": ["string","null"],
|
79
|
-
"description": "The jurisdiction of the 'home' company if this is a branch",
|
80
|
-
"minLength": 1
|
81
|
-
},
|
82
|
-
"home_company_number": {
|
83
|
-
"type": ["string","null"],
|
84
|
-
"description": "If the entity is a 'branch', this is the company_number of the 'home' company in the home company's jurisdiction",
|
85
|
-
"minLength": 1
|
86
|
-
},
|
87
|
-
"home_legal_name": {
|
88
|
-
"type": ["string","null"],
|
89
|
-
"description": "The legal name of the 'home' company in its jurisdiction if this is a branch, and the name is different from the legal name of the branch",
|
90
|
-
"minLength": 1
|
91
|
-
},
|
92
|
-
"registered_agent_address": {
|
93
|
-
"type": ["string","null"],
|
94
|
-
"description": "The address of the 'Agent', a public address to which legal papers can be served",
|
95
|
-
"minLength": 1
|
96
|
-
},
|
97
|
-
"registered_agent_name": {
|
98
|
-
"type": ["string","null"],
|
99
|
-
"description": "The 'Agent' of the company \u2013 a person or entity that is empowered to accept service for the company",
|
100
|
-
"minLength": 1
|
101
|
-
},
|
102
|
-
"number_of_employees": {
|
103
|
-
"type": "number",
|
104
|
-
"description": "The number of employees",
|
105
|
-
"minimum": 0
|
106
|
-
}
|
107
|
-
}
|
108
|
-
}
|
109
|
-
},
|
110
|
-
"additionalProperties": false,
|
111
|
-
"required": ["company_number", "name", "jurisdiction_code"]
|
112
|
-
}
|
@@ -1,23 +0,0 @@
|
|
1
|
-
{ "oneOf":
|
2
|
-
[
|
3
|
-
{
|
4
|
-
"type": ["string","null"],
|
5
|
-
"minLength": 2
|
6
|
-
},
|
7
|
-
{
|
8
|
-
"name": "Address",
|
9
|
-
"description": "An address object",
|
10
|
-
"type": "object",
|
11
|
-
"properties": { "street_address": { "type": "string" },
|
12
|
-
"locality": { "type": "date" },
|
13
|
-
"region": { "type": "string" },
|
14
|
-
"postal_code": { "type": "string" },
|
15
|
-
"country": { "type": "string" }
|
16
|
-
},
|
17
|
-
"anyOf": [ { "required": ["street_address"] },
|
18
|
-
{ "required": ["postal_code"] }
|
19
|
-
]
|
20
|
-
}
|
21
|
-
]
|
22
|
-
}
|
23
|
-
|
@@ -1,27 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "Base statement",
|
3
|
-
"description": "A base statement which must be extended by a schema to be used in OpenCorporates",
|
4
|
-
"type": "object",
|
5
|
-
"properties": {
|
6
|
-
"source_url": {
|
7
|
-
"description": "Place where this fact can be verified",
|
8
|
-
"type": "string"
|
9
|
-
},
|
10
|
-
"source_jurisdiction": {
|
11
|
-
"description": "Jurisdiction of the source of the data",
|
12
|
-
"type": "string"
|
13
|
-
},
|
14
|
-
"sample_date": {
|
15
|
-
"description": "Date on which this fact was known to be true",
|
16
|
-
"type": "string"
|
17
|
-
},
|
18
|
-
"company": {
|
19
|
-
"$ref" : "../includes/company.json"
|
20
|
-
},
|
21
|
-
"data": {
|
22
|
-
"type": "array",
|
23
|
-
"additionalItems": false
|
24
|
-
}
|
25
|
-
},
|
26
|
-
"required": ["source_url", "data", "sample_date", "company"]
|
27
|
-
}
|
@@ -1,14 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "Company",
|
3
|
-
"description": "A company which is the subject of a statement",
|
4
|
-
"type": "object",
|
5
|
-
"properties": {
|
6
|
-
"name": { "type": "string" },
|
7
|
-
"jurisdiction": { "type": "string" },
|
8
|
-
"identifier": {
|
9
|
-
"type": "string",
|
10
|
-
"pattern": "^[^/]+/[^/]+$"
|
11
|
-
}
|
12
|
-
},
|
13
|
-
"required": [ "name", "jurisdiction" ]
|
14
|
-
}
|
@@ -1,20 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "Filing",
|
3
|
-
"description": "A statutory filing",
|
4
|
-
"type": "object",
|
5
|
-
"properties": { "title": { "type": "string" },
|
6
|
-
"date": { "type": "date" },
|
7
|
-
"description": { "type": "string" },
|
8
|
-
"uid": { "type": "string" },
|
9
|
-
"url": { "type": "string" },
|
10
|
-
"filing_type_code": { "type": "string" },
|
11
|
-
"filing_type_name": { "type": "string" },
|
12
|
-
"other_attributes": { "type": "object" }
|
13
|
-
},
|
14
|
-
"required": [ "date" ],
|
15
|
-
"anyOf": [ { "required": ["title"] },
|
16
|
-
{ "required": ["description"] },
|
17
|
-
{ "required": ["filing_type_name"] }
|
18
|
-
]
|
19
|
-
}
|
20
|
-
|
@@ -1,27 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "License Data",
|
3
|
-
"type": "object",
|
4
|
-
"properties": {
|
5
|
-
"data_type": { "enum": [ "licence" ] },
|
6
|
-
"properties": {
|
7
|
-
"type": "object",
|
8
|
-
"properties": {
|
9
|
-
"regulator": {
|
10
|
-
"description": "The regulating body that issued the licence",
|
11
|
-
"type": "string"},
|
12
|
-
"jurisdiction_code": {
|
13
|
-
"description": "The jurisdiction for which licence was issued",
|
14
|
-
"type": "string"},
|
15
|
-
"licence_number": {
|
16
|
-
"type": "string"},
|
17
|
-
"jurisdiction_classification": {
|
18
|
-
"type": "array",
|
19
|
-
"minItems": 1},
|
20
|
-
"oc_classification": {
|
21
|
-
"type": "array"}
|
22
|
-
},
|
23
|
-
"required": [ "jurisdiction_code", "jurisdiction_classification" ]
|
24
|
-
}
|
25
|
-
},
|
26
|
-
"required": [ "data_type", "properties" ]
|
27
|
-
}
|
@@ -1,14 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "Officer",
|
3
|
-
"description": "An officer (director, senior executive) of a company",
|
4
|
-
"type": "object",
|
5
|
-
"properties": { "name": { "type": "string", "minLength": 1 },
|
6
|
-
"start_date": { "type": "date" },
|
7
|
-
"end_date": { "type": "date" },
|
8
|
-
"position": { "type": "string" },
|
9
|
-
"other_attributes": { "type": "object" },
|
10
|
-
"uid": { "type": "string" }
|
11
|
-
},
|
12
|
-
"required": [ "name" ]
|
13
|
-
}
|
14
|
-
|
@@ -1,11 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "PreviousName",
|
3
|
-
"description": "A previous name of a company",
|
4
|
-
"type": "object",
|
5
|
-
"properties": { "company_name": { "type": "string", "minLength": 1 },
|
6
|
-
"con_date": { "type": "date" },
|
7
|
-
"start_date": { "type": "date" }
|
8
|
-
},
|
9
|
-
"required": [ "company_name" ]
|
10
|
-
}
|
11
|
-
|
@@ -1,67 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "Share Parcel Data",
|
3
|
-
"type": "object",
|
4
|
-
"properties": {
|
5
|
-
"data_type": { "enum": [ "share_parcel" ] },
|
6
|
-
"properties": {
|
7
|
-
"type": "object",
|
8
|
-
"required": ["shareholders"],
|
9
|
-
"properties": {
|
10
|
-
"number_of_shares": {
|
11
|
-
"description": "Number of shares, if known",
|
12
|
-
"type": "integer"},
|
13
|
-
"percentage_of_shares": {
|
14
|
-
"description": "Percentage of shares, if known",
|
15
|
-
"type": "number",
|
16
|
-
"maximum": 100,
|
17
|
-
"minimum": 0
|
18
|
-
},
|
19
|
-
"shareholders": {
|
20
|
-
"description": "Legal persons who own this share parcel",
|
21
|
-
"type": "array",
|
22
|
-
"minItems": 1,
|
23
|
-
"items": {
|
24
|
-
"anyOf": [
|
25
|
-
{"type": "object",
|
26
|
-
"name": "person",
|
27
|
-
"required": ["name"],
|
28
|
-
"properties": {
|
29
|
-
"name": {
|
30
|
-
"description": "Name of natural person or company",
|
31
|
-
"type": "string"
|
32
|
-
},
|
33
|
-
"jurisdiction": {
|
34
|
-
"description": "Jurisdiction of registration, if company",
|
35
|
-
"type": "string"
|
36
|
-
},
|
37
|
-
"company_number": {
|
38
|
-
"description": "Company number, if company and known",
|
39
|
-
"type": "string"
|
40
|
-
},
|
41
|
-
"identifier": {
|
42
|
-
"description": "Unique identifier of person",
|
43
|
-
"type": "string"
|
44
|
-
},
|
45
|
-
"type": {
|
46
|
-
"description": "Type of person if known (company or natural person)",
|
47
|
-
"enum" : ["Company", "Person"]
|
48
|
-
},
|
49
|
-
"address": {
|
50
|
-
"description": "Address given for owner of parcel",
|
51
|
-
"type": "string"
|
52
|
-
},
|
53
|
-
"address_country": {
|
54
|
-
"description": "Country part of owner's address",
|
55
|
-
"type": "string"
|
56
|
-
}
|
57
|
-
|
58
|
-
}
|
59
|
-
}
|
60
|
-
]
|
61
|
-
}
|
62
|
-
}
|
63
|
-
}
|
64
|
-
}
|
65
|
-
},
|
66
|
-
"required": [ "data_type", "properties" ]
|
67
|
-
}
|
@@ -1,60 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "Share Parcel",
|
3
|
-
"type": "object",
|
4
|
-
"description": "A parcel of shares in a company",
|
5
|
-
"required": ["shareholders"],
|
6
|
-
"properties": {
|
7
|
-
"number_of_shares": {
|
8
|
-
"description": "Number of shares, if known",
|
9
|
-
"type": "integer"},
|
10
|
-
"percentage_of_shares": {
|
11
|
-
"description": "Percentage of shares, if known",
|
12
|
-
"type": "number",
|
13
|
-
"maximum": 100,
|
14
|
-
"minimum": 0
|
15
|
-
},
|
16
|
-
"shareholders": {
|
17
|
-
"description": "Legal persons who own this share parcel",
|
18
|
-
"type": "array",
|
19
|
-
"minItems": 1,
|
20
|
-
"items": {
|
21
|
-
"type": "object",
|
22
|
-
"name": "shareholder",
|
23
|
-
"required": ["name"],
|
24
|
-
"properties": {
|
25
|
-
"name": {
|
26
|
-
"description": "Name of natural person or company",
|
27
|
-
"type": "string",
|
28
|
-
"minLength": 1
|
29
|
-
},
|
30
|
-
"jurisdiction": {
|
31
|
-
"description": "Jurisdiction of registration, if company",
|
32
|
-
"type": "string"
|
33
|
-
},
|
34
|
-
"company_number": {
|
35
|
-
"description": "Company number, if company and known",
|
36
|
-
"type": "string"
|
37
|
-
},
|
38
|
-
"identifier": {
|
39
|
-
"description": "Unique identifier of person",
|
40
|
-
"type": "string"
|
41
|
-
},
|
42
|
-
"type": {
|
43
|
-
"description": "Type of person if known (company or natural person)",
|
44
|
-
"enum" : ["Company", "Person"]
|
45
|
-
},
|
46
|
-
"address": {
|
47
|
-
"description": "Address given for owner of parcel",
|
48
|
-
"type": "string"
|
49
|
-
},
|
50
|
-
"address_country": {
|
51
|
-
"description": "Country part of owner's address",
|
52
|
-
"type": "string"
|
53
|
-
}
|
54
|
-
|
55
|
-
}
|
56
|
-
}
|
57
|
-
}
|
58
|
-
},
|
59
|
-
"required": [ ]
|
60
|
-
}
|
@@ -1,52 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"name": "Share Parcel Data",
|
3
|
-
"type": "object",
|
4
|
-
"properties": {
|
5
|
-
"data_type": { "enum": [ "subsidiary_relationship" ] },
|
6
|
-
"properties": {
|
7
|
-
"type": "object",
|
8
|
-
"required": ["subsidiary"],
|
9
|
-
"additionalProperties": false,
|
10
|
-
"properties": {
|
11
|
-
"direct": {
|
12
|
-
"description": "If the control is direct (if via an intermediary, this value should be false; if unknown, left blank)",
|
13
|
-
"type": "boolean"},
|
14
|
-
"significant": {
|
15
|
-
"description": "Does the source define the control as somehow significant?",
|
16
|
-
"type": "boolean"},
|
17
|
-
"subsidiary": {
|
18
|
-
"description": "Company that is controlled",
|
19
|
-
"type": "object",
|
20
|
-
"required": ["name"],
|
21
|
-
"additionalProperties": false,
|
22
|
-
"properties": {
|
23
|
-
"name": {
|
24
|
-
"description": "Name of company",
|
25
|
-
"type": "string"
|
26
|
-
},
|
27
|
-
"jurisdiction": {
|
28
|
-
"description": "Jurisdiction of registration",
|
29
|
-
"type": "string"
|
30
|
-
},
|
31
|
-
"company_number": {
|
32
|
-
"description": "Company number, if company and known",
|
33
|
-
"type": "string"
|
34
|
-
},
|
35
|
-
"identifier": {
|
36
|
-
"description": "Unique identifier of person",
|
37
|
-
"type": "string"
|
38
|
-
},
|
39
|
-
"address": {
|
40
|
-
"description": "Address given for owner of parcel",
|
41
|
-
"type": "string"
|
42
|
-
},
|
43
|
-
"address_country": {
|
44
|
-
"description": "Country part of owner's address",
|
45
|
-
"type": "string"
|
46
|
-
}
|
47
|
-
}
|
48
|
-
}
|
49
|
-
}
|
50
|
-
}
|
51
|
-
}
|
52
|
-
}
|
@@ -1,21 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"$schema": "http://json-schema.org/draft-04/schema#",
|
3
|
-
"title": "Licence Schema",
|
4
|
-
"type": "object",
|
5
|
-
"allOf" : [
|
6
|
-
// The following is a basic statement with sample_date, etc
|
7
|
-
{ "$ref": "includes/base-statement.json" },
|
8
|
-
// And this overrides it to provide data-type-specific information
|
9
|
-
{
|
10
|
-
"properties": {
|
11
|
-
"data": {
|
12
|
-
"items": {
|
13
|
-
"allOf": [
|
14
|
-
{ "$ref": "includes/license-data.json" }
|
15
|
-
]
|
16
|
-
}
|
17
|
-
}
|
18
|
-
}
|
19
|
-
}
|
20
|
-
]
|
21
|
-
}
|
@@ -1,17 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"$schema": "http://json-schema.org/draft-04/schema#",
|
3
|
-
"title": "Primary Data Schema",
|
4
|
-
"type": "object",
|
5
|
-
"properties": {
|
6
|
-
"source_url": {
|
7
|
-
"description": "Place where this fact can be verified",
|
8
|
-
"type": "string"
|
9
|
-
},
|
10
|
-
"sample_date": {
|
11
|
-
"description": "Date on which this fact was known to be true",
|
12
|
-
"type": "string"
|
13
|
-
}
|
14
|
-
},
|
15
|
-
"required": ["source_url", "sample_date"],
|
16
|
-
"additionalProperties": true
|
17
|
-
}
|
@@ -1,21 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"$schema": "http://json-schema.org/draft-04/schema#",
|
3
|
-
"title": "Share Parcel Schema",
|
4
|
-
"type": "object",
|
5
|
-
"allOf" : [
|
6
|
-
// The following is a basic statement with sample_date, etc
|
7
|
-
{ "$ref": "includes/base-statement.json" },
|
8
|
-
// And this overrides it to provide data-type-specific information
|
9
|
-
{
|
10
|
-
"properties": {
|
11
|
-
"data": {
|
12
|
-
"items": {
|
13
|
-
"allOf": [
|
14
|
-
{ "$ref": "includes/share-parcel-data.json" }
|
15
|
-
]
|
16
|
-
}
|
17
|
-
}
|
18
|
-
}
|
19
|
-
}
|
20
|
-
]
|
21
|
-
}
|
@@ -1,19 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"$schema": "http://json-schema.org/draft-04/schema#",
|
3
|
-
"title": "Subsidiary Relationship Schema",
|
4
|
-
"type": "object",
|
5
|
-
"allOf" : [
|
6
|
-
{ "$ref": "includes/base-statement.json" },
|
7
|
-
{
|
8
|
-
"properties": {
|
9
|
-
"data": {
|
10
|
-
"items": {
|
11
|
-
"allOf": [
|
12
|
-
{ "$ref": "includes/subsidiary-relationship-data.json" }
|
13
|
-
]
|
14
|
-
}
|
15
|
-
}
|
16
|
-
}
|
17
|
-
}
|
18
|
-
]
|
19
|
-
}
|