Open Build Service API
The _Open Build Service API_ is a XML API. To authenticate, use [HTTP basic authentication](https://en.wikipedia.org/wiki/Basic_access_authentication) by…
Developer tools#openapi#developer-tools
Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.
Overview
The _Open Build Service API_ is a XML API.
To authenticate, use HTTP basic authentication by passing the _Authorization_ header in the form of Authorization: Basic .
There is no API versioning as there is no need for it right now.
Only rudimentary rate limiting is implemented, so please be gentle when using the API concurrently, especially with potentially expensive operations.
In case of abuse, we will limit/remove your access.
For command-line users, we recommend using osc with its _api_ command to interact with the API.
It's as simple as this example: osc api /about (_about_ is one of the endpoints documented below)
Endpoints 81
General Information
- GETGet information about API.
/aboutGet generic information about the API. - GETList all known architectures.
/architecturesGet a list of all known architectures known to OBS in general. This is not the list of architectures provided by this instance. Check the schedulers element… - GETShow one architecture.
/architectures/:architecture_nameShow information about one architecture.
Attributes
- DELETEDelete an attribute and all its values in projects or packages.
/attribute/:namespace/:attribute_nameDelete an attribute and all its values in projects or packages. This operation is the same as the one defined with DELETE… - GETShows attribute.
/attribute/:namespace/:attribute_name/_metaShows attribute. - PUTChange attribute data. Create an attribute if it doesn't exist.
/attribute/:namespace/:attribute_name/_metaThis endpoint can be used for both, creating an attribute and updating it: * If the attribute passed as parameter doesn't exist, it will create the attribute.… - POSTChange attribute data. Create an attribute if it doesn't exist.
/attribute/:namespace/:attribute_name/_metaThis endpoint can be used for both, creating an attribute and updating it: * If the attribute passed as parameter doesn't exist, it will create the attribute.… - DELETEDelete an attribute and all its values in projects or packages.
/attribute/:namespace/:attribute_name/_metaDelete an attribute and all its values in projects or packages. This operation is the same as the one defined with DELETE…
Attribute Namespaces
- GETList all attribute namespaces.
/attributeList all attribute namespaces. - GETList all attributes below a namespace.
/attribute/:namespaceList all attributes under a given attribute namespace. - DELETEDelete an attribute namespace and all attributes below.
/attribute/:namespaceDelete an attribute namespace and all attributes below. This operation is the same as the one defined with DELETE /attribute/{namespace}/_meta. - GETShow attribute namespace.
/attribute/:namespace/_metaShows attribute namespace. - PUTChange attribute namespace. Create an attribute namespace if it doesn't exist.
/attribute/:namespace/_metaThis endpoint can be used for both, creating an attribute namespace and updating it: * If the attribute namespace passed as parameter doesn't exist, it will… - POSTChange attribute namespace. Create an attribute namespace if it doesn't exist.
/attribute/:namespace/_metaThis endpoint can be used for both, creating an attribute namespace and updating it: * If the attribute namespace passed as parameter doesn't exist, it will… - DELETEDelete an attribute namespace and all attributes below.
/attribute/:namespace/_metaDelete an attribute namespace and all attributes below. This operation is the same as the one defined with DELETE /attribute/{namespace}.
Build
- GETGet a simple directory listing of all projects
/buildGet a simple directory listing of all projects - GETGet a simple directory listing of all repositories for the specified project
/build/:project_nameGet a simple directory listing of all repositories for the specified project - POSTApply different actions on builds/build processes of the specified project
/build/:project_name?package=firefox&arch=x86_64&repository=openSUSE_Leap_15.2&cmd=wipeApply different actions on builds/build processes of the specified project - GETGet the build results for packages, architectures and repositories of the specified project.
/build/:project_name/_result?view=summary&package=obs-server&arch=x86_64&repository=openSUSE_Leap_15.2&lastbuild=1&locallink=1&multibuild=1Get the build results for packages, architectures and repositories of the specified project. - GETList of all architectures the specified project builds against a given repository.
/build/:project_name/:repository_nameList of all architectures the specified project builds against a given repository. - GETShow the build configuration for the specified repository.
/build/:project_name/:repository_name/_buildconfigShow the build configuration for the specified repository. Includes all base package requirements, mappings and macros. - GETShow the build dependencies of packages that are part of the project.
/build/:project_name/:repository_name/:architecture_name/_builddepinfo?package=obs-server&view=pkgnamesShow the build dependencies of packages that are part of the project, for a given repository and architecture. - GETList all binaries (produced by all packages of the given project).
/build/:project_name/:repository_name/:architecture_name/_repositoryList all binaries (produced by all packages of the given project) for the specified repository and architecture. - GETList binaries built by the sources of the specified package.
/build/:project_name/:repository_name/:architecture_name/:package_nameList binaries built by the sources of the specified package. - GETgetBuildProjectRepositoryArchPackageBuildinfo
/build/:project_name/:repository_name/:architecture_name/:package_name/_buildinfoThis endpoint returns information about some specific artifact - GETgetBuildProjectRepositoryArchPackageHistory
/build/:project_name/:repository_name/:architecture_name/:package_name/_historyThis endpoint returns the build history for a specific artifact - GETShow the build status of a currently running build job.
/build/:project_name/:repository_name/:architecture_name/:package_name/_jobstatusShow the build status of a currently running build job. Shows an empty result if no build job is running. - GETgetBuildProjectRepositoryArchPackageLog
/build/:project_name/:repository_name/:architecture_name/:package_name/_logThis endpoint returns the last log file for a specific build artifact - GETShow the reason for the lastly triggered build.
/build/:project_name/:repository_name/:architecture_name/:package_name/_reasonDetails about the reason of the lastly triggered build. - GETgetBuildProjectRepositoryArchPackageStatus
/build/:project_name/:repository_name/:architecture_name/:package_name/_statusThis endpoint returns the building status for a specific artifact - GETReturn a specific artifact file contents
/build/:project_name/:repository_name/:architecture_name/:package_name/:file_nameGiven a project, repository, architecture and package, retrieve the given file's content. - PUTUpdate a specific artifact file contents
/build/:project_name/:repository_name/:architecture_name/:package_name/:file_nameGiven a project, repository, architecture and package, update the given file's content. This is for Admins only. - GETThis endpoint returns details about an specific artifact
/build/:project_name/:repository_name/:architecture_name/:package_name/:file_name?view=fileinfo?view=fileinfoGiven a project, repository, architecture and package, retrieve the given artifact's details.
Configuration
- GETDisplay the configuration of this Open Build Service instance
/configurationDisplay the configuration of this Open Build Service instance. - PUTUpdate the configuration of this Open Build Service instance
/configurationUpdate the configuration of this Open Build Service instance. This is for admins only.
Distributions
- GETList all distributions.
/distributionsList all distributions that can be build against. This will not list distributions that are available via interconnect. Check /distributions/include_remotes… - POSTCreate a distribution.
/distributionsCreate a distribution. This is only for admins. - PUTBulk replace all distributions.
/distributions/bulk_replaceBulk replace all distributions. This is only for admins. - GETList all distributions including remote.
/distributions/include_remotesList all distributions that can be build against, including the ones provided by the interconnect. - GETShow a distribution.
/distributions/:distribution_idShow a distribution that can be build against. - PUTUpdate a distribution.
/distributions/:distribution_idUpdate the data of a distribution. - DELETEDelete a distribution.
/distributions/:distribution_idDelete a distribution. This is only for admins.
Groups
- GETList available groups.
/groupList available groups. - GETRead group data.
/group/:group_titleRead group data. - PUTWrite group data.
/group/:group_titleWrite group data. - POSTModify group data.
/group/:group_title?cmd=add_user&userid=string&email=stringModify group data. - DELETEDelete a group.
/group/:group_titleDelete a group.
Issue Trackers
- GETGet the list of issue trackers.
/issue_trackersGet the list of issue trackers. - POSTCreate an issue tracker.
/issue_trackersCreate an issue tracker. - GETShow an issue tracker.
/issue_trackers/:issue_tracker_nameShow an issue tracker. - PUTUpdate or create an issue tracker.
/issue_trackers/:issue_tracker_nameUpdate the issue tracker given as path parameter. If it is not found, create it. - DELETEDelete an issue tracker.
/issue_trackers/:issue_tracker_nameDelete an issue tracker. - GETShow an issue of an issue tracker.
/issue_trackers/:issue_tracker_name/issues/:issue_nameShow an issue of an issue tracker.
Person
- GETList all people.
/person?prefix=AdmList all people. - POSTExecutes a command on the person endpoint.
/person?cmd=registerAllows executing command on the person endpoint. As of now, the only command allowed is 'register'. - POSTRegisters a new person
/person/register - GETGet details about a person
/person/:login - PUTUpdate person
/person/:login - POSTPerform changes on a registered person
/person/:login?cmd=change_password - GETList the groups of a person
/person/:login/groupList the groups the person belongs to. - GETList the authentication tokens of a person.
/person/:login/tokenList the authentication tokens of a person. - POSTCreate a new authentication token for a person.
/person/:login/token?project=home:hans&package=gchz&operation=runservice&scm_token=ghp_fake_token_123Create a new authentication token for a person. The token may be limited to a specific package. In this case the query parameters project and package should… - DELETEDelete a token of a person.
/person/:login/token/:idDelete a token of the specified person.
Published Binaries
- GETList all the published projects.
/publishedGet a list of all the projects, all of them are considered published. - GETList the repositories of a project with published binaries
/published/:project_nameGet a list of the repositories of the project that already have published binaries. - GETList the content of the directory tree where the binaries are published at the level project/repository.
/published/:project_name/:repository_nameGet a list of architectures' directories and other files (.repo, .ymp, etc.) present at the level project/repository of the directory tree where the published… - GETList the content of the directory tree where the binaries are published at the level project/repository/architecture.
/published/:project_name/:repository_name/:architecture_nameGet a list of binaries and other files present at the level project/repository/architecture of the directory tree as a result of successful building and… - GETReturn the binary file itself.
/published/:project_name/:repository_name/:architecture_name/:binary_filenameAllow to download the binary file that was published and stored under the directory given by project/repository/architecture/. Can response with Media Types… - GETGenerate a ymp pattern that includes the needed repositories to install the given binary.
/published/:project_name/:repository_name/:architecture_name/:binary_filename?view=ympGenerate a ymp pattern, which contains the list of packages needed for intalling certain software without having to create dependencies between them. Read… - GETPresent information about the last publication of the pair project and repository.
/published/:project_name/:repository_name?view=status?view=statusGet information about the build process (build id, start time, etc.) for the pair project and repository.
Request
- GETGet a simple directory listing of all requests
/requestGet a simple directory listing of all requests - POSTCreate a request
/request?cmd=create&addrevision=1&ignore_delegate=1&ignore_build_state=1Create a request - GETShow details about a specified request.
/request/:id?withhistory=1&withfullhistory=1Show details about a specified request. - PUTModify a given request.
/request/:idModify a given request. NOTE: Certain parts of a request can only be changed by admins. - POSTApply certain actions on a specified request.
/request/:id?cmd=cmd=addreview&by_group=heroes&newstate=string&priority=string&by_user=string&by_group=string&by_project=string&by_package=string&incident=string&time=string&comment=stringApply certain actions on a specified request. - DELETEDelete a given request.
/request/:idDelete a given request. - POSTGet the diff for all packages affected by the request.
/request/:id?cmd=diff?diff_to_superseded=10401&view=xml&withissues=trueGet the diff for all packages affected by the request. - GETGet a collection of requests for a specified target
/request?view=collection?user=hans&project=home:hans&package=ruby&states=new,review&types=add_role,submit&roles=creator,maintainer,reviewer,source,target&withhistory=1&withfullhistory=1&limit=7&ids=15,19,23Get a collection of requests for a specified target. NOTE: You need to set at least one of the following parameters in order to use this endpoint: * user *…
Workers
- GETLists status of workers, jobs, backend services and general statistics.
/worker/statusLists status of workers, running jobs, waiting jobs, status of the backend services and general statistics. Other ways to obtain the same information as with… - GETLists capabilites of a worker.
/worker/:architecture_name::worker_idLists capabilites of a worker. This can be useful when checking for constraints. This operation is the same as GET… - POSTLists workers which match a constraints filter.
/worker?cmd=checkconstraints?project=home:user1&repository=openSUSE_Tumbleweed&arch=x86_64&package=test_packageGiven a project, package, repository and architecture, list workers which can build with that restrictions, and also match a constraints filter. This endpoint…
API details
- Authentication
- HTTP Basic authentication (username and password)
- Operations
- 81 operations on 54 pathsGET 48POST 14PUT 10DELETE 9
- Main resources
- Build 18Person 10Request 8Attribute Namespaces 7Distributions 7Published Binaries 7Issue Trackers 6Attributes 5Groups 5General Information 3
- Response formats
application/xml; charset=utf-8application/*text/plaintext/plain; charset=utf-8- Description format
- OpenAPI 3.0.0, API version
2.10.50 - Links
- Documentation · OpenAPI document · Support
- Listed from
- APIs.guru OpenAPI Directory (CC0-1.0)
Source updated
How to test the Open Build Service API in Swastik Codes
- Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
- Fork it into your workspaceChoose a workspace. You get your own copy of the Open Build Service API collection, without the publisher's secrets.
- Add your credentialsThis API uses HTTP Basic authentication (username and password). Add yours in the collection's variables or an environment; the requests already reference it.
- Send a requestPick an endpoint, for example “Get information about API.” (GET /about), and press Send. Check the response, add tests and run the whole collection with the runner.
Frequently asked questions
What is the Open Build Service API?
The _Open Build Service API_ is a XML API. To authenticate, use [HTTP basic authentication](https://en.wikipedia.org/wiki/Basic_access_authentication) by… It is listed under Developer tools and has 81 endpoints.
Who publishes the Open Build Service API?
It is listed from Opensuse's public API description (an OpenAPI document), not published by Opensuse on Swastik Codes. Anyone who controls opensuse.org can claim the profile by adding a DNS TXT record.
How do I authenticate with the Open Build Service API?
With HTTP Basic authentication (username and password).
How many endpoints does the Open Build Service API have?
81 operations on 54 paths (48 GET, 14 POST, 10 PUT, 9 DELETE). The largest groups are Build, Person, Request, Attribute Namespaces.
Is forking the Open Build Service API free?
Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.