blueprint_ruby_client 0.4.1 → 0.5.0
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 +4 -4
- data/Gemfile.lock +65 -0
- data/LICENSE +201 -0
- data/README.md +25 -11
- data/docs/AssetTypeConfigsApi.md +63 -0
- data/docs/AssetTypeTemplatesApi.md +179 -0
- data/docs/AssetsApi.md +19 -19
- data/docs/HierarchyApi.md +35 -35
- data/docs/Integration.md +10 -0
- data/docs/IntegrationBody.md +9 -0
- data/docs/IntegrationTransform.md +11 -0
- data/docs/IntegrationTransformExample.md +9 -0
- data/docs/IntegrationsApi.md +329 -0
- data/docs/LTIApi.md +98 -0
- data/docs/Lti1IntegrationAttributes.md +11 -0
- data/docs/NodeAttributes.md +2 -0
- data/docs/SecurityApi.md +48 -0
- data/docs/Template.md +10 -0
- data/docs/TemplateAttributes.md +9 -0
- data/docs/TemplateBody.md +9 -0
- data/docs/{AssetAttributes.md → TemplateVariables.md} +3 -2
- data/generate.sh +1 -2
- data/git_push.sh +16 -1
- data/lib/blueprint_ruby_client/api/asset_type_configs_api.rb +84 -0
- data/lib/blueprint_ruby_client/api/asset_type_templates_api.rb +214 -0
- data/lib/blueprint_ruby_client/api/assets_api.rb +23 -191
- data/lib/blueprint_ruby_client/api/hierarchy_api.rb +49 -409
- data/lib/blueprint_ruby_client/api/integrations_api.rb +415 -0
- data/lib/blueprint_ruby_client/api/lti_api.rb +156 -0
- data/lib/blueprint_ruby_client/api/security_api.rb +75 -0
- data/lib/blueprint_ruby_client/api_client.rb +0 -2
- data/lib/blueprint_ruby_client/models/asset.rb +2 -59
- data/lib/blueprint_ruby_client/models/asset_body.rb +2 -42
- data/lib/blueprint_ruby_client/models/asset_relationship.rb +2 -57
- data/lib/blueprint_ruby_client/models/asset_result_set.rb +2 -57
- data/lib/blueprint_ruby_client/models/error.rb +2 -59
- data/lib/blueprint_ruby_client/models/errors.rb +2 -25
- data/lib/blueprint_ruby_client/models/integration.rb +225 -0
- data/lib/blueprint_ruby_client/models/{mixed_resource_result_set.rb → integration_body.rb} +27 -12
- data/lib/blueprint_ruby_client/models/integration_transform.rb +221 -0
- data/lib/blueprint_ruby_client/models/integration_transform_example.rb +197 -0
- data/lib/blueprint_ruby_client/models/links.rb +2 -57
- data/lib/blueprint_ruby_client/models/lti1_integration_attributes.rb +225 -0
- data/lib/blueprint_ruby_client/models/meta.rb +2 -57
- data/lib/blueprint_ruby_client/models/namespace.rb +2 -43
- data/lib/blueprint_ruby_client/models/namespace_relationship.rb +2 -25
- data/lib/blueprint_ruby_client/models/node.rb +2 -75
- data/lib/blueprint_ruby_client/models/node_attributes.rb +26 -109
- data/lib/blueprint_ruby_client/models/node_body.rb +2 -42
- data/lib/blueprint_ruby_client/models/node_relationship.rb +2 -57
- data/lib/blueprint_ruby_client/models/node_relationships.rb +2 -73
- data/lib/blueprint_ruby_client/models/node_result_set.rb +2 -57
- data/lib/blueprint_ruby_client/models/resource.rb +2 -59
- data/lib/blueprint_ruby_client/models/template.rb +215 -0
- data/lib/blueprint_ruby_client/models/template_attributes.rb +217 -0
- data/lib/blueprint_ruby_client/models/{asset_attributes.rb → template_body.rb} +23 -33
- data/lib/blueprint_ruby_client/models/template_variables.rb +237 -0
- data/lib/blueprint_ruby_client/version.rb +1 -1
- data/lib/blueprint_ruby_client.rb +14 -0
- data/spec/api/asset_type_configs_api_spec.rb +52 -0
- data/spec/api/asset_type_templates_api_spec.rb +88 -0
- data/spec/api/assets_api_spec.rb +9 -9
- data/spec/api/hierarchy_api_spec.rb +17 -17
- data/spec/api/integrations_api_spec.rb +141 -0
- data/spec/api/lti_api_spec.rb +69 -0
- data/spec/api/security_api_spec.rb +50 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/integration_body_spec.rb +56 -0
- data/spec/models/integration_spec.rb +66 -0
- data/spec/models/integration_transform_example_spec.rb +56 -0
- data/spec/models/integration_transform_spec.rb +76 -0
- data/spec/models/lti1_integration_attributes_spec.rb +76 -0
- data/spec/models/node_attributes_spec.rb +20 -0
- data/spec/models/template_attributes_spec.rb +56 -0
- data/spec/models/{asset_attributes_spec.rb → template_body_spec.rb} +17 -7
- data/spec/models/template_spec.rb +66 -0
- data/spec/models/template_variables_spec.rb +56 -0
- data/spec/spec_helper.rb +111 -0
- data/swagger-codegen-cli.jar +0 -0
- data/templates/model.mustache +5 -5
- metadata +67 -12
- data/docs/MixedResourceResultSet.md +0 -7
- data/spec/models/mixed_resource_result_set_spec.rb +0 -36
@@ -0,0 +1,329 @@
|
|
1
|
+
# BlueprintClient::IntegrationsApi
|
2
|
+
|
3
|
+
All URIs are relative to *http://localhost:10010/1*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**add_integration**](IntegrationsApi.md#add_integration) | **POST** /{namespace}/integrations |
|
8
|
+
[**delete_integration**](IntegrationsApi.md#delete_integration) | **DELETE** /{namespace}/integrations/{integrationType}/{integrationId} |
|
9
|
+
[**get_integration**](IntegrationsApi.md#get_integration) | **GET** /{namespace}/integrations/{integrationType}/{integrationId} |
|
10
|
+
[**namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post**](IntegrationsApi.md#namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post) | **POST** /{namespace}/integrations/lti1/{integrationId}/assets/{assetType}/{assetId} |
|
11
|
+
[**replace_integration**](IntegrationsApi.md#replace_integration) | **PUT** /{namespace}/integrations/{integrationType}/{integrationId} |
|
12
|
+
|
13
|
+
|
14
|
+
# **add_integration**
|
15
|
+
> IntegrationBody add_integration(namespace, body)
|
16
|
+
|
17
|
+
|
18
|
+
|
19
|
+
Add an integration
|
20
|
+
|
21
|
+
### Example
|
22
|
+
```ruby
|
23
|
+
# load the gem
|
24
|
+
require 'blueprint_ruby_client'
|
25
|
+
# setup authorization
|
26
|
+
BlueprintClient.configure do |config|
|
27
|
+
# Configure OAuth2 access token for authorization: oauth2
|
28
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
29
|
+
end
|
30
|
+
|
31
|
+
api_instance = BlueprintClient::IntegrationsApi.new
|
32
|
+
|
33
|
+
namespace = "namespace_example" # String | identifier namespacing the blueprint.
|
34
|
+
|
35
|
+
body = BlueprintClient::IntegrationBody.new # IntegrationBody | integration
|
36
|
+
|
37
|
+
|
38
|
+
begin
|
39
|
+
result = api_instance.add_integration(namespace, body)
|
40
|
+
p result
|
41
|
+
rescue BlueprintClient::ApiError => e
|
42
|
+
puts "Exception when calling IntegrationsApi->add_integration: #{e}"
|
43
|
+
end
|
44
|
+
```
|
45
|
+
|
46
|
+
### Parameters
|
47
|
+
|
48
|
+
Name | Type | Description | Notes
|
49
|
+
------------- | ------------- | ------------- | -------------
|
50
|
+
**namespace** | **String**| identifier namespacing the blueprint. |
|
51
|
+
**body** | [**IntegrationBody**](IntegrationBody.md)| integration |
|
52
|
+
|
53
|
+
### Return type
|
54
|
+
|
55
|
+
[**IntegrationBody**](IntegrationBody.md)
|
56
|
+
|
57
|
+
### Authorization
|
58
|
+
|
59
|
+
[oauth2](../README.md#oauth2)
|
60
|
+
|
61
|
+
### HTTP request headers
|
62
|
+
|
63
|
+
- **Content-Type**: application/json
|
64
|
+
- **Accept**: application/vnd.api+json
|
65
|
+
|
66
|
+
|
67
|
+
|
68
|
+
# **delete_integration**
|
69
|
+
> delete_integration(namespace, integration_id, integration_type)
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
Delete an integration
|
74
|
+
|
75
|
+
### Example
|
76
|
+
```ruby
|
77
|
+
# load the gem
|
78
|
+
require 'blueprint_ruby_client'
|
79
|
+
# setup authorization
|
80
|
+
BlueprintClient.configure do |config|
|
81
|
+
# Configure OAuth2 access token for authorization: oauth2
|
82
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
83
|
+
end
|
84
|
+
|
85
|
+
api_instance = BlueprintClient::IntegrationsApi.new
|
86
|
+
|
87
|
+
namespace = "namespace_example" # String | identifier namespacing the blueprint.
|
88
|
+
|
89
|
+
integration_id = "integration_id_example" # String | id of an integration
|
90
|
+
|
91
|
+
integration_type = "integration_type_example" # String | Type of external integration, e.g. 'lti1'
|
92
|
+
|
93
|
+
|
94
|
+
begin
|
95
|
+
api_instance.delete_integration(namespace, integration_id, integration_type)
|
96
|
+
rescue BlueprintClient::ApiError => e
|
97
|
+
puts "Exception when calling IntegrationsApi->delete_integration: #{e}"
|
98
|
+
end
|
99
|
+
```
|
100
|
+
|
101
|
+
### Parameters
|
102
|
+
|
103
|
+
Name | Type | Description | Notes
|
104
|
+
------------- | ------------- | ------------- | -------------
|
105
|
+
**namespace** | **String**| identifier namespacing the blueprint. |
|
106
|
+
**integration_id** | **String**| id of an integration |
|
107
|
+
**integration_type** | **String**| Type of external integration, e.g. 'lti1' |
|
108
|
+
|
109
|
+
### Return type
|
110
|
+
|
111
|
+
nil (empty response body)
|
112
|
+
|
113
|
+
### Authorization
|
114
|
+
|
115
|
+
[oauth2](../README.md#oauth2)
|
116
|
+
|
117
|
+
### HTTP request headers
|
118
|
+
|
119
|
+
- **Content-Type**: application/json
|
120
|
+
- **Accept**: application/vnd.api+json
|
121
|
+
|
122
|
+
|
123
|
+
|
124
|
+
# **get_integration**
|
125
|
+
> IntegrationBody get_integration(namespace, integration_typeintegration_id, )
|
126
|
+
|
127
|
+
|
128
|
+
|
129
|
+
Get details of a given integration
|
130
|
+
|
131
|
+
### Example
|
132
|
+
```ruby
|
133
|
+
# load the gem
|
134
|
+
require 'blueprint_ruby_client'
|
135
|
+
# setup authorization
|
136
|
+
BlueprintClient.configure do |config|
|
137
|
+
# Configure OAuth2 access token for authorization: oauth2
|
138
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
139
|
+
end
|
140
|
+
|
141
|
+
api_instance = BlueprintClient::IntegrationsApi.new
|
142
|
+
|
143
|
+
namespace = "namespace_example" # String | identifier namespacing the blueprint.
|
144
|
+
|
145
|
+
integration_type = "integration_type_example" # String | Type of external integration, e.g. 'lti1'
|
146
|
+
|
147
|
+
integration_id = "integration_id_example" # String | id of an integration
|
148
|
+
|
149
|
+
|
150
|
+
begin
|
151
|
+
result = api_instance.get_integration(namespace, integration_typeintegration_id, )
|
152
|
+
p result
|
153
|
+
rescue BlueprintClient::ApiError => e
|
154
|
+
puts "Exception when calling IntegrationsApi->get_integration: #{e}"
|
155
|
+
end
|
156
|
+
```
|
157
|
+
|
158
|
+
### Parameters
|
159
|
+
|
160
|
+
Name | Type | Description | Notes
|
161
|
+
------------- | ------------- | ------------- | -------------
|
162
|
+
**namespace** | **String**| identifier namespacing the blueprint. |
|
163
|
+
**integration_type** | **String**| Type of external integration, e.g. 'lti1' |
|
164
|
+
**integration_id** | **String**| id of an integration |
|
165
|
+
|
166
|
+
### Return type
|
167
|
+
|
168
|
+
[**IntegrationBody**](IntegrationBody.md)
|
169
|
+
|
170
|
+
### Authorization
|
171
|
+
|
172
|
+
[oauth2](../README.md#oauth2)
|
173
|
+
|
174
|
+
### HTTP request headers
|
175
|
+
|
176
|
+
- **Content-Type**: application/json
|
177
|
+
- **Accept**: application/vnd.api+json
|
178
|
+
|
179
|
+
|
180
|
+
|
181
|
+
# **namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post**
|
182
|
+
> namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post(namespace, integration_id, asset_type, asset_idlti_message_type, lti_version, resource_link_id, opts)
|
183
|
+
|
184
|
+
|
185
|
+
|
186
|
+
LTI launch url for integration
|
187
|
+
|
188
|
+
### Example
|
189
|
+
```ruby
|
190
|
+
# load the gem
|
191
|
+
require 'blueprint_ruby_client'
|
192
|
+
|
193
|
+
api_instance = BlueprintClient::IntegrationsApi.new
|
194
|
+
|
195
|
+
namespace = "namespace_example" # String | identifier namespacing the blueprint.
|
196
|
+
|
197
|
+
integration_id = "integration_id_example" # String | id of an integration
|
198
|
+
|
199
|
+
asset_type = "asset_type_example" # String | subtype of Asset, e.g. 'textbooks', 'digitisations', etc.
|
200
|
+
|
201
|
+
asset_id = "asset_id_example" # String | id of an asset
|
202
|
+
|
203
|
+
lti_message_type = "lti_message_type_example" # String | LTI launch data message type, must be 'basic-lti-launch-request'
|
204
|
+
|
205
|
+
lti_version = "lti_version_example" # String | LTI launch version, must be 'LTI-1p0'
|
206
|
+
|
207
|
+
resource_link_id = "resource_link_id_example" # String | LTI resource_link_id parameters
|
208
|
+
|
209
|
+
opts = {
|
210
|
+
oauth_consumer_key: "oauth_consumer_key_example", # String | OAuth 1.0 consumer_key parameters
|
211
|
+
oauth_consumer_key2: "oauth_consumer_key_example", # String | OAuth 1.0 consumer_key parameters
|
212
|
+
oauth_signature_method: "oauth_signature_method_example", # String | OAuth 1.0 signature method, must be 'HMAC-SHA1'
|
213
|
+
oauth_signature_method2: "oauth_signature_method_example", # String | OAuth 1.0 signature method, must be 'HMAC-SHA1'
|
214
|
+
oauth_timestamp: 56, # Integer | OAuth 1.0 timestamp of request
|
215
|
+
oauth_timestamp2: 56, # Integer | OAuth 1.0 timestamp of request
|
216
|
+
oauth_version: 3.4, # Float | OAuth 1.0 version, must be '1.0'
|
217
|
+
oauth_version2: 3.4, # Float | OAuth 1.0 version, must be '1.0'
|
218
|
+
oauth_nonce: "oauth_nonce_example", # String | OAuth 1.0 Nonce
|
219
|
+
oauth_nonce2: "oauth_nonce_example", # String | OAuth 1.0 Nonce
|
220
|
+
oauth_signature: "oauth_signature_example", # String | OAuth 1.0 request signature
|
221
|
+
oauth_signature2: "oauth_signature_example" # String | OAuth 1.0 request signature
|
222
|
+
}
|
223
|
+
|
224
|
+
begin
|
225
|
+
api_instance.namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post(namespace, integration_id, asset_type, asset_idlti_message_type, lti_version, resource_link_id, opts)
|
226
|
+
rescue BlueprintClient::ApiError => e
|
227
|
+
puts "Exception when calling IntegrationsApi->namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post: #{e}"
|
228
|
+
end
|
229
|
+
```
|
230
|
+
|
231
|
+
### Parameters
|
232
|
+
|
233
|
+
Name | Type | Description | Notes
|
234
|
+
------------- | ------------- | ------------- | -------------
|
235
|
+
**namespace** | **String**| identifier namespacing the blueprint. |
|
236
|
+
**integration_id** | **String**| id of an integration |
|
237
|
+
**asset_type** | **String**| subtype of Asset, e.g. 'textbooks', 'digitisations', etc. |
|
238
|
+
**asset_id** | **String**| id of an asset |
|
239
|
+
**lti_message_type** | **String**| LTI launch data message type, must be 'basic-lti-launch-request' |
|
240
|
+
**lti_version** | **String**| LTI launch version, must be 'LTI-1p0' |
|
241
|
+
**resource_link_id** | **String**| LTI resource_link_id parameters |
|
242
|
+
**oauth_consumer_key** | **String**| OAuth 1.0 consumer_key parameters | [optional]
|
243
|
+
**oauth_consumer_key2** | **String**| OAuth 1.0 consumer_key parameters | [optional]
|
244
|
+
**oauth_signature_method** | **String**| OAuth 1.0 signature method, must be 'HMAC-SHA1' | [optional]
|
245
|
+
**oauth_signature_method2** | **String**| OAuth 1.0 signature method, must be 'HMAC-SHA1' | [optional]
|
246
|
+
**oauth_timestamp** | **Integer**| OAuth 1.0 timestamp of request | [optional]
|
247
|
+
**oauth_timestamp2** | **Integer**| OAuth 1.0 timestamp of request | [optional]
|
248
|
+
**oauth_version** | **Float**| OAuth 1.0 version, must be '1.0' | [optional]
|
249
|
+
**oauth_version2** | **Float**| OAuth 1.0 version, must be '1.0' | [optional]
|
250
|
+
**oauth_nonce** | **String**| OAuth 1.0 Nonce | [optional]
|
251
|
+
**oauth_nonce2** | **String**| OAuth 1.0 Nonce | [optional]
|
252
|
+
**oauth_signature** | **String**| OAuth 1.0 request signature | [optional]
|
253
|
+
**oauth_signature2** | **String**| OAuth 1.0 request signature | [optional]
|
254
|
+
|
255
|
+
### Return type
|
256
|
+
|
257
|
+
nil (empty response body)
|
258
|
+
|
259
|
+
### Authorization
|
260
|
+
|
261
|
+
No authorization required
|
262
|
+
|
263
|
+
### HTTP request headers
|
264
|
+
|
265
|
+
- **Content-Type**: application/x-www-form-urlencoded
|
266
|
+
- **Accept**: text/html
|
267
|
+
|
268
|
+
|
269
|
+
|
270
|
+
# **replace_integration**
|
271
|
+
> IntegrationBody replace_integration(namespace, integration_id, integration_typebody)
|
272
|
+
|
273
|
+
|
274
|
+
|
275
|
+
Replace an integration
|
276
|
+
|
277
|
+
### Example
|
278
|
+
```ruby
|
279
|
+
# load the gem
|
280
|
+
require 'blueprint_ruby_client'
|
281
|
+
# setup authorization
|
282
|
+
BlueprintClient.configure do |config|
|
283
|
+
# Configure OAuth2 access token for authorization: oauth2
|
284
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
285
|
+
end
|
286
|
+
|
287
|
+
api_instance = BlueprintClient::IntegrationsApi.new
|
288
|
+
|
289
|
+
namespace = "namespace_example" # String | identifier namespacing the blueprint.
|
290
|
+
|
291
|
+
integration_id = "integration_id_example" # String | id of an integration
|
292
|
+
|
293
|
+
integration_type = "integration_type_example" # String | Type of external integration, e.g. 'lti1'
|
294
|
+
|
295
|
+
body = BlueprintClient::IntegrationBody.new # IntegrationBody | integration
|
296
|
+
|
297
|
+
|
298
|
+
begin
|
299
|
+
result = api_instance.replace_integration(namespace, integration_id, integration_typebody)
|
300
|
+
p result
|
301
|
+
rescue BlueprintClient::ApiError => e
|
302
|
+
puts "Exception when calling IntegrationsApi->replace_integration: #{e}"
|
303
|
+
end
|
304
|
+
```
|
305
|
+
|
306
|
+
### Parameters
|
307
|
+
|
308
|
+
Name | Type | Description | Notes
|
309
|
+
------------- | ------------- | ------------- | -------------
|
310
|
+
**namespace** | **String**| identifier namespacing the blueprint. |
|
311
|
+
**integration_id** | **String**| id of an integration |
|
312
|
+
**integration_type** | **String**| Type of external integration, e.g. 'lti1' |
|
313
|
+
**body** | [**IntegrationBody**](IntegrationBody.md)| integration |
|
314
|
+
|
315
|
+
### Return type
|
316
|
+
|
317
|
+
[**IntegrationBody**](IntegrationBody.md)
|
318
|
+
|
319
|
+
### Authorization
|
320
|
+
|
321
|
+
[oauth2](../README.md#oauth2)
|
322
|
+
|
323
|
+
### HTTP request headers
|
324
|
+
|
325
|
+
- **Content-Type**: application/json
|
326
|
+
- **Accept**: application/vnd.api+json
|
327
|
+
|
328
|
+
|
329
|
+
|
data/docs/LTIApi.md
ADDED
@@ -0,0 +1,98 @@
|
|
1
|
+
# BlueprintClient::LTIApi
|
2
|
+
|
3
|
+
All URIs are relative to *http://localhost:10010/1*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post**](LTIApi.md#namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post) | **POST** /{namespace}/integrations/lti1/{integrationId}/assets/{assetType}/{assetId} |
|
8
|
+
|
9
|
+
|
10
|
+
# **namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post**
|
11
|
+
> namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post(namespace, integration_id, asset_type, asset_idlti_message_type, lti_version, resource_link_id, opts)
|
12
|
+
|
13
|
+
|
14
|
+
|
15
|
+
LTI launch url for integration
|
16
|
+
|
17
|
+
### Example
|
18
|
+
```ruby
|
19
|
+
# load the gem
|
20
|
+
require 'blueprint_ruby_client'
|
21
|
+
|
22
|
+
api_instance = BlueprintClient::LTIApi.new
|
23
|
+
|
24
|
+
namespace = "namespace_example" # String | identifier namespacing the blueprint.
|
25
|
+
|
26
|
+
integration_id = "integration_id_example" # String | id of an integration
|
27
|
+
|
28
|
+
asset_type = "asset_type_example" # String | subtype of Asset, e.g. 'textbooks', 'digitisations', etc.
|
29
|
+
|
30
|
+
asset_id = "asset_id_example" # String | id of an asset
|
31
|
+
|
32
|
+
lti_message_type = "lti_message_type_example" # String | LTI launch data message type, must be 'basic-lti-launch-request'
|
33
|
+
|
34
|
+
lti_version = "lti_version_example" # String | LTI launch version, must be 'LTI-1p0'
|
35
|
+
|
36
|
+
resource_link_id = "resource_link_id_example" # String | LTI resource_link_id parameters
|
37
|
+
|
38
|
+
opts = {
|
39
|
+
oauth_consumer_key: "oauth_consumer_key_example", # String | OAuth 1.0 consumer_key parameters
|
40
|
+
oauth_consumer_key2: "oauth_consumer_key_example", # String | OAuth 1.0 consumer_key parameters
|
41
|
+
oauth_signature_method: "oauth_signature_method_example", # String | OAuth 1.0 signature method, must be 'HMAC-SHA1'
|
42
|
+
oauth_signature_method2: "oauth_signature_method_example", # String | OAuth 1.0 signature method, must be 'HMAC-SHA1'
|
43
|
+
oauth_timestamp: 56, # Integer | OAuth 1.0 timestamp of request
|
44
|
+
oauth_timestamp2: 56, # Integer | OAuth 1.0 timestamp of request
|
45
|
+
oauth_version: 3.4, # Float | OAuth 1.0 version, must be '1.0'
|
46
|
+
oauth_version2: 3.4, # Float | OAuth 1.0 version, must be '1.0'
|
47
|
+
oauth_nonce: "oauth_nonce_example", # String | OAuth 1.0 Nonce
|
48
|
+
oauth_nonce2: "oauth_nonce_example", # String | OAuth 1.0 Nonce
|
49
|
+
oauth_signature: "oauth_signature_example", # String | OAuth 1.0 request signature
|
50
|
+
oauth_signature2: "oauth_signature_example" # String | OAuth 1.0 request signature
|
51
|
+
}
|
52
|
+
|
53
|
+
begin
|
54
|
+
api_instance.namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post(namespace, integration_id, asset_type, asset_idlti_message_type, lti_version, resource_link_id, opts)
|
55
|
+
rescue BlueprintClient::ApiError => e
|
56
|
+
puts "Exception when calling LTIApi->namespace_integrations_lti1_integration_id_assets_asset_type_asset_id_post: #{e}"
|
57
|
+
end
|
58
|
+
```
|
59
|
+
|
60
|
+
### Parameters
|
61
|
+
|
62
|
+
Name | Type | Description | Notes
|
63
|
+
------------- | ------------- | ------------- | -------------
|
64
|
+
**namespace** | **String**| identifier namespacing the blueprint. |
|
65
|
+
**integration_id** | **String**| id of an integration |
|
66
|
+
**asset_type** | **String**| subtype of Asset, e.g. 'textbooks', 'digitisations', etc. |
|
67
|
+
**asset_id** | **String**| id of an asset |
|
68
|
+
**lti_message_type** | **String**| LTI launch data message type, must be 'basic-lti-launch-request' |
|
69
|
+
**lti_version** | **String**| LTI launch version, must be 'LTI-1p0' |
|
70
|
+
**resource_link_id** | **String**| LTI resource_link_id parameters |
|
71
|
+
**oauth_consumer_key** | **String**| OAuth 1.0 consumer_key parameters | [optional]
|
72
|
+
**oauth_consumer_key2** | **String**| OAuth 1.0 consumer_key parameters | [optional]
|
73
|
+
**oauth_signature_method** | **String**| OAuth 1.0 signature method, must be 'HMAC-SHA1' | [optional]
|
74
|
+
**oauth_signature_method2** | **String**| OAuth 1.0 signature method, must be 'HMAC-SHA1' | [optional]
|
75
|
+
**oauth_timestamp** | **Integer**| OAuth 1.0 timestamp of request | [optional]
|
76
|
+
**oauth_timestamp2** | **Integer**| OAuth 1.0 timestamp of request | [optional]
|
77
|
+
**oauth_version** | **Float**| OAuth 1.0 version, must be '1.0' | [optional]
|
78
|
+
**oauth_version2** | **Float**| OAuth 1.0 version, must be '1.0' | [optional]
|
79
|
+
**oauth_nonce** | **String**| OAuth 1.0 Nonce | [optional]
|
80
|
+
**oauth_nonce2** | **String**| OAuth 1.0 Nonce | [optional]
|
81
|
+
**oauth_signature** | **String**| OAuth 1.0 request signature | [optional]
|
82
|
+
**oauth_signature2** | **String**| OAuth 1.0 request signature | [optional]
|
83
|
+
|
84
|
+
### Return type
|
85
|
+
|
86
|
+
nil (empty response body)
|
87
|
+
|
88
|
+
### Authorization
|
89
|
+
|
90
|
+
No authorization required
|
91
|
+
|
92
|
+
### HTTP request headers
|
93
|
+
|
94
|
+
- **Content-Type**: application/x-www-form-urlencoded
|
95
|
+
- **Accept**: text/html
|
96
|
+
|
97
|
+
|
98
|
+
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# BlueprintClient::Lti1IntegrationAttributes
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**consumer_key** | **String** | |
|
7
|
+
**shared_secret** | **String** | |
|
8
|
+
**taught_unit_type** | **String** | | [optional]
|
9
|
+
**transforms** | [**Array<IntegrationTransform>**](IntegrationTransform.md) | |
|
10
|
+
|
11
|
+
|
data/docs/NodeAttributes.md
CHANGED
@@ -9,5 +9,7 @@ Name | Type | Description | Notes
|
|
9
9
|
**valid_to** | **Date** | The node is judged invalid after this date. Should be an ISO8601 date | [optional]
|
10
10
|
**student_numbers** | **Float** | | [optional]
|
11
11
|
**domain_ids** | **Array<String>** | Additional identifiers linked to the external domain of the hierarchy, for example JACS code. Allows comparisons between hierarchies. | [optional]
|
12
|
+
**reminder_date** | **Date** | Reminder date for redemption period nodes, should be an ISO8601 date. Drop if we can get additionalProperties working. | [optional]
|
13
|
+
**deadline** | **Date** | Deadline date for redemption period nodes, should be an ISO8601 date. Drop if we can get additionalProperties working. | [optional]
|
12
14
|
|
13
15
|
|
data/docs/SecurityApi.md
ADDED
@@ -0,0 +1,48 @@
|
|
1
|
+
# BlueprintClient::SecurityApi
|
2
|
+
|
3
|
+
All URIs are relative to *http://localhost:10010/1*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**get_public_certificate**](SecurityApi.md#get_public_certificate) | **GET** /keys/public |
|
8
|
+
|
9
|
+
|
10
|
+
# **get_public_certificate**
|
11
|
+
> get_public_certificate
|
12
|
+
|
13
|
+
|
14
|
+
|
15
|
+
Return public key that is used to verify signed data
|
16
|
+
|
17
|
+
### Example
|
18
|
+
```ruby
|
19
|
+
# load the gem
|
20
|
+
require 'blueprint_ruby_client'
|
21
|
+
|
22
|
+
api_instance = BlueprintClient::SecurityApi.new
|
23
|
+
|
24
|
+
begin
|
25
|
+
api_instance.get_public_certificate
|
26
|
+
rescue BlueprintClient::ApiError => e
|
27
|
+
puts "Exception when calling SecurityApi->get_public_certificate: #{e}"
|
28
|
+
end
|
29
|
+
```
|
30
|
+
|
31
|
+
### Parameters
|
32
|
+
This endpoint does not need any parameter.
|
33
|
+
|
34
|
+
### Return type
|
35
|
+
|
36
|
+
nil (empty response body)
|
37
|
+
|
38
|
+
### Authorization
|
39
|
+
|
40
|
+
No authorization required
|
41
|
+
|
42
|
+
### HTTP request headers
|
43
|
+
|
44
|
+
- **Content-Type**: application/json
|
45
|
+
- **Accept**: text/plain
|
46
|
+
|
47
|
+
|
48
|
+
|
data/docs/Template.md
ADDED
@@ -0,0 +1,10 @@
|
|
1
|
+
# BlueprintClient::Template
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**id** | **String** | the unique id of the resource of a given type. |
|
7
|
+
**type** | **String** | |
|
8
|
+
**attributes** | [**TemplateAttributes**](TemplateAttributes.md) | |
|
9
|
+
|
10
|
+
|
@@ -0,0 +1,9 @@
|
|
1
|
+
# BlueprintClient::TemplateAttributes
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**redirect_uri** | **String** | |
|
7
|
+
**template_vars** | [**Array<TemplateVariables>**](TemplateVariables.md) | | [optional]
|
8
|
+
|
9
|
+
|
@@ -1,8 +1,9 @@
|
|
1
|
-
# BlueprintClient::
|
1
|
+
# BlueprintClient::TemplateVariables
|
2
2
|
|
3
3
|
## Properties
|
4
4
|
Name | Type | Description | Notes
|
5
5
|
------------ | ------------- | ------------- | -------------
|
6
|
-
**
|
6
|
+
**field** | **String** | |
|
7
|
+
**data** | **String** | |
|
7
8
|
|
8
9
|
|
data/generate.sh
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
#!/bin/sh
|
2
2
|
|
3
3
|
if [ ! -f swagger-codegen-cli.jar ]; then
|
4
|
-
wget http://repo1.maven.org/maven2/io/swagger/swagger-codegen-cli/2.1
|
4
|
+
wget http://repo1.maven.org/maven2/io/swagger/swagger-codegen-cli/2.2.1/swagger-codegen-cli-2.2.1.jar -O swagger-codegen-cli.jar
|
5
5
|
fi
|
6
6
|
java -jar swagger-codegen-cli.jar generate -l ruby -o . -i https://staging-hierarchy.talis.com/api-docs -c config.json -t templates
|
7
|
-
|
data/git_push.sh
CHANGED
@@ -1,4 +1,19 @@
|
|
1
1
|
#!/bin/sh
|
2
|
+
#
|
3
|
+
# Generated by: https://github.com/swagger-api/swagger-codegen.git
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
#
|
2
17
|
# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
|
3
18
|
#
|
4
19
|
# Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update"
|
@@ -28,7 +43,7 @@ git init
|
|
28
43
|
# Adds the files in the local repository and stages them for commit.
|
29
44
|
git add .
|
30
45
|
|
31
|
-
# Commits the tracked changes and prepares them to be pushed to a remote repository.
|
46
|
+
# Commits the tracked changes and prepares them to be pushed to a remote repository.
|
32
47
|
git commit -m "$release_note"
|
33
48
|
|
34
49
|
# Sets the new remote
|
@@ -0,0 +1,84 @@
|
|
1
|
+
=begin
|
2
|
+
Talis Blueprint API
|
3
|
+
|
4
|
+
This is the API documentation for [Blueprint](https://github.com/talis/blueprint-server), a primitive for institutional structure and time periods
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require "uri"
|
14
|
+
|
15
|
+
module BlueprintClient
|
16
|
+
class AssetTypeConfigsApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
|
23
|
+
#
|
24
|
+
# get a template for a given asset type
|
25
|
+
# @param namespace identifier namespacing the blueprint.
|
26
|
+
# @param asset_type subtype of Asset, e.g. 'textbooks', 'digitisations', etc.
|
27
|
+
# @param [Hash] opts the optional parameters
|
28
|
+
# @return [TemplateBody]
|
29
|
+
def get(namespace, asset_type, opts = {})
|
30
|
+
data, _status_code, _headers = get_with_http_info(namespace, asset_type, opts)
|
31
|
+
return data
|
32
|
+
end
|
33
|
+
|
34
|
+
#
|
35
|
+
# get a template for a given asset type
|
36
|
+
# @param namespace identifier namespacing the blueprint.
|
37
|
+
# @param asset_type subtype of Asset, e.g. 'textbooks', 'digitisations', etc.
|
38
|
+
# @param [Hash] opts the optional parameters
|
39
|
+
# @return [Array<(TemplateBody, Fixnum, Hash)>] TemplateBody data, response status code and response headers
|
40
|
+
def get_with_http_info(namespace, asset_type, opts = {})
|
41
|
+
if @api_client.config.debugging
|
42
|
+
@api_client.config.logger.debug "Calling API: AssetTypeConfigsApi.get ..."
|
43
|
+
end
|
44
|
+
# verify the required parameter 'namespace' is set
|
45
|
+
fail ArgumentError, "Missing the required parameter 'namespace' when calling AssetTypeConfigsApi.get" if namespace.nil?
|
46
|
+
# verify the required parameter 'asset_type' is set
|
47
|
+
fail ArgumentError, "Missing the required parameter 'asset_type' when calling AssetTypeConfigsApi.get" if asset_type.nil?
|
48
|
+
# resource path
|
49
|
+
local_var_path = "/{namespace}/assets/{assetType}/templates".sub('{format}','json').sub('{' + 'namespace' + '}', namespace.to_s).sub('{' + 'assetType' + '}', asset_type.to_s)
|
50
|
+
|
51
|
+
# query parameters
|
52
|
+
query_params = {}
|
53
|
+
|
54
|
+
# header parameters
|
55
|
+
header_params = {}
|
56
|
+
|
57
|
+
# HTTP header 'Accept' (if needed)
|
58
|
+
local_header_accept = ['application/vnd.api+json']
|
59
|
+
local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
|
60
|
+
|
61
|
+
# HTTP header 'Content-Type'
|
62
|
+
local_header_content_type = ['application/json']
|
63
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
|
64
|
+
|
65
|
+
# form parameters
|
66
|
+
form_params = {}
|
67
|
+
|
68
|
+
# http body (model)
|
69
|
+
post_body = nil
|
70
|
+
auth_names = ['oauth2']
|
71
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
72
|
+
:header_params => header_params,
|
73
|
+
:query_params => query_params,
|
74
|
+
:form_params => form_params,
|
75
|
+
:body => post_body,
|
76
|
+
:auth_names => auth_names,
|
77
|
+
:return_type => 'TemplateBody')
|
78
|
+
if @api_client.config.debugging
|
79
|
+
@api_client.config.logger.debug "API called: AssetTypeConfigsApi#get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
80
|
+
end
|
81
|
+
return data, status_code, headers
|
82
|
+
end
|
83
|
+
end
|
84
|
+
end
|