@devopness/sdk-js 2.11.1 → 2.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/generated/apis/users-team-invitations-api.d.ts +26 -0
- package/dist/api/generated/apis/users-team-invitations-api.js +53 -0
- package/dist/api/generated/models/invitation.d.ts +7 -0
- package/dist/services/UserService.d.ts +2 -0
- package/dist/services/UserService.js +5 -0
- package/package.json +1 -1
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* devopness API
|
|
3
|
+
* Devopness API - Painless essential DevOps to everyone
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: latest
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import { ApiBaseService } from "../../../services/ApiBaseService";
|
|
13
|
+
import { ApiResponse } from "../../../common/ApiResponse";
|
|
14
|
+
import { Invitation } from '../../generated/models';
|
|
15
|
+
/**
|
|
16
|
+
* UsersTeamInvitationsApiService - Auto-generated
|
|
17
|
+
*/
|
|
18
|
+
export declare class UsersTeamInvitationsApiService extends ApiBaseService {
|
|
19
|
+
/**
|
|
20
|
+
*
|
|
21
|
+
* @summary Returns a list of all pending team invitations for the authenticated user
|
|
22
|
+
* @param {number} [page] Number of the page to be retrieved
|
|
23
|
+
* @param {number} [perPage] Number of items returned per page
|
|
24
|
+
*/
|
|
25
|
+
listUserTeamInvitations(page?: number, perPage?: number): Promise<ApiResponse<Array<Invitation>>>;
|
|
26
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* devopness API
|
|
5
|
+
* Devopness API - Painless essential DevOps to everyone
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: latest
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
15
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
16
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
17
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
18
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
19
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
20
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
24
|
+
exports.UsersTeamInvitationsApiService = void 0;
|
|
25
|
+
const ApiBaseService_1 = require("../../../services/ApiBaseService");
|
|
26
|
+
const ApiResponse_1 = require("../../../common/ApiResponse");
|
|
27
|
+
/**
|
|
28
|
+
* UsersTeamInvitationsApiService - Auto-generated
|
|
29
|
+
*/
|
|
30
|
+
class UsersTeamInvitationsApiService extends ApiBaseService_1.ApiBaseService {
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @summary Returns a list of all pending team invitations for the authenticated user
|
|
34
|
+
* @param {number} [page] Number of the page to be retrieved
|
|
35
|
+
* @param {number} [perPage] Number of items returned per page
|
|
36
|
+
*/
|
|
37
|
+
listUserTeamInvitations(page, perPage) {
|
|
38
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
39
|
+
let queryString = '';
|
|
40
|
+
const queryParams = { page: page, per_page: perPage, };
|
|
41
|
+
for (const key in queryParams) {
|
|
42
|
+
if (queryParams[key] === undefined || queryParams[key] === null) {
|
|
43
|
+
continue;
|
|
44
|
+
}
|
|
45
|
+
queryString += (queryString ? '&' : '') + `${key}=${encodeURI(queryParams[key])}`;
|
|
46
|
+
}
|
|
47
|
+
const requestUrl = '/users/teams/invitations' + (queryString ? `?${queryString}` : '');
|
|
48
|
+
const response = yield this.get(requestUrl);
|
|
49
|
+
return new ApiResponse_1.ApiResponse(response);
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
exports.UsersTeamInvitationsApiService = UsersTeamInvitationsApiService;
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import { InvitationStatus } from './invitation-status';
|
|
13
|
+
import { ProjectRelation } from './project-relation';
|
|
13
14
|
import { TeamRelation } from './team-relation';
|
|
14
15
|
import { UserRelation } from './user-relation';
|
|
15
16
|
/**
|
|
@@ -66,6 +67,12 @@ export interface Invitation {
|
|
|
66
67
|
* @memberof Invitation
|
|
67
68
|
*/
|
|
68
69
|
team: TeamRelation;
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @type {ProjectRelation}
|
|
73
|
+
* @memberof Invitation
|
|
74
|
+
*/
|
|
75
|
+
project?: ProjectRelation;
|
|
69
76
|
/**
|
|
70
77
|
* The date and time when the invitation will expire
|
|
71
78
|
* @type {string}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
import { UsersApiService } from '../api/generated/apis/users-api';
|
|
2
|
+
import { UsersTeamInvitationsApiService } from '../api/generated/apis/users-team-invitations-api';
|
|
2
3
|
export declare class UserService extends UsersApiService {
|
|
4
|
+
teamInvitations: UsersTeamInvitationsApiService;
|
|
3
5
|
}
|
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.UserService = void 0;
|
|
4
4
|
const users_api_1 = require("../api/generated/apis/users-api");
|
|
5
|
+
const users_team_invitations_api_1 = require("../api/generated/apis/users-team-invitations-api");
|
|
5
6
|
class UserService extends users_api_1.UsersApiService {
|
|
7
|
+
constructor() {
|
|
8
|
+
super(...arguments);
|
|
9
|
+
this.teamInvitations = new users_team_invitations_api_1.UsersTeamInvitationsApiService();
|
|
10
|
+
}
|
|
6
11
|
}
|
|
7
12
|
exports.UserService = UserService;
|