Choose Organization¶
Select the organization that the user needs to use after login.
Operation Permissions¶
User login to Application Portal is required.
Request Format¶
POST https://{apigw-address}/app-portal-service/v2.2/session/set?channel
Request Parameters (Query)¶
Name |
Mandatory/Optional |
Data Type |
Description |
---|---|---|---|
channel |
Optional |
String |
Login source. |
Request Parameters (Header)¶
Name |
Mandatory/Optional |
Data Type |
Description |
---|---|---|---|
Authorization |
Mandatory |
String |
The access token (or bearer token). The format of the parameter’s string is Bearer {your token}. Refer to Log In or Refresh Access Token to learn how to get the access token. |
Request Parameters (Body)¶
Name |
Mandatory/Optional |
Data Type |
Description |
---|---|---|---|
orgId |
Mandatory |
String |
The organization ID. |
Response Parameters¶
Name |
Data Type |
Description |
---|---|---|
data |
Data Struct |
The details of the organization. |
data Struct¶
Name |
Data Type |
Description |
---|---|---|
userId |
String |
The user ID. |
userName |
String |
The user name. |
currentOrgId |
String |
The current organization ID. |
currentOrgName |
String |
The current organization name. |
accessToken |
String |
The access token in the request. |
refreshToken |
String |
The new refresh token. |
refreshTokenExpire |
String |
The refresh token expiration time in UTC format. For the time format, see ISO8601 Standard Time Formats Used by UTC |
Samples¶
Request Sample¶
url: https://{apigw-address}/app-portal-service/v2.2/session/set?channel=web
method: POST
headers: {"Authorization":"Bearer your_token"}
requestBody:
{"orgId":"yourOrgId"}
Return Sample¶
{
"code": 0,
"message": "OK",
"data": {
"userId": "your_user_id",
"userName": "your_user_name",
"currentOrgId": "your_org_id",
"currentOrgName": "your_org_name",
"accessToken": "your_access_token",
"refreshToken": "your_refresh_token",
"refreshTokenExpire": 1570018958000
}
}