PDA

View Full Version : Add Client through the API requires more fields



wifiguys
02-23-10, 08:47 PM
I'm trying to add clients though the api with only the first name, last name, email, and postal code. I can do this though the admin interface, but not through the api. I need to do it this way because with our Auth.net account those are the only fields required and when we start adding more fields to our shopping cart in raises our support costs.

Any help would be greatly appreciated

kmm2908
02-24-10, 03:13 AM
I'm trying to add clients though the api with only the first name, last name, email, and postal code. I can do this though the admin interface, but not through the api. I need to do it this way because with our Auth.net account those are the only fields required and when we start adding more fields to our shopping cart in raises our support costs.

Any help would be greatly appreciated

Suggest trying to add the other fields that you don't want to use as blank fields.


$postfields["address1"] = "";

Hope it works for you :-)

wifiguys
02-24-10, 01:59 PM
I tried that and it is still giving me the same error. I did find that if I add the client and then update the client I can update the fields required by the api to add a client to almost blank strings. It will do anything with the string: ''. But if I use the string: ' ' (note the space) it seems to blank out the fields in question. This feels pretty hooky though. And I have not tried it yet to see if it will work with our Auth.net account. I'm still worried that it will send information about the address, city, state, country that is not accurate. If there is a better way that I am missing I would very much appreciate any more help.

wifiguys
02-24-10, 02:08 PM
I just found that by updating with a null char, "\0", I can in fact get rid of the address1, city, state, country, and phonenumber fields. I checked in the DB and the result is the same as when done through the admin interface, so this is a working solution.

wifiguys
02-24-10, 02:29 PM
I take it back. When logging into the client area I can see the null chars for any field updated with one. Same if a pass a field with a one space string. So it seems that I'm back to square one. Again if anyone has encountered this issue or knows how I can get around I would really appreciate your help.

formulaclick
03-19-11, 11:14 AM
HI

Any solution to this issue??? I'm in the same situation...

Thanks