-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapiary.apib
More file actions
1610 lines (1302 loc) · 55.1 KB
/
Copy pathapiary.apib
File metadata and controls
1610 lines (1302 loc) · 55.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
FORMAT: 1A
HOST: https://atmobeta.iplantc.org/api/v1
# Atmosphere
Atmosphere is a private, self-service cloud computing platform that supports research efforts in the plant sciences
community. It addresses the growing need for customized computational resources and provides the community with
access to:
1. Infrastructure as a Service (IaaS), accessible through a web portal or by API
2. Platform as a Service (PaaS), for developing and deploying software to the scientific community
3. Software as a Service (SaaS), with preconfigured, frequently used analysis routines, algorithms, and
datasets designed to accommodate computationally and data-intensive bioinformatics tasks.
<span style="color:orange;">NOTE: These API docs are currently IN DEVELOPMENT.</span>
## Useful Links
- [Atmosphere Homepage](http://www.iplantcollaborative.org/ci/atmosphere)
- [Atmosphere on GitHub](https://github.com/iPlantCollaborativeOpenSource/atmosphere)
# Group Image/Application
Images are snapshots of an instance at some point in time, including all programs and files. They can be used to create
a clone of an instance for others to use, or simply to save the state of an instance as a backup or recovery.
## Image [/application/{id}]
A single Image object.
Each Image has the following properties:
- **alias**: unique id of the image
- **icon**: (optional) if a custom display icon has been uploaded for this image, this field will contain the relative
path to that image (e.g. "/images/icon.png")
- **created_by**: username of the person who created the image
- **uuid_hash**: **[deprecated]**
- **tags**: tags applied to the image (an array of strings).
- **description**: description of the image
- **start_date**: the date the image was created
- **end_date**: Atmosphere implements soft deletes for everything (or nearly everything). Any images with an
end_date before the moment the request was made will be filtered out of the result set. however, end_dates can also be
used to schedule resources deletion by setting them at a future date. This can also be used to give someone access to
a resource for a limited time (such as for a workshop session).
- **private**: if this field is true, it means the access to the image is limited to a group of people that includes you
- **featured**: this boolean field can only be set by Atmosphere staff and is reserved for images that have gone through
a special review process
- **machines**: admittedly, this field is poorly named, but it represents all the previous versions of this image, which
includes the current version. It also shows which cloud providers that image version is available for.
- **is_bookmarked**: **[user specific property]** this field is specific to the user making the request, and shows whether they identified this
images as being personally significant. In the future this will be taken out and moved to a different endpoint.
- **projects**: **[user specific property]** Shows which projects the user has added this image to.
+ Parameters
+ id (required, string, `bdc31c14-f807-11e3-8ef5-b2227cce2b54`) ... String `uuid` of the Image.
+ Model (application/json)
JSON representation of Image Resource.
+ Body
{
"uuid": "bdc31c14-f807-11e3-8ef5-b2227cce2b54",
"icon": null,
"created_by": "username",
"uuid_hash": "318bf81a238d6c263fc7241c1ff41361",
"name": "Ubuntu 12.04 Updated NoGUI v1",
"tags": [
"Ubuntu",
"Featured"
],
"description": "Descriptiong for Ubuntu 12.04 Updated NoGUI v1",
"start_date": "2014-02-05T01:03:27.903Z",
"end_date": null,
"private": false,
"featured": true,
"machines": [
{
"alias": "813557f2-f808-11e3-8ef5-b2227cce2b54",
"version": "1",
"start_date": "2014-02-04T23:56:40.077Z",
"end_date": null,
"provider": 1
}
],
"is_bookmarked": false,
"projects": []
}
### Retrieve a Single Image [GET]
+ Response 200 (application/json)
[Image][]
### Edit an Image [GET]
+ Response 200 (application/json)
[Image][]
## Images Collection [/application]
Collection of all Images.
This is both a public and private endpoint. If accessed without being authenticated you will get a list of all public
images. If authenticated, you will also get any private images you have permission to use.
+ Model (application/json)
JSON representation of the Images Collection.
+ Body
{
"count": 5,
"next": null,
"previous": null,
"results": [
{
"uuid": "457b8b7c-f809-11e3-8ef5-b2227cce2b54",
"icon": null,
"created_by": "username",
"uuid_hash": "4f8bc92e81dbcb7bd856be34173966e7",
"name": "Ubuntu 13.04 NoGUI Base",
"tags": [],
"description": "Description of Ubuntu 13.04 NoGUI Base",
"start_date": "2014-01-14T23:17:23.813Z",
"end_date": null,
"private": false,
"featured": true,
"machines": [
{
"alias": "855e8c3d-cefa-4654-8728-32902d4d74c2",
"version": "1",
"start_date": "2014-01-28T05:14:56.114Z",
"end_date": null,
"provider": 1
},
{
"alias": "2657cad0-f809-11e3-8ef5-b2227cce2b54",
"version": "2",
"start_date": "2014-01-14T19:25:22.220Z",
"end_date": null,
"provider": 1
}
],
"is_bookmarked": false,
"projects": null
},
{
"uuid": "589174a6-f809-11e3-8ef5-b2227cce2b54",
"icon": null,
"created_by": "username",
"uuid_hash": "b51ae503a6e4cfef6ec00084f3046db0",
"name": "TCW v1.2",
"tags": [],
"description": "Description for TCW v1.2",
"start_date": "2014-01-16T03:04:29.764Z",
"end_date": null,
"private": false,
"featured": false,
"machines": [
{
"alias": "8803eb10-f809-11e3-8ef5-b2227cce2b54",
"version": "1",
"start_date": "2014-01-28T05:14:56.114Z",
"end_date": null,
"provider": 1
},
{
"alias": "8c632108-f809-11e3-8ef5-b2227cce2b54",
"version": "2",
"start_date": "2014-01-15T13:35:42.820Z",
"end_date": null,
"provider": 1
}
],
"is_bookmarked": false,
"projects": null
},
{
"uuid": "aa672302-f809-11e3-8ef5-b2227cce2b54",
"icon": null,
"created_by": "username",
"uuid_hash": "ba12c5bec58263cadfeee62131a0242d",
"name": "Ubuntu 13.04 XFCE GUI Base",
"tags": [],
"description": "Description for Ubuntu 13.04 XFCE GUI Base",
"start_date": "2014-01-16T08:10:31.622Z",
"end_date": null,
"private": false,
"featured": true,
"machines": [
{
"alias": "af851984-f809-11e3-8ef5-b2227cce2b54",
"version": "1",
"start_date": "2014-01-28T05:14:56.114Z",
"end_date": null,
"provider": 1
}
],
"is_bookmarked": true,
"projects": null
},
{
"uuid": "bdc31c14-f807-11e3-8ef5-b2227cce2b54",
"icon": null,
"created_by": "username",
"uuid_hash": "318bf81a238d6c263fc7241c1ff41361",
"name": "Ubuntu 12.04 Updated NoGUI v1",
"tags": [
"Ubuntu",
"Featured"
],
"description": "Descriptiong for Ubuntu 12.04 Updated NoGUI v1",
"start_date": "2014-02-05T01:03:27.903Z",
"end_date": null,
"private": false,
"featured": true,
"machines": [
{
"alias": "813557f2-f808-11e3-8ef5-b2227cce2b54",
"version": "1",
"start_date": "2014-02-04T23:56:40.077Z",
"end_date": null,
"provider": 1
}
],
"is_bookmarked": false,
"projects": []
},
{
"uuid": "8f66dae2-f80a-11e3-8ef5-b2227cce2b54",
"icon": null,
"created_by": "username",
"uuid_hash": "83ae31784ba0e1768f1439ca4b18bb38",
"name": "phytoImage",
"tags": [],
"description": "Description of phytoImage",
"start_date": "2014-01-18T06:12:46.923Z",
"end_date": null,
"private": false,
"featured": false,
"machines": [
{
"alias": "89b42744-f80a-11e3-8ef5-b2227cce2b54",
"version": "1",
"start_date": "2014-01-28T05:14:56.114Z",
"end_date": null,
"provider": 5
}
],
"is_bookmarked": true,
"projects": null
}
]
}
### List all Images [GET]
+ Response 200 (application/json)
[Images Collection][]
## Request an Image [/provider/{providerId}/identity/{identityId}/request_image/]
Images are created by sending a request to Atmosphere support. This is the endpoint used to make that request.
+ Parameters
+ id (required, string, 'b94d4964-8de3-4965-a87a-f4cf44d33165') ... String `alias` of the Instance.
+ providerId (required, number, '4') ... Number `id` of the Provider.
### Request an Image [POST]
To request an image, you need to specify the following properties:
- **name**: the name of the image
- **instance**: alias property of the instance you want imaged
- **provider**: the id of the provider you want the image to be created for
- **description**: A description of the image for display purposes
- **software**: What software is installed on the instance
- **sys**: (**todo:** add details for what this field controls)
- **exclude**: Files on the instance that should be excluded from the image, like ssh keys
- **tags**: tags that should be applied to the image
- **vis**: This field can be one of public, private, or a user-list. If public, everyone can view and create an instance
from the image. If this field is private, the user who created the image will be able to see or launch it. If user
specific, only those users that are listed will be able to see or launch the image.
+ Request (application/json)
{
instance: "74089c18-f80a-11e3-8ef5-b2227cce2b54",
ip_address: "127.0.0.1",
provider: 1,
description: "I would like to request an image of this instance for [reasons].",
software: "Description of software installed on the machine.",
sys: "I'm not sure what this field means.",
exclude: "I do not need any files excluded from the image.",
tags: [
"ESD",
"BGF",
"apache2",
"SpliceGrapher"
],
vis: "public"
}
# Group Profile
The Profile contains information about the authenticated user. Profile can be thought of as the 'entry-point' to the
Atmosphere APIs. Once authenticated, a user can find their default provider and identity. The IDs for provider and
Identity can be used to navigate the rest of the API.
## Profile [/profile]
A single Profile object.
Each Profile has the following properties:
- **user**: the id for the user this profile belongs to
- **username**: the username of the user this profile belongs to
- **email**: the users email address
- **is_staff**: true if the user is iPlant staff
- **is_superuser**: true if the user is a super user (comes with special privileges)
- **groups**: **[deprecated]**
- **send_emails**: true if the user wants to be notified via email when instances they've launched are ready
- **quick_launch**: **[deprecated]**
- **vnc_resolution**: **[deprecated]**
- **default_size**: **[deprecated]**
- **background**: **[deprecated]**
- **icon_set**: the style of icons the user would like to see in the Atmosphere UI when no there is no custom icon to
display
- **selected_identity**: **[deprecated]**
+ Model (application/json)
JSON representation of Profile Resource.
+ Body
{
"user": 1,
"username": "username",
"email": "username@example.com",
"is_staff": false,
"is_superuser": false,
"groups": [
"username"
],
"send_emails": true,
"quick_launch": true,
"vnc_resolution": "800x600",
"default_size": "m1.small",
"background": "default",
"icon_set": "default",
"selected_identity": {
"quota": {
"mem": 256,
"suspended_count": 2,
"storage": 1000,
"cpu": 128,
"storage_count": 10
},
"provider_id": 1,
"id": 1,
"provider": "planet tatooine"
}
}
### Retrieve the Profile [GET]
+ Response 200 (application/json)
[Profile][]
### Update the Profile [PATCH]
To update the profile, send a PATCH request that includes the fields you want to modify. Currently the only modifiable
fields are **send_emails** and **icon_set**
+ Request (application/json)
{
"send_emails": true,
"icon_set": "robots"
}
+ Response 200 (application/json)
[Profile][]
# Group Identity
Identities are like user account information. A user has at least one identity per provider, and each identity
contains information about how many resources can be consumed on that provider. If a user has multiple identities
under a single provider, it means they can allocate more resources by using a different identity.
## Identity [/identity/{id}]
A single Identity object.
Each Identity has the following properties:
- **id**: id of the Identity
- **provider_id**: the id of the provider this identity is for
- **provider**: **[deprecated]** the name of the provider
- **quota**: object describing the resources that can be allocated on the provider under this identity
- **quota.mem**: the maximum amount of memory that can be allocated across all instances under this identity
- **quota.suspended_count**: **[deprecated]** how many instances are currently suspended
- **quota.storage**: the maximum storage space that can be allocated across all volumes under this identity
- **quota.cpu**: the number of CPUs that can be allocated across all instance under this identity
- **quota.storage_count**: the maximum number of volumes that can be created under this identity
+ Parameters
+ id (required, number, 1) ... Number `id` of the Identity.
+ Model (application/json)
JSON representation of Identity Resource.
+ Body
{
"id": 1,
"provider_id": 1,
"provider": "iPlant Cloud - Tucson",
"quota": {
"mem": 256,
"suspended_count": 2,
"storage": 1000,
"cpu": 128,
"storage_count": 10
}
}
## Identity Collection [/identity]
Collection of all Identities.
+ Model (application/json)
JSON representation of Identity Collection Resource.
+ Body
[
{
"id": 1,
"provider_id": 1,
"provider": "iPlant Cloud - Tucson",
"quota": {
"mem": 256,
"suspended_count": 2,
"storage": 1000,
"cpu": 128,
"storage_count": 10
}
}
]
### List all Identities [GET]
+ Response 200 (application/json)
[Identity Collection][]
# Group Instance
Instances are virtual machines that users have created from an image (application). When a user creates an instance
it immediately starts deducting AU's from their account.
## Instance [/provider/{providerId}/identity/{identityId}/instance/{id}]
A single Instance object.
Each Instance has the following properties:
- **alias**: id
- **alias_hash**: **[deprecated]**
- **created_by**: username for the person who created the instance
- **status**: the state the instance is in (active, suspended, shutoff, etc.)
- **size_alias**: the id of the size resource for the instance (number of CPUs, RAM, and Disk Space)
- **machine_alias**: which image the instance was based off. Machines are image versions.
- **ip_address**: IP address you can use to connect to the machine. Address that start with 196, 178, or 10 are private,
all others are public. Instances with an IP address of 0.0.0.0 have not been assigned an IP address yet.
- **start_date**: the date the instance was created
- **token**: **[deprecated]**
- **has_shell**: true if a user can ssh into the instance
- **has_vnc**: true if a user can remote desktop into the instance
- **identity**: which account the instance deducts AU's from
- **name**: name of the instance
- **tags**: instance specific tags (array of strings)
+ Parameters
+ id (required, string, '26f0795e-f80b-11e3-8ef5-b2227cce2b54') ... String `alias` of the Instance.
+ providerId (required, number, '1') ... Number `id` of the Provider.
+ identityId (required, number, '1') ... Number `id` of the Identity.
+ Model (application/json)
JSON representation of Instance Resource.
+ Body
{
"alias": "26f0795e-f80b-11e3-8ef5-b2227cce2b54",
"alias_hash": "b30430ab304a637e0fac9a0322edf7a3",
"created_by": "username",
"status": "active",
"size_alias": "1",
"machine_alias": "4a254940-f80b-11e3-8ef5-b2227cce2b54",
"machine_name": "Ubuntu 13.04 w/Docker 0.9",
"machine_alias_hash": "3f8add823804dc73b221a6c8308a8ab2",
"ip_address": "127.0.0.1",
"start_date": "2014-05-14T18:17:18Z",
"token": null,
"has_shell": false,
"has_vnc": false,
"identity": {
"id": 1,
"created_by": "username",
"provider": 1
},
"name": "Ubuntu 13.04 w/Docker 0.9",
"tags": ["SpliceGrapher"],
"projects": [
1
]
}
### Retrieve an Instance [GET]
Get a specific instance.
+ Response 200 (application/json)
[Instance][]
### Terminate an Instance [DELETE]
Terminate an instance.
+ Response 200 (application/json)
[Instance][]
## Instance Actions [/provider/{providerId}/identity/{identityId}/instance/{id}/action]
+ Parameters
+ id (required, string, '26f0795e-f80b-11e3-8ef5-b2227cce2b54') ... String `alias` of the Instance.
+ providerId (required, number, '1') ... Number `id` of the Provider.
+ identityId (required, number, '1') ... Number `id` of the Identity.
### Suspend an Instance [POST]
Suspend a running instance. This will also stop subtracting AU's.
+ Request (application/json)
{
"action": "suspend"
}
+ Response 200 (application/json)
{
"message": "The requested action <suspend> was run successfully",
"object": null,
"result": "success"
}
### Resume an Instance [POST]
Resume a suspended instance. This will also start subtracting AU's again.
+ Request (application/json)
{
action: "resume"
}
+ Response 200 (application/json)
{
message: "The requested action <resume> was run successfully",
object: null,
result: "success"
}
### Stop an Instance [POST]
Stop a running instance. Stopped instances continue to reduce the AU's.
+ Request (application/json)
{
action: "start"
}
+ Response 200 (application/json)
{
message: "The requested action <start> was run successfully",
object: null,
result: "success"
}
### Start an Instance [POST]
Start a stopped instance.
+ Request (application/json)
{
action: "stop"
}
+ Response 200 (application/json)
{
message: "The requested action <stop> was run successfully",
object: null,
result: "success"
}
## Instances Collection [/provider/{providerId}/identity/{identityId}/instance]
Collection of all Instances for a specific identity and provider.
+ Parameters
+ providerId (required, number, '1') ... Number `id` of the Provider.
+ identityId (required, number, '1') ... Number `id` of the Identity.
+ Model (application/json)
JSON representation of Instances Collection Resource.
+ Body
[
{
"alias": "26f0795e-f80b-11e3-8ef5-b2227cce2b54",
"alias_hash": "b30430ab304a637e0fac9a0322edf7a3",
"created_by": "username",
"status": "active",
"size_alias": "1",
"machine_alias": "4a254940-f80b-11e3-8ef5-b2227cce2b54",
"machine_name": "Ubuntu 13.04 w/Docker 0.9",
"machine_alias_hash": "3f8add823804dc73b221a6c8308a8ab2",
"ip_address": "127.0.0.1",
"start_date": "2014-05-14T18:17:18Z",
"token": null,
"has_shell": false,
"has_vnc": false,
"identity": {
"id": 1,
"created_by": "username",
"provider": 1
},
"name": "Ubuntu 13.04 w/Docker 0.9",
"tags": ["SpliceGrapher"],
"projects": [
1
]
}
]
### List all Instances [GET]
Get a list of your instances created under the specific provider/identity.
+ Response 200 (application/json)
[Instances Collection][]
### Launch an Instance [POST]
Launch an instance of an application. You must specify the following properties:
- **machine_alias**: the specific version of the application you'd like to launch an instance of.
- **size_alias**: the size of the virtual machine you need
- **name**: the name of your instance
+ Request (application/json)
{
machine_alias: "237f983e-f80d-11e3-8ef5-b2227cce2b54"
size_alias: "1"
name: "Instance Name"
}
+ Response 201 (application/json)
[Instance][]
# Group Tag
Tags are small labels users can apply to various resources and are primarily used to help focus searches.
## Tag [/tag/{name}]
A single Tag object.
Each Tag has the following properties:
- **id**: the id of the tag
- **user**: username of the person who created the tag (**todo:** inconsistent? Seen created_by used on other resources)
- **name**: the name of the tag
- **description**: a description of what the tag means
+ Parameters
+ name (required, string, `Featured`) ... String `name` of the Tag.
+ Model (application/json)
JSON representation of Tag Resource.
+ Body
{
"user": null,
"description": "A description of Ubuntu",
"id": 5,
"name": "Ubuntu"
}
### Retrieve a Tag [GET]
+ Response 200 (application/json)
[Tag][]
## Tags Collection [/tag]
Collection of all Tags.
+ Model (application/json)
JSON representation of Tags Collection Resource.
+ Body
[
{
"user": null,
"description": "A description of SpliceGrapher",
"id": 1,
"name": "SpliceGrapher"
},
{
"user": null,
"description": "A description of xGDBvm",
"id": 2,
"name": "xGDBvm"
},
{
"user": null,
"description": "A description of R",
"id": 3,
"name": "R"
},
{
"user": null,
"description": "Featured applications receive priority ordering over non-featured applications",
"id": 4,
"name": "Featured"
},
{
"user": null,
"description": "A description of Ubuntu",
"id": 5,
"name": "Ubuntu"
}
]
### List all Tags [GET]
+ Response 200 (application/json)
[Tags Collection][]
### Create a Tag [POST]
Create a Tag. You must specify the following properties:
- **name**: a name for the tag
- **description**: a description of the tag
+ Request (application/json)
{
"name": "Tag name",
"description": "A description of the tag."
}
+ Response 201 (application/json)
[Tag][]
# Group Provider
Providers represent the different cloud providers managed by Atmosphere.
## Provider [/provider/{provider_id}]
A single Provider object.
Each Provider has the following properties:
- **type**: cloud provider (AWS, Azure, OpenStack, etc.)
- **location**: the display name for the provider
- **id**: unique id for the provider
- **description**: a description of the provider
- **virtualization**: **[deprecated]**
- **public**: **[deprecated]**
- **traits**: **[deprecated]**
+ Parameters
+ provider_id (required, number, '1') ... Number `provider_id` of the Identity.
+ Model(application/json)
JSON representation of Provider Resource
+ Body
{
"id": 1,
"type": "OpenStack",
"location": "planetTatooine",
"description": "planetTatooine",
"virtualization": 2,
"public": false,
"traits": []
}
### Retrieve a Provider [GET]
+ Response 200 (application/json)
[Provider][]
## Providers Collection [/provider]
Collection of all Providers.
+ Model (application/json)
JSON representation of Providers Collection Resource.
+ Body
[
{
"id": 1,
"type": "OpenStack",
"location": "planetTatooine",
"description": "planetTatooine",
"virtualization": 2,
"public": false,
"traits": []
}
]
### List all Providers [GET]
+ Response 200 (application/json)
[Providers Collection][]
# Group Size
Sizes represent the different instance configurations offered by that cloud provider. Each configuration includes the
number of CPUs, memory, and disk space. Sizes with fewer resources will consume AUs at a slower rate.
## Provider Sizes Collection [/provider/{providerId}/identity/{identityId}/size]
+ Parameters
+ providerId (required, number, '1') ... Number `id` of the Provider.
+ identityId (required, number, '1') ... Number `id` of the Identity.
### List all Sizes [GET]
For a combination of provider and identity.
+ Response 200 (application/json)
[
{
"occupancy": 0,
"total": 1,
"remaining": 1,
"active": true,
"alias": "1",
"name": "m1.tiny",
"provider": 1,
"cpu": 1,
"disk": 0,
"root": 1,
"mem": 512
},
{
"occupancy": 0,
"total": 1,
"remaining": 1,
"active": true,
"alias": "2",
"name": "m1.small",
"provider": 1,
"cpu": 1,
"disk": 0,
"root": 20,
"mem": 2048
},
{
"occupancy": 0,
"total": 1,
"remaining": 1,
"active": true,
"alias": "3",
"name": "m1.medium",
"provider": 1,
"cpu": 2,
"disk": 0,
"root": 40,
"mem": 4096
}
]
## Provider Size [/provider/{providerId}/identity/{identityId}/size/{id}]
A single Size object (in the specified provider) with all its details.
+ Parameters
+ id (required, string, 'b24ce221-1ed4-4317-av7q-b4yf4q4qe3239') ... String `alias` of the Size.
+ providerId (required, number, '1') ... Number `id` of the Provider.
+ identityId (required, number, '1') ... Number `id` of the Identity.
### Retrieve a Size [GET]
+ Response 200 (application/json)
+ Body
{
"occupancy": 0,
"total": 1,
"remaining": 1,
"active": true,
"alias": "1",
"name": "m1.tiny",
"provider": 1,
"cpu": 1,
"disk": 0,
"root": 1,
"mem": 512
}
# Group Volume
Volumes are network based storage that a user can attach to any instance. They can then be detached and attached to a
different instance.
## Volume [/provider/{providerId}/identity/{identityId}/volume/{id}]
A single Volume object.
Each Volume has the following properties:
- **alias**: unique id for the volume
- **created_by**: user id of the person who created the volume
- **name**: name of the volume
- **description**: description of the volume
- **status**: status of the volume (detaching, attaching, available or in-use)
- **size**: size of the volume in Gigabytes
- **attach_data**: if the volume is attached to an instance, provides details about which instance it's attached to and
where the volume is mounted to on the instance
- **provider**: provider the volume is created on
- **identity**: identity that created the volume
+ Parameters
+ id (required, string, '13138b97-786a-4e57-9acc-5d41cfd21f75') ... String `alias` of the Volume.
+ providerId (required, number, '1') ... Number `id` of the Provider.
+ identityId (required, number, '1') ... Number `id` of the Identity.
+ Model (application/json)
JSON representation of Volume Resource.
+ Body
{
"alias": "232333c94-7864-4157-9cq-5441ff321F11",
"created_by": 1,
"name": "My_Other_Volume",
"description": "",
"status": "available",
"size": 1,
"attach_data": {},
"provider": 1,
"identity": {
"id": 1,
"created_by": "HanSolo",
"provider": 1
},
"projects": [
1
],
"start_date": "2014-05-13T00:24:58Z"
}
### Retrieve a Volume [GET]
+ Response 200 (application/json)
[Volume][]
### Destroy a Volume [DELETE]
Destroy a volume.
+ Response 200 (application/json)
[Volume][]
## Volume Actions [/provider/{providerId}/identity/{identityId}/instance/{id}/action]
+ Parameters
+ id (required, string, '26f0795e-f80b-11e3-8ef5-b2227cce2b54') ... String `alias` of the Instance.
+ providerId (required, number, '1') ... Number `id` of the Provider.
+ identityId (required, number, '1') ... Number `id` of the Identity.
### Attach a Volume [POST]
Attach a volume to an instance.
+ Request (application/json)
{
action: "attach_volume",
volume_id: "21637611-d75c-4c94-a761-dcd58ed8324b"
}