JavaScript SDK: swarmhit.workspaces.update(workspaceId, params)
Updates any subset of a workspace's name, avatar (empty string clears
it) and seatAllocation. Lowering the allocation below the seats the
workspace already uses (its LinkedIn sender accounts) is rejected with
400, and so is over-allocating the organization pool,
unless the organization's seats are added on demand (pay as you go):
then the missing seats are added to the subscription instead.
Authorization
bearerAuth An API key created on the Access tokens page.
In: header
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Any subset of these fields.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/workspaces/string" \ -H "Content-Type: application/json" \ -d '{ "name": "Acme Inc.", "seatAllocation": 3 }'{ "data": { "id": "string", "name": "string", "avatar": "string", "seatAllocation": 0, "sendersUsed": 0, "mailboxesUsed": 0, "seatsUsed": 0, "ownerId": "string", "members": [ { "id": "string", "email": "string", "username": "string", "role": "owner" } ], "orgMembers": [ { "id": "string", "email": "string", "username": "string" } ], "invites": [ { "identifier": "string", "role": "admin", "createdAt": "2019-08-24T14:15:22Z" } ] }}Remove a workspace member or revoke an invite DELETE
**JavaScript SDK:** [`swarmhit.workspaces.members.remove(workspaceId, memberId, params?)`](/smart-api/sdk/methods#workspaces.members) Removes a member from the workspace, or revokes a pending invite. Pass `?type=invite` (with the invite email as `memberId`) to revoke an invite; `type` defaults to `user`. The workspace's owner, organization members and the last admin cannot be removed here (400).
Update a workspace member's role PATCH
**JavaScript SDK:** [`swarmhit.workspaces.members.update(workspaceId, memberId, params)`](/smart-api/sdk/methods#workspaces.members) Change the role of a workspace member or a pending invite. Set `type` to `user` (default; `memberId` is the user id) or `invite` (`memberId` is the invite email). Organization members cannot be changed here.