mno_enterprise-nimbus 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (30) hide show
  1. checksums.yaml +7 -0
  2. data/APACHE-LICENSE-2.0 +201 -0
  3. data/README.md +28 -0
  4. data/Rakefile +27 -0
  5. data/app/assets/config/mno_enterprise_nimbus_manifest.js +1 -0
  6. data/app/assets/stylesheets/mno_enterprise/nimbus/application.css +15 -0
  7. data/app/controllers/mno_enterprise/nimbus/application_controller.rb +7 -0
  8. data/app/controllers/mno_enterprise/nimbus/v4/app_instances_controller.rb +36 -0
  9. data/app/controllers/mno_enterprise/nimbus/v4/apps_controller.rb +22 -0
  10. data/app/controllers/mno_enterprise/nimbus/v4/base_controller.rb +281 -0
  11. data/app/controllers/mno_enterprise/nimbus/v4/events_controller.rb +52 -0
  12. data/app/controllers/mno_enterprise/nimbus/v4/organizations_controller.rb +37 -0
  13. data/app/controllers/mno_enterprise/nimbus/v4/resource_instances_controller.rb +134 -0
  14. data/app/controllers/mno_enterprise/nimbus/v4/services_controller.rb +20 -0
  15. data/app/controllers/mno_enterprise/nimbus/v4/statistics_controller.rb +40 -0
  16. data/app/controllers/mno_enterprise/nimbus/v4/users_controller.rb +83 -0
  17. data/app/helpers/mno_enterprise/nimbus/application_helper.rb +6 -0
  18. data/app/jobs/mno_enterprise/nimbus/application_job.rb +6 -0
  19. data/app/mailers/mno_enterprise/nimbus/application_mailer.rb +8 -0
  20. data/app/models/mno_enterprise/nimbus/application_record.rb +7 -0
  21. data/app/views/layouts/mno_enterprise/nimbus/application.html.erb +14 -0
  22. data/app/views/mno_enterprise/nimbus/v4/services/schema.json +970 -0
  23. data/app/views/mno_enterprise/nimbus/v4/services/schema_dev.json +970 -0
  24. data/app/views/mno_enterprise/nimbus/v4/services/schema_uat.json +970 -0
  25. data/config/routes.rb +17 -0
  26. data/lib/mno_enterprise/nimbus/engine.rb +7 -0
  27. data/lib/mno_enterprise/nimbus/version.rb +5 -0
  28. data/lib/mno_enterprise/nimbus.rb +14 -0
  29. data/lib/tasks/mno_enterprise/nimbus_tasks.rake +4 -0
  30. metadata +184 -0
@@ -0,0 +1,970 @@
1
+ {
2
+ "$schema": "https://westcon-group.com/api/v4/hyper-schema#",
3
+ "type": [
4
+ "object"
5
+ ],
6
+ "definitions": {
7
+ "organization": {
8
+ "description": "An organization represents a customer account and/or company.",
9
+ "$schema": "http://json-schema.org/draft-04/hyper-schema",
10
+ "title": "Organization",
11
+ "type": [
12
+ "object"
13
+ ],
14
+ "entity": "group",
15
+ "definitions": {
16
+ "id": {
17
+ "description": "unique identifier for the organization",
18
+ "example": "org-1f4d8",
19
+ "readOnly": true,
20
+ "type": [
21
+ "string"
22
+ ]
23
+ },
24
+ "name": {
25
+ "description": "name of the group/company",
26
+ "example": "Doe Inc.",
27
+ "type": [
28
+ "string"
29
+ ],
30
+ "minLength": 1
31
+ },
32
+ "status": {
33
+ "description": "current status of the organization",
34
+ "example": "active",
35
+ "type": [
36
+ "string"
37
+ ],
38
+ "readOnly": true,
39
+ "enum": [
40
+ "active",
41
+ "suspended",
42
+ "pending"
43
+ ]
44
+ }
45
+ },
46
+ "schemas": {
47
+ "targetIndex": {
48
+ "properties": {
49
+ "data": {
50
+ "items": {
51
+ "$ref": "#/definitions/organization"
52
+ },
53
+ "type": [
54
+ "array"
55
+ ]
56
+ }
57
+ },
58
+ "type": [
59
+ "object"
60
+ ]
61
+ },
62
+ "targetShow": {
63
+ "properties": {
64
+ "data": {
65
+ "$ref": "#/definitions/organization"
66
+ }
67
+ },
68
+ "type": [
69
+ "object"
70
+ ]
71
+ },
72
+ "create": {
73
+ "properties": {
74
+ "data": {
75
+ "properties": {
76
+ "name": {
77
+ "$ref": "#/definitions/organization/definitions/name"
78
+ }
79
+ },
80
+ "type": [
81
+ "object"
82
+ ],
83
+ "required": [
84
+ "name"
85
+ ]
86
+ }
87
+ },
88
+ "type": [
89
+ "object"
90
+ ]
91
+ },
92
+ "update": {
93
+ "properties": {
94
+ "data": {
95
+ "properties": {
96
+ "name": {
97
+ "$ref": "#/definitions/organization/definitions/name"
98
+ }
99
+ },
100
+ "type": [
101
+ "object"
102
+ ]
103
+ }
104
+ },
105
+ "type": [
106
+ "object"
107
+ ]
108
+ },
109
+ "targetDestroy": {
110
+ "$ref": "#/definitions/organization/schemas/targetShow"
111
+ }
112
+ },
113
+ "links": [
114
+ {
115
+ "title": "List",
116
+ "description": "List all organizations",
117
+ "href": "/organizations",
118
+ "method": "GET",
119
+ "rel": "instances",
120
+ "targetSchema": {
121
+ "$ref": "#/definitions/organization/schemas/targetIndex"
122
+ }
123
+ },
124
+ {
125
+ "title": "Info",
126
+ "description": "Info for an organizations",
127
+ "href": "/organizations/{(%23%2Fdefinitions%2Forganization%2Fdefinitions%2Fid)}",
128
+ "method": "GET",
129
+ "rel": "self",
130
+ "targetSchema": {
131
+ "$ref": "#/definitions/organization/schemas/targetShow"
132
+ }
133
+ },
134
+ {
135
+ "title": "Create",
136
+ "description": "Create a new organization",
137
+ "href": "/organizations",
138
+ "method": "POST",
139
+ "rel": "create",
140
+ "schema": {
141
+ "$ref": "#/definitions/organization/schemas/create"
142
+ },
143
+ "targetSchema": {
144
+ "$ref": "#/definitions/organization/schemas/targetShow"
145
+ }
146
+ },
147
+ {
148
+ "title": "Update",
149
+ "description": "Update an organization",
150
+ "href": "/organizations/{(%23%2Fdefinitions%2Forganization%2Fdefinitions%2Fid)}",
151
+ "method": "PUT",
152
+ "rel": "update",
153
+ "schema": {
154
+ "$ref": "#/definitions/organization/schemas/update"
155
+ },
156
+ "targetSchema": {
157
+ "$ref": "#/definitions/organization/schemas/targetShow"
158
+ }
159
+ }
160
+ ],
161
+ "properties": {
162
+ "id": {
163
+ "$ref": "#/definitions/organization/definitions/id"
164
+ },
165
+ "name": {
166
+ "$ref": "#/definitions/organization/definitions/name"
167
+ },
168
+ "status": {
169
+ "$ref": "#/definitions/organization/definitions/status"
170
+ }
171
+ }
172
+ },
173
+ "user": {
174
+ "description": "An user is a system user with access to the company applications.",
175
+ "$schema": "http://json-schema.org/draft-04/hyper-schema",
176
+ "title": "User",
177
+ "type": [
178
+ "object"
179
+ ],
180
+ "entity": "user",
181
+ "definitions": {
182
+ "id": {
183
+ "description": "unique identifier for the user",
184
+ "example": "usr-1f4d6",
185
+ "readOnly": true,
186
+ "type": [
187
+ "string"
188
+ ]
189
+ },
190
+ "name": {
191
+ "description": "first name of the user",
192
+ "example": "John",
193
+ "type": [
194
+ "string"
195
+ ],
196
+ "minLength": 1
197
+ },
198
+ "surname": {
199
+ "description": "last name of the user",
200
+ "example": "Doe",
201
+ "type": [
202
+ "string"
203
+ ],
204
+ "minLength": 1
205
+ },
206
+ "email": {
207
+ "description": "email of the user",
208
+ "example": "john.doe@doecorp.com",
209
+ "type": [
210
+ "string"
211
+ ],
212
+ "format": "email"
213
+ }
214
+ },
215
+ "schemas": {
216
+ "targetIndex": {
217
+ "properties": {
218
+ "data": {
219
+ "items": {
220
+ "$ref": "#/definitions/user"
221
+ },
222
+ "type": [
223
+ "array"
224
+ ]
225
+ }
226
+ },
227
+ "type": [
228
+ "object"
229
+ ]
230
+ },
231
+ "targetShow": {
232
+ "properties": {
233
+ "data": {
234
+ "$ref": "#/definitions/user"
235
+ }
236
+ },
237
+ "type": [
238
+ "object"
239
+ ]
240
+ },
241
+ "create": {
242
+ "properties": {
243
+ "data": {
244
+ "properties": {
245
+ "name": {
246
+ "$ref": "#/definitions/user/definitions/name"
247
+ },
248
+ "surname": {
249
+ "$ref": "#/definitions/user/definitions/surname"
250
+ },
251
+ "email": {
252
+ "$ref": "#/definitions/user/definitions/email"
253
+ }
254
+ },
255
+ "type": [
256
+ "object"
257
+ ],
258
+ "required": [
259
+ "name",
260
+ "surname",
261
+ "email"
262
+ ]
263
+ }
264
+ },
265
+ "type": [
266
+ "object"
267
+ ]
268
+ },
269
+ "update": {
270
+ "properties": {
271
+ "data": {
272
+ "properties": {
273
+ "name": {
274
+ "$ref": "#/definitions/user/definitions/name"
275
+ },
276
+ "surname": {
277
+ "$ref": "#/definitions/user/definitions/surname"
278
+ },
279
+ "email": {
280
+ "$ref": "#/definitions/user/definitions/email"
281
+ }
282
+ },
283
+ "type": [
284
+ "object"
285
+ ]
286
+ }
287
+ },
288
+ "type": [
289
+ "object"
290
+ ]
291
+ },
292
+ "targetDestroy": {
293
+ "$ref": "#/definitions/user/schemas/targetShow"
294
+ }
295
+ },
296
+ "links": [
297
+ {
298
+ "title": "List",
299
+ "description": "List all the users for the specified organization",
300
+ "href": "/organizations/{(%23%2Fdefinitions%2Forganization%2Fdefinitions%2Fid)}/users",
301
+ "method": "GET",
302
+ "rel": "instances",
303
+ "targetSchema": {
304
+ "$ref": "#/definitions/user/schemas/targetIndex"
305
+ }
306
+ },
307
+ {
308
+ "title": "Info",
309
+ "description": "Info for a user",
310
+ "href": "/users/{(%23%2Fdefinitions%2Fuser%2Fdefinitions%2Fid)}",
311
+ "method": "GET",
312
+ "rel": "self",
313
+ "targetSchema": {
314
+ "$ref": "#/definitions/user/schemas/targetShow"
315
+ }
316
+ },
317
+ {
318
+ "title": "Create",
319
+ "description": "Create a new user for the specified organization",
320
+ "href": "/organizations/{(%23%2Fdefinitions%2Forganization%2Fdefinitions%2Fid)}/users",
321
+ "method": "POST",
322
+ "rel": "create",
323
+ "schema": {
324
+ "$ref": "#/definitions/user/schemas/create"
325
+ },
326
+ "targetSchema": {
327
+ "$ref": "#/definitions/user/schemas/targetShow"
328
+ }
329
+ },
330
+ {
331
+ "title": "Update",
332
+ "description": "Update an existing user",
333
+ "href": "/users/{(%23%2Fdefinitions%2Fuser%2Fdefinitions%2Fid)}",
334
+ "method": "PUT",
335
+ "rel": "update",
336
+ "schema": {
337
+ "$ref": "#/definitions/user/schemas/update"
338
+ },
339
+ "targetSchema": {
340
+ "$ref": "#/definitions/user/schemas/targetShow"
341
+ }
342
+ },
343
+ {
344
+ "title": "Terminate",
345
+ "description": "Remove a user from the specified organization",
346
+ "href": "/users/{(%23%2Fdefinitions%2Fuser%2Fdefinitions%2Fid)}",
347
+ "method": "DELETE",
348
+ "rel": "destroy",
349
+ "targetSchema": {
350
+ "$ref": "#/definitions/user/schemas/targetDestroy"
351
+ }
352
+ }
353
+ ],
354
+ "properties": {
355
+ "id": {
356
+ "$ref": "#/definitions/user/definitions/id"
357
+ },
358
+ "name": {
359
+ "$ref": "#/definitions/user/definitions/name"
360
+ },
361
+ "surname": {
362
+ "$ref": "#/definitions/user/definitions/surname"
363
+ },
364
+ "email": {
365
+ "$ref": "#/definitions/user/definitions/email"
366
+ }
367
+ }
368
+ },
369
+ "app_instance": {
370
+ "$schema": "http://json-schema.org/draft-04/hyper-schema",
371
+ "description": "An app is a software product such as a CRM, ERP, etc.",
372
+ "title": "Application",
373
+ "type": [
374
+ "object"
375
+ ],
376
+ "entity": "product_instance",
377
+ "definitions": {
378
+ "id": {
379
+ "description": "unique identifier for the application",
380
+ "example": "xyz.mcube.co",
381
+ "readOnly": true,
382
+ "type": [
383
+ "string"
384
+ ]
385
+ },
386
+ "status": {
387
+ "description": "current status of the organization",
388
+ "example": "active",
389
+ "type": [
390
+ "string"
391
+ ],
392
+ "readOnly": true,
393
+ "enum": [
394
+ "provisioning",
395
+ "running",
396
+ "starting",
397
+ "stopping",
398
+ "terminating",
399
+ "terminated"
400
+ ]
401
+ },
402
+ "product": {
403
+ "description": "the actual product reference",
404
+ "example": "vtiger",
405
+ "type": [
406
+ "string"
407
+ ],
408
+ "enum": [
409
+ "vtiger",
410
+ "collabtive",
411
+ "drupal",
412
+ "joomla",
413
+ "orangehrm",
414
+ "dolibarr"
415
+ ]
416
+ },
417
+ "stack": {
418
+ "description": "the product stack",
419
+ "example": "cube",
420
+ "type": [
421
+ "string"
422
+ ],
423
+ "readOnly": true,
424
+ "enum": [
425
+ "cube",
426
+ "cloud",
427
+ "connector"
428
+ ]
429
+ }
430
+ },
431
+ "schemas": {
432
+ "targetIndex": {
433
+ "properties": {
434
+ "data": {
435
+ "items": {
436
+ "$ref": "#/definitions/app_instance"
437
+ },
438
+ "type": [
439
+ "array"
440
+ ]
441
+ }
442
+ },
443
+ "type": [
444
+ "object"
445
+ ]
446
+ },
447
+ "targetShow": {
448
+ "properties": {
449
+ "data": {
450
+ "$ref": "#/definitions/app_instance"
451
+ }
452
+ },
453
+ "type": [
454
+ "object"
455
+ ]
456
+ },
457
+ "create": {
458
+ "properties": {
459
+ "data": {
460
+ "properties": {
461
+ "product": {
462
+ "$ref": "#/definitions/app_instance/definitions/product"
463
+ }
464
+ },
465
+ "type": [
466
+ "object"
467
+ ],
468
+ "required": [
469
+ "product"
470
+ ]
471
+ }
472
+ },
473
+ "type": [
474
+ "object"
475
+ ]
476
+ },
477
+ "targetDestroy": {
478
+ "$ref": "#/definitions/app_instance/schemas/targetShow"
479
+ }
480
+ },
481
+ "links": [
482
+ {
483
+ "title": "List",
484
+ "description": "List all the applications for the specified organization",
485
+ "href": "/organizations/{(%23%2Fdefinitions%2Forganization%2Fdefinitions%2Fid)}/app_instances",
486
+ "method": "GET",
487
+ "rel": "instances",
488
+ "targetSchema": {
489
+ "$ref": "#/definitions/app_instance/schemas/targetIndex"
490
+ }
491
+ },
492
+ {
493
+ "title": "Info",
494
+ "description": "Info for an application",
495
+ "href": "/app_instances/{(%23%2Fdefinitions%2Fapp_instance%2Fdefinitions%2Fid)}",
496
+ "method": "GET",
497
+ "rel": "self",
498
+ "targetSchema": {
499
+ "$ref": "#/definitions/app_instance/schemas/targetShow"
500
+ }
501
+ },
502
+ {
503
+ "title": "Provision",
504
+ "description": "Provision a new application for the specified organization",
505
+ "href": "/organizations/{(%23%2Fdefinitions%2Forganization%2Fdefinitions%2Fid)}/app_instances",
506
+ "method": "POST",
507
+ "rel": "create",
508
+ "schema": {
509
+ "$ref": "#/definitions/app_instance/schemas/create"
510
+ },
511
+ "targetSchema": {
512
+ "$ref": "#/definitions/app_instance/schemas/targetShow"
513
+ }
514
+ },
515
+ {
516
+ "title": "Terminate",
517
+ "description": "Terminate an application",
518
+ "href": "/app_instances/{(%23%2Fdefinitions%2Fapp_instance%2Fdefinitions%2Fid)}",
519
+ "method": "DELETE",
520
+ "rel": "destroy",
521
+ "targetSchema": {
522
+ "$ref": "#/definitions/app_instance/schemas/targetDestroy"
523
+ }
524
+ }
525
+ ],
526
+ "properties": {
527
+ "id": {
528
+ "$ref": "#/definitions/app_instance/definitions/id"
529
+ },
530
+ "status": {
531
+ "$ref": "#/definitions/app_instance/definitions/status"
532
+ },
533
+ "product": {
534
+ "$ref": "#/definitions/app_instance/definitions/product"
535
+ },
536
+ "stack": {
537
+ "$ref": "#/definitions/app_instance/definitions/stack"
538
+ }
539
+ }
540
+ },
541
+ "event": {
542
+ "$schema": "http://json-schema.org/draft-04/hyper-schema",
543
+ "title": "Event",
544
+ "description": "An event represents a change in billing, service or product state/configuration for a customer account.",
545
+ "strictProperties": true,
546
+ "type": [
547
+ "object"
548
+ ],
549
+ "definitions": {
550
+ "id": {
551
+ "description": "unique identifier for the event",
552
+ "example": "01234567-89ab-cdef-0123-456789abcdef",
553
+ "format": "uuid",
554
+ "readOnly": true,
555
+ "type": [
556
+ "string"
557
+ ]
558
+ },
559
+ "event_type": {
560
+ "description": "the type of event",
561
+ "example": "financial",
562
+ "readOnly": true,
563
+ "type": [
564
+ "string"
565
+ ],
566
+ "enum": [
567
+ "financial",
568
+ "audit"
569
+ ]
570
+ },
571
+ "amount_cents": {
572
+ "description": "amount of the charge in cents",
573
+ "example": "2990",
574
+ "readOnly": true,
575
+ "type": [
576
+ "integer"
577
+ ]
578
+ },
579
+ "amount_currency": {
580
+ "description": "alpha3 code for the currency of the amount",
581
+ "example": "AUD",
582
+ "type": [
583
+ "string"
584
+ ],
585
+ "readOnly": true,
586
+ "enum": [
587
+ "AUD",
588
+ "USD"
589
+ ]
590
+ },
591
+ "label": {
592
+ "description": "label for the event",
593
+ "example": "monthly subscription for 5 users",
594
+ "readOnly": true,
595
+ "type": [
596
+ "string"
597
+ ]
598
+ },
599
+ "tx_type": {
600
+ "description": "the type financial transaction",
601
+ "example": "charge",
602
+ "readOnly": true,
603
+ "type": [
604
+ "string"
605
+ ],
606
+ "enum": [
607
+ "charge",
608
+ "refund"
609
+ ]
610
+ },
611
+ "organization_id": {
612
+ "description": "the id of the organization related to the event",
613
+ "example": "org-1f2d6",
614
+ "type": [
615
+ "string"
616
+ ],
617
+ "readOnly": true
618
+ },
619
+ "product_instance_type": {
620
+ "description": "the name of the product instance related to this event",
621
+ "example": "virtual_machine",
622
+ "type": [
623
+ "string"
624
+ ],
625
+ "readOnly": true
626
+ },
627
+ "product_instance_id": {
628
+ "description": "the id of the product instance related to the event",
629
+ "example": "1f2fds31f4f7g4",
630
+ "type": [
631
+ "string"
632
+ ],
633
+ "readOnly": true
634
+ }
635
+ },
636
+ "schemas": {
637
+ "targetIndex": {
638
+ "properties": {
639
+ "data": {
640
+ "items": {
641
+ "$ref": "#/definitions/event"
642
+ },
643
+ "type": [
644
+ "array"
645
+ ]
646
+ }
647
+ },
648
+ "type": [
649
+ "object"
650
+ ]
651
+ },
652
+ "targetShow": {
653
+ "properties": {
654
+ "data": {
655
+ "$ref": "#/definitions/event"
656
+ }
657
+ },
658
+ "type": [
659
+ "object"
660
+ ]
661
+ }
662
+ },
663
+ "links": [
664
+ {
665
+ "title": "Info",
666
+ "description": "Info for an existing event",
667
+ "href": "/events/{(%23%2Fdefinitions%2Fevent%2Fdefinitions%2Fid)}",
668
+ "method": "GET",
669
+ "rel": "self",
670
+ "targetSchema": {
671
+ "$ref": "#/definitions/organization/schemas/targetShow"
672
+ }
673
+ },
674
+ {
675
+ "title": "List",
676
+ "description": "List organization events",
677
+ "href": "/organizations/{(%23%2Fdefinitions%2Forganization%2Fdefinitions%2Fid)}/events",
678
+ "method": "GET",
679
+ "rel": "instances",
680
+ "targetSchema": {
681
+ "$ref": "#/definitions/organization/schemas/targetIndex"
682
+ }
683
+ }
684
+ ],
685
+ "properties": {
686
+ "id": {
687
+ "$ref": "#/definitions/event/definitions/id"
688
+ },
689
+ "event_type": {
690
+ "$ref": "#/definitions/event/definitions/event_type"
691
+ },
692
+ "amount_cents": {
693
+ "$ref": "#/definitions/event/definitions/amount_cents"
694
+ },
695
+ "amount_currency": {
696
+ "$ref": "#/definitions/event/definitions/amount_currency"
697
+ },
698
+ "tx_type": {
699
+ "$ref": "#/definitions/event/definitions/tx_type"
700
+ },
701
+ "label": {
702
+ "$ref": "#/definitions/event/definitions/label"
703
+ },
704
+ "organization_id": {
705
+ "$ref": "#/definitions/event/definitions/organization_id"
706
+ },
707
+ "product_instance_type": {
708
+ "$ref": "#/definitions/event/definitions/product_instance_type"
709
+ },
710
+ "product_instance_id": {
711
+ "$ref": "#/definitions/event/definitions/product_instance_id"
712
+ }
713
+ },
714
+ "entity": "event",
715
+ "dependencies": {
716
+ "amount_cents": {
717
+ "properties": {
718
+ "event_type": {
719
+ "enum": [
720
+ "financial"
721
+ ]
722
+ }
723
+ }
724
+ },
725
+ "amount_currency": {
726
+ "properties": {
727
+ "event_type": {
728
+ "enum": [
729
+ "financial"
730
+ ]
731
+ }
732
+ }
733
+ },
734
+ "tx_type": {
735
+ "properties": {
736
+ "event_type": {
737
+ "enum": [
738
+ "financial"
739
+ ]
740
+ }
741
+ }
742
+ }
743
+ }
744
+ },
745
+ "resource_instance": {
746
+ "description": "A resource instance is a full representation of a customer account including the organization, users and app instances",
747
+ "$schema": "http://json-schema.org/draft-04/hyper-schema",
748
+ "title": "Resource Instance",
749
+ "type": "object",
750
+ "entity": "resource_instance",
751
+ "definitions": {
752
+ "id": {
753
+ "$ref": "#/definitions/organization/definitions/id"
754
+ },
755
+ "targetShow": {
756
+ "properties": {
757
+ "data": {
758
+ "$ref": "#/definitions/resource_instance"
759
+ }
760
+ },
761
+ "type": "object"
762
+ },
763
+ "create": {
764
+ "properties": {
765
+ "organization": {
766
+ "$ref": "#/definitions/organization/definitions/create"
767
+ },
768
+ "users": {
769
+ "items": {
770
+ "title":"User",
771
+ "$ref": "#/definitions/user/definitions/create"
772
+ },
773
+ "type": "array"
774
+ },
775
+ "app_instances": {
776
+ "items": {
777
+ "title":"App-Instance",
778
+ "$ref": "#/definitions/app_instance/definitions/create"
779
+ },
780
+ "type": "array"
781
+ }
782
+ },
783
+ "required": [
784
+ "organization"
785
+ ],
786
+ "type": "object",
787
+ "links":[{
788
+ "title": "Provision",
789
+ "description": "Info for a resource instance",
790
+ "href": "https://westcon-enterprise-mnoe.maestrano.io/nimbus/v4/resource_instances",
791
+ "method": "POST",
792
+ "rel": "Provision"
793
+ }]
794
+ },
795
+ "createRecordOnly": {
796
+ "properties": {
797
+ "organization": {
798
+ "$ref": "#/definitions/organization/definitions/create"
799
+ },
800
+ "users": {
801
+ "items": {
802
+ "title":"User",
803
+ "$ref": "#/definitions/user/definitions/create"
804
+ },
805
+ "type": "array"
806
+ },
807
+ "app_instances": {
808
+ "items": {
809
+ "title":"App-Instance",
810
+ "$ref": "#/definitions/app_instance/definitions/create"
811
+ },
812
+ "type": "array"
813
+ }
814
+ },
815
+ "required": [
816
+ "organization"
817
+ ],
818
+ "type": "object",
819
+ "links":[{
820
+ "title": "RecordOnly",
821
+ "description": "RecordOnly Info for a resource instance",
822
+ "href": "/recordOnly",
823
+ "method": "POST",
824
+ "rel": "RecordOnly"
825
+ }]
826
+ }
827
+ },
828
+ "schemas": {
829
+ "targetIndex": {
830
+ "properties": {
831
+ "data": {
832
+ "items": {
833
+ "$ref": "#/definitions/resource_instance"
834
+ },
835
+ "type": "array"
836
+ }
837
+ },
838
+ "type": "object"
839
+ }
840
+ },
841
+ "links": [
842
+ {
843
+ "title": "Discovery",
844
+ "description": "Info for a resource instance",
845
+ "href": "https://westcon-enterprise-mnoe.maestrano.io/nimbus/v4/resource_instances/#/definitions/resource_instance/definitions/id",
846
+ "method": "GET",
847
+ "rel": "Discover",
848
+ "schema": {
849
+ "type":"object",
850
+ "properties":{
851
+ "resource_instance_id":{
852
+ "title":"Resource Instance Id",
853
+ "$ref": "#/definitions/resource_instance/definitions/id",
854
+ "default":"org-fb0w",
855
+ "minLength":1,
856
+ "readOnly":false
857
+ }
858
+
859
+ },
860
+ "required":["resource_instance_id"],
861
+ "links":[{
862
+ "title": "Discovery",
863
+ "description": "Info for a r",
864
+ "href": "https://westcon-enterprise-mnoe.maestrano.io/nimbus/v4/resource_instances/{(%23%2Fdefinitions%2Fresource_instance%2Fdefinitions%2Fid)}",
865
+ "method": "GET",
866
+ "rel": "Discover"
867
+ }]
868
+ },
869
+ "targetSchema": {
870
+ "$ref": "#/definitions/resource_instance/schemas/targetShow"
871
+ }
872
+ },
873
+ {
874
+ "title": "Provisioning",
875
+ "description": "Create a new organization",
876
+ "href": "https://westcon-enterprise-mnoe.maestrano.io/nimbus/v4/resource_instances",
877
+ "method": "POST",
878
+ "rel": "Provision",
879
+ "schema": {
880
+ "properties":{
881
+ "data":{
882
+ "title":"provisioning",
883
+ "$ref": "#/definitions/resource_instance/definitions/create"
884
+ }
885
+ },
886
+ "type":"object"
887
+ },
888
+ "targetSchema": {
889
+ "$ref": "#/definitions/resource_instance/definitions/targetShow"
890
+ }
891
+ },
892
+ {
893
+ "title": "RecordOnly",
894
+ "description": "Create RecordOnly Resource_instance",
895
+ "href": "/recordOnly",
896
+ "method": "POST",
897
+ "rel": "RecordOnly",
898
+ "schema": {
899
+ "properties":{
900
+ "data":{
901
+ "title":"RecordOnly",
902
+ "$ref": "#/definitions/resource_instance/definitions/createRecordOnly"
903
+ }
904
+ },
905
+ "type":"object"
906
+ },
907
+ "targetSchema": {
908
+ "$ref": "#/definitions/resource_instance/definitions/targetShow"
909
+ }
910
+ }
911
+ ],
912
+ "properties": {
913
+ "id": {
914
+ "$ref": "#/definitions/resource_instance/definitions/id"
915
+ },
916
+ "organization": {
917
+ "$ref": "#/definitions/organization"
918
+ },
919
+ "users": {
920
+ "description": "the list of users under the resource instance",
921
+ "items": {
922
+ "$ref": "#/definitions/user"
923
+ },
924
+ "type": "array"
925
+ },
926
+ "app_instances": {
927
+ "description": "the list of app instances under the resource instance",
928
+ "items": {
929
+ "$ref": "#/definitions/app_instance"
930
+ },
931
+ "type": "array"
932
+ }
933
+ }
934
+ }
935
+ },
936
+ "properties": {
937
+ "organization": {
938
+ "$ref": "#/definitions/organization"
939
+ },
940
+ "user": {
941
+ "$ref": "#/definitions/user"
942
+ },
943
+ "app_instance": {
944
+ "$ref": "#/definitions/app_instance"
945
+ },
946
+ "event": {
947
+ "$ref": "#/definitions/event"
948
+ },
949
+ "resource_instance": {
950
+ "$ref": "#/definitions/resource_instance"
951
+ }
952
+ },
953
+ "id": "https://westcon-enterprise-mnoe.maestrano.io/nimbus/v4/schema#",
954
+ "title": "Maestrano Supplier API",
955
+ "description": "Maestrano is an application marketplace for Small and Medium Businesses",
956
+ "links": [
957
+ {
958
+ "href": "https://westcon-enterprise-mnoe.maestrano.io/nimbus/v4",
959
+ "rel": "self"
960
+ },
961
+ {
962
+ "href": "/schema",
963
+ "method": "GET",
964
+ "rel": "self",
965
+ "targetSchema": {
966
+ "additionalProperties": true
967
+ }
968
+ }
969
+ ]
970
+ }