Edit
curl --request PATCH \
--url https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: */*' \
--header 'X-SIMA-SYSTEM-ID: <api-key>' \
--data '
"\"{\\n \\\"name\\\": \\\"Test 3 edit\\\",\\n \\\"wo_labour_type_category_id\\\": 1,\\n \\\"wo_labour_type_attribute_ids\\\": [1,3, 4],\\n \\\"active\\\": 1 \\n}\""
'import requests
url = "https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775"
payload = "\"{\n \\"name\\": \\"Test 3 edit\\",\n \\"wo_labour_type_category_id\\": 1,\n \\"wo_labour_type_attribute_ids\\": [1,3, 4],\n \\"active\\": 1 \n}\""
headers = {
"Authorization": "Bearer <token>",
"X-SIMA-SYSTEM-ID": "<api-key>",
"Content-Type": "*/*"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
Authorization: 'Bearer <token>',
'X-SIMA-SYSTEM-ID': '<api-key>',
'Content-Type': '*/*'
},
body: JSON.stringify('"{\n \"name\": \"Test 3 edit\",\n \"wo_labour_type_category_id\": 1,\n \"wo_labour_type_attribute_ids\": [1,3, 4],\n \"active\": 1 \n}"')
};
fetch('https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode('"{\\n \\"name\\": \\"Test 3 edit\\",\\n \\"wo_labour_type_category_id\\": 1,\\n \\"wo_labour_type_attribute_ids\\": [1,3, 4],\\n \\"active\\": 1 \\n}"'),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: */*",
"X-SIMA-SYSTEM-ID: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"id": 2775,
"name": "Test 3 edit",
"table_code_id": 47,
"wo_labour_type_category_id": 1,
"wo_labour_type_attributes": [
{
"id": 1,
"name": "Horas",
"description": "Registro de horas de trabajo. Ejemplo: 5 hs Unidad: horas",
"voucher_type_id": 47,
"created_at": "2024-04-22T11:55:00-03:00",
"modified_at": "2024-04-22T11:55:00-03:00",
"deleted_at": null,
"active": true
},
{
"id": 3,
"name": "Profundidad",
"description": "Profundidad de trabajo de los distintos implementos\tya que trabajan a diferentes profundidades en el suelo. Ej: 25 cm Unidad: cm",
"voucher_type_id": 47,
"created_at": "2024-04-22T11:55:00-03:00",
"modified_at": "2024-04-22T11:55:00-03:00",
"deleted_at": null,
"active": true
},
{
"id": 4,
"name": "Ancho",
"description": "Ancho de labor del implemento. Ej: 10 metros Unidad: metros (m)",
"voucher_type_id": 47,
"created_at": "2024-04-22T11:55:00-03:00",
"modified_at": "2024-04-22T11:55:00-03:00",
"deleted_at": null,
"active": true
}
],
"voucher_type_id": 47,
"date_created": "2024-06-28T10:56:12-03:00",
"date_modified": "2024-06-28T11:01:00-03:00",
"active": 1
}Version 1 > Application Order Labour Types
Edit
PATCH
/
api
/
v2
/
third_party
/
application_order_labour_types
/
2775
Edit
curl --request PATCH \
--url https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: */*' \
--header 'X-SIMA-SYSTEM-ID: <api-key>' \
--data '
"\"{\\n \\\"name\\\": \\\"Test 3 edit\\\",\\n \\\"wo_labour_type_category_id\\\": 1,\\n \\\"wo_labour_type_attribute_ids\\\": [1,3, 4],\\n \\\"active\\\": 1 \\n}\""
'import requests
url = "https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775"
payload = "\"{\n \\"name\\": \\"Test 3 edit\\",\n \\"wo_labour_type_category_id\\": 1,\n \\"wo_labour_type_attribute_ids\\": [1,3, 4],\n \\"active\\": 1 \n}\""
headers = {
"Authorization": "Bearer <token>",
"X-SIMA-SYSTEM-ID": "<api-key>",
"Content-Type": "*/*"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
Authorization: 'Bearer <token>',
'X-SIMA-SYSTEM-ID': '<api-key>',
'Content-Type': '*/*'
},
body: JSON.stringify('"{\n \"name\": \"Test 3 edit\",\n \"wo_labour_type_category_id\": 1,\n \"wo_labour_type_attribute_ids\": [1,3, 4],\n \"active\": 1 \n}"')
};
fetch('https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.qa.sima.ag/api/v2/third_party/application_order_labour_types/2775",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode('"{\\n \\"name\\": \\"Test 3 edit\\",\\n \\"wo_labour_type_category_id\\": 1,\\n \\"wo_labour_type_attribute_ids\\": [1,3, 4],\\n \\"active\\": 1 \\n}"'),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: */*",
"X-SIMA-SYSTEM-ID: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"id": 2775,
"name": "Test 3 edit",
"table_code_id": 47,
"wo_labour_type_category_id": 1,
"wo_labour_type_attributes": [
{
"id": 1,
"name": "Horas",
"description": "Registro de horas de trabajo. Ejemplo: 5 hs Unidad: horas",
"voucher_type_id": 47,
"created_at": "2024-04-22T11:55:00-03:00",
"modified_at": "2024-04-22T11:55:00-03:00",
"deleted_at": null,
"active": true
},
{
"id": 3,
"name": "Profundidad",
"description": "Profundidad de trabajo de los distintos implementos\tya que trabajan a diferentes profundidades en el suelo. Ej: 25 cm Unidad: cm",
"voucher_type_id": 47,
"created_at": "2024-04-22T11:55:00-03:00",
"modified_at": "2024-04-22T11:55:00-03:00",
"deleted_at": null,
"active": true
},
{
"id": 4,
"name": "Ancho",
"description": "Ancho de labor del implemento. Ej: 10 metros Unidad: metros (m)",
"voucher_type_id": 47,
"created_at": "2024-04-22T11:55:00-03:00",
"modified_at": "2024-04-22T11:55:00-03:00",
"deleted_at": null,
"active": true
}
],
"voucher_type_id": 47,
"date_created": "2024-06-28T10:56:12-03:00",
"date_modified": "2024-06-28T11:01:00-03:00",
"active": 1
}Authorizations
access_token obtenido via POST /api/v2/login
Identificador del sistema integrador (8 para Third-Party API)
Body
*/*
The body is of type string.
Example:
"\"{\\n \\\"name\\\": \\\"Test 3 edit\\\",\\n \\\"wo_labour_type_category_id\\\": 1,\\n \\\"wo_labour_type_attribute_ids\\\": [1,3, 4],\\n \\\"active\\\": 1 \\n}\""
Response
200 - application/json
OK
The response is of type object.

