Reset a reader's metering count
Put one reader's question count back to zero, for testing a metering wall. It takes your Secret API Key. A publishable key returns 403. Send user_id, anonymous_id, or both. The count is the sum over both ids, so a front end that sends both on a question resets both. Returns 400 without an id, or when the app is not metered. A question the reader already asked in the last 30 days still does not count after the reset. See the Metering guide.
Body·
required
application/json
At least one of user_id or anonymous_id is required.
- Type: stringanonymous
_id The anonymous visitor id to reset.
- Type: stringuser
_id The signed-in reader to reset.
Responses
- application/json
- 400
No
user_idoranonymous_id, or the app is not metered. - 403
Publishable key.
- application/json
Request Example for post/v1/ask/metering/reset
curl https://api.askmiso.com/v1/ask/metering/reset \
--request POST \
--header 'Content-Type: application/json' \
--data '{
"user_id": "alice"
}'
{
"message": "success",
"data": {
"user_id": {
"id": "alice",
"previous_count": 5
}
}
}