0 utilizadores on-line |
0 Convidados e 0 Registados

How to edit the request of a number via API?


POST: http://www.sitename.com/api_seller_orders.php?action=update_orders

 

Header Parameter Format
Token base64_encode()
Secret base64_encode()
E-mail base64_encode()

 

Parameter Format Description
oID JSON Order ID
Only number is required
Check the API to get the Order Number
Format: bigint(11)
* FIELD REQUIRED
status JSON

Use the API to list the status and get name and id
Only number is required
Format: int(2)
* FIELD REQUIRED

pID JSON Use the API to list the order data to get the product_id
Format: int(11)
tID JSON The Tracking Id number to notify the customer and administrator the order was shipped
Format: varchar(255)

PHP Sample

	// sample edit orders
	
	$url = $domain_url . '/api_seller_orders.php?action=update_orders';

	$data = array("oID" => '12345678910', // Order ID (Only number is required) * FIELD REQUIRED
				  "product_id" => '430', // The the product_id (Only number is required) * FIELD REQUIRED
				  "Tracking_Id" => 'OF123456789BR' // The tracking id
				  );
				  
	$data_string = json_encode($data);  

	$ch = curl_init($url);
	curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");                                                                     
	curl_setopt($ch, CURLOPT_POSTFIELDS, $data_string);                                                                  
	curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
	curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);                                                                   
	curl_setopt($ch, CURLOPT_HTTPHEADER, array(                                                                          
		'Content-Type: application/json',
		"Cache-Control: no-cache", 
		'Token: ' . base64_encode($token),
		'Secret: ' . base64_encode($secret),
		'E-mail: ' . base64_encode($email),
		'Content-Length: ' . strlen($data_string))
	);                                                                                                                      
																														 
	$result = curl_exec($ch);
	curl_close($ch);

	print_r($result);
	
	// sample edit orders eof

 

Return Error:

code
message

Return Success:

code
oID
message

2018-08-30 22:16 MFORMULA FAQ {writeRevision}
Avaliação média: 0 (0 Avaliações)

Não pode comentar este artigo

Chuck Norris has counted to infinity. Twice.

{debugMessages}