Lấy trạng thái tờ khai
GET /core-api/customers/declaration-status
API dùng để lấy trạng thái tờ khai kiểm tra xem đã có tờ khai chấp nhận chưa.
Headers
| Name | Required | Description |
|---|---|---|
Authorization | ✅ | Bearer token |
Content-Type | ✅ | application/json |
Query Parameters
| Name | Required | Description |
|---|---|---|
provider | ✅ | Tên nhà cung cấp đang sử dụng (ví dụ: '1Invoice'). |
taxCode | ✅ | Mã số thuế người bán (ví dụ: '00883243241'). |
sorting | Sắp xếp theo trường (ví dụ: 'creationTime'). | |
sortType | Kiểu sắp xếp (DESCEND: Giảm dần, ASCEND: Tăng dần). | |
formDate | Ngày lập từ ngày (ví dụ: '2024-12-31'). | |
toDate | Ngày lập đến ngày (ví dụ: '2025-08-11'). | |
taxAuthorityFeedback | Phản hồi của CQT (1: Tiếp nhận, 2: Không tiếp nhận, 3: Chấp nhận, 4: Không chấp nhận). |
Response
| Name | Description |
|---|---|
data[].id | Id tờ khai |
data[].formality | Loại tờ khai, 1: Đăng ký, 2: Thay đổi |
data[].taxCode | Mã số thuế người bán |
data[].taxAuthorityFeedback | Phản hồi của CQT (1: Tiếp nhận, 2: Không tiếp nhận, 3: Chấp nhận, 4: Không chấp nhận) |
data[].dateCreate | Ngày tạo, định dạng ISO 8601 |
data[].status | Trạng thái tờ khai, 0: Chưa gửi, 1: Đã gửi |
data[].dateSign | Ngày ký, định dạng ISO 8601 |
ghi chú
Endpoint này được gọi trực tiếp (không theo dạng /<provider>/...); nhà cung cấp được truyền qua tham số provider trên query.
- 1Invoice
- one-invoice
- Response
curl --location 'https://stag-invoice-hub.1invoice.vn/core-api/customers/declaration-status?provider=1Invoice&taxCode=0106026495-998&sorting=creationTime&sortType=DESCEND&fromDate=2024-12-31&toDate=2025-08-12&taxAuthorityFeedback=3' \
--header 'authorization: Bearer <token>'
curl --location 'https://stag-invoice-hub.1invoice.vn/core-api/customers/declaration-status?provider=one-invoice&taxCode=0106026495-998&sorting=creationTime&sortType=DESCEND&fromDate=2025-12-31&toDate=2026-04-15&taxAuthorityFeedback=3' \
--header 'accept: application/json, text/plain, */*' \
--header 'authorization: Bearer <token>' \
--header 'x-tax-code: 0106026495-998'
{
"success": true,
"data": [
{
"id": "3a1b94b4-04f9-d3d5-41a8-74dcba5c71d5",
"formality": 2,
"taxCode": "0106026495-998",
"taxAuthorityFeedback": 3,
"dateCreate": "2025-08-07T00:00:00",
"status": 1,
"dateSign": "2025-08-07T03:16:00.126946+00:00"
},
{
"id": "3a1b8512-7a76-ba2c-a6a1-6f656276d399",
"formality": 2,
"taxCode": "0106026495-998",
"taxAuthorityFeedback": 3,
"dateCreate": "2025-08-04T00:00:00",
"status": 1,
"dateSign": "2025-08-04T02:25:13.474248+00:00"
},
{
"id": "3a1b1e62-6618-109a-691f-e286f66c1c97",
"formality": 2,
"taxCode": "0106026495-998",
"taxAuthorityFeedback": 3,
"dateCreate": "2025-07-15T00:00:00",
"status": 1,
"dateSign": "2025-07-15T03:53:51.537946+00:00"
}
]
}