Release Overrides Rpm List
Create, search or delete RPM overrides for specific release. The release is
referenced by its release_id
.
Documents & examples
Method: GET
URL: /rest_api/v1/overrides/rpm/
Query params:
arch
(string)comment
(string, case insensitive, substring match)release
(string)rpm_arch
(string)rpm_name
(string)srpm_name
(string)variant
(string)ordering
(string) Comma separated list of fields for ordering results.- To sort by a field in descending order, prefix its name with minus (e.g.
-name
). - Use double underscores for nested field names (e.g.
parent__child
for{"parent": {"child": ...}}
).
- To sort by a field in descending order, prefix its name with minus (e.g.
Following filters can be used to show only specific fields. This can make
response time faster. Format is list or single value
(JSON: {"fields": ["a","b"]}
or {"fields": "a"}
, in URL: ?fields=a&fields=b
).
fields
(list | string) Fields to display (other fields will be hidden).exclude_fields
: (list | string) Fields NOT to display (overrulesfields
).
Response: a paged list of following objects
{
"arch": "string",
"comment (optional, default=\"\")": "string",
"do_not_delete (optional, default=false)": "boolean",
"id (read-only)": "int",
"include": "boolean",
"release": "Release.release_id",
"rpm_arch": "string",
"rpm_name": "string",
"srpm_name": "string",
"variant": "string"
}
Example:
$ curl -H 'Content-Type: application/json' "https://pdc.fedoraproject.org/rest_api/v1/overrides/rpm/"
{
"previous": null,
"next": null,
"count": 1,
"results": [{
"id": 1,
"do_not_delete": false,
"release": "release-1.0",
"variant": "Client",
"arch": "x86_64",
"srpm_name": "bash",
"rpm_name": "bash-doc",
"rpm_arch": "src",
"include": true,
"comment": ""
}]
}
Method: POST
URL: /rest_api/v1/overrides/rpm/
Data:
{
"arch": "string",
"comment (optional, default=\"\")": "string",
"do_not_delete (optional, default=false)": "boolean",
"include": "boolean",
"release": "Release.release_id",
"rpm_arch": "string",
"rpm_name": "string",
"srpm_name": "string",
"variant": "string"
}
Response:
{
"arch": "string",
"comment (optional, default=\"\")": "string",
"do_not_delete (optional, default=false)": "boolean",
"id (read-only)": "int",
"include": "boolean",
"release": "Release.release_id",
"rpm_arch": "string",
"rpm_name": "string",
"srpm_name": "string",
"variant": "string"
}
Example:
$ curl -H 'Content-Type: application/json' "https://pdc.fedoraproject.org/rest_api/v1/overrides/rpm/" \
-X POST -d '{"variant": "Client", "arch": "x86_64", "srpm_name": "bash", \
"rpm_name": "bash-doc", "rpm_arch": "src", "include": true, \
"release": "release-1.0"}'
{
"id": 1,
"release": "release-1.0",
"variant": "Client",
"arch": "x86_64",
"srpm_name": "bash",
"rpm_name": "bash-doc",
"rpm_arch": "src",
"include": true,
"comment": "",
"do_not_delete": false
}
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.
There are two ways to invoke this call. Both require a request body. In one case you can only delete a list of specific overrides, in the other you clear all overrides on a given release.
Method: DELETE
URL: /rest_api/v1/overrides/rpm/
Data:
[id]
or
{
"release": string,
"force": bool # optional, default false
}
Response:
For deleting a list of specific objects there is no output.
When clearing all overrides, a list of deleted objects is returned.
Example:
$ curl -H 'Content-Type: application/json' "https://pdc.fedoraproject.org/rest_api/v1/overrides/rpm/" \
-X DELETE -d '[1, 15, 29]'
Clearing all overrides.
$ curl -H 'Content-Type: application/json' "https://pdc.fedoraproject.org/rest_api/v1/overrides/rpm/" \
-X DELETE -d '{ "release": "release-1.0", "force": false }'
[
{
"id": 1,
"do_not_delete": false,
"release": "release-1.0",
"variant": "Client",
"arch": "x86_64",
"srpm_name": "bash",
"rpm_name": "bash-magic",
"rpm_arch": "src",
"include": true,
"comment": ""
}
]
Browsable GET
GET /rest_api/v1/overrides/rpm/
{
"count": 0,
"next": null,
"previous": null,
"results": []
}