API Reference - pims.authentication.account-isAccountBlocked
Info: Stellantis Mobile SDK for ex Groupe PSA brands (CitroĂŤn, DS, Peugeot, Opel and Vauxhall) is not publicly available for now.
Available since:
v2.0.X
Component:
StrongAuthentication
Security:
Authentication
is required.
Operation:
Returns if the account is blocked or not.
Input Parameter | |||||
---|---|---|---|---|---|
Param name | Description | Type | Unit/Values | Example | Required |
actionType | Action Name, in this case |
String |
|
strong
|
true |
type | Retrieve if account is blocked. |
String |
|
isAccountBlocked
|
true |
Output Data | ||||
---|---|---|---|---|
Data name | Description | Type | Unit/Values | Example |
isAccountBlocked | Indicates if the user accountâs is blocked or not. |
Enum of Strings |
- Unknown
- PinBlocked
- NotBlocked
|
NotBlocked
|
Error | |
---|---|
Error Code | Error Label |
2001 | Facade not initialized |
2101 | Missing [PARAMETER] parameter |
2102 | Invalid [PARAMETER] parameter |
2344 | [Component] not configured |
Code Example
1
2
3
4
5
6
7
8
9
10
pims.get("pims.authentication.account",
mapOf( /* parameters */
Pair("actionType", "strong"),
Pair("type", "isAccountBlocked")
)
) { message -> when (message["status"] as? String) {
"SUCCEEDED" -> { } // handle succeeded status
"FAILED" -> { } // handle failed status
} }
1
2
3
4
5
6
7
8
9
10
pims.get(api: "pims.authentication.account",
parameters: [
"actionType": "strong",
"type": "isAccountBlocked"
]
) { (message) in
if message["status"] == "SUCEEDED" { } // handle succeeded status
else if message["status"] == "FAILED" { } // handle failed status
}
1
2
3
4
5
6
7
8
// representation of the `succeeded` dictionary object message as JSON
{
"transactionId": "953cfefb-bc72",
"status": "SUCCEEDED",
"result": {
"isAccountBlocked": "NotBlocked"
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// representation of the `failed` dictionary objects messages as JSON
/* -------- STATUS FAILED: 2001 -------- */
{
"transactionId": "953cfefb-bc72",
"status": "FAILED",
"error": {
"code": 2001,
"label": "Facade not initialized"
}
}
/* -------- STATUS FAILED: 2101 -------- */
{
"transactionId": "953cfefb-bc72",
"status": "FAILED",
"error": {
"code": 2101,
"label": "Missing [PARAMETER] parameter"
}
}
/* -------- STATUS FAILED: 2102 -------- */
{
"transactionId": "953cfefb-bc72",
"status": "FAILED",
"error": {
"code": 2102,
"label": "Invalid [PARAMETER] parameter"
}
}
/* -------- STATUS FAILED: 2344 -------- */
{
"transactionId": "953cfefb-bc72",
"status": "FAILED",
"error": {
"code": 2344,
"label": "[Component] not configured"
}
}