Skip to main content
POST
/
gateway
/
auth
/
login
Login
curl --request POST \
  --url https://api.discountdrugnetwork.com/gateway/auth/login \
  --header 'x-ddn-client-key: <api-key>'
{
  "accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "refreshToken": "8joiu...",
  "expiresIn": 3600,
  "tokenType": "Bearer"
}

Endpoint

POST https://api.discountdrugnetwork.com/gateway/auth/login?groupId=GROUPID

Input Parameters

groupId
string
required
Your group ID number.Example: 12345

Response Fields

accessToken
string
required
The JWT Authentication token to use in the Authorization Bearer header for future requests.Example: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
refreshToken
string
required
The token to refresh the authentication session.Example: 8joiu...
expiresIn
int
required
Number of seconds before the token expires.Example: 3600
tokenType
string
required
Identifies the type of token. Typically, this will be “Bearer”.Example: Bearer

Authorizations

x-ddn-client-key
string
header
required

Query Parameters

groupId
string
required

Your group ID number. Example: 12345

Response

Successful login

accessToken
string

The JWT Authentication token to use in the Authorization Bearer header for future requests.

Example:

"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."

refreshToken
string

The token to refresh the authentication session.

Example:

"8joiu..."

expiresIn
integer

Number of seconds before the token expires.

Example:

3600

tokenType
string

Identifies the type of token. Typically, this will be 'Bearer'.

Example:

"Bearer"