Flag programs: update, delete
The Flag Verbs update, delete as MCP do programs, with inputs, result, refusals and an example.
Reference for Flag, one group of Flag programs.
Flag.update
Changes the given properties of a Flag. Verb page.
do: return await $.Flag.update(input)Emits Flag.updated.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
id | string | required | The id of the Flag. |
key | string | The name code reads. | |
rules | json | Who gets which value, including percentage splits. |
Returns
| Output | Type | Required | Description |
|---|---|---|---|
flag | Flag | required | The Flag. |
Refuses when
| Check | Error | Fix | Then call |
|---|---|---|---|
| The key is valid, but its scopes do not allow this operation. | forbidden | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |
Example
{
"name": "do",
"arguments": {
"code": "return await $.Flag.update({ id: 'flag_1YJLhjTlfx', key: 'new-checkout' })"
}
}Flag.delete
Deletes a Flag: a soft delete that keeps its history, undone by Thing.restore. Verb page.
do: return await $.Flag.delete(input)Emits Flag.deleted.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
id | string | required | The id of the Flag. |
Returns
| Output | Type | Required | Description |
|---|---|---|---|
flag | Flag | required | The Flag. |
Refuses when
| Check | Error | Fix | Then call |
|---|---|---|---|
| The key is valid, but its scopes do not allow this operation. | forbidden | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |
Example
{
"name": "do",
"arguments": {
"code": "return await $.Flag.delete({ id: 'flag_1YJLhjTlfx' })"
}
}