Skip to content

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.

Text
POST /{namespace}/limits/{limit}/raise

Path: limit. Body, as JSON: the other inputs. Emits Limit.raised.

Inputs

InputTypeRequiredDescription
limitLimitrequiredThe Limit to lift.
tojsonrequiredThe new amount, count or rate.

Returns

OutputTypeRequiredDescription
limitLimitrequiredThe raised Limit.

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.
The record is not in a state that allows this Verb, so the call is refused.refusedRead the record, run the Verb that moves it to an allowed state, then retry.None.

Example

Terminal
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":{}}'
JSON
{
  "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"
  }
}