NuevoAlly IA ya responde con las cifras de tu negocioPruébala →

Desarrolladores

Referencia de la API

Cada endpoint de https://api.ally360.co/v1, con sus parámetros y un ejemplo del cuerpo.

contacts

GET

/v1/contacts

Listar contactos

  • limit (query)
  • cursor (query)
  • type (query)
  • id_number (query)
  • email (query)
  • updated_since (query)
POST

/v1/contacts

Crear un contacto

Ejemplo del cuerpo
{
  "email": "ana@example.com",
  "id_number": "1020304050",
  "id_type": "CC",
  "mobile": "3001234567",
  "name": "Ana María Gómez",
  "types": [
    "client"
  ]
}
GET

/v1/contacts/{contact_id}

Ver un contacto

  • contact_id (path, obligatorio)
PATCH

/v1/contacts/{contact_id}

Editar un contacto

  • contact_id (path, obligatorio)
Ejemplo del cuerpo
{
  "email": "ana@example.com",
  "id_number": "1020304050",
  "id_type": "CC",
  "mobile": "3001234567",
  "name": "Ana María Gómez",
  "types": [
    "client"
  ]
}

credit-notes

GET

/v1/credit-notes

Listar notas crédito

  • limit (query)
  • cursor (query)
  • invoice_id (query)
  • updated_since (query)
POST

/v1/credit-notes

Crear una nota crédito

Ejemplo del cuerpo
{
  "invoice_id": "5a6b7c8d-1e2f-4a3b-9c4d-5e6f7a8b9c0d",
  "lines": [
    {
      "product_id": "9b2f6c1d-8e3a-4f7b-a1c2-3d4e5f6a7b8c",
      "quantity": "1"
    }
  ],
  "reason": "Devolución del pedido 1001"
}
GET

/v1/credit-notes/{credit_note_id}

Ver una nota crédito

  • credit_note_id (path, obligatorio)

events

GET

/v1/events/types

Eventos que se pueden recibir

invoices

GET

/v1/invoices

Listar facturas de venta

  • limit (query)
  • cursor (query)
  • status (query)
  • customer_id (query)
  • issued_from (query)
  • issued_to (query)
  • updated_since (query)
POST

/v1/invoices

Crear una factura

Ejemplo del cuerpo
{
  "customer_id": "3f1c2a7e-0d55-4c55-9a7a-6a1f0d1b2c3d",
  "lines": [
    {
      "product_id": "9b2f6c1d-8e3a-4f7b-a1c2-3d4e5f6a7b8c",
      "quantity": "2",
      "unit_price": "50000"
    }
  ],
  "status": "open"
}
GET

/v1/invoices/{invoice_id}

Ver una factura

  • invoice_id (path, obligatorio)

me

GET

/v1/me

La credencial en uso

payments

GET

/v1/payments

Listar pagos recibidos

  • limit (query)
  • cursor (query)
  • invoice_id (query)
  • contact_id (query)
  • updated_since (query)
POST

/v1/payments

Pagar una factura

Ejemplo del cuerpo
{
  "amount": "119000",
  "invoice_id": "5a6b7c8d-1e2f-4a3b-9c4d-5e6f7a8b9c0d",
  "method": "TRANSFER"
}
GET

/v1/payments/{payment_id}

Ver un pago

  • payment_id (path, obligatorio)

price-lists

GET

/v1/price-lists

Listar listas de precios

  • limit (query)
  • cursor (query)
GET

/v1/price-lists/{price_list_id}

Ver una lista de precios

  • price_list_id (path, obligatorio)

products

GET

/v1/products

Listar productos

  • limit (query)
  • cursor (query)
  • sku (query)
  • barcode (query)
  • active (query)
  • updated_since (query)
POST

/v1/products

Crear un producto

Ejemplo del cuerpo
{
  "initial_stock": "10",
  "name": "Funda de silicona",
  "opening_origin": "prior_earnings",
  "price": "25000",
  "sku": "FUN-001",
  "unit_cost": "12000"
}
GET

/v1/products/{product_id}

Ver un producto

  • product_id (path, obligatorio)
PATCH

/v1/products/{product_id}

Editar un producto

  • product_id (path, obligatorio)
Ejemplo del cuerpo
{
  "is_active": true,
  "price": "27000"
}
GET

/v1/products/{product_id}/stock

Existencias de un producto

  • product_id (path, obligatorio)

sandbox

POST

/v1/sandbox/events

Simular un evento (sólo empresa de pruebas)

Ejemplo del cuerpo
{
  "entity_id": "5a6b7c8d-1e2f-4a3b-9c4d-5e6f7a8b9c0d",
  "type": "invoice.dian_accepted"
}

stock

GET

/v1/stock

Existencias por bodega

  • limit (query)
  • cursor (query)
  • product_id (query)
  • warehouse_id (query)
  • updated_since (query)

treasury-accounts

GET

/v1/treasury-accounts

Listar cuentas de tesorería

  • limit (query)
  • cursor (query)
  • active (query)

warehouses

GET

/v1/warehouses

Listar bodegas

  • limit (query)
  • cursor (query)

webhooks

GET

/v1/webhooks

Listar webhooks

POST

/v1/webhooks

Crear un webhook

Ejemplo del cuerpo
{
  "description": "Tienda en línea",
  "event_types": [
    "invoice.paid",
    "stock.changed"
  ],
  "url": "https://mitienda.example.com/ally360/webhooks"
}
GET

/v1/webhooks/{subscription_id}

Ver un webhook

  • subscription_id (path, obligatorio)
DELETE

/v1/webhooks/{subscription_id}

Borrar un webhook

  • subscription_id (path, obligatorio)
POST

/v1/webhooks/{subscription_id}/test

Enviar un evento de prueba

  • subscription_id (path, obligatorio)
¿Tienes dudas?