com.vzaar.api.Vzaar.getAccountDetails C# (CSharp) Method

getAccountDetails() public method

This API call returns the details and rights for each vzaar subscription account type along with it's relevant metadata. This will show the details of the packages available here: http://vzaar.com/pricing
public getAccountDetails ( int accountId ) : com.vzaar.api.AccountDetails
accountId int is the vzaar account type. This is an integer.
return com.vzaar.api.AccountDetails
        public AccountDetails getAccountDetails(int accountId)
        {
            var url = apiUrl + "/api/accounts/" + accountId + ".json";

            var response = executeRequest(url);
            var jo = (JObject)JsonConvert.DeserializeObject(response);

            var details = new AccountDetails
            {
                accountId = String.IsNullOrEmpty(jo["account_id"].ToString()) ? 0 : int.Parse(jo["account_id"].ToString()),
                title = (string)jo["title"],
                bandwidth = String.IsNullOrEmpty(jo["bandwidth"].ToString()) ? 0 : Int64.Parse(jo["bandwidth"].ToString()),
                cost = new AccountCostDetails
                {
                    monthly = String.IsNullOrEmpty(jo["cost"]["monthly"].ToString()) ? 0 : int.Parse(jo["cost"]["monthly"].ToString()),
                    currency = (string)jo["cost"]["currency"]
                },
                rights = new AccountRightsDetails
                {
                    borderless = String.IsNullOrEmpty(jo["rights"]["borderless"].ToString()) ? false : bool.Parse(jo["rights"]["borderless"].ToString()),
                    searchEnhancer = String.IsNullOrEmpty(jo["rights"]["searchEnhancer"].ToString()) ? false : bool.Parse(jo["rights"]["searchEnhancer"].ToString()),
                }
            };
            return details;
        }