question

terryasmith03 avatar image
terryasmith03 asked

Updating Stored Cards - getting 500 - Internal Server Error

I am trying to update the token on a stored card profile, to reflect a new card. I am receiving 500-ISE error code.


code sample:

    String PostUrl = BuildUrl + String.Format("/customers/{0}/cards/{1}?access_token=", passMdl.customer.id, passMdl.id) + _envInfo[_chargeToken];
                var client = new RestClient(PostUrl);
                List<object> ctjson = new List<object>();

                
                ctjson.Add(passMdl);
                var jsonStringify = ConvertModelToJSON(passMdl);

                IRestRequest reqPost = CloverRequestPOST;
                reqPost.AddParameter("application/json", jsonStringify, ParameterType.RequestBody);
                IRestResponse response = client.Execute(reqPost);
                if (response.IsSuccessful != true)
                {
                    throw
                        new Exception(response.Content);
                }
                created = true;

PostUrl works out to this: https://api.clover.com/v3/merchants/<removed>/customers/<removed>/cards/<removed>?access_token=<removed>


Any help would be appreciated.

Customers
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

0 Answers

·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community