1. Convenios
API | Doing Solutions
  • Introducción
  • Autenticación
  • Ambientes
  • Implementación
  • Modelo Outsourcing
    • Personal
      • Consultar Datos Generales
      • Consultar Comprobantes de Pago
      • Crear Empleado y Contrato
      • Registrar Conceptos
    • Empresa
      • Consultar Estructura
      • Consultar Contabilización
    • Convenios
      • Webook desde Integrador
        POST
      • Petición a Integrador
        POST
  • Autenticación
    POST
  1. Convenios

Petición a Integrador

POST
/api/ExternalDiscount/batch
Recibe y persiste un lote de descuentos de nómina.
El encabezado del lote y todas sus líneas de detalle se almacenan de forma atómica: entra el lote completo o no entra nada.
declared_record_count y declared_total_amount son señales de conciliación, no controles de admisión. Un lote cuyos contadores declarados no coinciden con las líneas realmente recibidas se acepta igual y se almacena con status = 1 (Received); la diferencia queda registrada en la traza de auditoría para conciliarla después.

Request

Authorization
API Key
Add parameter in header
X-Integrator-Id
Example:
X-Integrator-Id: ********************
or
Header Params

Body Params application/jsonRequired

Examples

Responses

🟢200
application/json
Reintento idempotente. Ya se había recibido un lote con este external_batch_id y el hash del cuerpo es idéntico, así que se devuelve el resultado original sin cambios y no se reprocesa nada. Este es el resultado esperado de un reintento tras un timeout de red — no es un error.
Bodyapplication/json

🟢201
🟠400
🟠401
🟠409
🟠422
Request Request Example
Shell
JavaScript
Java
Swift
cURL
curl --location 'https://doisol.sytes.net/api/ExternalDiscount/batch' \
--header 'X-Integrator-Timestamp: 2026-09-05T14:32:05Z' \
--header 'X-Integrator-Signature: TWFuIGlzIGRpc3Rpbmd1aXNoZWQsIG5vdCBvbmx5IGJ5IGhpcyByZWFzb24sIGJ1dCBieSB0aGlz...' \
--header 'X-Integrator-Id: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
    "external_batch_id": "CLIENT-2026-09-001",
    "payroll_period": "2026-09",
    "declared_record_count": 25,
    "declared_total_amount": 7340052.25,
    "details": [
        {
            "identification": "1000000001",
            "discounted_amount": 129950
        },
        {
            "identification": "1000000002",
            "discounted_amount": 348000
        },
        {
            "identification": "1000000003",
            "discounted_amount": 215750.5
        },
        {
            "identification": "1000000004",
            "discounted_amount": 97300
        },
        {
            "identification": "1000000005",
            "discounted_amount": 452800
        },
        {
            "identification": "1000000006",
            "discounted_amount": 186400.25
        },
        {
            "identification": "1000000007",
            "discounted_amount": 273900
        },
        {
            "identification": "1000000008",
            "discounted_amount": 512000
        },
        {
            "identification": "1000000009",
            "discounted_amount": 145600
        },
        {
            "identification": "1000000010",
            "discounted_amount": 389250.75
        },
        {
            "identification": "1000000011",
            "discounted_amount": 208100
        },
        {
            "identification": "1000000012",
            "discounted_amount": 476300
        },
        {
            "identification": "1000000013",
            "discounted_amount": 163850
        },
        {
            "identification": "1000000014",
            "discounted_amount": 325400.5
        },
        {
            "identification": "1000000015",
            "discounted_amount": 198700
        },
        {
            "identification": "1000000016",
            "discounted_amount": 441200
        },
        {
            "identification": "1000000017",
            "discounted_amount": 287650
        },
        {
            "identification": "1000000018",
            "discounted_amount": 356900
        },
        {
            "identification": "1000000019",
            "discounted_amount": 174300.25
        },
        {
            "identification": "1000000020",
            "discounted_amount": 495800
        },
        {
            "identification": "1000000021",
            "discounted_amount": 231450
        },
        {
            "identification": "1000000022",
            "discounted_amount": 368200
        },
        {
            "identification": "1000000023",
            "discounted_amount": 152900
        },
        {
            "identification": "1000000024",
            "discounted_amount": 419750
        },
        {
            "identification": "1000000025",
            "discounted_amount": 288600
        }
    ]
}'
Response Response Example
200 - Retry of an already-stored batch
{
    "id": 4471,
    "externalBatchId": "CLIENT-2026-09-001",
    "payrollPeriod": "2026-09",
    "status": 1,
    "statusName": "Received",
    "declaredRecordCount": 25,
    "storedRecordCount": 25,
    "declaredTotalAmount": 7340052.25,
    "storedTotalAmount": 7340052.25,
    "countersMatch": true,
    "createdAt": "2026-09-05T14:32:07.412Z"
}
Previous
Webook desde Integrador
Next
Autenticación
Built with