Nhất Tín LogisticsDevelopers
API Reference

Authentication API

Sign-in and refresh token endpoints for the NTL Bill Online API.

POST/v1/auth/sign-in

Sign in with environment credentials to receive an access token and refresh token.

Auth: No token required

Request body

FieldTypeRequiredDescription
usernamestringYesAccount provided by Nhất Tín.
passwordstringYesPassword for the corresponding environment.
curl --request POST \
--url https://apisandbox.ntlogistics.vn/v1/auth/sign-in \
--header "Content-Type: application/json" \
--data '{"username":"your_account","password":"your_password"}'

Response

{
  "success": true,
  "data": {
    "jwt_token": "<access_token>",
    "token_type": "Bearer",
    "token_expires_in": "1m",
    "refresh_token": "<refresh_token>",
    "refresh_expires_in": "2m"
  }
}
POST/v1/auth/refresh-token

Refresh the access token when the current token expires.

Auth: Refresh token required

Refresh token request body

FieldTypeRequiredDescription
refresh_tokenstringYesRefresh token from the latest sign-in or refresh response.

On this page