feat: gitlab triggers integration

This commit is contained in:
Krzysztof Dukszta-Kwiatkowski
2023-05-15 11:22:37 +02:00
committed by Ali BARIN
parent 93a2e2151e
commit 3f8f022d48
45 changed files with 2130 additions and 12 deletions

View File

@@ -0,0 +1,11 @@
import { IGlobalVariable, IJSONObject } from '@automatisch/types';
const getCurrentUser = async ($: IGlobalVariable): Promise<IJSONObject> => {
// ref: https://docs.gitlab.com/ee/api/users.html#list-current-user
const response = await $.http.get(`${$.auth.data.oInstanceUrl}/api/v4/user`);
const currentUser = response.data;
return currentUser;
};
export default getCurrentUser;