Chuyển tới nội dung chính
Phiên bản: 1.7.0

Đăng nhập lấy token

POST /<provider>/sign-in

API dùng để xác thực và lấy token truy cập cho các yêu cầu tiếp theo.

Headers​

NameRequiredDescription
Content-Type✅application/json
X-Tax-Code✅Mã số thuế người bán (cửa hàng...)

Body Parameters​

NameTypeRequiredDescription
usernamestring✅Tên đăng nhập
passwordstring✅Mật khẩu

Response​

NameTypeDescription
successbooleanAPI thực thi thành công hay không
tokenstringThông tin token truy cập vào hệ thống
messagestringThông báo tổng quan (nếu có)
error_codestringMã lỗi (nếu có)
errorsarray[object]Danh sách lỗi (nếu có)
curl --location 'https://stag-invoice-hub.1invoice.vn/1Invoice/sign-in' \
--header 'x-tax-code: 0106026495-998' \
--header 'Content-Type: application/json' \
--data-raw '{"username":"ATOM","password":"Kythuat@123"}'