Get Message Credit Cost

This request is used to retrieve the estimated credit cost of any message configuration. It can only be used when the relevant message configuration id is available. The message configuration id is automatically generated and returned by the system upon message configuration.

HTTP Request

URLHTTP MethodDescription
https://app.tellody.com/CampaignCloud/Message/<message_configuration_id>/count GET Get credit cost for message

Sample Request

PythonOther

#Retrieving the XSRF Token needed for Session
pingResponse = my_session.get("https://app.tellody.com/CampaignCloud/RememberMeController/ping")

#Import the X-XSRF-Token returned from RememberMeController/ping into the request headers
xsrfToken = pingResponse.headers.get("X-XSRF-TOKEN")

#HTTP request header
header = {"Content-Type" : "application/json", "X-XSRF-TOKEN" : xsrfToken}
print('Retrieving credit count for message...')
url = "https://app.tellody.com/CampaignCloud/Message/" + response_id + "/count"
count = my_session.get(url,headers=header).json()
print(json.dumps(response,ensure_ascii=False))

Sample Response

The result returns a list of values with the top two values indicating the credits cost in integer and double representation, respectively.


  [
   2,
   2.0,
   ......
]
  

Errors

If the result of the request does not return any such list, then the request has failed. More information on the issue can be derived by the HTTP response. (e.g. HTTP 400, 414 etc.)

Back to Top