List orders

GET

GET https://external-api.lia.com.br/external_api/v1/orders

Query params

NameDescriptionRequiredType
searchSearch by: customer_document, customer_name, order.id, email or phonefalseString
sort_by_attributeAny order attribute that you want to sort_by, default is created_atfalseString
sort_bySort your results by asc or descfalseString
statusFilter by order statusfalseString
created_at_startFilter by orders greater than or equal to (YYYY-MM-DD)falseString
created_at_endFilter by orders lower than or equal to (YYYY-MM-DD)falseString
updated_at_startFilter by orders greater than or equal to (YYYY-MM-DD)falseString
updated_at_endFilter by orders lower than or equal to (YYYY-MM-DD)falseString
pageNumber of the page you wantfalseInteger
per_pageTotal items per pagefalseInteger

Example request

curl --location 'https://external-api-sandbox.lia.com.br/external_api/v1/orders?search=78e28665-93d8-5f75-9432-1dbf5771a965&sort_by=asc&created_at_start=2023-06-01&created_at_end=2023-06-30&updated_at_start=2023-03-01&updated_at_end=2023-03-30&status=in_progress&per_page=2&page=1&sort_by_attribute=created_at' \
--header 'Authorization: Bearer YOUR_API_TOKEN'

Example response

{
    "results": [
        {
            "address": {
                "city": {
                    "ibge_code": "3471",
                    "id": "77b764ad-53d4-5630-bed3-ab106036ebe1",
                    "name": "Santana do Araguaia",
                    "state": {
                        "acronym": "SP",
                        "id": "50405e03-46a1-5b31-8ed1-d08167af85f6",
                        "name": "São Paulo"
                    },
                    "state_id": "50405e03-46a1-5b31-8ed1-d08167af85f6"
                },
                "complement": "Sem complementos",
                "id": "4eebc118-6201-5824-a9fd-ad03ff1bf896",
                "neighborhood": "Centro",
                "number": "100",
                "street": "Rua Exemplo",
                "zipcode": "35900000"
            },
            "amount_cents": 200000,
            "analyses": [],
            "billings": [
                {
                    "amount_cents": 200000,
                    "amount_currency": "BRL",
                    "bills": [
                        {
                            "amount_cents": 10243,
                            "authentication_code": null,
                            "bill_details": [],
                            "bill_type": "installment",
                            "billing": {
                                "amount_cents": 200000,
                                "amount_currency": "BRL",
                                "cancelation_reason": "down_payment_not_paid",
                                "created_at": "2023-11-29T10:32:42.915-03:00",
                                "due_day": 10,
                                "finished_at": "2023-12-12T21:00:50.271-03:00",
                                "id": "bd3b3350-7c67-5b7e-be5c-e6fdd6748213",
                                "installments": 1,
                                "order_id": "b72db961-6a94-5168-8689-30d8fcd55409",
                                "origin_billing_id": null,
                                "status": "canceled",
                                "updated_at": "2023-12-12T21:00:50.360-03:00"
                            },
                            "checkout_url": "https://pague-sandbox.lia.com.br/parcela/pagamento?bill_id=ea281e20-b404-5b35-b545-07743d57905e",
                            "created_at": "2023-11-29T10:32:42.931-03:00",
                            "current_amount_cents": 10750,
                            "disable_penalties_until": null,
                            "due_date": "2023-11-30T10:32:42.918-03:00",
                            "effective_due_date": "2023-11-30T10:32:42.918-03:00",
                            "id": "ea281e20-b404-5b35-b545-07743d57905e",
                            "metadata": {},
                            "original_amount_cents": 10000,
                            "paid_at": null,
                            "payments": [
                                {
                                    "amount_cents": 10000,
                                    "barcode": "00000.00000 00000.000000 00000.000000 0 00000000000000",
                                    "barcode_image_url": "https://platform-api-sandbox.lia.com.br/barcode_image",
                                    "bill_id": "ea281e20-b404-5b35-b545-07743d57905e",
                                    "created_at": "2023-11-29T10:32:42.957-03:00",
                                    "expires_at": "2023-12-02T10:32:42.952-03:00",
                                    "id": "f497139f-ed78-538b-9d0d-6939ffcbbbff",
                                    "installments": 1,
                                    "paid_amount_cents": 0,
                                    "paid_at": null,
                                    "payment_method": "boleto",
                                    "refunded_amount_cents": 0,
                                    "refunded_at": null,
                                    "refused_reason": null,
                                    "refused_reason_description": null,
                                    "status": "unpaid",
                                    "url": "https://pague-sandbox.lia.com.br/parcela/pagamento?bill_id=ea281e20-b404-5b35-b545-07743d57905e"
                                }
                            ],
                            "status": "canceled",
                            "updated_at": "2023-12-12T21:00:50.148-03:00"
                        }
                    ],
                    "cancelation_reason": "down_payment_not_paid",
                    "created_at": "2023-11-29T10:32:42.915-03:00",
                    "due_day": 10,
                    "finished_at": "2023-12-12T21:00:50.271-03:00",
                    "id": "bd3b3350-7c67-5b7e-be5c-e6fdd6748213",
                    "installments": 1,
                    "order_id": "b72db961-6a94-5168-8689-30d8fcd55409",
                    "origin_billing_id": null,
                    "payment_configuration": {
                        "allowed_down_payment_methods": [],
                        "availability": "enabled",
                        "down_payment_interest_rate": null,
                        "down_payment_type": null,
                        "down_payment_value": 0.0,
                        "expires_in": 12,
                        "fee_embedded_in_down_payment": false,
                        "financed_type": null,
                        "id": "f3a6410d-f1eb-589e-915a-50a9f5e8aa58",
                        "interest_rate": 0.0,
                        "max_down_payment_installments": null,
                        "max_installments": 1,
                        "min_installment_amount_cents": 5000,
                        "payment_methods": [
                            "boleto"
                        ],
                        "payment_type": "upfront",
                        "registration_fee": 0.0,
                        "take_rate_type": "absolute",
                        "take_rate_value": 297.0
                    },
                    "status": "canceled",
                    "updated_at": "2023-12-12T21:00:50.360-03:00"
                }
            ],
            "cancelation_reason": "down_payment_not_paid",
            "checkout_type": "default",
            "created_at": "2023-11-29T10:32:42.856-03:00",
            "customer_birthdate": "1990-01-01",
            "customer_document": "11144477735",
            "customer_name": "The Great Customer",
            "customer_type": "person",
            "email": {
                "address": "customer@example.com",
                "contact_type": "email",
                "created_at": "2023-11-29T10:32:42.878-03:00",
                "id": "056a62f7-97fb-553a-862e-35f1e7b8ebec",
                "purpose": "communication",
                "updated_at": "2024-04-09T08:50:56.813-03:00",
                "validated": false
            },
            "finished_at": null,
            "id": "b72db961-6a94-5168-8689-30d8fcd55409",
            "metadata": {},
            "offer": {
                "amount_cents": 100000,
                "amount_currency": "BRL",
                "availability": "enabled",
                "checkout_type": "default",
                "created_at": "2023-11-29T10:32:42.765-03:00",
                "id": "bdeebdb0-851e-5983-a63e-7b2668f12f50",
                "name": "Padrão",
                "payment_configurations": [
                    {
                        "allowed_down_payment_methods": [],
                        "availability": "enabled",
                        "down_payment_interest_rate": null,
                        "down_payment_type": null,
                        "down_payment_value": 0.0,
                        "expires_in": 12,
                        "fee_embedded_in_down_payment": false,
                        "financed_type": null,
                        "id": "a3dc85da-00a7-5eca-bea4-a753ea5abc49",
                        "interest_rate": 0.0,
                        "max_down_payment_installments": null,
                        "max_installments": 1,
                        "min_installment_amount_cents": 5000,
                        "payment_methods": [
                            "pix"
                        ],
                        "payment_type": "upfront",
                        "registration_fee": 0.0,
                        "take_rate_type": "absolute",
                        "take_rate_value": 297.0
                    },
                    {
                        "allowed_down_payment_methods": [],
                        "availability": "enabled",
                        "down_payment_interest_rate": null,
                        "down_payment_type": null,
                        "down_payment_value": 0.0,
                        "expires_in": null,
                        "fee_embedded_in_down_payment": false,
                        "financed_type": null,
                        "id": "f10453af-9a9e-5637-914f-e531582ed377",
                        "interest_rate": 0.028,
                        "max_down_payment_installments": null,
                        "max_installments": 12,
                        "min_installment_amount_cents": 5000,
                        "payment_methods": [
                            "credit_card"
                        ],
                        "payment_type": "upfront",
                        "registration_fee": 0.0,
                        "take_rate_type": "percentage",
                        "take_rate_value": 0.0297
                    },
                    {
                        "allowed_down_payment_methods": [
                            "boleto",
                            "pix",
                            "credit_card"
                        ],
                        "availability": "enabled",
                        "down_payment_interest_rate": 0.028,
                        "down_payment_type": "percentage",
                        "down_payment_value": 0.1,
                        "expires_in": 12,
                        "fee_embedded_in_down_payment": false,
                        "financed_type": null,
                        "id": "ed683267-5ca4-5b6a-8567-6c097a46846f",
                        "interest_rate": 0.028,
                        "max_down_payment_installments": 12,
                        "max_installments": 24,
                        "min_installment_amount_cents": 5000,
                        "payment_methods": [
                            "boleto",
                            "credit_card",
                            "pix"
                        ],
                        "payment_type": "financed",
                        "registration_fee": 0.0197,
                        "take_rate_type": "percentage",
                        "take_rate_value": 0.0897
                    }
                ],
                "product": {
                    "access_period": "lifetime",
                    "availability": "enabled",
                    "banner_url": null,
                    "company_id": "10d95971-868c-517a-9354-8a2b8905fccd",
                    "created_at": "2023-11-29T10:32:42.753-03:00",
                    "description": "Produto da alegria.",
                    "duration_in_days": null,
                    "duration_in_hours": 12,
                    "end_date": null,
                    "formatted_access_period": "Vitalício",
                    "full_amount_cents": 100000,
                    "full_amount_currency": "BRL",
                    "google_pixel_code": null,
                    "id": "d41d3b70-7ecc-5b50-89de-6658595cc1ae",
                    "kind": {
                        "id": "47b593d4-68ec-55b1-acd4-6273bfd6d445",
                        "name": "Curso"
                    },
                    "meta_pixel_code": null,
                    "metadata": {},
                    "name": "Produto Exemplo",
                    "shift": {
                        "id": "3def779a-1247-532e-ac4b-1cb861ce9ce0",
                        "name": "Online"
                    },
                    "start_date": null,
                    "updated_at": "2023-11-29T10:32:42.753-03:00"
                },
                "smart_payment_enabled": false,
                "updated_at": "2023-11-29T10:32:42.765-03:00",
                "url": "https://pague-sandbox.lia.com.br/lia/oferta?offer_id=b8a16b0a-0978-5f0e-9cf1-493f56921c22"
            },
            "offers": [],
            "phone": {
                "address": "5511988888888",
                "contact_type": "phone",
                "created_at": "2023-11-29T10:32:42.876-03:00",
                "id": "35552917-6c3d-5c1d-8eb2-632880325aed",
                "purpose": "communication",
                "updated_at": "2024-04-09T08:50:56.806-03:00",
                "validated": false
            },
            "root_billing": null,
            "status": "canceled",
            "translated_cancelation_reason": "Compra expirada",
            "updated_at": "2023-12-12T21:00:50.857-03:00",
            "url": "https://pague-sandbox.lia.com.br/lia/pedido?order_id=df5dc696-2535-5b7b-9b72-b998654b00f2"
        },
        {
            "address": {
                "city": {
                    "ibge_code": "3549904",
                    "id": "137f7173-928a-596d-82f8-b63c8890c047",
                    "name": "São José dos Campos",
                    "state": {
                        "acronym": "SP",
                        "id": "50405e03-46a1-5b31-8ed1-d08167af85f6",
                        "name": "São Paulo"
                    },
                    "state_id": "50405e03-46a1-5b31-8ed1-d08167af85f6"
                },
                "complement": "",
                "id": "7f5d4d5b-c5bd-567a-ae5b-614e0f249a32",
                "neighborhood": "Centro",
                "number": "100",
                "street": "Rua Exemplo",
                "zipcode": "01001000"
            },
            "amount_cents": 100000,
            "analyses": [
                {
                    "created_at": "2023-11-29T16:16:10.127-03:00",
                    "denied_reason": null,
                    "id": "a4ac68a4-5d1b-515f-8bfc-4166a1bd2bf3",
                    "kind": null,
                    "status": "approved"
                },
                {
                    "created_at": "2023-11-29T16:16:10.066-03:00",
                    "denied_reason": "invalid_data",
                    "id": "e5382e49-f37c-564e-b606-88613f4feac0",
                    "kind": "identity",
                    "status": "denied"
                }
            ],
            "billings": [],
            "cancelation_reason": "analysis_denied",
            "checkout_type": "default",
            "created_at": "2023-11-29T16:16:06.976-03:00",
            "customer_birthdate": "1990-01-01",
            "customer_document": "12345678909",
            "customer_name": "John Armless",
            "customer_type": "person",
            "email": {
                "address": "john.armless@example.com",
                "contact_type": "email",
                "created_at": "2023-11-29T16:16:06.985-03:00",
                "id": "78d8551a-0b56-58f3-91cd-cd93417c2dff",
                "purpose": "communication",
                "updated_at": "2024-04-09T08:50:56.826-03:00",
                "validated": false
            },
            "finished_at": null,
            "id": "8570574a-8146-5b24-8263-66488874416b",
            "metadata": {},
            "offer": {
                "amount_cents": 100000,
                "amount_currency": "BRL",
                "availability": "enabled",
                "checkout_type": "default",
                "created_at": "2023-11-29T10:32:42.765-03:00",
                "id": "bdeebdb0-851e-5983-a63e-7b2668f12f50",
                "name": "Padrão",
                "payment_configurations": [
                    {
                        "allowed_down_payment_methods": [],
                        "availability": "enabled",
                        "down_payment_interest_rate": null,
                        "down_payment_type": null,
                        "down_payment_value": 0.0,
                        "expires_in": 12,
                        "fee_embedded_in_down_payment": false,
                        "financed_type": null,
                        "id": "a3dc85da-00a7-5eca-bea4-a753ea5abc49",
                        "interest_rate": 0.0,
                        "max_down_payment_installments": null,
                        "max_installments": 1,
                        "min_installment_amount_cents": 5000,
                        "payment_methods": [
                            "pix"
                        ],
                        "payment_type": "upfront",
                        "registration_fee": 0.0,
                        "take_rate_type": "absolute",
                        "take_rate_value": 297.0
                    },
                    {
                        "allowed_down_payment_methods": [],
                        "availability": "enabled",
                        "down_payment_interest_rate": null,
                        "down_payment_type": null,
                        "down_payment_value": 0.0,
                        "expires_in": null,
                        "fee_embedded_in_down_payment": false,
                        "financed_type": null,
                        "id": "f10453af-9a9e-5637-914f-e531582ed377",
                        "interest_rate": 0.028,
                        "max_down_payment_installments": null,
                        "max_installments": 12,
                        "min_installment_amount_cents": 5000,
                        "payment_methods": [
                            "credit_card"
                        ],
                        "payment_type": "upfront",
                        "registration_fee": 0.0,
                        "take_rate_type": "percentage",
                        "take_rate_value": 0.0297
                    },
                    {
                        "allowed_down_payment_methods": [
                            "boleto",
                            "pix",
                            "credit_card"
                        ],
                        "availability": "enabled",
                        "down_payment_interest_rate": 0.028,
                        "down_payment_type": "percentage",
                        "down_payment_value": 0.1,
                        "expires_in": 12,
                        "fee_embedded_in_down_payment": false,
                        "financed_type": null,
                        "id": "ed683267-5ca4-5b6a-8567-6c097a46846f",
                        "interest_rate": 0.028,
                        "max_down_payment_installments": 12,
                        "max_installments": 24,
                        "min_installment_amount_cents": 5000,
                        "payment_methods": [
                            "boleto",
                            "credit_card",
                            "pix"
                        ],
                        "payment_type": "financed",
                        "registration_fee": 0.0197,
                        "take_rate_type": "percentage",
                        "take_rate_value": 0.0897
                    }
                ],
                "product": {
                    "access_period": "lifetime",
                    "availability": "enabled",
                    "banner_url": null,
                    "company_id": "10d95971-868c-517a-9354-8a2b8905fccd",
                    "created_at": "2023-11-29T10:32:42.753-03:00",
                    "description": "Produto da alegria.",
                    "duration_in_days": null,
                    "duration_in_hours": 12,
                    "end_date": null,
                    "formatted_access_period": "Vitalício",
                    "full_amount_cents": 100000,
                    "full_amount_currency": "BRL",
                    "google_pixel_code": null,
                    "id": "d41d3b70-7ecc-5b50-89de-6658595cc1ae",
                    "kind": {
                        "id": "47b593d4-68ec-55b1-acd4-6273bfd6d445",
                        "name": "Curso"
                    },
                    "meta_pixel_code": null,
                    "metadata": {},
                    "name": "Produto Exemplo",
                    "shift": {
                        "id": "3def779a-1247-532e-ac4b-1cb861ce9ce0",
                        "name": "Online"
                    },
                    "start_date": null,
                    "updated_at": "2023-11-29T10:32:42.753-03:00"
                },
                "smart_payment_enabled": false,
                "updated_at": "2023-11-29T10:32:42.765-03:00",
                "url": "https://pague-sandbox.lia.com.br/lia/oferta?offer_id=f2bc7cca-fa76-5252-9109-fd7c6c42ae33"
            },
            "offers": [],
            "phone": {
                "address": "5511999999999",
                "contact_type": "phone",
                "created_at": "2023-11-29T16:16:06.983-03:00",
                "id": "6f7667c0-c600-576f-b919-8aee7535c7f7",
                "purpose": "communication",
                "updated_at": "2024-04-09T08:50:56.819-03:00",
                "validated": false
            },
            "root_billing": null,
            "status": "canceled",
            "translated_cancelation_reason": "Dado inconsistente",
            "updated_at": "2023-11-29T16:16:10.074-03:00",
            "url": "https://pague-sandbox.lia.com.br/lia/pedido?order_id=cca19ec3-9088-57d9-af8c-cb39ca28ba62"
        }
    ],
    "total_items": 7,
    "total_pages": 4
}