Difference between revisions of "Offerit API Set Member Details"
From Offerit
(→Sample Output) |
(→Server Request/Response) |
||
Line 55: | Line 55: | ||
'''Request:''' | '''Request:''' | ||
<pre> | <pre> | ||
− | + | <?xml version="1.0" encoding="ISO-8859-1"?><SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" | |
+ | xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" | ||
+ | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" | ||
+ | xmlns:tns="urn:offeritapiadmin_wsdl"><SOAP-ENV:Body><tns:set_aff_sales_add xmlns:tns="urn:offeritapiadmin_wsdl"> | ||
+ | <orderid xsi:type="xsd:string">ABCDEFGHI</orderid> | ||
+ | <amount xsi:type="xsd:string">1</amount> | ||
+ | <offeritcode xsi:type="xsd:string">Mi4yLjEuMS4wLjAuMC4wLjAuMC4wLjA</offeritcode> | ||
+ | <customer xsi:type="tns:Member"> | ||
+ | <firstname xsi:type="xsd:string">Ben</firstname> | ||
+ | <lastname xsi:type="xsd:string">OfferIt</lastname> | ||
+ | <currency xsi:type="xsd:string">USD</currency> | ||
+ | <time xsi:type="xsd:string">1319475600</time> | ||
+ | </tns:set_aff_sales_add></SOAP-ENV:Body></SOAP-ENV:Envelope> | ||
</pre> | </pre> | ||
'''Response:''' | '''Response:''' | ||
<pre> | <pre> | ||
− | + | <?xml version="1.0" encoding="ISO-8859-1"?><SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" | |
+ | xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" | ||
+ | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"> | ||
+ | <SOAP-ENV:Body><ns1:set_aff_sales_addResponse xmlns:ns1="urn:offeritapiadmin_wsdl"> | ||
+ | <message xsi:type="xsd:string">Add Success</message><customerid xsi:type="xsd:int">124</customerid><orderid xsi:type="xsd:string">ABCDEFGHI</orderid> | ||
+ | </ns1:set_aff_sales_addResponse></SOAP-ENV:Body> | ||
+ | </SOAP-ENV:Envelope> | ||
</pre> | </pre> |
Revision as of 14:23, 15 January 2013
This function is used to update a member in Offerit. To use this function, you must make a SOAP call with the following parameters:
- memberid - the ID of the member to modify
The following are optional parameters:
- firstname - The first name of the member
- lastname - The last name of the member
- email - The email address of the member
- address1 - The address of the member
- address2 - The address of the member
- city - The city of the member
- state - The state of the member
- country - The country of the member
- zip - The zip code of the member
- custom1 - The custom1 field of the member
- custom2 - The custom2 field of the member
- custom3 - The custom3 field of the member
- custom4 - The custom4 field of the member
- custom5 - The custom5 field of the member
- password - The new password of the member
NuSOAP Example
This example continues from the main article NuSOAP Example:
$values = Array( 'memberid'=>'34', 'firstname'=>'Megan', 'lastname'=>'Murray' ) ); $result = $client->call('get_member_data', $values, 'offeritapiadmin_wsdl');
Sample Output
On success: array(3) { ["message"]=>string(11) "Add Success" ["customerid"]=>int(124) ["orderid"]=>string(9) "ABCDEFGHI" } On error: error message
Server Request/Response
Request:
<?xml version="1.0" encoding="ISO-8859-1"?><SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="urn:offeritapiadmin_wsdl"><SOAP-ENV:Body><tns:set_aff_sales_add xmlns:tns="urn:offeritapiadmin_wsdl"> <orderid xsi:type="xsd:string">ABCDEFGHI</orderid> <amount xsi:type="xsd:string">1</amount> <offeritcode xsi:type="xsd:string">Mi4yLjEuMS4wLjAuMC4wLjAuMC4wLjA</offeritcode> <customer xsi:type="tns:Member"> <firstname xsi:type="xsd:string">Ben</firstname> <lastname xsi:type="xsd:string">OfferIt</lastname> <currency xsi:type="xsd:string">USD</currency> <time xsi:type="xsd:string">1319475600</time> </tns:set_aff_sales_add></SOAP-ENV:Body></SOAP-ENV:Envelope>
Response:
<?xml version="1.0" encoding="ISO-8859-1"?><SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"> <SOAP-ENV:Body><ns1:set_aff_sales_addResponse xmlns:ns1="urn:offeritapiadmin_wsdl"> <message xsi:type="xsd:string">Add Success</message><customerid xsi:type="xsd:int">124</customerid><orderid xsi:type="xsd:string">ABCDEFGHI</orderid> </ns1:set_aff_sales_addResponse></SOAP-ENV:Body> </SOAP-ENV:Envelope>