Twilio. Usage. Records. Yesterday
(twilio v0.2.0)
Copy Markdown
API calls: list.
Summary
Functions
GET /2010-04-01/Accounts/{AccountSid}/Usage/Records/Yesterday.json
Like list/2, but returns the result or raises Infusion.Runtime.Error.
Like list/2, but returns every item, from every page: a lazy stream of Twilio.Schemas.UsageRecordYesterday.t() that fetches pages as it is read.
Like list_all/2, but returns the stream or raises Infusion.Runtime.Error.
Functions
@spec list(map() | keyword(), keyword()) :: {:ok, Twilio.Schemas.UsageRecordsYesterdayListResponse.t()} | {:error, Infusion.Runtime.Error.t()}
GET /2010-04-01/Accounts/{AccountSid}/Usage/Records/Yesterday.json
{AccountSid} in the path is the :account_sid setting; pass account_sid: "..." as an option to use another.
Parameters
category- The usage category of the UsageRecord resources to read. Only UsageRecord resources in the specified category are retrieved.start_date- Only include usage that has occurred on or after this date. Specify the date in GMT and format asYYYY-MM-DD. You can also specify offsets from the current date, such as:-30days, which will set the start date to be 30 days before the current date.end_date- Only include usage that occurred on or before this date. Specify the date in GMT and format asYYYY-MM-DD. You can also specify offsets from the current date, such as:+30days, which will set the end date to 30 days from the current date.include_subaccounts- Whether to include usage from the master account and all its subaccounts. Can be:true(the default) to include usage from the master account and all subaccounts orfalseto retrieve usage from only the specified account.page_size- How many resources to return in each list page. The default is 50, and the maximum is 1000.page- The page index. This value is simply for client state.page_token- The page token. This is provided by the API.
To read every item across all pages, use list_all.
@spec list!(map() | keyword(), keyword()) :: Twilio.Schemas.UsageRecordsYesterdayListResponse.t()
Like list/2, but returns the result or raises Infusion.Runtime.Error.
@spec list_all(map() | keyword(), keyword()) :: {:ok, Enumerable.t()} | {:error, Infusion.Runtime.Error.t()}
Like list/2, but returns every item, from every page: a lazy stream of Twilio.Schemas.UsageRecordYesterday.t() that fetches pages as it is read.
The first page is fetched right away, so its errors are returned; a later page that fails raises Infusion.Runtime.Error. Stopping early (Enum.take/2) fetches no more pages.
@spec list_all!(map() | keyword(), keyword()) :: Enumerable.t()
Like list_all/2, but returns the stream or raises Infusion.Runtime.Error.