Skip to content

Update workspace

POST
/rest/workspaces/{id}/config/{configId}/update
curl --request POST \
--url https://api.shypr.app/rest/workspaces/example/config/example/update \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <X-API-KEY>' \
--data '{ "key": "email.from.name", "value": "example" }'

Creates a Workspace resource.

id
required
string

Workspace identifier

configId
required
string

Workspace identifier

The new Workspace resource

object
key
required
string
Allowed values: email.from.name email.from.address email.transport.name email.transport.host email.transport.port email.transport.tls email.auth.username email.auth.password finance.sequence.prefix finance.sequence.suffix finance.accountant.email carriers.select-courier.key carriers.select-courier.secret carriers.sendcloud.key carriers.sendcloud.secret carriers.sendcloud.webhook.secret payment.gateway.mollie.key payment.gateway.mollie.webhook.secret payment.transaction.fee.percentage tos.file.id workspace.portal.domain workspace.brand.color workspace.onboarding.hidden app.cron.enabled app.worker.enabled
value

Workspace resource created

object
avatarUrl
string | null
deactivatedAt

Set by a Dev. Nobody works in a deactivated workspace: no login, no session, no API key and no MCP connection, see UserAccount::canUseWorkspace(). A Dev keeps access, so a Dev can reactivate it. The data and the members stay, so a reactivation gives all access back.

string | null format: date-time
aiAllowance

Set by a Dev: the AI cost that the workspace may use in one period, in cents (one credit each). Null takes the allowance of the plan, see PaymentPlanType::aiAllowance().

integer | null
suspiciousAt

Set by the AI after a sign-up, when the sign-up looks like abuse (spam, a fake name, a throwaway address), see ScreenSignUpHandler. It marks the workspace and a Dev decides, but the workspace cannot send mail through the Shypr domain (MailTransportFactory::shypr()) until a Dev clears the mark (clearSuspicion).

string | null format: date-time
suspicionReason

Why the AI marked the workspace, with $suspiciousAt.

string | null
defaultCurrency

The currency of a new record when the customer or the supplier has no currency of the workspace. It is always one of the currencies.

object
currencyCode

The currency code. For ISO currencies this will be the 3-letter uppercase ISO 4217 currency code. For non-ISO currencies no constraints are defined, but the code must be unique across an application and must not conflict with ISO currency codes.

string
numericCode

The numeric currency code. For ISO currencies this will be the ISO 4217 numeric currency code. For non-ISO currencies no constraints are defined, but the code must be unique across an application and must not conflict with ISO currency codes. Set to null if the currency does not have a numeric code.

integer | null
name

The currency name. For ISO currencies this will be the official English name of the currency. For non-ISO currencies no constraints are defined.

string
defaultFractionDigits

The default number of fraction digits (typical scale) used with this currency. For example, the default number of fraction digits for the Euro is 2, while for the Japanese Yen it is 0. This cannot be a negative number.

integer
currencyType

The type of the currency. For ISO currencies, this indicates whether the currency is currently in use (IsoCurrent) or has been withdrawn (IsoHistorical). For non-ISO currencies defined by the application, the type is Custom.

object
name
string
currencies

The ISO 4217 codes that a quote, a purchase order and a bank account of the workspace can take, the default first. A record keeps its currency when the workspace removes it.

Array<string>
ossRegistered

True when the workspace is registered for the One Stop Shop: a sale to a consumer in another EU country then has the VAT rate of that country, else the rate of the workspace. See docs/vat.md.

boolean
location
string | null format: iri-reference
avatar
string | null format: iri-reference
bankAccounts
Array<string>
config
Array<object>
object
value
dataType
string
Allowed values: S I B D O A
key
string
Allowed values: email.from.name email.from.address email.transport.name email.transport.host email.transport.port email.transport.tls email.auth.username email.auth.password finance.sequence.prefix finance.sequence.suffix finance.accountant.email carriers.select-courier.key carriers.select-courier.secret carriers.sendcloud.key carriers.sendcloud.secret carriers.sendcloud.webhook.secret payment.gateway.mollie.key payment.gateway.mollie.webhook.secret payment.transaction.fee.percentage tos.file.id workspace.portal.domain workspace.brand.color workspace.onboarding.hidden app.cron.enabled app.worker.enabled
id

More information

string format: uuid
uid
string
typeModel
string
Allowed values: email.from.name email.from.address email.transport.name email.transport.host email.transport.port email.transport.tls email.auth.username email.auth.password finance.sequence.prefix finance.sequence.suffix finance.accountant.email carriers.select-courier.key carriers.select-courier.secret carriers.sendcloud.key carriers.sendcloud.secret carriers.sendcloud.webhook.secret payment.gateway.mollie.key payment.gateway.mollie.webhook.secret payment.transaction.fee.percentage tos.file.id workspace.portal.domain workspace.brand.color workspace.onboarding.hidden app.cron.enabled app.worker.enabled
paymentPlan
string
Allowed values: DEMO TRIAL BOAT YACHT TITANIC EP
name
string
subdomain
string
vatNo
string | null
cocNo
string | null
email
string
phoneNumber
string | null
faxNumber
string | null
website
string | null
eoriNumber
string | null
createdAt
string format: date-time
updatedAt
string | null format: date-time
id

More information

string format: uuid
uid
string
kenosha
boolean
apMailAddress
string
configs
Array<Array>

Example

{
"ossRegistered": false,
"location": "https://example.com/",
"avatar": "https://example.com/",
"bankAccounts": [
"https://example.com/"
],
"config": [
{
"dataType": "S",
"key": "email.from.name",
"typeModel": "email.from.name"
}
],
"paymentPlan": "DEMO"
}

Invalid input

A representation of common errors.

object
title

A short, human-readable summary of the problem.

string | null
detail

A human-readable explanation specific to this occurrence of the problem.

string | null
status
integer | null
default: 400
instance

A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.

string | null
type

A URI reference that identifies the problem type

string

Example

{
"status": 400
}

Forbidden

A representation of common errors.

object
title

A short, human-readable summary of the problem.

string | null
detail

A human-readable explanation specific to this occurrence of the problem.

string | null
status
integer | null
default: 400
instance

A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.

string | null
type

A URI reference that identifies the problem type

string

Example

{
"status": 400
}

An error occurred

Unprocessable entity

object
status
integer
default: 422
violations
Array<object>
object
propertyPath
required

The property path of the violation

string
message
required

The message associated with the violation

string
code

The code of the violation

string
hint

An extra hint to understand the violation

string
payload

The serialized payload of the violation

object
key
additional properties
any
detail
string
type
string
title
string | null
instance
string | null

Example

{
"status": 422
}