Skip to navigation

Preview which users a proposed credit limit change would block

Beta

Preview which users would be blocked by a proposed set of credit limit changes. This is a dry run: no credit limits are created, updated, or deleted.

Returns the users whose AI credit usage this month already meets or exceeds the effective limit they would have after the proposed changes. A user’s effective limit is the maximum of the tenant-wide limit and the limits of every team and organization they belong to.

Proposed creates are checked for field constraints and conflicts with existing limits; a successful preview does not guarantee that the write will succeed.

Notes

  • Requires tenant admin permission.
  • creates are validated with the same rules as the create endpoint.
  • updates and deletes must reference existing credit limits by id.
  • Users are returned in an unspecified but stable order.
  • Results are paginated, with a default pageSize of 50: pass the returned nextToken, with the same pageSize and proposed changes, to get the next page. A page may contain fewer than pageSize users, or none, even when more pages follow.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Headers

EARLY-ACCESSstringOptional

Set to true to access beta operations via /api/v3.

Request

This endpoint expects an object.
createslist of objectsOptional
Proposed credit limits to create. Validated with the same rules as the create endpoint.
deleteslist of objectsOptional

Existing credit limits proposed for deletion, identified by id.

nextTokenstringOptional

Token from a previous response’s nextToken, to continue from where that response ended. The pageSize and proposed changes must match the previous request.

pageSizeintegerOptional
Maximum number of blocked users to return, from 1 to 100. Defaults to 50.
updateslist of objectsOptional

Proposed changes to existing credit limits, identified by id.

Response

OK
blockedUserslist of objectsOptional
Users blocked by the proposed change, in an unspecified but stable order.
nextTokenstring or nullOptional

Token for retrieving the next page of blocked users, or null if there are no more. Pass it in the next request as nextToken, with the same pageSize and proposed changes, to continue. A non-null token may be followed by an empty page.

Errors

400
Bad Request Error
403
Forbidden Error
404
Not Found Error
409
Conflict Error
429
Too Many Requests Error
500
Internal Server Error