API Reference / Workspaces
Update a workspace
Updates the caller's active workspace's name or description. The target is always the workspace resolved from the caller's session or API key, never a request field, so a caller can never name a different workspace to update. Only the fields you supply are changed.
/ accounts. v1. Accounts/ UpdateWorkspaceRequest body
application/jsonRequired
Request to update the caller's current workspace. Fields left out are unchanged.
description?stringNew workspace description. Omit to leave unchanged.
name?stringNew workspace name. Omit to leave unchanged.
Response body
application/json
Success
workspace?WorkspaceThe workspace with the update applied.
Show attributes
createdAt?stringWhen the workspace was created.
Format"date-time"
deletedAt?stringWhen the workspace was soft-deleted. Unset for active workspaces.
Format"date-time"
description?stringFree-form workspace description set by the workspace owner.
getStartedCompletedAt?stringWhen the workspace completed Get started: the first time it had proxies, accounts, a connected market and a contract all at once. Unset until then. Once set it is never cleared.
Format"date-time"
hardDeleteAt?stringWhen a soft-deleted workspace and everything in it is removed permanently. Unset for active workspaces.
Format"date-time"
id?stringOpaque 16-byte workspace identifier, base64-encoded in JSON.
Format"byte" base64
memberCount?integerNumber of accepted memberships in the workspace, computed server-side at read time. Read-only: any value sent by a client is ignored.
Format"int32"
name?stringHuman-readable workspace name.
owner?ActorSummaryThe workspace owner resolved for display at read time. Set only on administrator reads. Unset when the workspace has no accepted owner.
Show attributes
avatarUrl?stringThe user's avatar image URL. Unset for an API key or a user with no avatar.
displayName?stringThe user's name or the API key's name at read time. Empty when the actor no longer exists.
id?stringOpaque 16-byte identifier of the user or API key, base64-encoded in JSON.
Format"byte" base64
subjectType?stringHow the actor authenticated: a user session or an API key.
Value in"SUBJECT_"SUBJECT_"SUBJECT_
ownerEmail?stringThe workspace owner's email. Set only on administrator reads.
updatedAt?stringWhen the workspace was last modified.
Format"date-time"
application/json
The request was malformed, such as a missing required field or an unparseable cursor.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The request lacks a valid API key in the Authorization header.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The API key is not allowed to perform this action on this workspace.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The requested resource does not exist in this workspace.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The request was rate limited. Slow down and retry later.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
An internal server error occurred.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
curl -X POST "https://api.goldmine.to/accounts.v1.Accounts/UpdateWorkspace" \
-H "Authorization: Bearer $CSTRADER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"description": "Primary trading and inventory workspace."
}'const res = await fetch("https://api.goldmine.to/accounts.v1.Accounts/UpdateWorkspace", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.CSTRADER_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"description": "Primary trading and inventory workspace."
}),
});
const data = await res.json();body := strings.NewReader(`{
"description": "Primary trading and inventory workspace."
}`)
req, err := http.NewRequestWithContext(ctx, http.MethodPost, "https://api.goldmine.to/accounts.v1.Accounts/UpdateWorkspace", body)
if err != nil {
return err
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("CSTRADER_API_KEY"))
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)import os, requests
res = requests.post(
"https://api.goldmine.to/accounts.v1.Accounts/UpdateWorkspace",
headers={"Authorization": f"Bearer {os.environ['CSTRADER_API_KEY']}"},
json={
"description": "Primary trading and inventory workspace."
},
)
data = res.json(){
"workspace": {
"id": "AAECAwQFBgcICQoLDA0ODw==",
"name": "Acme Trading",
"description": "Primary trading and inventory workspace.",
"createdAt": "2026-01-15T10:00:00Z",
"updatedAt": "2026-06-29T12:05:00Z"
}
}{
"code": "invalid_argument",
"message": "The request was malformed, such as a missing required field or an unparseable cursor."
}{
"code": "unauthenticated",
"message": "The request lacks a valid API key in the Authorization header."
}{
"code": "permission_denied",
"message": "The API key is not allowed to perform this action on this workspace."
}{
"code": "not_found",
"message": "The requested resource does not exist in this workspace."
}{
"code": "resource_exhausted",
"message": "The request was rate limited. Slow down and retry later."
}{
"code": "internal",
"message": "An internal server error occurred."
}