This month's usage and plan limits
GET
/usage
const url = 'https://api.duta.indra.sh/v1/usage';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
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://api.duta.indra.sh/v1/usage \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Responses
Section titled “ Responses ”Success
Media typeapplication/json
object
period
required
The calendar month, YYYY-MM
string
periodDays
required
number
plan
required
object
id
required
string
includedEmails
required
integer | null
overageSenPerThousand
required
integer | null
maxDomains
required
integer
dailyLimit
required
integer | null
logRetentionDays
required
integer
ratePerSecond
required
number
usage
required
object
usedThisMonth
required
integer
includedEmails
required
integer | null
overage
required
integer
overageBlocks
required
integer
overageChargedSen
required
Integer sen
integer
overageCapSen
required
integer | null
percent
required
number
counts
required
Messages by status over the last 30 days
object
key
additional properties
integer
Example
{ "periodDays": 30}Missing or invalid API key
Media typeapplication/json
object
statusCode
required
integer
name
required
The Resend error name, so code that branches on it keeps working
string
message
required
string
code
required
Duta’s error code, finer grained than name
string
detail
object
key
additional properties
request_id
required
Find this request on the Logs screen
string
Example
{ "code": "unauthorized"}The request was refused. code says why
Media typeapplication/json
object
statusCode
required
integer
name
required
The Resend error name, so code that branches on it keeps working
string
message
required
string
code
required
Duta’s error code, finer grained than name
string
detail
object
key
additional properties
request_id
required
Find this request on the Logs screen
string
Example
{ "code": "unauthorized"}Rate limited. Retry after the Retry-After header
Media typeapplication/json
object
statusCode
required
integer
name
required
The Resend error name, so code that branches on it keeps working
string
message
required
string
code
required
Duta’s error code, finer grained than name
string
detail
object
key
additional properties
request_id
required
Find this request on the Logs screen
string
Example
{ "code": "unauthorized"}