@parra/parra-js-sdk 0.3.91 → 0.3.92
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/ParraAPI.d.ts +18 -0
- package/dist/ParraAPI.js +26 -0
- package/package.json +1 -1
package/dist/ParraAPI.d.ts
CHANGED
|
@@ -95,6 +95,9 @@ export interface ImageAsset {
|
|
|
95
95
|
export interface UploadUserAvatarRequestBody {
|
|
96
96
|
image: File;
|
|
97
97
|
}
|
|
98
|
+
export interface UploadTenantUserAvatarRequestBody {
|
|
99
|
+
image: File;
|
|
100
|
+
}
|
|
98
101
|
export interface CreateCheckoutSessionRequestBody {
|
|
99
102
|
plan_id: string;
|
|
100
103
|
}
|
|
@@ -828,6 +831,7 @@ export interface CreateTicketRequestBody {
|
|
|
828
831
|
voting_enabled: boolean;
|
|
829
832
|
is_public: boolean;
|
|
830
833
|
user_note_id?: string | null;
|
|
834
|
+
estimated_start_date?: string | null;
|
|
831
835
|
estimated_completion_date?: string | null;
|
|
832
836
|
}
|
|
833
837
|
export declare enum ReleaseStatus {
|
|
@@ -874,6 +878,7 @@ export interface TicketStub {
|
|
|
874
878
|
voting_enabled: boolean;
|
|
875
879
|
is_public: boolean;
|
|
876
880
|
user_note_id?: string | null;
|
|
881
|
+
estimated_start_date?: string | null;
|
|
877
882
|
estimated_completion_date?: string | null;
|
|
878
883
|
ticket_number: string;
|
|
879
884
|
tenant_id: string;
|
|
@@ -894,6 +899,7 @@ export interface Ticket {
|
|
|
894
899
|
voting_enabled: boolean;
|
|
895
900
|
is_public: boolean;
|
|
896
901
|
user_note_id?: string | null;
|
|
902
|
+
estimated_start_date?: string | null;
|
|
897
903
|
estimated_completion_date?: string | null;
|
|
898
904
|
ticket_number: string;
|
|
899
905
|
tenant_id: string;
|
|
@@ -965,6 +971,7 @@ export interface UpdateTicketRequestBody {
|
|
|
965
971
|
description?: string | null;
|
|
966
972
|
voting_enabled?: boolean;
|
|
967
973
|
is_public?: boolean;
|
|
974
|
+
estimated_start_date?: string | null;
|
|
968
975
|
estimated_completion_date?: string | null;
|
|
969
976
|
}
|
|
970
977
|
export interface BulkUpdateTicketsRequestBody {
|
|
@@ -977,6 +984,7 @@ export interface BulkUpdateTicketsRequestBody {
|
|
|
977
984
|
description?: string | null;
|
|
978
985
|
voting_enabled?: boolean;
|
|
979
986
|
is_public?: boolean;
|
|
987
|
+
estimated_start_date?: string | null;
|
|
980
988
|
estimated_completion_date?: string | null;
|
|
981
989
|
ticket_ids?: Array<string>;
|
|
982
990
|
}
|
|
@@ -1005,6 +1013,7 @@ export interface UserTicket {
|
|
|
1005
1013
|
voting_enabled: boolean;
|
|
1006
1014
|
voted: boolean;
|
|
1007
1015
|
ticket_number: string;
|
|
1016
|
+
estimated_start_date?: string | null;
|
|
1008
1017
|
estimated_completion_date?: string | null;
|
|
1009
1018
|
released_at?: string | null;
|
|
1010
1019
|
}
|
|
@@ -1012,6 +1021,7 @@ export interface ReleaseVersionInfoRequestBody {
|
|
|
1012
1021
|
type: ReleaseType;
|
|
1013
1022
|
}
|
|
1014
1023
|
export interface ReleaseVersionInfo {
|
|
1024
|
+
latest_release?: ReleaseStub;
|
|
1015
1025
|
version: string;
|
|
1016
1026
|
name: string;
|
|
1017
1027
|
}
|
|
@@ -1508,6 +1518,11 @@ export interface TeamMember {
|
|
|
1508
1518
|
email: string;
|
|
1509
1519
|
avatar?: ImageAssetStub;
|
|
1510
1520
|
}
|
|
1521
|
+
export interface UpdateTenantUserRequestBody {
|
|
1522
|
+
identity?: string;
|
|
1523
|
+
name?: string | null;
|
|
1524
|
+
properties?: object | null;
|
|
1525
|
+
}
|
|
1511
1526
|
export interface TenantUserCollectionResponse {
|
|
1512
1527
|
page: number;
|
|
1513
1528
|
page_count: number;
|
|
@@ -1558,6 +1573,7 @@ declare class ParraAPI {
|
|
|
1558
1573
|
getParraAuthToken: () => Promise<AuthToken>;
|
|
1559
1574
|
uploadImageAssetForTenantById: (tenant_id: string, body: UploadImageAssetForTenantRequestBody) => Promise<ImageAsset>;
|
|
1560
1575
|
uploadAvatarForUser: (body: UploadUserAvatarRequestBody) => Promise<ImageAssetStub>;
|
|
1576
|
+
uploadAvatarForTenantUser: (tenant_id: string, body: UploadTenantUserAvatarRequestBody) => Promise<ImageAssetStub>;
|
|
1561
1577
|
createCheckoutSession: (body: CreateCheckoutSessionRequestBody) => Promise<CheckoutSession>;
|
|
1562
1578
|
getPlansForTenantById: (tenant_id: string) => Promise<TenantPlansResponse>;
|
|
1563
1579
|
createBillingPortalSession: (tenant_id: string) => Promise<BillingPortalSession>;
|
|
@@ -1786,6 +1802,8 @@ declare class ParraAPI {
|
|
|
1786
1802
|
getTeamMembersForTenantById: (tenant_id: string) => Promise<Array<TeamMember>>;
|
|
1787
1803
|
deleteTeamMemberForTenantById: (tenant_id: string, team_member_id: string) => Promise<Response>;
|
|
1788
1804
|
getUserForTenantById: (tenant_id: string, user_id: string) => Promise<TenantUser>;
|
|
1805
|
+
updateUserForTenantById: (tenant_id: string, user_id: string, body?: UpdateTenantUserRequestBody) => Promise<TenantUser>;
|
|
1806
|
+
deleteUserForTenantById: (tenant_id: string, user_id: string) => Promise<Response>;
|
|
1789
1807
|
paginateTenantUsersForTenantById: (tenant_id: string, query?: {
|
|
1790
1808
|
$select?: string;
|
|
1791
1809
|
$top?: number;
|
package/dist/ParraAPI.js
CHANGED
|
@@ -245,6 +245,18 @@ var ParraAPI = /** @class */ (function () {
|
|
|
245
245
|
headers: {},
|
|
246
246
|
});
|
|
247
247
|
};
|
|
248
|
+
this.uploadAvatarForTenantUser = function (tenant_id, body) {
|
|
249
|
+
var formData = new FormData();
|
|
250
|
+
Object.entries(body).forEach(function (_a) {
|
|
251
|
+
var key = _a[0], value = _a[1];
|
|
252
|
+
formData.append(key, value);
|
|
253
|
+
});
|
|
254
|
+
return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/avatar"), {
|
|
255
|
+
method: "post",
|
|
256
|
+
body: formData,
|
|
257
|
+
headers: {},
|
|
258
|
+
});
|
|
259
|
+
};
|
|
248
260
|
this.createCheckoutSession = function (body) {
|
|
249
261
|
return _this.http.execute("".concat(_this.options.baseUrl, "/v1/checkout/sessions"), {
|
|
250
262
|
method: "post",
|
|
@@ -971,6 +983,20 @@ var ParraAPI = /** @class */ (function () {
|
|
|
971
983
|
method: "get",
|
|
972
984
|
});
|
|
973
985
|
};
|
|
986
|
+
this.updateUserForTenantById = function (tenant_id, user_id, body) {
|
|
987
|
+
return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id), {
|
|
988
|
+
method: "put",
|
|
989
|
+
body: JSON.stringify(body),
|
|
990
|
+
headers: {
|
|
991
|
+
"content-type": "application/json",
|
|
992
|
+
},
|
|
993
|
+
});
|
|
994
|
+
};
|
|
995
|
+
this.deleteUserForTenantById = function (tenant_id, user_id) {
|
|
996
|
+
return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id), {
|
|
997
|
+
method: "delete",
|
|
998
|
+
});
|
|
999
|
+
};
|
|
974
1000
|
this.paginateTenantUsersForTenantById = function (tenant_id, query) {
|
|
975
1001
|
return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users"), {
|
|
976
1002
|
method: "get",
|