Arch List
Overview
This page shows the usage of the Arch API, please see the following for more details.
Test tools
You can use curl
in terminal, with -X method (GET|POST|PUT|PATCH|DELETE),
-d data (a json string). or GUI plugins for
browsers, such as RESTClient
, RESTConsole
.
Documents & examples
LIST
Method: GET
URL: /rest_api/v1/arches/
Response: a paged list of following objects
{
"name": "string"
}
Example:
curl -H "Content-Type: application/json" -X GET https://pdc.fedoraproject.org/rest_api/v1/arches/
# output
{
"count": 47,
"next": "https://pdc.fedoraproject.org/rest_api/v1/arches/?page=2",
"previous": null,
"results": [
{
"name": "alpha"
},
{
"name": "alphaev4",
},
...
]
}
CREATE
Method: POST
URL: /rest_api/v1/arches/
Data:
{
"name": "string"
}
Response:
{
"name": "string"
}
Example:
curl -H "Content-Type: application/json" -X POST -d '{"name": "arm"}' https://pdc.fedoraproject.org/rest_api/v1/arches/
# output
{"name": "arm"}
It is possible to create this resource in bulk. To do so, use the same procedure as when creating a single instance, only the request body should contain a list of JSON objects. The response you get back will also contain a list of values which you would obtain by submitting the request data separately.
Browsable GET
GET /rest_api/v1/arches/
https://pdc.fedoraproject.org/rest_api/v1/arches/?page=2", "previous": null, "results": [ { "name": "alpha" }, { "name": "alphaev4" }, { "name": "alphaev45" }, { "name": "alphaev5" }, { "name": "alphaev56" }, { "name": "alphaev6" }, { "name": "alphaev67" }, { "name": "alphaev68" }, { "name": "alphaev7" }, { "name": "alphapca56" }, { "name": "amd64" }, { "name": "arm64" }, { "name": "armv5tejl" }, { "name": "armv5tel" }, { "name": "armv6l" }, { "name": "armv7hl" }, { "name": "armv7hnl" }, { "name": "armv7l" }, { "name": "athlon" }, { "name": "geode" } ] }{ "count": 49, "next": "