Limit routes: raise
The Limit Verbs raise as api.sb routes, with inputs, result, refusals and an example.
Reference for Limit, one group of Limit routes.
Limit.raise
Raise lifts a Limit after an Approval allows it, and the Action that waited on it proceeds. Verb page.
POST /{namespace}/ limits/ {limit}/ raisePath: limit. Body, as JSON: the other inputs. Emits Limit.raised.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
limit | Limit | required | The Limit to lift. |
to | json | required | The new amount, count or rate. |
Returns
| Output | Type | Required | Description |
|---|---|---|---|
limit | Limit | required | The raised Limit. |
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. |
| The record is not in a state that allows this Verb, so the call is refused. | refused | Read the record, run the Verb that moves it to an allowed state, then retry. | None. |
Example
curl -X POST https: //api.sb/ leaseline.app/ limits/ limit_UWHXYVKsJB/ raise \
-H "Authorization: Bearer $STARTUP_BUILDER_API_KEY" \
-H "Content-Type: application/ json" \
-d '{"to": {}}'{
"api": "https: //api.sb/ leaseline.app",
"limit": {
"$id": "https: //api.sb/ leaseline.app/ limits/ limit_UWHXYVKsJB",
"$type": "Limit",
"amount": {
"amount": 29,
"currency": "USD"
},
"count": 1
},
"action": {
"$id": "https: //api.sb/ leaseline.app/ actions/ act_br07HsG8MG",
"operation": "Limit.raise",
"status": "done"
},
"links": {
"self": "https: //api.sb/ leaseline.app/ actions/ act_br07HsG8MG"
}
}