The related operation for querying work orders by ID is described.
Details of the request:
- Base URL: {host}/AFLSAPI/
- URI: api/workorders/{id}
-
Type: GET
-
Required headings:
- Content-Type: application/json
- X-Authorization: Bearer {Token}
URL Description
- {host}: It represents the domain of the environment in which the API is located.
- AFLSAPI/: Fixed API prefix.
- URI: Specific endpoint for the request.
⚐ EXAMPLE URL:
https://{host}/AFLSAPI/api/workorders/{id}
Parameters:
Name | Data type | Obligatory | Description |
---|---|---|---|
Id | Integer | Yes | Order ID |
Answer:
As an answer, a JSON object is obtained, with the following information:
{
"addressContact": "Floresta Outlet, Carrera 69, Santa Rosa, 11121 Suba, Distrito Capital, Colombia",
"addressContactInfo": "Piso 7",
"assignmentType": 0,
"clientId": 213,
"companyId": null,
"contactEmail": "tati_4@pruebas.com",
"contactLatitude": 4.69191580000000,
"contactLongitude": -74.07453940000000,
"contactName": "PRUEBAS CREACIÓN DE ORDENES DESDE LA API DE WORKORDERS",
"contactPhone": "3016153272",
"creatorId": 3,
"description": "PRUEBAS CREACIÓN DE ORDENES DESDE LA API DE WORKORDERS",
"endAddress": null,
"endAddressInfo": "",
"endLatitude": 0.00000000000000,
"endLongitude": 0.00000000000000,
"id": 87,
"priority": 1,
"providerId": 2,
"serviceId": 1,
"specialistId": 11,
"state": 1,
"subject": "Pruebas de Creación de orden de Emergencia",
"subStateId": 10,
"ticketId": "87",
"attentionEndDate": null,
"attentionStartDate": null,
"tentativeAttentionEndDate": "2024-03-20T01:12:27.08+00:00",
"tentativeAttentionStartDate": "2024-03-19T22:12:27.08+00:00",
"tentativeTravelStartDate": "2024-03-19T22:12:27.08+00:00",
"travelStartDate": null,
"additionalFields": [
{
"actions": null,
"definitionId": 1,
"description": null,
"formatValidator": null,
"helpMessage": "Campo orden simple",
"id": 4,
"itemId": 0,
"keepHistory": false,
"label": "Campo orden simple",
"name": "ca-campo orden simple-1",
"options": null,
"order": 1,
"permissions": [
{
"statusId": 7,
"name": "General",
"roles": [
{
"actions": {
"edit": true,
"required": false,
"view": true
},
"id": 276,
"name": "AFLS_Dispatcher"
},
{
"actions": {
"edit": true,
"required": false,
"view": true
},
"id": 278,
"name": "AFLS_Monitor"
}
]
}
],
"state": null,
"status": true,
"typeId": 1,
"value": null
}
],
"attachments": [
{
"createDate": "2024-03-19T22:24:37.607+00:00",
"description": null,
"fileExtension": "pdf",
"filePath": null,
"fileSize": "182848",
"id": 6,
"realFileName": "PRUEBA",
"serveFileName": null
}
],
"products": [
{
"cost": 10000.00,
"description": "Cable",
"id": 11,
"isActive": true,
"name": "Cable",
"productId": 1,
"quantity": 2,
"sku": "001",
"typeProduct": 0
}
],
"workTasks": null
}
Error messages:
Code | HTTP status | Error Message |
---|---|---|
400 | BadRequest | No information found. |
500 | Internal Server Error | FailureLogin |