Saltar al contenido principal

getAllOrdersByMarker

Obteniendo todas las órdenes del objeto de almacenamiento de órdenes creado por el usuario. 🔐 Este método requiere autorización.

Descripción

Este método obtiene todos los objetos de almacenamiento de órdenes por marcador. El método añadirá el idioma predeterminado al cuerpo de la solicitud. Si deseas cambiar el idioma, simplemente pásalo como segundo argumento. Devuelve una Promesa que se resuelve en un objeto IOrdersByMarkerEntity.

Órdenes.getAllOrdersByMarker(

marcador, langCode, offset, limit

);

Esquema de parámetros

Esquema

marcador(requerido): string
Identificador textual del objeto de almacenamiento de órdenes
ejemplo: "order_storage_1"

langCode: string
Código de idioma. Predeterminado: "en_US"
ejemplo: "en_US"

offset: number
Parámetro de desplazamiento. Predeterminado: 0
ejemplo: 0

limit: number
Parámetro de límite. Predeterminado: 30
ejemplo: 30

Ejemplos

Ejemplo mínimo

const response = await Órdenes.getAllOrdersByMarker('mi-orden');

Ejemplo con atributos

const response = await Órdenes.getAllOrdersByMarker('mi-orden', 'en_US', 0, 30);

Ejemplo de respuesta

{
"items": [
{
"id": 276,
"storageId": 1,
"createdDate": "2025-09-30T20:32:45.338Z",
"statusIdentifier": "inProgress",
"formIdentifier": "orderForm",
"formData": [
{
"marker": "order_name",
"value": "Ivan",
"type": "string"
}
],
"attributeSetIdentifier": "order_form",
"totalSum": "300.00",
"currency": "",
"paymentAccountIdentifier": "cash",
"paymentAccountLocalizeInfos": {
"title": "Efectivo"
},
"products": [
{
"id": 2957,
"title": "Cosmo",
"sku": null,
"previewImage": null,
"price": 150,
"quantity": 2
}
],
"isCompleted": false
},
{
"id": 275,
"storageId": 1,
"createdDate": "2025-09-30T20:31:44.881Z",
"statusIdentifier": "inProgress",
"formIdentifier": "orderForm",
"formData": [
{
"marker": "order_name",
"value": "Ivan",
"type": "string"
}
],
"attributeSetIdentifier": "order_form",
"totalSum": "300.00",
"currency": "",
"paymentAccountIdentifier": "cash",
"paymentAccountLocalizeInfos": {
"title": "Efectivo"
},
"products": [
{
"id": 2957,
"title": "Cosmo",
"sku": null,
"previewImage": null,
"price": 150,
"quantity": 2
}
],
"isCompleted": false
},
{
"id": 274,
"storageId": 1,
"createdDate": "2025-09-30T17:36:19.027Z",
"statusIdentifier": "inProgress",
"formIdentifier": "orderForm",
"formData": [
{
"marker": "order_name",
"value": "Ivan",
"type": "string"
}
],
"attributeSetIdentifier": "order_form",
"totalSum": "300.00",
"currency": "",
"paymentAccountIdentifier": "cash",
"paymentAccountLocalizeInfos": {
"title": "Efectivo"
},
"products": [
{
"id": 2957,
"title": "Cosmo",
"sku": null,
"previewImage": null,
"price": 150,
"quantity": 2
}
],
"isCompleted": false
},
"..."
],
"total": 83
}

Esquema de respuesta

Esquema: IOrdersByMarkerEntity

items: IOrderByMarkerEntity[]
Array de objetos de almacenamiento de órdenes.
ejemplo:

[
{
"id": 55,
"storageId": 1,
"createdDate": "2025-03-22T21:12:42.371Z",
"statusIdentifier": "inProgress",
"formIdentifier": "orderForm",
"formData": [
{
"marker": "order_name",
"value": "Ivan",
"type": "string"
}
],
"attributeSetIdentifier": "order_form",
"totalSum": "300.00",
"currency": "",
"paymentAccountIdentifier": "cash",
"paymentAccountLocalizeInfos": {
"title": "Efectivo"
},
"products": [
{
"id": 2957,
"title": "Cosmo",
"sku": null,
"previewImage": null,
"price": 150,
"quantity": 2
}
],
"isCompleted": false
}
]

total: number
Número total de registros encontrados.
ejemplo: 100