Skip to content
Snippets Groups Projects
Commit 9315e8c7 authored by michael.minelli's avatar michael.minelli
Browse files

GitlabManager => Add addRepositoryBadge function

parent f273178a
No related branches found
No related tags found
No related merge requests found
......@@ -111,6 +111,16 @@ class GitlabManager {
return response.data;
}
async addRepositoryBadge(repoId: number, linkUrl: string, imageUrl: string, name: string): Promise<GitlabMember> {
const response = await axios.post<GitlabMember>(this.getApiUrl(GitlabRoute.REPOSITORY_BADGES_ADD).replace('{{id}}', String(repoId)), {
link_url : linkUrl,
image_url: imageUrl,
name : name
});
return response.data;
}
async checkTemplateAccess(idOrNamespace: string, req: express.Request): Promise<StatusCodes> {
// Get the Gitlab project and check if it have public or internal visibility
try {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment