1
- openapi : 3.0 .0
1
+ openapi : 3.1 .0
2
2
info :
3
3
title : Quantum as a Service API
4
4
description : |-
@@ -285,6 +285,9 @@ tags:
285
285
- name : Bookings
286
286
description : |
287
287
A booking is a reserved timeframe for a platform where only one user could send its jobs
288
+ - name : Models
289
+ description : |
290
+ A model is a quantum computation (circuit, sequence, hamiltonian...) to be executed by job
288
291
components :
289
292
schemas :
290
293
google.protobuf.Int32Value :
@@ -446,6 +449,14 @@ components:
446
449
type : string
447
450
description : Result of the job, if the job is finished.
448
451
nullable : true
452
+ model_id :
453
+ type : string
454
+ description : Computation model ID executed by the job.
455
+ nullable : true
456
+ parameters :
457
+ type : string
458
+ description : Execution parameters for this job.
459
+ nullable : true
449
460
x-properties-order :
450
461
- id
451
462
- name
@@ -458,6 +469,8 @@ components:
458
469
- progress_message
459
470
- job_duration
460
471
- result_distribution
472
+ - model_id
473
+ - parameters
461
474
scaleway.qaas.v1alpha1.JobCircuit :
462
475
type : object
463
476
properties :
@@ -559,6 +572,21 @@ components:
559
572
x-properties-order :
560
573
- total_count
561
574
- jobs
575
+ scaleway.qaas.v1alpha1.ListModelsResponse :
576
+ type : object
577
+ properties :
578
+ total_count :
579
+ type : integer
580
+ description : Total number of models.
581
+ format : uint64
582
+ models :
583
+ type : array
584
+ description : List of models.
585
+ items :
586
+ $ref : ' #/components/schemas/scaleway.qaas.v1alpha1.Model'
587
+ x-properties-order :
588
+ - total_count
589
+ - models
562
590
scaleway.qaas.v1alpha1.ListPlatformsResponse :
563
591
type : object
564
592
properties :
@@ -638,6 +666,30 @@ components:
638
666
x-properties-order :
639
667
- total_count
640
668
- sessions
669
+ scaleway.qaas.v1alpha1.Model :
670
+ type : object
671
+ properties :
672
+ id :
673
+ type : string
674
+ description : Unique ID of the model.
675
+ created_at :
676
+ type : string
677
+ description : Time at which the model was created. (RFC 3339 format)
678
+ format : date-time
679
+ example : " 2022-03-22T12:34:56.123456Z"
680
+ nullable : true
681
+ url :
682
+ type : string
683
+ description : Storage URL of the model.
684
+ nullable : true
685
+ project_id :
686
+ type : string
687
+ description : Project ID in which the model has been created.
688
+ x-properties-order :
689
+ - id
690
+ - created_at
691
+ - url
692
+ - project_id
641
693
scaleway.qaas.v1alpha1.Platform :
642
694
type : object
643
695
properties :
@@ -1058,6 +1110,11 @@ components:
1058
1110
type : string
1059
1111
description : An optional booking unique ID of an attached booking.
1060
1112
nullable : true
1113
+ model_id :
1114
+ type : string
1115
+ description : Default computation model ID to be executed by job assigned
1116
+ to this session.
1117
+ nullable : true
1061
1118
x-properties-order :
1062
1119
- id
1063
1120
- name
@@ -1078,6 +1135,7 @@ components:
1078
1135
- origin_id
1079
1136
- progress_message
1080
1137
- booking_id
1138
+ - model_id
1081
1139
scaleway.qaas.v1alpha1.Session.Access :
1082
1140
type : string
1083
1141
enum :
@@ -1475,6 +1533,14 @@ paths:
1475
1533
description : Maximum duration of the job. (in seconds)
1476
1534
example : 2.5s
1477
1535
nullable : true
1536
+ model_id :
1537
+ type : string
1538
+ description : Computation model ID to be executed by the job.
1539
+ nullable : true
1540
+ parameters :
1541
+ type : string
1542
+ description : Execution parameters for this job.
1543
+ nullable : true
1478
1544
required :
1479
1545
- name
1480
1546
- session_id
@@ -1485,6 +1551,8 @@ paths:
1485
1551
- session_id
1486
1552
- circuit
1487
1553
- max_duration
1554
+ - model_id
1555
+ - parameters
1488
1556
security :
1489
1557
- scaleway : []
1490
1558
x-codeSamples :
@@ -1765,6 +1833,146 @@ paths:
1765
1833
source : |-
1766
1834
http GET "https://api.scaleway.com/qaas/v1alpha1/jobs/{job_id}/results" \
1767
1835
X-Auth-Token:$SCW_SECRET_KEY
1836
+ /qaas/v1alpha1/models :
1837
+ get :
1838
+ tags :
1839
+ - Models
1840
+ operationId : ListModels
1841
+ summary : List all models attached to the **project ID**
1842
+ description : Retrieve information about all models of the provided **project
1843
+ ID**.
1844
+ parameters :
1845
+ - in : query
1846
+ name : project_id
1847
+ description : List models belonging to this project ID.
1848
+ required : true
1849
+ schema :
1850
+ type : string
1851
+ description : List models belonging to this project ID.
1852
+ - in : query
1853
+ name : page
1854
+ description : Page number.
1855
+ schema :
1856
+ type : integer
1857
+ description : Page number.
1858
+ format : int32
1859
+ - in : query
1860
+ name : page_size
1861
+ description : Maximum number of results to return per page.
1862
+ schema :
1863
+ type : integer
1864
+ description : Maximum number of results to return per page.
1865
+ format : uint32
1866
+ - in : query
1867
+ name : order_by
1868
+ description : Sort order of the returned results.
1869
+ schema :
1870
+ type : string
1871
+ description : Sort order of the returned results.
1872
+ enum :
1873
+ - created_at_desc
1874
+ - created_at_asc
1875
+ default : created_at_desc
1876
+ responses :
1877
+ " 200 " :
1878
+ description : " "
1879
+ content :
1880
+ application/json :
1881
+ schema :
1882
+ $ref : ' #/components/schemas/scaleway.qaas.v1alpha1.ListModelsResponse'
1883
+ security :
1884
+ - scaleway : []
1885
+ x-codeSamples :
1886
+ - lang : cURL
1887
+ source : |-
1888
+ curl -X GET \
1889
+ -H "X-Auth-Token: $SCW_SECRET_KEY" \
1890
+ "https://api.scaleway.com/qaas/v1alpha1/models?project_id=string"
1891
+ - lang : HTTPie
1892
+ source : |-
1893
+ http GET "https://api.scaleway.com/qaas/v1alpha1/models" \
1894
+ X-Auth-Token:$SCW_SECRET_KEY \
1895
+ project_id==string
1896
+ post :
1897
+ tags :
1898
+ - Models
1899
+ operationId : CreateModel
1900
+ summary : Create a new model
1901
+ description : Create and register a new model that can be executed through next
1902
+ jobs. A model can also be assigned to a Session.
1903
+ responses :
1904
+ " 200 " :
1905
+ description : " "
1906
+ content :
1907
+ application/json :
1908
+ schema :
1909
+ $ref : ' #/components/schemas/scaleway.qaas.v1alpha1.Model'
1910
+ requestBody :
1911
+ required : true
1912
+ content :
1913
+ application/json :
1914
+ schema :
1915
+ type : object
1916
+ properties :
1917
+ project_id :
1918
+ type : string
1919
+ description : Project ID to attach this model.
1920
+ payload :
1921
+ type : string
1922
+ description : The serialized model data.
1923
+ nullable : true
1924
+ x-properties-order :
1925
+ - project_id
1926
+ - payload
1927
+ security :
1928
+ - scaleway : []
1929
+ x-codeSamples :
1930
+ - lang : cURL
1931
+ source : |-
1932
+ curl -X POST \
1933
+ -H "X-Auth-Token: $SCW_SECRET_KEY" \
1934
+ -H "Content-Type: application/json" \
1935
+ -d '{"project_id":"string"}' \
1936
+ "https://api.scaleway.com/qaas/v1alpha1/models"
1937
+ - lang : HTTPie
1938
+ source : |-
1939
+ http POST "https://api.scaleway.com/qaas/v1alpha1/models" \
1940
+ X-Auth-Token:$SCW_SECRET_KEY \
1941
+ project_id="string"
1942
+ /qaas/v1alpha1/models/{model_id} :
1943
+ get :
1944
+ tags :
1945
+ - Models
1946
+ operationId : GetModel
1947
+ summary : Get model information
1948
+ description : Retrieve information about of the provided **model ID**.
1949
+ parameters :
1950
+ - in : path
1951
+ name : model_id
1952
+ description : Unique ID of the model.
1953
+ required : true
1954
+ schema :
1955
+ type : string
1956
+ description : Unique ID of the model.
1957
+ responses :
1958
+ " 200 " :
1959
+ description : " "
1960
+ content :
1961
+ application/json :
1962
+ schema :
1963
+ $ref : ' #/components/schemas/scaleway.qaas.v1alpha1.Model'
1964
+ security :
1965
+ - scaleway : []
1966
+ x-codeSamples :
1967
+ - lang : cURL
1968
+ source : |-
1969
+ curl -X GET \
1970
+ -H "X-Auth-Token: $SCW_SECRET_KEY" \
1971
+ "https://api.scaleway.com/qaas/v1alpha1/models/{model_id}"
1972
+ - lang : HTTPie
1973
+ source : |-
1974
+ http GET "https://api.scaleway.com/qaas/v1alpha1/models/{model_id}" \
1975
+ X-Auth-Token:$SCW_SECRET_KEY
1768
1976
/qaas/v1alpha1/platforms :
1769
1977
get :
1770
1978
tags :
@@ -2438,6 +2646,11 @@ paths:
2438
2646
- started_at
2439
2647
- finished_at
2440
2648
- description
2649
+ model_id :
2650
+ type : string
2651
+ description : Default computation model ID to be executed by job
2652
+ assigned to this session.
2653
+ nullable : true
2441
2654
required :
2442
2655
- project_id
2443
2656
- platform_id
@@ -2450,6 +2663,7 @@ paths:
2450
2663
- tags
2451
2664
- deduplication_id
2452
2665
- booking_demand
2666
+ - model_id
2453
2667
security :
2454
2668
- scaleway : []
2455
2669
x-codeSamples :
0 commit comments