Update car https://api.rrr.lt/crm/updateCar

POST variables

Name Type Required Data
username Text varchar(50) YES Username
password Text varchar(100) YES Password
user_token Text YES Token provided
car_id Numeric (int 11) YES Car id
car_model Numeric (int 11) NO Car model id assigned to car
car_years Text (varchar 4) NO Car years
car_class Numeric (int 11) NO Car class id assigned to car
car_engine_cubic_capacity Numeric (int 11) NO Car engine cubic capacity
car_engine_power Numeric (int 11) NO Car engine power (Kw)
car_gearbox_type Numeric (int 11) NO Car gearbox type id assigned to car
car_fuel Numeric (int 11) NO Car fuel id assigned to car
car_mileage Numeric (int 7) NO Car mileage
car_body_type Numeric (int 11) NO Car body type id assigned to car
status Numeric (int 11) NO Status id assigned to car
photo Text NO Photo url
photos[] Array NO Photo url * e.g. photos[0] => 'photos.url1.jpg', photos[1] => 'photos.url2.jpg'
id_bridge Numeric (int 11) NO Deprecated - field is not updatable
place Text varchar(255) NO Place where car is stored
seller_id Numeric (int 11) NO Seller id
seller_name_surname Text varchar(255) NO Seller name surname
seller_address Text varchar(255) NO Seller address
purchase_date Date (Y-m-d H:i:s) NO Purchase date
car_country_number Text NO Car country number
car_color Text varchar(10) NO Car color
car_color_code Text varchar(255) NO Car color code
car_body_number Text varchar(40) NO Car body number
car_engine_number Text varchar(255) NO Car engine number
car_empty_weight Numeric (int 10) NO Car empty weight
car_engine_type Text (varchar 32) NO Car engine type
car_engine_code Text (varchar 32) NO Car engine code
car_gearbox_code Text (varchar 32) NO Car gearbox code
car_interior Text (varchar 255) NO Car interior
car_price Numeric (float) NO Car price
original_currency Text NO Currency {EUR, PLN}. Default: EUR
defectation_notes Text NO Defectation notes
prime_cost Numeric (float) NO Prime cost
demolition_costs Numeric (float) NO Demolition costs
selling_costs Numeric (float) NO Selling costs
secondary_raw_materials_costs Numeric (float) NO Secondary raw materials costs
other_costs Numeric (int 11) NO Other costs
registration_document_id Text (varchar 20) NO Registration document id
write_down_nr Numeric (int 11) NO Write down nr
voucher_nr Numeric (int 11) NO Voucher nr
car_service_id Numeric (int 11) NO Car service id
car_wheel_type Numeric (int 1) NO Car steering wheel type
car_wheel_drive Numeric (int 1) NO Car wheel drive
payment_method Numeric (int 1) NO Payment method {0,1}
unregister Numeric (int 1) NO Unregister
car_docs_host Numeric (int 1) NO Car docs host {0,1}
car_price_wiwat Numeric (tinyint 1) NO Car price with or without WAT {0,1}
car_place Text (varchar 500) NO Car place
storages Text (varchar 255) NO Storages

PHP Curl example code

$post = [
'username' => '',
'password' => '',
'user_token' => '',
'car_mileage' => '270000',
'car_id' => '263'
];

$ch = curl_init('https://api.rrr.lt/crm/updateCar');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post);
$response = json_decode(curl_exec($ch));
curl_close($ch);

Output

{"msg":"OK","status_code":"R200"}

Attention

Values must be filled in order to be shown in shop.

Value of the 'photo' field must be first value of 'photos[]' field too, for correct main photo upload and thumbnail generation.