51
51
52
52
@ Produces (MediaType .APPLICATION_JSON )
53
53
@ RequestFilters (BitbucketAuthenticationFilter .class )
54
- @ Path ("/rest/api/{jclouds.api-version}/projects " )
54
+ @ Path ("/rest/api/{jclouds.api-version}" )
55
55
@ SuppressWarnings ("PMD.AvoidDuplicateLiterals" )
56
56
public interface RepositoryApi {
57
57
58
58
@ Named ("repository:create" )
59
59
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/latest/bitbucket-rest.html#idm45888277587248" })
60
60
@ Consumes (MediaType .APPLICATION_JSON )
61
- @ Path ("/{project}/repos" )
61
+ @ Path ("/projects/ {project}/repos" )
62
62
@ Fallback (BitbucketFallbacks .RepositoryOnError .class )
63
63
@ POST
64
64
Repository create (@ PathParam ("project" ) String project ,
@@ -67,7 +67,7 @@ Repository create(@PathParam("project") String project,
67
67
@ Named ("repository:get" )
68
68
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/latest/bitbucket-rest.html#idm45888277593152" })
69
69
@ Consumes (MediaType .APPLICATION_JSON )
70
- @ Path ("/{project}/repos/{repo}" )
70
+ @ Path ("/projects/ {project}/repos/{repo}" )
71
71
@ Fallback (BitbucketFallbacks .RepositoryOnError .class )
72
72
@ GET
73
73
Repository get (@ PathParam ("project" ) String project ,
@@ -76,7 +76,7 @@ Repository get(@PathParam("project") String project,
76
76
@ Named ("repository:fork" )
77
77
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/latest/bitbucket-rest.html#idm45888277587248" })
78
78
@ Consumes (MediaType .APPLICATION_JSON )
79
- @ Path ("/{project}/repos/{repo}" )
79
+ @ Path ("/projects/ {project}/repos/{repo}" )
80
80
@ Payload ("%7B \" name\" : \" {newRepo}\" , \" project\" : %7B \" key\" : \" {newProject}\" %7D %7D" )
81
81
@ Fallback (BitbucketFallbacks .RepositoryOnError .class )
82
82
@ POST
@@ -88,7 +88,7 @@ Repository fork(@PathParam("project") String project,
88
88
@ Named ("repository:delete" )
89
89
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/latest/bitbucket-rest.html#idm45888277567792" })
90
90
@ Consumes (MediaType .APPLICATION_JSON )
91
- @ Path ("/{project}/repos/{repo}" )
91
+ @ Path ("/projects/ {project}/repos/{repo}" )
92
92
@ Fallback (BitbucketFallbacks .RequestStatusOnError .class )
93
93
@ ResponseParser (DeleteRepositoryParser .class )
94
94
@ DELETE
@@ -98,17 +98,30 @@ RequestStatus delete(@PathParam("project") String project,
98
98
@ Named ("repository:list" )
99
99
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/latest/bitbucket-rest.html#idm45888277593152" })
100
100
@ Consumes (MediaType .APPLICATION_JSON )
101
- @ Path ("/{project}/repos" )
101
+ @ Path ("/projects/ {project}/repos" )
102
102
@ Fallback (BitbucketFallbacks .RepositoryPageOnError .class )
103
103
@ GET
104
104
RepositoryPage list (@ PathParam ("project" ) String project ,
105
105
@ Nullable @ QueryParam ("start" ) Integer start ,
106
106
@ Nullable @ QueryParam ("limit" ) Integer limit );
107
107
108
+ @ Named ("repository:list-all" )
109
+ @ Documentation ({"https://docs.atlassian.com/bitbucket-server/rest/5.0.0/bitbucket-rest.html#idm45659055274784" })
110
+ @ Consumes (MediaType .APPLICATION_JSON )
111
+ @ Path ("/repos" )
112
+ @ Fallback (BitbucketFallbacks .RepositoryPageOnError .class )
113
+ @ GET
114
+ RepositoryPage listAll (@ Nullable @ QueryParam ("projectname" ) String project ,
115
+ @ Nullable @ QueryParam ("name" ) String repo ,
116
+ @ Nullable @ QueryParam ("permission" ) String permission ,
117
+ @ Nullable @ QueryParam ("visibility" ) String visibility ,
118
+ @ Nullable @ QueryParam ("start" ) Integer start ,
119
+ @ Nullable @ QueryParam ("limit" ) Integer limit );
120
+
108
121
@ Named ("repository:get-pullrequest-settings" )
109
122
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054915136" })
110
123
@ Consumes (MediaType .APPLICATION_JSON )
111
- @ Path ("/{project}/repos/{repo}/settings/pull-requests" )
124
+ @ Path ("/projects/ {project}/repos/{repo}/settings/pull-requests" )
112
125
@ Fallback (BitbucketFallbacks .PullRequestSettingsOnError .class )
113
126
@ GET
114
127
PullRequestSettings getPullRequestSettings (@ PathParam ("project" ) String project ,
@@ -117,7 +130,7 @@ PullRequestSettings getPullRequestSettings(@PathParam("project") String project,
117
130
@ Named ("repository:update-pullrequest-settings" )
118
131
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054915136" })
119
132
@ Consumes (MediaType .APPLICATION_JSON )
120
- @ Path ("/{project}/repos/{repo}/settings/pull-requests" )
133
+ @ Path ("/projects/ {project}/repos/{repo}/settings/pull-requests" )
121
134
@ Fallback (BitbucketFallbacks .PullRequestSettingsOnError .class )
122
135
@ POST
123
136
PullRequestSettings updatePullRequestSettings (@ PathParam ("project" ) String project ,
@@ -127,7 +140,7 @@ PullRequestSettings updatePullRequestSettings(@PathParam("project") String proje
127
140
@ Named ("repository:create-permissions-by-user" )
128
141
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054938032" })
129
142
@ Consumes (MediaType .APPLICATION_JSON )
130
- @ Path ("/{project}/repos/{repo}/permissions/users" )
143
+ @ Path ("/projects/ {project}/repos/{repo}/permissions/users" )
131
144
@ Fallback (BitbucketFallbacks .RequestStatusOnError .class )
132
145
@ ResponseParser (RequestStatusParser .class )
133
146
@ PUT
@@ -139,7 +152,7 @@ RequestStatus createPermissionsByUser(@PathParam("project") String project,
139
152
@ Named ("repository:delete-permissions-by-user" )
140
153
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054938032" })
141
154
@ Consumes (MediaType .APPLICATION_JSON )
142
- @ Path ("/{project}/repos/{repo}/permissions/users" )
155
+ @ Path ("/projects/ {project}/repos/{repo}/permissions/users" )
143
156
@ Fallback (BitbucketFallbacks .RequestStatusOnError .class )
144
157
@ ResponseParser (RequestStatusParser .class )
145
158
@ DELETE
@@ -150,7 +163,7 @@ RequestStatus deletePermissionsByUser(@PathParam("project") String project,
150
163
@ Named ("repository:list-permissions-by-user" )
151
164
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054938032" })
152
165
@ Consumes (MediaType .APPLICATION_JSON )
153
- @ Path ("/{project}/repos/{repo}/permissions/users" )
166
+ @ Path ("/projects/ {project}/repos/{repo}/permissions/users" )
154
167
@ Fallback (BitbucketFallbacks .PermissionsPageOnError .class )
155
168
@ GET
156
169
PermissionsPage listPermissionsByUser (@ PathParam ("project" ) String project ,
@@ -161,7 +174,7 @@ PermissionsPage listPermissionsByUser(@PathParam("project") String project,
161
174
@ Named ("repository:create-permissions-by-group" )
162
175
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054969200" })
163
176
@ Consumes (MediaType .APPLICATION_JSON )
164
- @ Path ("/{project}/repos/{repo}/permissions/groups" )
177
+ @ Path ("/projects/ {project}/repos/{repo}/permissions/groups" )
165
178
@ Fallback (BitbucketFallbacks .RequestStatusOnError .class )
166
179
@ ResponseParser (RequestStatusParser .class )
167
180
@ PUT
@@ -173,7 +186,7 @@ RequestStatus createPermissionsByGroup(@PathParam("project") String project,
173
186
@ Named ("repository:delete-permissions-by-group" )
174
187
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054969200" })
175
188
@ Consumes (MediaType .APPLICATION_JSON )
176
- @ Path ("/{project}/repos/{repo}/permissions/groups" )
189
+ @ Path ("/projects/ {project}/repos/{repo}/permissions/groups" )
177
190
@ Fallback (BitbucketFallbacks .RequestStatusOnError .class )
178
191
@ ResponseParser (RequestStatusParser .class )
179
192
@ DELETE
@@ -184,7 +197,7 @@ RequestStatus deletePermissionsByGroup(@PathParam("project") String project,
184
197
@ Named ("repository:list-permissions-by-group" )
185
198
@ Documentation ({"https://developer.atlassian.com/static/rest/bitbucket-server/5.0.0/bitbucket-rest.html#idm45659054969200" })
186
199
@ Consumes (MediaType .APPLICATION_JSON )
187
- @ Path ("/{project}/repos/{repo}/permissions/groups" )
200
+ @ Path ("/projects/ {project}/repos/{repo}/permissions/groups" )
188
201
@ Fallback (BitbucketFallbacks .PermissionsPageOnError .class )
189
202
@ GET
190
203
PermissionsPage listPermissionsByGroup (@ PathParam ("project" ) String project ,
0 commit comments