Skip to content

Service programs: update, delete

The Service Verbs update, delete as MCP do programs, with inputs, result, refusals and an example.

Reference for Service, one group of Service programs.

Service.update

Changes the given properties of a Service. Verb page.

Text
do: return await $.Service.update(input)

Emits Service.updated.

Inputs

InputTypeRequiredDescription
idstringrequiredThe id of the Service.
namestringThe name of the Product.
promisetextWhat the Customer can rely on.
floorstringThe human floor: none, sign, or practice.

Returns

OutputTypeRequiredDescription
serviceServicerequiredThe Service.

Refuses when

CheckErrorFixThen call
The key is valid, but its scopes do not allow this operation.forbiddenUse a key whose scopes cover the operation, or ask an owner of the namespace to grant them.None.

Example

JSON
{
  "name": "do",
  "arguments": {
    "code": "return await $.Service.update({ id: 'service_Eq1ssq4AOW', floor: 'none' })"
  }
}

Service.delete

Deletes a Service: a soft delete that keeps its history, undone by Thing.restore. Verb page.

Text
do: return await $.Service.delete(input)

Emits Service.deleted.

Inputs

InputTypeRequiredDescription
idstringrequiredThe id of the Service.

Returns

OutputTypeRequiredDescription
serviceServicerequiredThe Service.

Refuses when

CheckErrorFixThen call
The key is valid, but its scopes do not allow this operation.forbiddenUse a key whose scopes cover the operation, or ask an owner of the namespace to grant them.None.

Example

JSON
{
  "name": "do",
  "arguments": {
    "code": "return await $.Service.delete({ id: 'service_Eq1ssq4AOW' })"
  }
}