Fetch and instance of a usage-trigger

GET /2010-04-01/Accounts/{AccountSid}/Usage/Triggers/{Sid}.json

Webhooks that notify you of usage thresholds

Fetch and instance of a usage-trigger

Path parameters

  • AccountSid string Required

    The SID of the Account that created the UsageTrigger resource to fetch.

  • Sid string Required

    The Twilio-provided string that uniquely identifies the UsageTrigger resource to fetch.

Responses

  • OK

    Hide response attributes Show response attributes object
    • account_sid string | null

      The SID of the Account that this trigger monitors

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^AC[0-9a-fA-F]{32}$.

    • api_version string | null

      The API version used to create the resource

    • callback_method string(http-method) | null

      The HTTP method we use to call callback_url

      Values are HEAD, GET, POST, PATCH, PUT, or DELETE.

    • callback_url string(uri) | null

      he URL we call when the trigger fires

    • current_value string | null

      The current value of the field the trigger is watching

    • date_created string(date-time-rfc-2822) | null

      The RFC 2822 date and time in GMT that the resource was created

    • date_fired string(date-time-rfc-2822) | null

      The RFC 2822 date and time in GMT that the trigger was last fired

    • date_updated string(date-time-rfc-2822) | null

      The RFC 2822 date and time in GMT that the resource was last updated

    • friendly_name string | null

      The string that you assigned to describe the trigger

    • recurring string | null

      The frequency of a recurring UsageTrigger

      Values are daily, monthly, yearly, or alltime.

    • sid string | null

      The unique string that identifies the resource

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^UT[0-9a-fA-F]{32}$.

    • trigger_by string | null

      The field in the UsageRecord resource that fires the trigger

      Values are count, usage, or price.

    • trigger_value string | null

      The value at which the trigger will fire

    • uri string(uri) | null

      The URI of the resource, relative to https://api.twilio.com

    • usage_category string | null

      The usage category the trigger watches

    • usage_record_uri string | null

      The URI of the UsageRecord resource this trigger watches

GET /2010-04-01/Accounts/{AccountSid}/Usage/Triggers/{Sid}.json
curl \
 -X GET https://api.twilio.com/2010-04-01/Accounts/{AccountSid}/Usage/Triggers/{Sid}.json \
 --user "username:password"
Response examples (200)
{
  "account_sid": "string",
  "api_version": "string",
  "callback_method": "HEAD",
  "callback_url": "https://example.com",
  "current_value": "string",
  "date_created": "string",
  "date_fired": "string",
  "date_updated": "string",
  "friendly_name": "string",
  "recurring": "daily",
  "sid": "string",
  "trigger_by": "count",
  "trigger_value": "string",
  "uri": "https://example.com",
  "usage_category": "a2p-registration-fees",
  "usage_record_uri": "string"
}
Response examples (200)
{
  "account_sid": "string",
  "api_version": "string",
  "callback_method": "HEAD",
  "callback_url": "https://example.com",
  "current_value": "string",
  "date_created": "string",
  "date_fired": "string",
  "date_updated": "string",
  "friendly_name": "string",
  "recurring": "daily",
  "sid": "string",
  "trigger_by": "count",
  "trigger_value": "string",
  "uri": "https://example.com",
  "usage_category": "a2p-registration-fees",
  "usage_record_uri": "string"
}