REST API for Categories for Bitbucket
Information
On this page you will find the REST API documentation for Categories for Bitbucket.
Further links regarding the REST API browser:
- https://developer.atlassian.com/bitbucket/server/docs/latest/how-tos/command-line-rest.html#Browsing_and_Testing_your_REST_APIs_from_the_Application_UI
- Using the REST API Browser
Not all requests may be available on all versions of Categories for Bitbucket.
The paths have been changed on version 1.3.0.
Version - 1.2.1 /rest/projectCategories/latest/...
Version 1.3.0+ /rest/categories/latest/...
Categories
Type: GET
Path: /rest/categories/latest/categories
Parameter:
- type QueryParam - Categories for "project" or "repository". (only since 1.3.0, default: project)
- query QueryParam - Search in category names for this string
Description: Search for categories. SINCE VERSION 1.3.0
Projects
All projects
Type: GET
Path: /rest/categories/latest/project
Description: List all projects and their categories.
Categories
Type: GET
Path: /rest/categories/latest/project/{projectKey}
Description: List all categories of a project.
Type: POST
Path: /rest/categories/latest/project/{projectKey}
Parameter:
- categories QueryParam - The category or categories you want to set for this project.
Return: List all categories of the project.
Description: Set the categories of a project.
Repositories
All repositories
Type: GET
Path: /rest/categories/latest/repositories
Parameter:
- projectkey - key of the project
- start - starting point for paging through the results. Defaults to 0.
- limit (required) - maximum number of results to return. Has to be a value greater than 0.
Description: List all repositories of the project with the given key and their categories.
BROKEN Categories are not returned
DEPRECATED This endpoint is known to have performance issues on bigger systems.
Repository Categories
Type: GET
Path: /rest/categories/latest/project/{projectKey}/repository{repositorySlug}
Description: List all categories of a repository.
Type: POST
Path: /rest/categories/latest/project/{projectKey}/repository{repositorySlug}
Parameter:
- categories QueryParam - The category or categories you want to set for this repository.
Return: List all categories of the repository.
Description: Set the categories of a repository.
Related articles