Skip to main content

Get SMS Rate

This request returns the SMS rates for the destination phone number and the direction specified in the request.

get /rating/sms/{sub_type}

Sample

A sample GET request to get rates for an SMS sent to or received from the phone number specified in the request:

curl -X GET \
'https://api.carrierx.com/core/v2/rating/sms/toll?direction=outbound&message_segments=1&to=17605692222' \
-H 'Authorization: Bearer 5ebc03d6-8b2b-44ad-bf65-72d4f1491dda'

Response

200 status code with a serialized copy of the Rating MCC/MNC Response object:

{
"direction": "outbound",
"price": "0.01000",
"rate": "0.01000",
"segments": "1"
}

Required Scopes

To get information about a Rating MCC/MNC Response object, the partner must have one of the following scopes enabled:

  • rating.manage
  • rating.read

Path Arguments

ParameterData TypeDescription
sub_type requiredstringThe type of the rating used to calculate the price for the SMS. Values accepted in this field are short_code, toll, and toll_free.

Query Arguments

ParameterData TypeDescription
direction requiredstringThe direction of the SMS. Values accepted in this field are:
  • inbound for receiving the SMS from the destination phone number.
  • outbound for sending the MMS to the destination phone number.
partner_sidstringThe secure ID of the partner for which you want to calculate the SMS price.
to requiredstringThe destination phone number.