🚀New lib version v0.3.0 [CI SKIP]
All checks were successful
continuous-integration/drone Build is passing

This commit is contained in:
2021-01-24 18:01:44 +00:00
parent 232cc74190
commit d4d6b713e2
54 changed files with 238 additions and 143 deletions

View File

@@ -17,5 +17,36 @@ class RunnerSelfService {
});
return result.body;
}
/**
* Register runner
* Create a new selfservice runner in the citizen org. <br> This endpoint shoud be used to allow "everyday citizen" to register themselves. <br> You have to provide a mail address, b/c the future we'll implement email verification.
* @param requestBody CreateSelfServiceCitizenRunner
* @returns ResponseSelfServiceRunner
* @throws ApiError
*/
static async runnerSelfServiceControllerRegisterRunner(requestBody) {
const result = await request_1.request({
method: 'POST',
path: `/api/runners/register`,
body: requestBody,
});
return result.body;
}
/**
* Register organization runner
* Create a new selfservice runner in a provided org. <br> The orgs get provided and authorized via api tokens that can be optained via the /organizations endpoint.
* @param token
* @param requestBody CreateSelfServiceRunner
* @returns ResponseSelfServiceRunner
* @throws ApiError
*/
static async runnerSelfServiceControllerRegisterOrganizationRunner(token, requestBody) {
const result = await request_1.request({
method: 'POST',
path: `/api/runners/register/${token}`,
body: requestBody,
});
return result.body;
}
}
exports.RunnerSelfService = RunnerSelfService;