Reads whether over-quota consumption may draw on the caller's OWN balance for this metric.
GET
/api/v1/provision/consumer/me/credits/{metric}/spending
const url = 'https://example.com/api/v1/provision/consumer/me/credits/example/spending';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/api/v1/provision/consumer/me/credits/example/spendingParameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”metric
required
string
The balance-carrying metric.
Query Parameters
Section titled “Query Parameters”sessionId
string format: uuid
The caller’s own session id.
Responses
Section titled “Responses”OK
The current state of a balance’s consumer spending switch.
object
entitlementId
string format: uuid
metric
string
allowed
true when over-quota consumption may draw on this balance.
boolean
The current state of a balance’s consumer spending switch.
object
entitlementId
string format: uuid
metric
string
allowed
true when over-quota consumption may draw on this balance.
boolean
Examplegenerated
{ "entitlementId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "metric": "example", "allowed": true}The current state of a balance’s consumer spending switch.
object
entitlementId
string format: uuid
metric
string
allowed
true when over-quota consumption may draw on this balance.
boolean
Examplegenerated
{ "entitlementId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "metric": "example", "allowed": true}Unauthorized
object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}Forbidden
object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}Not Found
object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}object
type
null | string
title
null | string
status
null | integer | string format: int32
detail
null | string
instance
null | string
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}