musora-content-services 2.145.9 → 2.146.1
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/CHANGELOG.md +9 -0
- package/package.json +1 -1
- package/publish.sh +6 -6
- package/src/index.d.ts +2 -0
- package/src/index.js +2 -0
- package/src/services/multi-user-accounts/multi-user-accounts.ts +14 -4
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [2.146.1](https://github.com/railroadmedia/musora-content-services/compare/v2.146.0...v2.146.1) (2026-04-02)
|
|
6
|
+
|
|
7
|
+
## [2.146.0](https://github.com/railroadmedia/musora-content-services/compare/v2.145.9...v2.146.0) (2026-04-02)
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Features
|
|
11
|
+
|
|
12
|
+
* **BEHLPT-18:** remove user from muppet ([#891](https://github.com/railroadmedia/musora-content-services/issues/891)) ([ecdf778](https://github.com/railroadmedia/musora-content-services/commit/ecdf778108f974f59885c3d442c47c90152c5554))
|
|
13
|
+
|
|
5
14
|
### [2.145.9](https://github.com/railroadmedia/musora-content-services/compare/v2.145.8...v2.145.9) (2026-04-01)
|
|
6
15
|
|
|
7
16
|
### [2.145.8](https://github.com/railroadmedia/musora-content-services/compare/v2.145.7...v2.145.8) (2026-04-01)
|
package/package.json
CHANGED
package/publish.sh
CHANGED
|
@@ -4,16 +4,16 @@
|
|
|
4
4
|
set -e
|
|
5
5
|
|
|
6
6
|
# Check if there are uncommitted changes.
|
|
7
|
-
if ! git diff-index --quiet HEAD --; then
|
|
8
|
-
echo "You have uncommitted changes. Please commit or stash them before publishing."
|
|
9
|
-
exit 1
|
|
10
|
-
fi
|
|
7
|
+
#if ! git diff-index --quiet HEAD --; then
|
|
8
|
+
# echo "You have uncommitted changes. Please commit or stash them before publishing."
|
|
9
|
+
# exit 1
|
|
10
|
+
#fi
|
|
11
11
|
|
|
12
12
|
# Run the release script
|
|
13
|
-
npm run release
|
|
13
|
+
# npm run release
|
|
14
14
|
|
|
15
15
|
# Push the changes and tags to the remote repository
|
|
16
|
-
git push --follow-tags origin main
|
|
16
|
+
# git push --follow-tags origin main
|
|
17
17
|
|
|
18
18
|
# Publish the package to npm
|
|
19
19
|
npm publish
|
package/src/index.d.ts
CHANGED
|
@@ -218,6 +218,7 @@ import {
|
|
|
218
218
|
createAccount,
|
|
219
219
|
createInvites,
|
|
220
220
|
fetchUsersMultiAccountDetails,
|
|
221
|
+
removeUserFromActiveMultiUserAccount,
|
|
221
222
|
rescindInvite
|
|
222
223
|
} from './services/multi-user-accounts/multi-user-accounts.ts';
|
|
223
224
|
|
|
@@ -727,6 +728,7 @@ declare module 'musora-content-services' {
|
|
|
727
728
|
registerProgressCallback,
|
|
728
729
|
removeContentAsInterested,
|
|
729
730
|
removeContentAsNotInterested,
|
|
731
|
+
removeUserFromActiveMultiUserAccount,
|
|
730
732
|
removeUserPractice,
|
|
731
733
|
replyToComment,
|
|
732
734
|
report,
|
package/src/index.js
CHANGED
|
@@ -222,6 +222,7 @@ import {
|
|
|
222
222
|
createAccount,
|
|
223
223
|
createInvites,
|
|
224
224
|
fetchUsersMultiAccountDetails,
|
|
225
|
+
removeUserFromActiveMultiUserAccount,
|
|
225
226
|
rescindInvite
|
|
226
227
|
} from './services/multi-user-accounts/multi-user-accounts.ts';
|
|
227
228
|
|
|
@@ -726,6 +727,7 @@ export {
|
|
|
726
727
|
registerProgressCallback,
|
|
727
728
|
removeContentAsInterested,
|
|
728
729
|
removeContentAsNotInterested,
|
|
730
|
+
removeUserFromActiveMultiUserAccount,
|
|
729
731
|
removeUserPractice,
|
|
730
732
|
replyToComment,
|
|
731
733
|
report,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @module MultiUserAccounts
|
|
3
3
|
*/
|
|
4
|
-
import { HttpClient } from '../../infrastructure/http/HttpClient'
|
|
4
|
+
import { HttpClient, DELETE } from '../../infrastructure/http/HttpClient'
|
|
5
5
|
import { globalConfig } from '../config.js'
|
|
6
6
|
|
|
7
7
|
const baseUrl = `/api/multi-user-accounts/v1`
|
|
@@ -75,9 +75,7 @@ export async function createAccount(params: CreateAccountParams): Promise<MultiU
|
|
|
75
75
|
*/
|
|
76
76
|
export async function fetchUsersMultiAccountDetails(userId: number): Promise<UsersMultiAccountResponse> {
|
|
77
77
|
const httpClient = new HttpClient(globalConfig.baseUrl)
|
|
78
|
-
|
|
79
|
-
console.log(url)
|
|
80
|
-
return httpClient.get<UsersMultiAccountResponse>(url)
|
|
78
|
+
return httpClient.get<UsersMultiAccountResponse>(`${baseUrl}/${userId}/details`)
|
|
81
79
|
}
|
|
82
80
|
|
|
83
81
|
/**
|
|
@@ -115,3 +113,15 @@ export async function rescindInvite(inviteId: number): Promise<void> {
|
|
|
115
113
|
const httpClient = new HttpClient(globalConfig.baseUrl)
|
|
116
114
|
return httpClient.post<void>(`${baseUrl}/invites/${inviteId}/rescind`, {})
|
|
117
115
|
}
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
/**
|
|
119
|
+
* Removes a member from a multi-user account. authorized user must be the primary account owner, or the user passed
|
|
120
|
+
*
|
|
121
|
+
* @param {number} userId - Id of the user to remove
|
|
122
|
+
* @returns {Promise<void|MultiUserAccountResponse>} - Updated MultiUserAccountResponse if account owner, void if active user
|
|
123
|
+
* @throws {HttpError} - If the request fails.
|
|
124
|
+
*/
|
|
125
|
+
export async function removeUserFromActiveMultiUserAccount(userId: number): Promise<MultiUserAccountResponse|void> {
|
|
126
|
+
return DELETE(`${globalConfig.baseUrl}${baseUrl}/${userId}/remove`, {})
|
|
127
|
+
}
|