kendama 0.2.3 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
data/openapi/root.yaml ADDED
@@ -0,0 +1,17 @@
1
+ openapi: 3.0.3
2
+ info:
3
+ title: 国税庁API
4
+ description: 国税庁が提供するインボイス制度適格請求書発行事業者公表システムWeb-APIを使用するためのクライアントAPI(https://www.invoice-kohyo.nta.go.jp/web-api/index.html)
5
+ version: 1.0.0
6
+ servers:
7
+ - url: https://kensyo.invoice-kohyo.nta.go.jp/
8
+ description: 検証環境
9
+ - url: https://web-api.invoice-kohyo.nta.go.jp/
10
+ description: 本番環境
11
+ paths:
12
+ "/1/num":
13
+ $ref: "./v1/num.yaml#/paths/~11~1num"
14
+ "/1/diff":
15
+ $ref: "./v1/diff.yaml#/paths/~11~1diff"
16
+ "/1/valid":
17
+ $ref: "./v1/valid.yaml#/paths/~11~1valid"
@@ -0,0 +1,179 @@
1
+ components:
2
+ schemas:
3
+ ResponseBody:
4
+ type: object
5
+ properties:
6
+ lastUpdateDate:
7
+ type: string
8
+ description: 最終更新年月日
9
+ example: "2021-11-01"
10
+ format: date
11
+ count:
12
+ type: string
13
+ description: 総件数
14
+ example: 1
15
+ minLength: 1
16
+ maxLength: 8
17
+ divideNumber:
18
+ type: string
19
+ description: 分割番号
20
+ example: 1
21
+ minLength: 1
22
+ maxLength: 6
23
+ divideSize:
24
+ type: string
25
+ description: 分割数
26
+ example: 1
27
+ minLength: 1
28
+ maxLength: 6
29
+ announcement:
30
+ type: array
31
+ items:
32
+ $ref: "#/components/schemas/Announcement"
33
+
34
+ Announcement:
35
+ type: object
36
+ properties:
37
+ sequenceNumber:
38
+ type: string
39
+ description: 一連番号
40
+ example: 1
41
+ minLength: 1
42
+ maxLength: 8
43
+ registratedNumber:
44
+ type: string
45
+ description: 登録番号
46
+ example: T8040001999011
47
+ process:
48
+ type: string
49
+ description: 事業者処理区分
50
+ example: 01
51
+ enum:
52
+ - "01"
53
+ - "02"
54
+ - "03"
55
+ - "04"
56
+ - "99"
57
+ correct:
58
+ type: string
59
+ description: 訂正区分
60
+ example: 0
61
+ enum:
62
+ - 0
63
+ - 1
64
+ - ""
65
+ kind:
66
+ type: string
67
+ description: 人格区分
68
+ example: 2
69
+ enum:
70
+ - 1
71
+ - 2
72
+ country:
73
+ type: string
74
+ description: 国内外区分
75
+ example: 1
76
+ enum:
77
+ - 1
78
+ - 2
79
+ - 3
80
+ latest:
81
+ type: string
82
+ description: 最新履歴
83
+ example: 1
84
+ enum:
85
+ - 0
86
+ - 1
87
+ registrationDate:
88
+ type: string
89
+ description: 登録年月日
90
+ example: "2023-10-01"
91
+ format: date
92
+ updateDate:
93
+ type: string
94
+ description: 更新年月日
95
+ example: "2021-11-01"
96
+ format: date
97
+ disposalDate:
98
+ type: string
99
+ description: 取消年月日
100
+ expireDate:
101
+ type: string
102
+ description: 失効年月日
103
+ address:
104
+ type: string
105
+ description: 本店又は主たる事務所の所在地(法人)
106
+ example: 北海道札幌市中央区大通西10丁目
107
+ maxLength: 600
108
+ addressPrefectureCode:
109
+ type: string
110
+ description: 本店又は主たる事務所の所在地都道府県コード(法人)
111
+ example: 01
112
+ addressCityCode:
113
+ type: string
114
+ description: 本店又は主たる事務所の所在地市区町村コード(法人)
115
+ example: 101
116
+ addressRequest:
117
+ type: string
118
+ description: 本店又は主たる事務所の所在地(公表申出)
119
+ maxLength: 600
120
+ addressRequestPrefectureCode:
121
+ type: string
122
+ description: 本店又は主たる事務所の所在地都道府県コード(公表申出)
123
+ addressRequestCityCode:
124
+ type: string
125
+ description: 本店又は主たる事務所の所在地市区町村コード(公表申出)
126
+ kana:
127
+ type: string
128
+ description: 日本語(カナ)
129
+ maxLength: 500
130
+ name:
131
+ type: string
132
+ description: 氏名又は名称
133
+ example: 株式会社インボイス公表
134
+ maxLength: 300
135
+ addressInside:
136
+ type: string
137
+ description: 国内において行う資産の譲渡等に係る事務所、事業所その他これらに準ずるものの所在地
138
+ maxLength: 300
139
+ addressInsidePrefectureCode:
140
+ type: string
141
+ description: 国内において行う資産の譲渡等に係る事務所、事業所その他これらに準ずるものの所在地都道府県コード
142
+ addressInsideCityCode:
143
+ type: string
144
+ description: 国内において行う資産の譲渡等に係る事務所、事業所その他これらに準ずるものの所在地市区町村コード
145
+ tradeName:
146
+ type: string
147
+ description: 主たる屋号
148
+ maxLength: 200
149
+ popularName_previousName:
150
+ type: string
151
+ description: 通称・旧姓
152
+ maxLength: 200
153
+ required:
154
+ - sequenceNumber
155
+ - registratedNumber
156
+ - process
157
+ - correct
158
+ - kind
159
+ - country
160
+ - latest
161
+ - registrationDate
162
+ - updateDate
163
+ - disposalDate
164
+ - expireDate
165
+ - address
166
+ - addressPrefectureCode
167
+ - addressCityCode
168
+ - addressRequest
169
+ - addressRequestPrefectureCode
170
+ - addressRequestCityCode
171
+ - kana
172
+ - name
173
+ - addressInside
174
+ - addressInsidePrefectureCod
175
+ - addressInsideCityCode
176
+ - tradeName
177
+ - popularName_previousName
178
+ - required
179
+
@@ -0,0 +1,87 @@
1
+ openapi: 3.0.3
2
+ info:
3
+ title: 国税庁API
4
+ description: 国税庁が提供するインボイス制度適格請求書発行事業者公表システムWeb-APIを使用するためのクライアントAPI(https://www.invoice-kohyo.nta.go.jp/web-api/index.html)
5
+ version: 1.0.0
6
+ paths:
7
+ "/1/diff":
8
+ get:
9
+ operationId: getAnnouncementByDiff
10
+ summary: 取得期間を指定して情報を取得
11
+ description: 取得期間を指定し、当該期間内に「更新年月日」が含まれる公表情報を取得
12
+ tags:
13
+ - v1
14
+ parameters:
15
+ - $ref: "#/components/parameters/Id"
16
+ - $ref: "#/components/parameters/From"
17
+ - $ref: "#/components/parameters/To"
18
+ - $ref: "#/components/parameters/Type"
19
+ - $ref: "#/components/parameters/Division"
20
+ - $ref: "#/components/parameters/Divide"
21
+ responses:
22
+ "200":
23
+ description: 成功
24
+ content:
25
+ application/json:
26
+ schema:
27
+ $ref: "./announcement.yaml#/components/schemas/ResponseBody"
28
+
29
+ components:
30
+ parameters:
31
+ Id:
32
+ in: query
33
+ name: id
34
+ required: true
35
+ schema:
36
+ type: string
37
+ description: アプリケーションID
38
+ From:
39
+ in: query
40
+ name: from
41
+ required: true
42
+ schema:
43
+ type: string
44
+ description: 取得期間開始日
45
+ example: "2024-10-01"
46
+ format: date
47
+ To:
48
+ in: query
49
+ name: to
50
+ required: true
51
+ schema:
52
+ type: string
53
+ description: 取得期間終了日
54
+ example: "2024-10-01"
55
+ format: date
56
+ Type:
57
+ in: query
58
+ name: type
59
+ required: true
60
+ schema:
61
+ type: string
62
+ description: 応答形式
63
+ example: 21
64
+ enum:
65
+ # - 01
66
+ # - 11
67
+ - 21
68
+ default: 21
69
+ Division:
70
+ in: query
71
+ name: division
72
+ schema:
73
+ type: string
74
+ description: 人格区分
75
+ default: 1
76
+ enum:
77
+ - 1
78
+ - 2
79
+ Divide:
80
+ in: query
81
+ name: divide
82
+ schema:
83
+ type: string
84
+ description: 分割番号
85
+ default: 1
86
+ minLength: 1
87
+ maxLength: 999999
@@ -0,0 +1,66 @@
1
+ openapi: 3.0.3
2
+ info:
3
+ title: 国税庁API
4
+ description: 国税庁が提供するインボイス制度適格請求書発行事業者公表システムWeb-APIを使用するためのクライアントAPI(https://www.invoice-kohyo.nta.go.jp/web-api/index.html)
5
+ version: 1.0.0
6
+ paths:
7
+ "/1/num":
8
+ get:
9
+ operationId: getAnnouncementByNumber
10
+ summary: 登録番号を指定して情報を取得
11
+ description: 指定された登録番号に係る登録年月日、取消年月日及び失効年月日に紐づく最新情報(履歴情報は任意)を取得
12
+ tags:
13
+ - v1
14
+ parameters:
15
+ - $ref: "#/components/parameters/Id"
16
+ - $ref: "#/components/parameters/Number"
17
+ - $ref: "#/components/parameters/Type"
18
+ - $ref: "#/components/parameters/History"
19
+ responses:
20
+ "200":
21
+ description: 成功
22
+ content:
23
+ application/json:
24
+ schema:
25
+ $ref: "./announcement.yaml#/components/schemas/ResponseBody"
26
+
27
+ components:
28
+ parameters:
29
+ Id:
30
+ in: query
31
+ name: id
32
+ required: true
33
+ schema:
34
+ type: string
35
+ description: アプリケーションID
36
+ Number:
37
+ in: query
38
+ name: number
39
+ required: true
40
+ schema:
41
+ type: string
42
+ description: 登録番号
43
+ example: T8040001999011
44
+ Type:
45
+ in: query
46
+ name: type
47
+ required: true
48
+ schema:
49
+ type: string
50
+ description: 応答形式
51
+ example: 21
52
+ enum:
53
+ # - 01
54
+ # - 11
55
+ - 21
56
+ default: 21
57
+ History:
58
+ in: query
59
+ name: history
60
+ schema:
61
+ type: string
62
+ description: 履歴情報要否
63
+ example: 0
64
+ enum:
65
+ - 0
66
+ - 1
@@ -0,0 +1,65 @@
1
+ openapi: 3.0.3
2
+ info:
3
+ title: 国税庁API
4
+ description: 国税庁が提供するインボイス制度適格請求書発行事業者公表システムWeb-APIを使用するためのクライアントAPI(https://www.invoice-kohyo.nta.go.jp/web-api/index.html)
5
+ version: 1.0.0
6
+ paths:
7
+ "/1/valid":
8
+ get:
9
+ operationId: getAnnouncementByValid
10
+ summary: 登録番号と日付を指定して情報を取得
11
+ description: 登録番号及び指定された日付を基準日とした直近の登録年月日、取消年月日、失効年月日に紐づく情報を取得
12
+ tags:
13
+ - v1
14
+ parameters:
15
+ - $ref: "#/components/parameters/Id"
16
+ - $ref: "#/components/parameters/Number"
17
+ - $ref: "#/components/parameters/Day"
18
+ - $ref: "#/components/parameters/Type"
19
+ responses:
20
+ "200":
21
+ description: 成功
22
+ content:
23
+ application/json:
24
+ schema:
25
+ $ref: "./announcement.yaml#/components/schemas/ResponseBody"
26
+
27
+ components:
28
+ parameters:
29
+ Id:
30
+ in: query
31
+ name: id
32
+ required: true
33
+ schema:
34
+ type: string
35
+ description: アプリケーションID
36
+ Number:
37
+ in: query
38
+ name: number
39
+ required: true
40
+ schema:
41
+ type: string
42
+ description: 登録番号
43
+ example: T8040001999011
44
+ Day:
45
+ in: query
46
+ name: day
47
+ required: true
48
+ schema:
49
+ type: string
50
+ description: 判定基準日
51
+ example: "2023-12-01"
52
+ format: date
53
+ Type:
54
+ in: query
55
+ name: type
56
+ required: true
57
+ schema:
58
+ type: string
59
+ description: 応答形式
60
+ example: 21
61
+ enum:
62
+ # - 01
63
+ # - 11
64
+ - 21
65
+ default: 21
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -1,12 +1,12 @@
1
1
  =begin
2
2
  #国税庁API
3
3
 
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ #国税庁が提供するインボイス制度適格請求書発行事業者公表システムWeb-APIを使用するためのクライアントAPI(https://www.invoice-kohyo.nta.go.jp/web-api/index.html)
5
5
 
6
- The version of the OpenAPI document: 0.1.0
6
+ The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.6.0
9
+ OpenAPI Generator version: 7.0.0
10
10
 
11
11
  =end
12
12
 
@@ -32,6 +32,23 @@ describe 'V1Api' do
32
32
  end
33
33
  end
34
34
 
35
+ # unit tests for get_announcement_by_diff
36
+ # 取得期間を指定して情報を取得
37
+ # 取得期間を指定し、当該期間内に「更新年月日」が含まれる公表情報を取得
38
+ # @param id
39
+ # @param from
40
+ # @param to
41
+ # @param type
42
+ # @param [Hash] opts the optional parameters
43
+ # @option opts [String] :division
44
+ # @option opts [String] :divide
45
+ # @return [ResponseBody]
46
+ describe 'get_announcement_by_diff test' do
47
+ it 'should work' do
48
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
49
+ end
50
+ end
51
+
35
52
  # unit tests for get_announcement_by_number
36
53
  # 登録番号を指定して情報を取得
37
54
  # 指定された登録番号に係る登録年月日、取消年月日及び失効年月日に紐づく最新情報(履歴情報は任意)を取得
@@ -47,4 +64,19 @@ describe 'V1Api' do
47
64
  end
48
65
  end
49
66
 
67
+ # unit tests for get_announcement_by_valid
68
+ # 登録番号と日付を指定して情報を取得
69
+ # 登録番号及び指定された日付を基準日とした直近の登録年月日、取消年月日、失効年月日に紐づく情報を取得
70
+ # @param id
71
+ # @param number
72
+ # @param day
73
+ # @param type
74
+ # @param [Hash] opts the optional parameters
75
+ # @return [ResponseBody]
76
+ describe 'get_announcement_by_valid test' do
77
+ it 'should work' do
78
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
79
+ end
80
+ end
81
+
50
82
  end
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.6.0
9
+ OpenAPI Generator version: 7.0.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.6.0
9
+ OpenAPI Generator version: 7.0.0
10
10
 
11
11
  =end
12
12
 
@@ -1,12 +1,12 @@
1
1
  =begin
2
2
  #国税庁API
3
3
 
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ #国税庁が提供するインボイス制度適格請求書発行事業者公表システムWeb-APIを使用するためのクライアントAPI(https://www.invoice-kohyo.nta.go.jp/web-api/index.html)
5
5
 
6
- The version of the OpenAPI document: 0.1.0
6
+ The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.6.0
9
+ OpenAPI Generator version: 7.0.0
10
10
 
11
11
  =end
12
12
 
@@ -20,7 +20,7 @@ require 'date'
20
20
  describe Kendama::Announcement do
21
21
  let(:instance) { Kendama::Announcement.new }
22
22
 
23
- describe 'test an instance of Announcement' do
23
+ describe 'test an instance of Announcement', skip: 'instance do not have anything' do
24
24
  it 'should create an instance of Announcement' do
25
25
  expect(instance).to be_instance_of(Kendama::Announcement)
26
26
  end
@@ -40,30 +40,50 @@ describe Kendama::Announcement do
40
40
  describe 'test attribute "process"' do
41
41
  it 'should work' do
42
42
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
43
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["01", "02", "03", "04", "99"])
44
+ # validator.allowable_values.each do |value|
45
+ # expect { instance.process = value }.not_to raise_error
46
+ # end
43
47
  end
44
48
  end
45
49
 
46
50
  describe 'test attribute "correct"' do
47
51
  it 'should work' do
48
52
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
53
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["0", "1", ""])
54
+ # validator.allowable_values.each do |value|
55
+ # expect { instance.correct = value }.not_to raise_error
56
+ # end
49
57
  end
50
58
  end
51
59
 
52
60
  describe 'test attribute "kind"' do
53
61
  it 'should work' do
54
62
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
63
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["1", "2"])
64
+ # validator.allowable_values.each do |value|
65
+ # expect { instance.kind = value }.not_to raise_error
66
+ # end
55
67
  end
56
68
  end
57
69
 
58
70
  describe 'test attribute "country"' do
59
71
  it 'should work' do
60
72
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
73
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["1", "2", "3"])
74
+ # validator.allowable_values.each do |value|
75
+ # expect { instance.country = value }.not_to raise_error
76
+ # end
61
77
  end
62
78
  end
63
79
 
64
80
  describe 'test attribute "latest"' do
65
81
  it 'should work' do
66
82
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
83
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["0", "1"])
84
+ # validator.allowable_values.each do |value|
85
+ # expect { instance.latest = value }.not_to raise_error
86
+ # end
67
87
  end
68
88
  end
69
89
 
@@ -1,12 +1,12 @@
1
1
  =begin
2
2
  #国税庁API
3
3
 
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ #国税庁が提供するインボイス制度適格請求書発行事業者公表システムWeb-APIを使用するためのクライアントAPI(https://www.invoice-kohyo.nta.go.jp/web-api/index.html)
5
5
 
6
- The version of the OpenAPI document: 0.1.0
6
+ The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.6.0
9
+ OpenAPI Generator version: 7.0.0
10
10
 
11
11
  =end
12
12
 
data/spec/spec_helper.rb CHANGED
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.6.0
9
+ OpenAPI Generator version: 7.0.0
10
10
 
11
11
  =end
12
12
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kendama
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - uichi
8
8
  autorequire:
9
- bindir: exe
9
+ bindir: bin
10
10
  cert_chain: []
11
- date: 2023-06-18 00:00:00.000000000 Z
11
+ date: 2023-09-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -57,12 +57,6 @@ executables: []
57
57
  extensions: []
58
58
  extra_rdoc_files: []
59
59
  files:
60
- - ".openapi-generator-ignore"
61
- - ".openapi-generator/FILES"
62
- - ".openapi-generator/VERSION"
63
- - ".rspec"
64
- - ".rubocop.yml"
65
- - ".travis.yml"
66
60
  - CHANGELOG.md
67
61
  - CODE_OF_CONDUCT.md
68
62
  - Gemfile
@@ -70,10 +64,13 @@ files:
70
64
  - LICENSE.txt
71
65
  - README.md
72
66
  - Rakefile
67
+ - bin/console
68
+ - bin/setup
73
69
  - docs/Announcement.md
74
70
  - docs/ResponseBody.md
75
71
  - docs/V1Api.md
76
72
  - git_push.sh
73
+ - kendama.gemspec
77
74
  - lib/kendama.rb
78
75
  - lib/kendama/api/v1_api.rb
79
76
  - lib/kendama/api_client.rb
@@ -82,6 +79,18 @@ files:
82
79
  - lib/kendama/models/announcement.rb
83
80
  - lib/kendama/models/response_body.rb
84
81
  - lib/kendama/version.rb
82
+ - openapi/root.yaml
83
+ - openapi/v1/announcement.yaml
84
+ - openapi/v1/diff.yaml
85
+ - openapi/v1/num.yaml
86
+ - openapi/v1/valid.yaml
87
+ - pkg/kendama-0.1.0.gem
88
+ - pkg/kendama-0.1.1.gem
89
+ - pkg/kendama-0.2.0.gem
90
+ - pkg/kendama-0.2.1.gem
91
+ - pkg/kendama-0.2.2.gem
92
+ - pkg/kendama-0.2.3.gem
93
+ - pkg/kendama-1.0.0.gem
85
94
  - sig/kendama.rbs
86
95
  - spec/api/v1_api_spec.rb
87
96
  - spec/api_client_spec.rb