83604: Query period exceeds the maximum allowed for the requested Granularity
GENERAL USAGE
ERROR
This error occurs when your Usage Records request spans more time than the selected granularity supports. Requests with all can query up to 18 months of data, requests with day can query up to 3 months of data, and requests with hour can query up to 31 days of data.
- Your request uses
startDateandendDatevalues that define a date range longer than the allowed limit for the granularity you selected. - Your request asks for
hourdata across more than 31 days. - Your request asks for
daydata across more than 3 months, oralldata across more than 18 months.
- Reduce the time span between
startDateandendDateso the request stays within the supported limit for the granularity you need. - Send
startDateandendDateinYYYY-MM-DDformat so Twilio can evaluate the requested period correctly. - If you need a different reporting interval, use one of the supported Usage Records subresources such as
Daily,Monthly,Yearly,AllTime,ThisMonth, orLastMonthinstead of querying an unsupported range.