refactor/rename UserNotLoggedIn to AuthenticatedUserIsRequired

This commit is contained in:
hongwei 2026-01-20 13:12:11 +01:00
parent 9ce6cb4164
commit 3b467129fb
218 changed files with 1722 additions and 1722 deletions

View File

@ -53,7 +53,7 @@ object APIMethods_AccountsApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -61,7 +61,7 @@ object APIMethods_AccountsApi extends RestHelper {
case "banking":: "accounts" :: accountId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -93,7 +93,7 @@ object APIMethods_AccountsApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -101,7 +101,7 @@ object APIMethods_AccountsApi extends RestHelper {
case "banking":: "accounts" :: accountId:: "transactions" :: transactionId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -194,7 +194,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -202,7 +202,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts" :: accountId:: "transactions" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -310,7 +310,7 @@ Some general notes that apply to all end points that retrieve transactions:
// "first" : "first"
// }
//}"""),
// List(UserNotLoggedIn, UnknownError),
// List(AuthenticatedUserIsRequired, UnknownError),
//
// ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
// )
@ -319,7 +319,7 @@ Some general notes that apply to all end points that retrieve transactions:
// case "banking":: "accounts" :: Nil JsonGet _ => {
// cc =>
// for {
// (Full(u), callContext) <- authorizedAccess(cc, UserNotLoggedIn)
// (Full(u), callContext) <- authorizedAccess(cc, AuthenticatedUserIsRequired)
// } yield {
// (json.parse("""{
// "data" : {
@ -394,7 +394,7 @@ Some general notes that apply to all end points that retrieve transactions:
// "self" : "self"
// }
//}"""),
// List(UserNotLoggedIn, UnknownError),
// List(AuthenticatedUserIsRequired, UnknownError),
//
// ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
// )
@ -403,7 +403,7 @@ Some general notes that apply to all end points that retrieve transactions:
// case "banking":: "accounts" :: accountId:: "balance" :: Nil JsonGet _ => {
// cc =>
// for {
// (Full(u), callContext) <- authorizedAccess(cc, UserNotLoggedIn)
// (Full(u), callContext) <- authorizedAccess(cc, AuthenticatedUserIsRequired)
// } yield {
// (json.parse("""{
// "data" : {
@ -486,7 +486,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -494,7 +494,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts":: "balances" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -605,7 +605,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -613,7 +613,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts":: "balances" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -65,7 +65,7 @@ object APIMethods_BankingApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -73,7 +73,7 @@ object APIMethods_BankingApi extends RestHelper {
case "banking":: "accounts" :: accountId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -105,7 +105,7 @@ object APIMethods_BankingApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Payees") :: apiTagMockedData :: Nil
)
@ -113,7 +113,7 @@ object APIMethods_BankingApi extends RestHelper {
case "banking":: "payees" :: payeeId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -145,7 +145,7 @@ object APIMethods_BankingApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Products") :: apiTagMockedData :: Nil
)
@ -153,7 +153,7 @@ object APIMethods_BankingApi extends RestHelper {
case "banking":: "products" :: productId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -185,7 +185,7 @@ object APIMethods_BankingApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -193,7 +193,7 @@ object APIMethods_BankingApi extends RestHelper {
case "banking":: "accounts" :: accountId:: "transactions" :: transactionId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -286,7 +286,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -294,7 +294,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts" :: accountId:: "transactions" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -402,7 +402,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: Nil
)
@ -410,7 +410,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
availablePrivateAccounts <- Views.views.vend.getPrivateBankAccountsFuture(u, BankId(defaultBankId))
(coreAccounts, callContext) <- NewStyle.function.getCoreBankAccountsFuture(availablePrivateAccounts, callContext)
} yield {
@ -452,7 +452,7 @@ Some general notes that apply to all end points that retrieve transactions:
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: Nil
)
@ -460,7 +460,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts" :: accountId:: "balance" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
(account, callContext) <- NewStyle.function.checkBankAccountExists(BankId(defaultBankId), AccountId(accountId), callContext)
} yield {
(JSONFactory_AU_OpenBanking_1_0_0.createAccountBalanceJson(account), HttpCode.`200`(callContext))
@ -524,7 +524,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -532,7 +532,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts":: "balances" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -643,7 +643,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -651,7 +651,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts":: "balances" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -751,7 +751,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -759,7 +759,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts" :: accountId:: "direct-debits" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -853,7 +853,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -861,7 +861,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts":: "direct-debits" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -960,7 +960,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -968,7 +968,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "accounts":: "direct-debits" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -1052,7 +1052,7 @@ Some general notes that apply to all end points that retrieve transactions:
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Payees") :: apiTagMockedData :: Nil
)
@ -1060,7 +1060,7 @@ Some general notes that apply to all end points that retrieve transactions:
case "banking":: "payees" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -1202,7 +1202,7 @@ In addition, the concept of effective date and time has also been included. This
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Products") :: apiTagMockedData :: Nil
)
@ -1210,7 +1210,7 @@ In addition, the concept of effective date and time has also been included. This
case "banking":: "products" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -1578,7 +1578,7 @@ In addition, the concept of effective date and time has also been included. This
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -1586,7 +1586,7 @@ In addition, the concept of effective date and time has also been included. This
case "banking":: "accounts" :: accountId:: "payments":: "scheduled" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -2196,7 +2196,7 @@ In addition, the concept of effective date and time has also been included. This
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -2204,7 +2204,7 @@ In addition, the concept of effective date and time has also been included. This
case "banking":: "payments":: "scheduled" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -2819,7 +2819,7 @@ In addition, the concept of effective date and time has also been included. This
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -2827,7 +2827,7 @@ In addition, the concept of effective date and time has also been included. This
case "banking":: "payments":: "scheduled" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -77,7 +77,7 @@ object APIMethods_CommonApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Customer") :: apiTagMockedData :: Nil
)
@ -85,7 +85,7 @@ object APIMethods_CommonApi extends RestHelper {
case "common":: "customer" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -148,7 +148,7 @@ object APIMethods_CommonApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Customer") :: apiTagMockedData :: Nil
)
@ -156,7 +156,7 @@ object APIMethods_CommonApi extends RestHelper {
case "common":: "customer":: "detail" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -204,7 +204,7 @@ object APIMethods_CommonApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Discovery") :: apiTagMockedData :: Nil
)
@ -212,7 +212,7 @@ object APIMethods_CommonApi extends RestHelper {
case "discovery":: "outages" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -262,7 +262,7 @@ object APIMethods_CommonApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Discovery") :: apiTagMockedData :: Nil
)
@ -270,7 +270,7 @@ object APIMethods_CommonApi extends RestHelper {
case "discovery":: "status" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -75,7 +75,7 @@ object APIMethods_CustomerApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Customer") :: apiTagMockedData :: Nil
)
@ -83,7 +83,7 @@ object APIMethods_CustomerApi extends RestHelper {
case "common":: "customer" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -146,7 +146,7 @@ object APIMethods_CustomerApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Customer") :: apiTagMockedData :: Nil
)
@ -154,7 +154,7 @@ object APIMethods_CustomerApi extends RestHelper {
case "common":: "customer":: "detail" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -80,7 +80,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -88,7 +88,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
case "banking":: "accounts" :: accountId:: "direct-debits" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -182,7 +182,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -190,7 +190,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
case "banking":: "accounts":: "direct-debits" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -289,7 +289,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -297,7 +297,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
case "banking":: "accounts":: "direct-debits" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -60,7 +60,7 @@ object APIMethods_DiscoveryApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Discovery") :: apiTagMockedData :: Nil
)
@ -68,7 +68,7 @@ object APIMethods_DiscoveryApi extends RestHelper {
case "discovery":: "outages" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -118,7 +118,7 @@ object APIMethods_DiscoveryApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Common") ::ApiTag("Discovery") :: apiTagMockedData :: Nil
)
@ -126,7 +126,7 @@ object APIMethods_DiscoveryApi extends RestHelper {
case "discovery":: "status" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -48,7 +48,7 @@ object APIMethods_PayeesApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Payees") :: apiTagMockedData :: Nil
)
@ -56,7 +56,7 @@ object APIMethods_PayeesApi extends RestHelper {
case "banking":: "payees" :: payeeId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -109,7 +109,7 @@ object APIMethods_PayeesApi extends RestHelper {
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Payees") :: apiTagMockedData :: Nil
)
@ -117,7 +117,7 @@ object APIMethods_PayeesApi extends RestHelper {
case "banking":: "payees" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -47,7 +47,7 @@ object APIMethods_ProductsApi extends RestHelper {
"self" : "self"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Products") :: apiTagMockedData :: Nil
)
@ -55,7 +55,7 @@ object APIMethods_ProductsApi extends RestHelper {
case "banking":: "products" :: productId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : "",
@ -176,7 +176,7 @@ In addition, the concept of effective date and time has also been included. This
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Products") :: apiTagMockedData :: Nil
)
@ -184,7 +184,7 @@ In addition, the concept of effective date and time has also been included. This
case "banking":: "products" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -338,7 +338,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -346,7 +346,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
case "banking":: "accounts" :: accountId:: "payments":: "scheduled" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -956,7 +956,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -964,7 +964,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
case "banking":: "payments":: "scheduled" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {
@ -1579,7 +1579,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
"first" : "first"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Banking") ::ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -1587,7 +1587,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
case "banking":: "payments":: "scheduled" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"data" : {

View File

@ -62,7 +62,7 @@ object APIMethods_AccountAccessConsentsApi extends RestHelper {
"TransactionFromDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Access Consents") :: apiTagMockedData :: Nil
)
@ -70,7 +70,7 @@ object APIMethods_AccountAccessConsentsApi extends RestHelper {
case "account-access-consents" :: consentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -135,7 +135,7 @@ object APIMethods_AccountAccessConsentsApi extends RestHelper {
"TransactionFromDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Access Consents") :: apiTagMockedData :: Nil
)
@ -143,7 +143,7 @@ object APIMethods_AccountAccessConsentsApi extends RestHelper {
case "account-access-consents" :: consentId :: Nil JsonPatch _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -210,7 +210,7 @@ object APIMethods_AccountAccessConsentsApi extends RestHelper {
"TransactionFromDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Access Consents") :: apiTagMockedData :: Nil
)
@ -218,7 +218,7 @@ object APIMethods_AccountAccessConsentsApi extends RestHelper {
case "account-access-consents" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -55,7 +55,7 @@ object APIMethods_AccountsApi extends RestHelper {
"Account" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -63,7 +63,7 @@ object APIMethods_AccountsApi extends RestHelper {
case "accounts" :: accountId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -112,7 +112,7 @@ object APIMethods_AccountsApi extends RestHelper {
"Account" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Accounts") :: apiTagMockedData :: Nil
)
@ -120,7 +120,7 @@ object APIMethods_AccountsApi extends RestHelper {
case "accounts" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -91,7 +91,7 @@ object APIMethods_BalancesApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Balances") :: apiTagMockedData :: Nil
)
@ -99,7 +99,7 @@ object APIMethods_BalancesApi extends RestHelper {
case "accounts" :: accountId:: "balances" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -220,7 +220,7 @@ object APIMethods_BalancesApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Balances") :: apiTagMockedData :: Nil
)
@ -228,7 +228,7 @@ object APIMethods_BalancesApi extends RestHelper {
case "balances" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -55,7 +55,7 @@ object APIMethods_BeneficiariesApi extends RestHelper {
"Beneficiary" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Beneficiaries") :: apiTagMockedData :: Nil
)
@ -63,7 +63,7 @@ object APIMethods_BeneficiariesApi extends RestHelper {
case "accounts" :: accountId:: "beneficiaries" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -112,7 +112,7 @@ object APIMethods_BeneficiariesApi extends RestHelper {
"Beneficiary" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Beneficiaries") :: apiTagMockedData :: Nil
)
@ -120,7 +120,7 @@ object APIMethods_BeneficiariesApi extends RestHelper {
case "beneficiaries" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -81,7 +81,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -89,7 +89,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
case "accounts" :: accountId:: "direct-debits" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -190,7 +190,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -198,7 +198,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
case "direct-debits" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -65,7 +65,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payment Consents") :: apiTagMockedData :: Nil
)
@ -73,7 +73,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
case "domestic-future-dated-payment-cancellation-consents" :: consentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Data" : {
@ -145,7 +145,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payment Consents") :: apiTagMockedData :: Nil
)
@ -153,7 +153,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
case "domestic-future-dated-payment-cancellation-consents" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Data" : {
@ -290,7 +290,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payment Consents") :: apiTagMockedData :: Nil
)
@ -298,7 +298,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
case "domestic-future-dated-payment-consents" :: consentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -566,7 +566,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payment Consents") :: apiTagMockedData :: Nil
)
@ -574,7 +574,7 @@ object APIMethods_DomesticFutureDatedPaymentConsentsApi extends RestHelper {
case "domestic-future-dated-payment-consents" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -123,7 +123,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payments") :: apiTagMockedData :: Nil
)
@ -131,7 +131,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
case "domestic-future-dated-payments" :: domesticFutureDatedPaymentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -317,7 +317,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payments") :: apiTagMockedData :: Nil
)
@ -325,7 +325,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
case "domestic-future-dated-payments" :: domesticFutureDatedPaymentId :: Nil JsonPatch _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -460,7 +460,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payments") :: apiTagMockedData :: Nil
)
@ -468,7 +468,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
case "domestic-future-dated-payments" :: domesticFutureDatedPaymentId:: "payment-details" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -652,7 +652,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Future Dated Payments") :: apiTagMockedData :: Nil
)
@ -660,7 +660,7 @@ object APIMethods_DomesticFutureDatedPaymentsApi extends RestHelper {
case "domestic-future-dated-payments" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -121,7 +121,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)
@ -129,7 +129,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
case "domestic-payments" :: domesticPaymentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -263,7 +263,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)
@ -271,7 +271,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
case "domestic-payments" :: domesticPaymentId:: "payment-details" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -453,7 +453,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)
@ -461,7 +461,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
case "domestic-payments" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -60,7 +60,7 @@ object APIMethods_DomesticPaymentsConsentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments Consents") :: apiTagMockedData :: Nil
)
@ -68,7 +68,7 @@ object APIMethods_DomesticPaymentsConsentsApi extends RestHelper {
case "domestic-payment-consents" :: consentId:: "funds-confirmation" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -199,7 +199,7 @@ object APIMethods_DomesticPaymentsConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments Consents") :: apiTagMockedData :: Nil
)
@ -207,7 +207,7 @@ object APIMethods_DomesticPaymentsConsentsApi extends RestHelper {
case "domestic-payment-consents" :: consentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -469,7 +469,7 @@ object APIMethods_DomesticPaymentsConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments Consents") :: apiTagMockedData :: Nil
)
@ -477,7 +477,7 @@ object APIMethods_DomesticPaymentsConsentsApi extends RestHelper {
case "domestic-payment-consents" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -94,7 +94,7 @@ object APIMethods_EventNotificationApi extends RestHelper {
"jti" : "jti"
}"""),
json.parse(""""""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Event Notification") :: apiTagMockedData :: Nil
)
@ -102,7 +102,7 @@ object APIMethods_EventNotificationApi extends RestHelper {
case "event-notifications" :: Nil JsonPost _ => {
cc => implicit val ec = EndpointContext(Some(cc))
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse(""""""), callContext)
}

View File

@ -42,7 +42,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
""",
json.parse(""""""),
json.parse("""{ }"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payment Consents") :: apiTagMockedData :: Nil
)
@ -50,7 +50,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
case "file-payment-consents" :: consentId:: "file" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{ }"""), callContext)
}
@ -69,7 +69,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
""",
json.parse("""{ }"""),
json.parse(""""""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payment Consents") :: apiTagMockedData :: Nil
)
@ -77,7 +77,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
case "file-payment-consents" :: consentId:: "file" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse(""""""), callContext)
}
@ -159,7 +159,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payment Consents") :: apiTagMockedData :: Nil
)
@ -167,7 +167,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
case "file-payment-consents" :: consentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -341,7 +341,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payment Consents") :: apiTagMockedData :: Nil
)
@ -349,7 +349,7 @@ object APIMethods_FilePaymentConsentsApi extends RestHelper {
case "file-payment-consents" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -96,7 +96,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -104,7 +104,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
case "file-payments" :: filePaymentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -212,7 +212,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -220,7 +220,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
case "file-payments" :: filePaymentId:: "payment-details" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -274,7 +274,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
""",
json.parse(""""""),
json.parse("""{ }"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -282,7 +282,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
case "file-payments" :: filePaymentId:: "report-file" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{ }"""), callContext)
}
@ -376,7 +376,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -384,7 +384,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
case "file-payments" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -55,7 +55,7 @@ object APIMethods_FutureDatedPaymentsApi extends RestHelper {
"FutureDatedPayment" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Future Dated Payments") :: apiTagMockedData :: Nil
)
@ -63,7 +63,7 @@ object APIMethods_FutureDatedPaymentsApi extends RestHelper {
case "accounts" :: accountId:: "future-dated-payments" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -112,7 +112,7 @@ object APIMethods_FutureDatedPaymentsApi extends RestHelper {
"FutureDatedPayment" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Future Dated Payments") :: apiTagMockedData :: Nil
)
@ -120,7 +120,7 @@ object APIMethods_FutureDatedPaymentsApi extends RestHelper {
case "future-dated-payments" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -60,7 +60,7 @@ object APIMethods_InternationalPaymentConsentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payment Consents") :: apiTagMockedData :: Nil
)
@ -68,7 +68,7 @@ object APIMethods_InternationalPaymentConsentsApi extends RestHelper {
case "international-payment-consents" :: consentId:: "funds-confirmation" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -238,7 +238,7 @@ object APIMethods_InternationalPaymentConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payment Consents") :: apiTagMockedData :: Nil
)
@ -246,7 +246,7 @@ object APIMethods_InternationalPaymentConsentsApi extends RestHelper {
case "international-payment-consents" :: consentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -618,7 +618,7 @@ object APIMethods_InternationalPaymentConsentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payment Consents") :: apiTagMockedData :: Nil
)
@ -626,7 +626,7 @@ object APIMethods_InternationalPaymentConsentsApi extends RestHelper {
case "international-payment-consents" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -192,7 +192,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)
@ -200,7 +200,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
case "international-payments" :: internationalPaymentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -405,7 +405,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)
@ -413,7 +413,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
case "international-payments" :: internationalPaymentId:: "payment-details" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -698,7 +698,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)
@ -706,7 +706,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
case "international-payments" :: Nil JsonPost _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -87,7 +87,7 @@ object APIMethods_OffersApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Offers") :: apiTagMockedData :: Nil
)
@ -95,7 +95,7 @@ object APIMethods_OffersApi extends RestHelper {
case "accounts" :: accountId:: "offers" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -208,7 +208,7 @@ object APIMethods_OffersApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Offers") :: apiTagMockedData :: Nil
)
@ -216,7 +216,7 @@ object APIMethods_OffersApi extends RestHelper {
case "offers" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -130,7 +130,7 @@ object APIMethods_PartiesApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Parties") :: apiTagMockedData :: Nil
)
@ -138,7 +138,7 @@ object APIMethods_PartiesApi extends RestHelper {
case "accounts" :: accountId:: "parties" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -298,7 +298,7 @@ object APIMethods_PartiesApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Parties") :: apiTagMockedData :: Nil
)
@ -306,7 +306,7 @@ object APIMethods_PartiesApi extends RestHelper {
case "accounts" :: accountId:: "party" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -429,7 +429,7 @@ object APIMethods_PartiesApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Parties") :: apiTagMockedData :: Nil
)
@ -437,7 +437,7 @@ object APIMethods_PartiesApi extends RestHelper {
case "party" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -55,7 +55,7 @@ object APIMethods_StandingOrdersApi extends RestHelper {
"StandingOrder" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Standing Orders") :: apiTagMockedData :: Nil
)
@ -63,7 +63,7 @@ object APIMethods_StandingOrdersApi extends RestHelper {
case "accounts" :: accountId:: "standing-orders" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -112,7 +112,7 @@ object APIMethods_StandingOrdersApi extends RestHelper {
"StandingOrder" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Standing Orders") :: apiTagMockedData :: Nil
)
@ -120,7 +120,7 @@ object APIMethods_StandingOrdersApi extends RestHelper {
case "standing-orders" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -58,7 +58,7 @@ object APIMethods_StatementsApi extends RestHelper {
"Statement" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -66,7 +66,7 @@ object APIMethods_StatementsApi extends RestHelper {
case "accounts" :: accountId:: "statements" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -100,7 +100,7 @@ object APIMethods_StatementsApi extends RestHelper {
""",
json.parse(""""""),
json.parse("""{ }"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -108,7 +108,7 @@ object APIMethods_StatementsApi extends RestHelper {
case "accounts" :: accountId:: "statements" :: statementId:: "file" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{ }"""), callContext)
}
@ -142,7 +142,7 @@ object APIMethods_StatementsApi extends RestHelper {
"Statement" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -150,7 +150,7 @@ object APIMethods_StatementsApi extends RestHelper {
case "accounts" :: accountId:: "statements" :: statementId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -199,7 +199,7 @@ object APIMethods_StatementsApi extends RestHelper {
"Transaction" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -207,7 +207,7 @@ object APIMethods_StatementsApi extends RestHelper {
case "accounts" :: accountId:: "statements" :: statementId:: "transactions" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -256,7 +256,7 @@ object APIMethods_StatementsApi extends RestHelper {
"Statement" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -264,7 +264,7 @@ object APIMethods_StatementsApi extends RestHelper {
case "statements" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -78,7 +78,7 @@ object APIMethods_SupplementaryAccountInfoApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Supplementary Account Info") :: apiTagMockedData :: Nil
)
@ -86,7 +86,7 @@ object APIMethods_SupplementaryAccountInfoApi extends RestHelper {
case "accounts" :: accountId:: "supplementary-account-info" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Data" : {

View File

@ -55,7 +55,7 @@ object APIMethods_TransactionsApi extends RestHelper {
"Transaction" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Transactions") :: apiTagMockedData :: Nil
)
@ -63,7 +63,7 @@ object APIMethods_TransactionsApi extends RestHelper {
case "accounts" :: accountId:: "transactions" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {
@ -112,7 +112,7 @@ object APIMethods_TransactionsApi extends RestHelper {
"Transaction" : [ { }, { } ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Transactions") :: apiTagMockedData :: Nil
)
@ -120,7 +120,7 @@ object APIMethods_TransactionsApi extends RestHelper {
case "transactions" :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
} yield {
(json.parse("""{
"Meta" : {

View File

@ -49,7 +49,7 @@ Removes consent""",
"consentId" : "consentId"
}"""),
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -106,7 +106,7 @@ User identification based on access token""",
"availableBalance" : "availableBalance"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -189,7 +189,7 @@ User identification based on access token""",
"accountNumber" : "accountNumber"
} ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -251,7 +251,7 @@ User identification based on access token""",
},
"holds" : [ "", "" ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -344,7 +344,7 @@ User identification based on access token""",
"amountBaseCurrency" : "amountBaseCurrency",
"tppName" : "tppName"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -432,7 +432,7 @@ User identification based on access token""",
},
"transactions" : [ "", "" ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -480,7 +480,7 @@ User identification based on access token""",
},
"transactions" : [ "", "" ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -528,7 +528,7 @@ User identification based on access token""",
},
"transactions" : [ "", "" ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -576,7 +576,7 @@ User identification based on access token""",
},
"transactions" : [ "", "" ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)
@ -624,7 +624,7 @@ User identification based on access token""",
},
"transactions" : [ "", "" ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AIS") :: apiTagMockedData :: Nil
)

View File

@ -927,7 +927,7 @@ Requests OAuth2 authorization code""",
},
"aspspRedirectUri" : "aspspRedirectUri"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AS") :: apiTagMockedData :: Nil
)
@ -1844,7 +1844,7 @@ Requests OAuth2 authorization code based One-time authorization code issued by E
"client_id" : "client_id"
}"""),
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AS") :: apiTagMockedData :: Nil
)
@ -2820,7 +2820,7 @@ Requests OAuth2 access token value""",
"token_type" : "token_type",
"expires_in" : "expires_in"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AS") :: apiTagMockedData :: Nil
)

View File

@ -56,7 +56,7 @@ Confirming the availability on the payers account of the amount necessary to exe
"isCallback" : true
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("CAF") :: apiTagMockedData :: Nil
)

View File

@ -253,7 +253,7 @@ object APIMethods_PISApi extends RestHelper {
"bundleDetailedStatus" : "bundleDetailedStatus",
"bundleStatus" : "inProgress"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -314,7 +314,7 @@ object APIMethods_PISApi extends RestHelper {
"executionMode" : "Immediate"
} ]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -367,7 +367,7 @@ object APIMethods_PISApi extends RestHelper {
"recurringPaymentStatus" : "submitted",
"recurringPaymentDetailedStatus" : "recurringPaymentDetailedStatus"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -430,7 +430,7 @@ object APIMethods_PISApi extends RestHelper {
"isCallback" : true
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -493,7 +493,7 @@ object APIMethods_PISApi extends RestHelper {
"isCallback" : true
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -556,7 +556,7 @@ object APIMethods_PISApi extends RestHelper {
"bundleDetailedStatus" : "bundleDetailedStatus",
"bundleStatus" : "inProgress"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -641,7 +641,7 @@ object APIMethods_PISApi extends RestHelper {
"isCallback" : true
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -690,7 +690,7 @@ object APIMethods_PISApi extends RestHelper {
"requestHeader" : ""
}"""),
json.parse(""""""""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -730,7 +730,7 @@ object APIMethods_PISApi extends RestHelper {
"recurringPaymentStatus" : "submitted",
"recurringPaymentDetailedStatus" : "recurringPaymentDetailedStatus"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -802,7 +802,7 @@ object APIMethods_PISApi extends RestHelper {
"isCallback" : true
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -948,7 +948,7 @@ object APIMethods_PISApi extends RestHelper {
"recurringPaymentStatus" : "submitted",
"recurringPaymentDetailedStatus" : "recurringPaymentDetailedStatus"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)
@ -1025,7 +1025,7 @@ object APIMethods_PISApi extends RestHelper {
"isCallback" : true
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PIS") :: apiTagMockedData :: Nil
)

View File

@ -652,7 +652,7 @@ object OpenAPI31JSONFactory extends MdcLoggable {
* Determines if an endpoint requires authentication
*/
private def requiresAuthentication(doc: ResourceDocJson): Boolean = {
doc.error_response_bodies.exists(_.contains("UserNotLoggedIn")) ||
doc.error_response_bodies.exists(_.contains("AuthenticatedUserIsRequired")) ||
doc.roles.nonEmpty ||
doc.description.toLowerCase.contains("authentication is required") ||
doc.description.toLowerCase.contains("user must be logged in")

View File

@ -101,7 +101,7 @@ The ASPSP answers by providing a list of balances on this account.
| }
|}
|""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AISP") :: Nil
)
@ -190,7 +190,7 @@ The TPP sends a request to the ASPSP for retrieving the list of the PSU payment
| }
| }
|}""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AISP") :: Nil
)
@ -282,7 +282,7 @@ The AISP requests the ASPSP on one of the PSU's accounts. It may specify some se
| }
| }
|}""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AISP") :: Nil
)
@ -358,7 +358,7 @@ The PSU specifies to the AISP which of his/her accounts will be accessible and w
"psuIdentity" : true
}"""),
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AISP") :: apiTagMockedData :: Nil
)
@ -400,7 +400,7 @@ The AISP asks for the identity of the PSU. The ASPSP answers with the identity,
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AISP") :: apiTagMockedData :: Nil
)
@ -442,7 +442,7 @@ The AISP asks for the trusted beneficiaries list. The ASPSP answers with a list
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("AISP") :: apiTagMockedData :: Nil
)

View File

@ -62,7 +62,7 @@ The CBPII requests the ASPSP for a payment coverage check against either a bank
}
}"""),
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("CBPII") :: apiTagMockedData :: Nil
)

View File

@ -66,7 +66,7 @@ In REDIRECT and DECOUPLED approach, this confirmation is not a prerequisite to t
"psuAuthenticationFactor" : "JJKJKJ788GKJKJBK"
}"""),
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PISP") :: apiTagMockedData :: Nil
)
@ -216,7 +216,7 @@ Since the modification request needs a PSU authentication before committing, the
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PISP") :: apiTagMockedData :: Nil
)
@ -281,7 +281,7 @@ The status information must be available during at least 30 calendar days after
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PISP") :: apiTagMockedData :: Nil
)
@ -523,7 +523,7 @@ When the chosen authentication approach within the ASPSP answers is set to "EMBE
}
}"""),
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("PISP") :: apiTagMockedData :: Nil
)

View File

@ -4,7 +4,7 @@ import code.api.APIFailureNewStyle
import code.api.ResourceDocs1_4_0.SwaggerDefinitionsJSON
import code.api.util.APIUtil._
import code.api.util.ApiTag._
import code.api.util.ErrorMessages.{InvalidConnectorResponseForGetTransactionRequests210, UnknownError, UserNotLoggedIn, _}
import code.api.util.ErrorMessages.{InvalidConnectorResponseForGetTransactionRequests210, UnknownError, AuthenticatedUserIsRequired, _}
import code.api.util.newstyle.ViewNewStyle
import code.api.util.{ErrorMessages, NewStyle}
import code.bankconnectors.Connector
@ -43,7 +43,7 @@ object APIMethods_UKOpenBanking_200 extends RestHelper{
|""",
EmptyBody,
SwaggerDefinitionsJSON.accountsJsonUKOpenBanking_v200,
List(ErrorMessages.UserNotLoggedIn,ErrorMessages.UnknownError),
List(ErrorMessages.AuthenticatedUserIsRequired,ErrorMessages.UnknownError),
List(apiTagUKOpenBanking, apiTagAccount, apiTagPrivateData))
apiRelations += ApiRelation(getAccountList, getAccountList, "self")
@ -77,7 +77,7 @@ object APIMethods_UKOpenBanking_200 extends RestHelper{
|""",
EmptyBody,
SwaggerDefinitionsJSON.transactionsJsonUKV200,
List(UserNotLoggedIn,UnknownError),
List(AuthenticatedUserIsRequired,UnknownError),
List(apiTagUKOpenBanking, apiTagTransaction, apiTagPrivateData, apiTagPsd2))
lazy val getAccountTransactions : OBPEndpoint = {
@ -127,7 +127,7 @@ object APIMethods_UKOpenBanking_200 extends RestHelper{
|""",
EmptyBody,
SwaggerDefinitionsJSON.accountsJsonUKOpenBanking_v200,
List(ErrorMessages.UserNotLoggedIn,ErrorMessages.UnknownError),
List(ErrorMessages.AuthenticatedUserIsRequired,ErrorMessages.UnknownError),
List(apiTagUKOpenBanking, apiTagAccount, apiTagPrivateData))
apiRelations += ApiRelation(getAccount, getAccount, "self")
@ -165,7 +165,7 @@ object APIMethods_UKOpenBanking_200 extends RestHelper{
|""",
EmptyBody,
SwaggerDefinitionsJSON.accountBalancesUKV200,
List(ErrorMessages.UserNotLoggedIn,ErrorMessages.UnknownError),
List(ErrorMessages.AuthenticatedUserIsRequired,ErrorMessages.UnknownError),
List(apiTagUKOpenBanking, apiTagAccount, apiTagPrivateData))
lazy val getAccountBalances : OBPEndpoint = {
@ -210,7 +210,7 @@ object APIMethods_UKOpenBanking_200 extends RestHelper{
|""",
EmptyBody,
SwaggerDefinitionsJSON.accountBalancesUKV200,
List(ErrorMessages.UserNotLoggedIn,ErrorMessages.UnknownError),
List(ErrorMessages.AuthenticatedUserIsRequired,ErrorMessages.UnknownError),
List(apiTagUKOpenBanking, apiTagAccount, apiTagPrivateData))
lazy val getBalances : OBPEndpoint = {

View File

@ -79,7 +79,7 @@ object APIMethods_AccountAccessApi extends RestHelper {
"LastAvailableDateTime": "2020-10-20T08:40:47.375Z"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Access") :: Nil
)
@ -149,7 +149,7 @@ object APIMethods_AccountAccessApi extends RestHelper {
|""".stripMargin,
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Access") :: Nil
)
@ -157,7 +157,7 @@ object APIMethods_AccountAccessApi extends RestHelper {
case "account-access-consents" :: consentId :: Nil JsonDelete _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
_ <- passesPsd2Aisp(callContext)
consent <- Future(Consents.consentProvider.vend.getConsentByConsentId(consentId)) map {
unboxFullOrFail(_, callContext, ConsentNotFound)
@ -206,7 +206,7 @@ object APIMethods_AccountAccessApi extends RestHelper {
"LastAvailableDateTime": "2020-10-20T10:28:39.801Z"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Access") :: Nil
)
@ -214,7 +214,7 @@ object APIMethods_AccountAccessApi extends RestHelper {
case "account-access-consents" :: consentId :: Nil JsonGet _ => {
cc =>
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
consent <- Future(Consents.consentProvider.vend.getConsentByConsentId(consentId)) map {
unboxFullOrFail(_, callContext, s"$ConsentNotFound ($consentId)")
}

View File

@ -100,7 +100,7 @@ object APIMethods_AccountsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Accounts") :: Nil
)
@ -110,7 +110,7 @@ object APIMethods_AccountsApi extends RestHelper {
val detailViewId = ViewId(Constant.SYSTEM_READ_ACCOUNTS_DETAIL_VIEW_ID)
val basicViewId = ViewId(Constant.SYSTEM_READ_ACCOUNTS_BASIC_VIEW_ID)
for {
(Full(u), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(u), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
_ <- NewStyle.function.checkUKConsent(u, callContext)
_ <- passesPsd2Aisp(callContext)
availablePrivateAccounts <- Views.views.vend.getPrivateBankAccountsFuture(u)
@ -207,7 +207,7 @@ object APIMethods_AccountsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Accounts") :: Nil
)

View File

@ -103,7 +103,7 @@ object APIMethods_BalancesApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Balances") :: Nil
)
@ -112,7 +112,7 @@ object APIMethods_BalancesApi extends RestHelper {
cc =>
val viewId = ViewId(Constant.SYSTEM_READ_BALANCES_VIEW_ID)
for {
(Full(user), callContext) <- authenticatedAccess(cc, UserNotLoggedIn)
(Full(user), callContext) <- authenticatedAccess(cc, AuthenticatedUserIsRequired)
_ <- NewStyle.function.checkUKConsent(user, callContext)
_ <- passesPsd2Aisp(callContext)
(account, callContext) <- NewStyle.function.getBankAccountByAccountId(accountId, callContext)
@ -197,7 +197,7 @@ object APIMethods_BalancesApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Balances") :: Nil
)

View File

@ -108,7 +108,7 @@ object APIMethods_BeneficiariesApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Beneficiaries") :: apiTagMockedData :: Nil
)
@ -272,7 +272,7 @@ object APIMethods_BeneficiariesApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Beneficiaries") :: apiTagMockedData :: Nil
)

View File

@ -76,7 +76,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)
@ -176,7 +176,7 @@ object APIMethods_DirectDebitsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Direct Debits") :: apiTagMockedData :: Nil
)

View File

@ -133,7 +133,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)
@ -330,7 +330,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)
@ -527,7 +527,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)
@ -663,7 +663,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)
@ -788,7 +788,7 @@ object APIMethods_DomesticPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Payments") :: apiTagMockedData :: Nil
)

View File

@ -134,7 +134,7 @@ object APIMethods_DomesticScheduledPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -334,7 +334,7 @@ object APIMethods_DomesticScheduledPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -534,7 +534,7 @@ object APIMethods_DomesticScheduledPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -734,7 +734,7 @@ object APIMethods_DomesticScheduledPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Scheduled Payments") :: apiTagMockedData :: Nil
)

View File

@ -125,7 +125,7 @@ object APIMethods_DomesticStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Standing Orders") :: apiTagMockedData :: Nil
)
@ -307,7 +307,7 @@ object APIMethods_DomesticStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Standing Orders") :: apiTagMockedData :: Nil
)
@ -489,7 +489,7 @@ object APIMethods_DomesticStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Standing Orders") :: apiTagMockedData :: Nil
)
@ -671,7 +671,7 @@ object APIMethods_DomesticStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Domestic Standing Orders") :: apiTagMockedData :: Nil
)

View File

@ -102,7 +102,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -186,7 +186,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -273,7 +273,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -418,7 +418,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -502,7 +502,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -589,7 +589,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)
@ -676,7 +676,7 @@ object APIMethods_FilePaymentsApi extends RestHelper {
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("File Payments") :: apiTagMockedData :: Nil
)

View File

@ -66,7 +66,7 @@ object APIMethods_FundsConfirmationsApi extends RestHelper {
"ConsentId" : "ConsentId"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Funds Confirmations") :: apiTagMockedData :: Nil
)
@ -140,7 +140,7 @@ object APIMethods_FundsConfirmationsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Funds Confirmations") :: apiTagMockedData :: Nil
)
@ -189,7 +189,7 @@ object APIMethods_FundsConfirmationsApi extends RestHelper {
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Funds Confirmations") :: apiTagMockedData :: Nil
)
@ -240,7 +240,7 @@ object APIMethods_FundsConfirmationsApi extends RestHelper {
"ConsentId" : "ConsentId"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Funds Confirmations") :: apiTagMockedData :: Nil
)

View File

@ -169,7 +169,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)
@ -438,7 +438,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)
@ -707,7 +707,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)
@ -879,7 +879,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)
@ -1040,7 +1040,7 @@ object APIMethods_InternationalPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Payments") :: apiTagMockedData :: Nil
)

View File

@ -171,7 +171,7 @@ object APIMethods_InternationalScheduledPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -443,7 +443,7 @@ object APIMethods_InternationalScheduledPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -715,7 +715,7 @@ object APIMethods_InternationalScheduledPaymentsApi extends RestHelper {
"ExpectedSettlementDateTime" : "2000-01-23T04:56:07.000+00:00"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -889,7 +889,7 @@ object APIMethods_InternationalScheduledPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -1051,7 +1051,7 @@ object APIMethods_InternationalScheduledPaymentsApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Scheduled Payments") :: apiTagMockedData :: Nil
)

View File

@ -152,7 +152,7 @@ object APIMethods_InternationalStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Standing Orders") :: apiTagMockedData :: Nil
)
@ -388,7 +388,7 @@ object APIMethods_InternationalStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Standing Orders") :: apiTagMockedData :: Nil
)
@ -624,7 +624,7 @@ object APIMethods_InternationalStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Standing Orders") :: apiTagMockedData :: Nil
)
@ -860,7 +860,7 @@ object APIMethods_InternationalStandingOrdersApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("International Standing Orders") :: apiTagMockedData :: Nil
)

View File

@ -92,7 +92,7 @@ object APIMethods_OffersApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Offers") :: apiTagMockedData :: Nil
)
@ -224,7 +224,7 @@ object APIMethods_OffersApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Offers") :: apiTagMockedData :: Nil
)

View File

@ -81,7 +81,7 @@ object APIMethods_PartysApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Partys") :: apiTagMockedData :: Nil
)
@ -191,7 +191,7 @@ object APIMethods_PartysApi extends RestHelper {
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Partys") :: apiTagMockedData :: Nil
)

View File

@ -38,7 +38,7 @@ object APIMethods_ProductsApi extends RestHelper {
s"""${mockedDataText(true)}""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Products") :: apiTagMockedData :: Nil
)
@ -64,7 +64,7 @@ object APIMethods_ProductsApi extends RestHelper {
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Products") :: apiTagMockedData :: Nil
)

View File

@ -94,7 +94,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)
@ -230,7 +230,7 @@ object APIMethods_ScheduledPaymentsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Scheduled Payments") :: apiTagMockedData :: Nil
)

View File

@ -118,7 +118,7 @@ object APIMethods_StandingOrdersApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Standing Orders") :: apiTagMockedData :: Nil
)
@ -302,7 +302,7 @@ object APIMethods_StandingOrdersApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Standing Orders") :: apiTagMockedData :: Nil
)

View File

@ -233,7 +233,7 @@ object APIMethods_StatementsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -641,7 +641,7 @@ object APIMethods_StatementsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -858,7 +858,7 @@ object APIMethods_StatementsApi extends RestHelper {
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)
@ -1107,7 +1107,7 @@ object APIMethods_StatementsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") ::ApiTag("Transactions") :: apiTagMockedData :: Nil
)
@ -1547,7 +1547,7 @@ object APIMethods_StatementsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") :: apiTagMockedData :: Nil
)

View File

@ -270,7 +270,7 @@ object APIMethods_TransactionsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Statements") ::ApiTag("Transactions") :: apiTagMockedData :: Nil
)
@ -743,7 +743,7 @@ object APIMethods_TransactionsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Transactions") :: Nil
)
@ -1010,7 +1010,7 @@ object APIMethods_TransactionsApi extends RestHelper {
} ]
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Transactions") :: Nil
)

View File

@ -140,7 +140,7 @@ recurringIndicator:
consentStatus = "received",
_links = ConsentLinksV13(Some(Href("/v1.3/consents/1234-wertiq-983/authorisations")))
),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -253,7 +253,7 @@ recurringIndicator:
The TPP can delete an account information consent object if needed.""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -336,7 +336,7 @@ of the PSU at this ASPSP.
| }
| ]
|}""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -414,7 +414,7 @@ The account-id is constant at least throughout the lifecycle of a given consent.
}]
}
"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -472,7 +472,7 @@ respectively the OAuth2 access token.
}
]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagMockedData :: Nil
)
@ -542,7 +542,7 @@ This account-id then can be retrieved by the
"referenceDate":"2018-03-08"
}]
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: Nil
)
@ -631,7 +631,7 @@ Reads account data from a given card account addressed by "account-id".
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM ::Nil
)
@ -677,7 +677,7 @@ This function returns an array of hyperlinks to all generated authorisation sub-
json.parse("""{
"authorisationIds" : "faa3657e-13f0-4feb-a6c3-34bf21a9ae8e"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -735,7 +735,7 @@ where the consent was directly managed between ASPSP and PSU e.g. in a re-direct
"lastActionDate": "2019-06-30",
"consentStatus": "received"
}"""),
List(UserNotLoggedIn, ConsentNotFound, UnknownError),
List(AuthenticatedUserIsRequired, ConsentNotFound, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -774,7 +774,7 @@ This method returns the SCA status of a consent initiation's authorisation sub-r
json.parse("""{
"scaStatus" : "started"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -809,7 +809,7 @@ This method returns the SCA status of a consent initiation's authorisation sub-r
json.parse("""{
"consentStatus": "received"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -867,7 +867,7 @@ of the "Read Transaction List" call within the _links subfield.
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: Nil
)
@ -959,7 +959,7 @@ The ASPSP might add balance information, if transaction lists without balances a
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1028,7 +1028,7 @@ Give detailed information about the addressed account together with balance info
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1102,7 +1102,7 @@ respectively the OAuth2 access token.
| }
| }
|}""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: Nil
)
@ -1185,7 +1185,7 @@ using the extended forms as indicated above.
"scaStatus": {"href":"/v1.3/consents/qwer3456tzui7890/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1240,7 +1240,7 @@ using the extended forms as indicated above.
"scaStatus": {"href":"/v1.3/consents/qwer3456tzui7890/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1282,7 +1282,7 @@ using the extended forms as indicated above.
"scaStatus": {"href":"/v1.3/consents/qwer3456tzui7890/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1348,7 +1348,7 @@ Maybe in a later version the access path will change.
scaStatus = "received",
_links = Some(LinksAll(scaStatus = Some(HrefType(Some(s"/v1.3/consents/1234-wertiq-983/authorisations")))))
),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1417,7 +1417,7 @@ Maybe in a later version the access path will change.
| "authoriseTransaction": {"href": "/psd2/v1/payments/1234-wertiq-983/authorisations/123auth456"}
| }
| }""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1462,7 +1462,7 @@ Maybe in a later version the access path will change.
| "authoriseTransaction": {"href": "/psd2/v1/payments/1234-wertiq-983/authorisations/123auth456"}
| }
| }""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1505,7 +1505,7 @@ Maybe in a later version the access path will change.
| "status": {"href":"/v1/payments/sepa-credit-transfers/qwer3456tzui7890/status"}
| }
| }""".stripMargin),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Account Information Service (AIS)") :: apiTagBerlinGroupM :: Nil
)

View File

@ -58,7 +58,7 @@ in the header. This field is contained but commented out in this specification.
"""{
"fundsAvailable" : true
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Confirmation of Funds Service (PIIS)") :: apiTagBerlinGroupM :: Nil
)

View File

@ -100,7 +100,7 @@ or * access method is generally applicable, but further authorisation processes
startAuthorisation = LinkHrefJson(s"/v1.3/payments/sepa-credit-transfers/cancellation-authorisations/1234-wertiq-983/status")
)
),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: Nil
)
@ -176,7 +176,7 @@ This method returns the SCA status of a payment initiation's authorisation sub-r
json.parse("""{
"scaStatus" : "psuAuthenticated"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -223,7 +223,7 @@ Returns the content of a payment object""",
},
"creditorName":"70charname"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM ::Nil
)
@ -282,7 +282,7 @@ This function returns an array of hyperlinks to all generated authorisation sub-
}
}
]"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -320,7 +320,7 @@ Retrieve a list of all created cancellation authorisation sub-resources.
json.parse("""{
"cancellationIds" : ["faa3657e-13f0-4feb-a6c3-34bf21a9ae8e]"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -357,7 +357,7 @@ This method returns the SCA status of a payment initiation's authorisation sub-r
json.parse("""{
"scaStatus" : "psuAuthenticated"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -396,7 +396,7 @@ Check the transaction status of a payment initiation.""",
json.parse(s"""{
"transactionStatus": "${TransactionStatus.ACCP.code}"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -607,7 +607,7 @@ Check the transaction status of a payment initiation.""",
"scaStatus": {"href": "/v1.3/payments/1234-wertiq-983/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -656,7 +656,7 @@ Check the transaction status of a payment initiation.""",
"scaStatus": {"href": "/v1.3/periodic-payments/1234-wertiq-983/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -718,7 +718,7 @@ Check the transaction status of a payment initiation.""",
"scaStatus": {"href": "/v1.3/bulk-payments/1234-wertiq-983/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -789,7 +789,7 @@ This applies in the following scenarios:
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -833,7 +833,7 @@ This applies in the following scenarios:
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -877,7 +877,7 @@ This applies in the following scenarios:
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -971,7 +971,7 @@ This applies in the following scenarios:
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1039,7 +1039,7 @@ This applies in the following scenarios:
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1083,7 +1083,7 @@ This applies in the following scenarios:
}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1168,7 +1168,7 @@ There are the following request types on this access path:
"scaStatus":"/v1.3/payments/sepa-credit-transfers/PAYMENT_ID/4f4a8b7f-9968-4183-92ab-ca512b396bfc"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1247,7 +1247,7 @@ There are the following request types on this access path:
"authoriseTransaction": {"href": "/psd2/v1.3/payments/1234-wertiq-983/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1289,7 +1289,7 @@ There are the following request types on this access path:
"authoriseTransaction": {"href": "/psd2/v1.3/payments/1234-wertiq-983/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1331,7 +1331,7 @@ There are the following request types on this access path:
"status": {"href":"/v1.3/payments/sepa-credit-transfers/qwer3456tzui7890/status"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1415,7 +1415,7 @@ There are the following request types on this access path:
"scaStatus": {"href":"/v1.3/payments/sepa-credit-transfers/88695566-6642-46d5-9985-0d824624f507"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1490,7 +1490,7 @@ There are the following request types on this access path:
"scaStatus": {"href":"/v1.3/payments/sepa-credit-transfers/88695566-6642-46d5-9985-0d824624f507"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1534,7 +1534,7 @@ There are the following request types on this access path:
"authoriseTransaction": {"href": "/psd2/v1.3/payments/1234-wertiq-983/authorisations/123auth456"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)
@ -1578,7 +1578,7 @@ There are the following request types on this access path:
"status": {"href":"/v1.3/payments/sepa-credit-transfers/qwer3456tzui7890/status"}
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
ApiTag("Payment Initiation Service (PIS)") :: apiTagBerlinGroupM :: Nil
)

View File

@ -97,7 +97,7 @@ The resource identifications of these transactions are contained in the payload
"transactionStatus" : "ACCP",
"psuMessage" : { }
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)
@ -146,7 +146,7 @@ Nevertheless, single transactions might be cancelled on an individual basis on t
""",
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)
@ -182,7 +182,7 @@ Returns the content of an signing basket object.""",
"payments" : "",
"consents" : ""
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)
@ -219,7 +219,7 @@ This function returns an array of hyperlinks to all generated authorisation sub-
json.parse("""{
"authorisationIds" : ""
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)
@ -250,7 +250,7 @@ This method returns the SCA status of a signing basket's authorisation sub-resou
json.parse("""{
"scaStatus" : "psuAuthenticated"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)
@ -286,7 +286,7 @@ Returns the status of a signing basket object.
json.parse("""{
"transactionStatus" : "RCVD"
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)
@ -372,7 +372,7 @@ This applies in the following scenarios:
"chosenScaMethod" : "",
"psuMessage" : { }
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)
@ -461,7 +461,7 @@ There are the following request types on this access path:
"scaStatus":"/v1.3/payments/sepa-credit-transfers/PAYMENT_ID/4f4a8b7f-9968-4183-92ab-ca512b396bfc"
}
}"""),
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagSigningBaskets :: Nil
)

View File

@ -6,7 +6,7 @@ import code.DynamicData.{DynamicDataProvider, DynamicDataT}
import code.DynamicEndpoint.{DynamicEndpointProvider, DynamicEndpointT}
import code.api.util.APIUtil.{BigDecimalBody, BigIntBody, BooleanBody, DoubleBody, EmptyBody, FloatBody, IntBody, JArrayBody, LongBody, PrimaryDataBody, ResourceDoc, StringBody}
import code.api.util.ApiTag._
import code.api.util.ErrorMessages.{DynamicDataNotFound, InvalidUrlParameters, UnknownError, UserHasMissingRoles, UserNotLoggedIn}
import code.api.util.ErrorMessages.{DynamicDataNotFound, InvalidUrlParameters, UnknownError, UserHasMissingRoles, AuthenticatedUserIsRequired}
import code.api.util.{APIUtil, ApiRole, ApiTag, CommonUtil, CustomJsonFormats, NewStyle}
import com.openbankproject.commons.util.{ApiShortVersions, ApiStandards, ApiVersion}
import com.openbankproject.commons.util.Functions.Memo
@ -324,7 +324,7 @@ object DynamicEndpointHelper extends RestHelper {
val exampleRequestBody: Product = getRequestExample(openAPI, op.getRequestBody)
val (successCode, successResponseBody: Product) = getResponseExample(openAPI, op.getResponses)
val errorResponseBodies: List[String] = List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
)

View File

@ -3,7 +3,7 @@ package code.api.dynamic.entity.helper
import code.api.util.APIUtil.{EmptyBody, ResourceDoc, userAuthenticationMessage}
import code.api.util.ApiRole.getOrCreateDynamicApiRole
import code.api.util.ApiTag._
import code.api.util.ErrorMessages.{InvalidJsonFormat, UnknownError, UserHasMissingRoles, UserNotLoggedIn}
import code.api.util.ErrorMessages.{InvalidJsonFormat, UnknownError, UserHasMissingRoles, AuthenticatedUserIsRequired}
import code.api.util._
import com.openbankproject.commons.model.enums.{DynamicEntityFieldType, DynamicEntityOperation}
import com.openbankproject.commons.util.ApiVersion
@ -183,7 +183,7 @@ object DynamicEntityHelper {
EmptyBody,
dynamicEntityInfo.getExampleList,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -211,7 +211,7 @@ object DynamicEntityHelper {
EmptyBody,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -240,7 +240,7 @@ object DynamicEntityHelper {
dynamicEntityInfo.getSingleExampleWithoutId,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -270,7 +270,7 @@ object DynamicEntityHelper {
dynamicEntityInfo.getSingleExampleWithoutId,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -297,7 +297,7 @@ object DynamicEntityHelper {
dynamicEntityInfo.getSingleExampleWithoutId,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -331,7 +331,7 @@ object DynamicEntityHelper {
EmptyBody,
dynamicEntityInfo.getExampleList,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UnknownError
),
List(apiTag, apiTagDynamicEntity, apiTagDynamic),
@ -357,7 +357,7 @@ object DynamicEntityHelper {
EmptyBody,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UnknownError
),
List(apiTag, apiTagDynamicEntity, apiTagDynamic),
@ -384,7 +384,7 @@ object DynamicEntityHelper {
dynamicEntityInfo.getSingleExampleWithoutId,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -412,7 +412,7 @@ object DynamicEntityHelper {
dynamicEntityInfo.getSingleExampleWithoutId,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -438,7 +438,7 @@ object DynamicEntityHelper {
dynamicEntityInfo.getSingleExampleWithoutId,
dynamicEntityInfo.getSingleExample,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UnknownError
),
List(apiTag, apiTagDynamicEntity, apiTagDynamic),

View File

@ -729,7 +729,7 @@ object APIUtil extends MdcLoggable with CustomJsonFormats{
message.contains(extractErrorMessageCode(ConsumerHasMissingRoles))
}
def check401(message: String): Boolean = {
message.contains(extractErrorMessageCode(UserNotLoggedIn))
message.contains(extractErrorMessageCode(AuthenticatedUserIsRequired))
}
def check408(message: String): Boolean = {
message.contains(extractErrorMessageCode(requestTimeout))
@ -1659,21 +1659,21 @@ object APIUtil extends MdcLoggable with CustomJsonFormats{
if (rolesIsEmpty) {
errorResponseBodies ?-= UserHasMissingRoles
} else {
errorResponseBodies ?+= UserNotLoggedIn
errorResponseBodies ?+= AuthenticatedUserIsRequired
errorResponseBodies ?+= UserHasMissingRoles
}
// if authentication is required, add UserNotLoggedIn to errorResponseBodies
// if authentication is required, add AuthenticatedUserIsRequired to errorResponseBodies
if (description.contains(authenticationIsRequired)) {
errorResponseBodies ?+= UserNotLoggedIn
errorResponseBodies ?+= AuthenticatedUserIsRequired
} else if (description.contains(authenticationIsOptional) && rolesIsEmpty) {
errorResponseBodies ?-= UserNotLoggedIn
} else if (errorResponseBodies.contains(UserNotLoggedIn)) {
errorResponseBodies ?-= AuthenticatedUserIsRequired
} else if (errorResponseBodies.contains(AuthenticatedUserIsRequired)) {
description +=
s"""
|
|$authenticationIsRequired
|"""
} else if (!errorResponseBodies.contains(UserNotLoggedIn)) {
} else if (!errorResponseBodies.contains(AuthenticatedUserIsRequired)) {
description +=
s"""
|
@ -1763,7 +1763,7 @@ object APIUtil extends MdcLoggable with CustomJsonFormats{
private val requestUrlPartPath: Array[String] = StringUtils.split(requestUrl, '/')
private val isNeedCheckAuth = errorResponseBodies.contains($UserNotLoggedIn)
private val isNeedCheckAuth = errorResponseBodies.contains($AuthenticatedUserIsRequired)
private val isNeedCheckRoles = _autoValidateRoles && rolesForCheck.nonEmpty
private val isNeedCheckBank = errorResponseBodies.contains($BankNotFound) && requestUrlPartPath.contains("BANK_ID")
private val isNeedCheckAccount = errorResponseBodies.contains($BankAccountNotFound) &&
@ -1780,7 +1780,7 @@ object APIUtil extends MdcLoggable with CustomJsonFormats{
}.toMap
/**
* According errorResponseBodies whether contains UserNotLoggedIn and UserHasMissingRoles do validation.
* According errorResponseBodies whether contains AuthenticatedUserIsRequired and UserHasMissingRoles do validation.
* So can avoid duplicate code in endpoint body for expression do check.
* Note: maybe this will be misused, So currently just comment out.
*/
@ -3319,7 +3319,7 @@ object APIUtil extends MdcLoggable with CustomJsonFormats{
* This function is used to factor out common code at endpoints regarding Authorized access
* @param emptyUserErrorMsg is a message which will be provided as a response in case that Box[User] = Empty
*/
def authenticatedAccess(cc: CallContext, emptyUserErrorMsg: String = UserNotLoggedIn): OBPReturnType[Box[User]] = {
def authenticatedAccess(cc: CallContext, emptyUserErrorMsg: String = AuthenticatedUserIsRequired): OBPReturnType[Box[User]] = {
anonymousAccess(cc) map{
x => (
fullBoxOrException(x._1 ~> APIFailureNewStyle(emptyUserErrorMsg, 401, Some(cc.toLight))),

View File

@ -6,11 +6,11 @@ import code.api.JSONFactoryGateway.PayloadOfJwtJSON
import code.api.oauth1a.OauthParams._
import code.api.util.APIUtil._
import code.api.util.AuthenticationType.{Anonymous, DirectLogin, GatewayLogin, DAuth, OAuth2_OIDC, OAuth2_OIDC_FAPI}
import code.api.util.ErrorMessages.{BankAccountNotFound, UserNotLoggedIn}
import code.api.util.ErrorMessages.{BankAccountNotFound, AuthenticatedUserIsRequired}
import code.api.util.RateLimitingJson.CallLimit
import code.context.UserAuthContextProvider
import code.customer.CustomerX
import code.model.{Consumer, _}
import code.model._
import code.util.Helper.MdcLoggable
import code.util.SecureLogging
import code.views.Views
@ -147,9 +147,9 @@ case class CallContext(
}
// for endpoint body convenient get userId
def userId: String = user.map(_.userId).openOrThrowException(UserNotLoggedIn)
def userPrimaryKey: UserPrimaryKey = user.map(_.userPrimaryKey).openOrThrowException(UserNotLoggedIn)
def loggedInUser: User = user.openOrThrowException(UserNotLoggedIn)
def userId: String = user.map(_.userId).openOrThrowException(AuthenticatedUserIsRequired)
def userPrimaryKey: UserPrimaryKey = user.map(_.userPrimaryKey).openOrThrowException(AuthenticatedUserIsRequired)
def loggedInUser: User = user.openOrThrowException(AuthenticatedUserIsRequired)
// for endpoint body convenient get cc.callContext
def callContext: Option[CallContext] = Option(this)

View File

@ -140,7 +140,7 @@ object ErrorMessages {
// Authentication / Authorisation / User messages (OBP-20XXX)
val UserNotLoggedIn = "OBP-20001: User not logged in. Authentication is required!"
val AuthenticatedUserIsRequired = "OBP-20001: User not logged in. Authentication is required!"
val DirectLoginMissingParameters = "OBP-20002: These DirectLogin parameters are missing:"
val DirectLoginInvalidToken = "OBP-20003: This DirectLogin token is invalid or expired:"
val InvalidLoginCredentials = "OBP-20004: Invalid login credentials. Check username/password."
@ -834,7 +834,7 @@ object ErrorMessages {
// NotImplemented -> 501, // 400 or 501
TooManyRequests -> 429,
ResourceDoesNotExist -> 404,
UserNotLoggedIn -> 401,
AuthenticatedUserIsRequired -> 401,
DirectLoginInvalidToken -> 401,
InvalidLoginCredentials -> 401,
UserNotFoundById -> 404,
@ -889,7 +889,7 @@ object ErrorMessages {
/**
* validate method: APIUtil.authorizedAccess
*/
def $UserNotLoggedIn = UserNotLoggedIn
def $AuthenticatedUserIsRequired = AuthenticatedUserIsRequired
/**
* validate method: NewStyle.function.getBank

View File

@ -4,7 +4,7 @@ package code.api.util
import code.api.Constant
import code.api.Constant._
import code.api.util.APIUtil.{DateWithMs, DateWithMsExampleString, formatDate, oneYearAgoDate, parseDate}
import code.api.util.ErrorMessages.{InvalidJsonFormat, UnknownError, UserHasMissingRoles, UserNotLoggedIn}
import code.api.util.ErrorMessages.{InvalidJsonFormat, UnknownError, UserHasMissingRoles, AuthenticatedUserIsRequired}
import code.api.util.Glossary.{glossaryItems, makeGlossaryItem}
import code.apicollection.ApiCollection
import code.dynamicEntity._
@ -570,7 +570,7 @@ object ExampleValue {
"""{"my_user_id": "some_id_value", "name": "Jhon", "age": 12, "hobby": ["coding"],"_optional_fields_": ["hobby"]}""".stripMargin, "the json string of the success response body.")
glossaryItems += makeGlossaryItem("DynamicResourceDoc.successResponseBody", successResponseBodyExample)
lazy val errorResponseBodiesExample = ConnectorField(s"$UnknownError,$UserNotLoggedIn,$UserHasMissingRoles,$InvalidJsonFormat", "The possible error messages of the endpoint. ")
lazy val errorResponseBodiesExample = ConnectorField(s"$UnknownError,$AuthenticatedUserIsRequired,$UserHasMissingRoles,$InvalidJsonFormat", "The possible error messages of the endpoint. ")
glossaryItems += makeGlossaryItem("DynamicResourceDoc.errorResponseBodies", errorResponseBodiesExample)

View File

@ -191,7 +191,7 @@ trait APIMethods121 {
|* Website""",
EmptyBody,
bankJSON,
List(UserNotLoggedIn, UnknownError, BankNotFound),
List(AuthenticatedUserIsRequired, UnknownError, BankNotFound),
apiTagBank :: apiTagPsd2 :: apiTagOldStyle :: Nil)
@ -223,7 +223,7 @@ trait APIMethods121 {
|""".stripMargin,
EmptyBody,
accountJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagAccount :: apiTagPsd2 :: apiTagOldStyle :: Nil)
//TODO double check with `lazy val privateAccountsAllBanks :`, they are the same now.
@ -232,7 +232,7 @@ trait APIMethods121 {
case "accounts" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
(privateViewsUserCanAccess, privateAccountAccess) <- Full(Views.views.vend.privateViewsUserCanAccess(u))
availablePrivateAccounts <- Full(BankAccountX.privateAccounts(privateAccountAccess))
} yield {
@ -256,7 +256,7 @@ trait APIMethods121 {
|""".stripMargin,
EmptyBody,
accountJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
apiTagAccount :: apiTagPsd2 :: apiTagOldStyle :: Nil)
lazy val privateAccountsAllBanks : OBPEndpoint = {
@ -264,7 +264,7 @@ trait APIMethods121 {
case "accounts" :: "private" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
(privateViewsUserCanAccess, privateAccountAccess) <- Full(Views.views.vend.privateViewsUserCanAccess(u))
privateAccounts <- Full(BankAccountX.privateAccounts(privateAccountAccess))
} yield {
@ -320,7 +320,7 @@ trait APIMethods121 {
""",
EmptyBody,
accountJSON,
List(UserNotLoggedIn, UnknownError, BankNotFound),
List(AuthenticatedUserIsRequired, UnknownError, BankNotFound),
apiTagAccount :: apiTagOldStyle :: Nil)
lazy val getPrivateAccountsAtOneBank : OBPEndpoint = {
@ -328,7 +328,7 @@ trait APIMethods121 {
case "banks" :: BankId(bankId) :: "accounts" :: Nil JsonGet req => {
cc =>
for{
u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
(bank, callContext) <- BankX(bankId, Some(cc)) ?~! BankNotFound
} yield {
val (privateViewsUserCanAccessAtOneBank, privateAccountAccess) = Views.views.vend.privateViewsUserCanAccessAtBank(u, bankId)
@ -353,7 +353,7 @@ trait APIMethods121 {
|""".stripMargin,
EmptyBody,
accountJSON,
List(UserNotLoggedIn, UnknownError, BankNotFound),
List(AuthenticatedUserIsRequired, UnknownError, BankNotFound),
List(apiTagAccount, apiTagPsd2, apiTagOldStyle))
lazy val privateAccountsAtOneBank : OBPEndpoint = {
@ -361,7 +361,7 @@ trait APIMethods121 {
case "banks" :: BankId(bankId) :: "accounts" :: "private" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
(bank, callContext) <- BankX(bankId, Some(cc)) ?~! BankNotFound
} yield {
val (privateViewsUserCanAccessAtOneBank, privateAccountAccess) = Views.views.vend.privateViewsUserCanAccessAtBank(u, bankId)
@ -385,7 +385,7 @@ trait APIMethods121 {
|""".stripMargin,
EmptyBody,
accountJSON,
List(UserNotLoggedIn, UnknownError, BankNotFound),
List(AuthenticatedUserIsRequired, UnknownError, BankNotFound),
apiTagAccountPublic :: apiTagAccount :: apiTagPublicData :: apiTagOldStyle :: Nil)
lazy val publicAccountsAtOneBank : OBPEndpoint = {
@ -428,7 +428,7 @@ trait APIMethods121 {
|""".stripMargin,
EmptyBody,
moderatedAccountJSON,
List(UserNotLoggedIn, UnknownError, BankAccountNotFound),
List(AuthenticatedUserIsRequired, UnknownError, BankAccountNotFound),
apiTagAccount :: apiTagOldStyle :: Nil)
lazy val accountById : OBPEndpoint = {
@ -436,7 +436,7 @@ trait APIMethods121 {
case "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: ViewId(viewId) :: "account" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
(account, callContext) <- BankAccountX(bankId, accountId, Some(cc)) ?~! BankAccountNotFound
availableviews <- Full(Views.views.vend.privateViewsUserCanAccessForAccount(u, BankIdAccountId(account.bankId, account.accountId)))
view <- APIUtil.checkViewAccessAndReturnView(viewId, BankIdAccountId(account.bankId, account.accountId), Some(u), callContext)
@ -464,7 +464,7 @@ trait APIMethods121 {
""".stripMargin,
updateAccountJSON,
successMessage,
List(InvalidJsonFormat, UserNotLoggedIn, UnknownError, BankAccountNotFound, "user does not have access to owner view on account"),
List(InvalidJsonFormat, AuthenticatedUserIsRequired, UnknownError, BankAccountNotFound, "user does not have access to owner view on account"),
List(apiTagAccount)
)
@ -529,7 +529,7 @@ trait APIMethods121 {
|${userAuthenticationMessage(true)} and the user needs to have access to the owner view.""",
EmptyBody,
viewsJSONV121,
List(UserNotLoggedIn, BankAccountNotFound, UnknownError, "user does not have owner access"),
List(AuthenticatedUserIsRequired, BankAccountNotFound, UnknownError, "user does not have owner access"),
List(apiTagView, apiTagAccount, apiTagOldStyle))
lazy val getViewsForBankAccount : OBPEndpoint = {
@ -537,7 +537,7 @@ trait APIMethods121 {
case "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: "views" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
bankAccount <- BankAccountX(bankId, accountId) ?~! BankAccountNotFound
permission <- Views.views.vend.permission(BankIdAccountId(bankAccount.bankId, bankAccount.accountId), u)
anyViewContainsCanSeeAvailableViewsForBankAccountPermission = permission.views.map(_.allowed_actions.exists(_ == CAN_SEE_AVAILABLE_VIEWS_FOR_BANK_ACCOUNT)).find(_.==(true)).getOrElse(false)
@ -576,7 +576,7 @@ trait APIMethods121 {
createViewJsonV121,
viewJSONV121,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
BankAccountNotFound,
UnknownError,
@ -590,7 +590,7 @@ trait APIMethods121 {
case "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: "views" :: Nil JsonPost json -> _ => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
createViewJsonV121 <- tryo{json.extract[CreateViewJsonV121]} ?~ InvalidJsonFormat
//customer views are started ith `_`,eg _life, _work, and System views startWith letter, eg: owner
_<- booleanToBox(isValidCustomViewName(createViewJsonV121.name), InvalidCustomViewFormat+s"Current view_name (${createViewJsonV121.name})")
@ -635,7 +635,7 @@ trait APIMethods121 {
viewJSONV121,
List(
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
ViewNotFound,
UnknownError,
@ -653,7 +653,7 @@ trait APIMethods121 {
for {
updateJsonV121 <- tryo{ json.extract[UpdateViewJsonV121] } ?~ InvalidJsonFormat
account <- BankAccountX(bankId, accountId) ?~! BankAccountNotFound
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
//customer views are started ith `_`,eg _life, _work, and System views startWith letter, eg: owner
_ <- booleanToBox(viewId.value.startsWith("_"), InvalidCustomViewFormat +s"Current view_id (${viewId.value})")
view <- Views.views.vend.customView(viewId, BankIdAccountId(bankId, accountId)) ?~! ViewNotFound
@ -691,7 +691,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError,
"user does not have owner access"
@ -740,7 +740,7 @@ trait APIMethods121 {
|${userAuthenticationMessage(true)} and the user needs to have access to the owner view.""",
EmptyBody,
permissionsJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagView, apiTagAccount, apiTagEntitlement, apiTagOldStyle)
)
@ -749,7 +749,7 @@ trait APIMethods121 {
case "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: "permissions" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
account <- BankAccountX(bankId, accountId) ?~! BankAccountNotFound
anyViewContainsCanSeeViewsWithPermissionsForAllUsersPermission = Views.views.vend.permission(BankIdAccountId(account.bankId, account.accountId), u)
.map(_.views.map(_.allowed_actions.exists(_ == CAN_SEE_VIEWS_WITH_PERMISSIONS_FOR_ALL_USERS))).getOrElse(Nil).find(_.==(true)).getOrElse(false)
@ -779,7 +779,7 @@ trait APIMethods121 {
EmptyBody,
viewsJSONV121,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError,
"user does not have access to owner view on account"
@ -793,7 +793,7 @@ trait APIMethods121 {
case "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: "permissions" :: provider :: providerId :: Nil JsonGet req => {
cc =>
for {
loggedInUser <- cc.user ?~ UserNotLoggedIn
loggedInUser <- cc.user ?~ AuthenticatedUserIsRequired
account <- BankAccountX(bankId, accountId) ?~! BankAccountNotFound
loggedInUserPermissionBox = Views.views.vend.permission(BankIdAccountId(bankId, accountId), loggedInUser)
anyViewContainsCanSeeViewsWithPermissionsForOneUserPermission = loggedInUserPermissionBox.map(_.views.map(_.allowed_actions.exists(_ == CAN_SEE_VIEWS_WITH_PERMISSIONS_FOR_ONE_USER)))
@ -828,7 +828,7 @@ trait APIMethods121 {
viewIdsJson,
viewsJSONV121,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError,
"wrong format JSON",
@ -877,7 +877,7 @@ trait APIMethods121 {
EmptyBody, // No Json body required
viewJSONV121,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError,
UserLacksPermissionCanGrantAccessToViewForTargetAccount,
@ -938,7 +938,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"could not save the privilege",
"user does not have access to owner view on account",
@ -976,7 +976,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError,
"user does not have access to owner view on account"
@ -1074,7 +1074,7 @@ trait APIMethods121 {
|Authentication via OAuth is required if the view is not public.""",
EmptyBody,
otherAccountMetadataJSON,
List(UserNotLoggedIn, UnknownError, "the view does not allow metadata access"),
List(AuthenticatedUserIsRequired, UnknownError, "the view does not allow metadata access"),
List(apiTagCounterpartyMetaData, apiTagCounterparty))
lazy val getOtherAccountMetadata : OBPEndpoint = {
@ -1212,7 +1212,7 @@ trait APIMethods121 {
List(
BankAccountNotFound,
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
"the view does not allow metadata access",
"the view does not allow updating the public alias",
"Alias cannot be updated",
@ -1311,7 +1311,7 @@ trait APIMethods121 {
EmptyBody,
aliasJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"the view does not allow metadata access",
"the view does not allow private alias access",
@ -1355,7 +1355,7 @@ trait APIMethods121 {
aliasJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -1407,7 +1407,7 @@ trait APIMethods121 {
aliasJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -1459,7 +1459,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"the view does not allow metadata access",
"the view does not allow deleting the private alias",
@ -1506,7 +1506,7 @@ trait APIMethods121 {
moreInfoJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
NoViewPermission,
@ -1556,7 +1556,7 @@ trait APIMethods121 {
moreInfoJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -1605,7 +1605,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"the view does not allow metadata access",
"the view does not allow deleting more info",
@ -1652,7 +1652,7 @@ trait APIMethods121 {
urlJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -1702,7 +1702,7 @@ trait APIMethods121 {
urlJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
NoViewPermission,
@ -1751,7 +1751,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"the view does not allow metadata access",
"the view does not allow deleting a url",
@ -1798,7 +1798,7 @@ trait APIMethods121 {
imageUrlJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -1984,7 +1984,7 @@ trait APIMethods121 {
openCorporateUrlJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -2033,7 +2033,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"the view does not allow metadata access",
"the view does not allow deleting an open corporate url",
@ -2080,7 +2080,7 @@ trait APIMethods121 {
corporateLocationJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"the view does not allow metadata access",
"the view does not allow adding a corporate location",
@ -2134,7 +2134,7 @@ trait APIMethods121 {
corporateLocationJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -2187,7 +2187,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
"the view does not allow metadata access",
"Corporate Location cannot be deleted",
@ -2236,7 +2236,7 @@ trait APIMethods121 {
physicalLocationJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -2291,7 +2291,7 @@ trait APIMethods121 {
physicalLocationJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
"the view does not allow metadata access",
@ -2344,7 +2344,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
NoViewPermission,
"Physical Location cannot be deleted",
@ -2611,7 +2611,7 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
NoViewPermission,
UnknownError),
@ -2648,7 +2648,7 @@ trait APIMethods121 {
EmptyBody,
transactionCommentsJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
NoViewPermission,
ViewNotFound,
@ -2687,7 +2687,7 @@ trait APIMethods121 {
postTransactionCommentJSON,
transactionCommentJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
BankAccountNotFound,
NoViewPermission,
@ -2734,7 +2734,7 @@ trait APIMethods121 {
BankAccountNotFound,
NoViewPermission,
ViewNotFound,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UnknownError),
List(apiTagTransactionMetaData, apiTagTransaction))
@ -2808,7 +2808,7 @@ trait APIMethods121 {
postTransactionTagJSON,
transactionTagJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
NoViewPermission,
@ -2889,7 +2889,7 @@ trait APIMethods121 {
EmptyBody,
transactionImagesJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
NoViewPermission,
ViewNotFound,
@ -2974,7 +2974,7 @@ trait APIMethods121 {
List(
BankAccountNotFound,
NoViewPermission,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
"You must be able to see images in order to delete them",
"Image not found for this transaction",
"Deleting images not permitted for this view",
@ -3053,7 +3053,7 @@ trait APIMethods121 {
postTransactionWhereJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
ViewNotFound,
@ -3099,7 +3099,7 @@ trait APIMethods121 {
postTransactionWhereJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
InvalidJsonFormat,
ViewNotFound,
@ -3145,10 +3145,10 @@ trait APIMethods121 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
NoViewPermission,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
ViewNotFound,
"there is no tag to delete",
"Delete not completed",

View File

@ -67,7 +67,7 @@ trait APIMethods130 {
"Returns data about all the physical cards a user has been issued. These could be debit cards, credit cards, etc.",
EmptyBody,
physicalCardsJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagCard))
lazy val getCards : OBPEndpoint = {
@ -95,7 +95,7 @@ trait APIMethods130 {
"",
EmptyBody,
physicalCardsJSON,
List(UserNotLoggedIn,BankNotFound, UnknownError),
List(AuthenticatedUserIsRequired,BankNotFound, UnknownError),
List(apiTagCard),
Some(List(canGetCardsForBank)))

View File

@ -104,14 +104,14 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
|Authentication via OAuth is required.""",
EmptyBody,
customerJsonV140,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagCustomer, apiTagOldStyle))
lazy val getCustomer : OBPEndpoint = {
case "banks" :: BankId(bankId) :: "customer" :: Nil JsonGet _ => {
cc => {
for {
u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {ErrorMessages.BankNotFound}
ucls <- tryo{UserCustomerLink.userCustomerLink.vend.getUserCustomerLinksByUserId(u.userId)} ?~! ErrorMessages.UserCustomerLinksNotFoundForUser
ucl <- tryo{ucls.find(x=>CustomerX.customerProvider.vend.getBankIdByCustomerId(x.customerId) == bankId.value)}
@ -139,7 +139,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
|Authentication via OAuth is required.""",
EmptyBody,
customerMessagesJson,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagMessage, apiTagCustomer))
lazy val getCustomersMessages : OBPEndpoint = {
@ -171,7 +171,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
// We use Extraction.decompose to convert to json
addCustomerMessageJson,
successMessage,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagMessage, apiTagCustomer, apiTagPerson)
)
@ -225,7 +225,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
EmptyBody,
branchesJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
"No branches available. License may not be set.",
UnknownError),
@ -239,7 +239,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
_ <- if(getBranchesIsPublic)
Box(Some(1))
else
cc.user ?~! UserNotLoggedIn
cc.user ?~! AuthenticatedUserIsRequired
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {ErrorMessages.BankNotFound}
// Get branches from the active provider
httpParams <- createHttpParamsByUrl(cc.url)
@ -277,7 +277,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
EmptyBody,
atmsJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
"No ATMs available. License may not be set.",
UnknownError),
@ -293,7 +293,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
_ <- if(getAtmsIsPublic)
Box(Some(1))
else
cc.user ?~! UserNotLoggedIn
cc.user ?~! AuthenticatedUserIsRequired
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {ErrorMessages.BankNotFound}
httpParams <- createHttpParamsByUrl(cc.url)
@ -335,7 +335,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
EmptyBody,
productsJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
"No products available.",
"License may not be set.",
@ -351,7 +351,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
_ <- if(getProductsIsPublic)
Box(Some(1))
else
cc.user ?~! UserNotLoggedIn
cc.user ?~! AuthenticatedUserIsRequired
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {ErrorMessages.BankNotFound}
products <- Box(Products.productsProvider.vend.getProducts(bankId)) ~> APIFailure("No products available. License may not be set.", 204)
} yield {
@ -376,7 +376,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
EmptyBody,
crmEventsJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
"No CRM Events available.",
UnknownError),
@ -431,7 +431,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
EmptyBody,
transactionRequestTypesJsonV140,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
AccountNotFound,
"Please specify a valid value for CURRENCY of your Bank Account. "
@ -491,7 +491,7 @@ trait APIMethods140 extends MdcLoggable with APIMethods130 with APIMethods121{
code.api.ResourceDocs1_4_0.SwaggerDefinitionsJSON.createCustomerJson,
customerJsonV140,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
"entitlements required",

View File

@ -7,7 +7,7 @@ import code.api.Constant._
import code.api.ResourceDocs1_4_0.SwaggerDefinitionsJSON._
import code.api.util.APIUtil._
import code.api.util.ApiTag._
import code.api.util.ErrorMessages.UserNotLoggedIn
import code.api.util.ErrorMessages.AuthenticatedUserIsRequired
import code.api.util.FutureUtil.EndpointContext
import code.api.util.NewStyle.HttpCode
import code.api.util._
@ -173,7 +173,7 @@ trait APIMethods200 {
|""".stripMargin,
EmptyBody,
basicAccountsJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagAccount, apiTagPrivateData, apiTagPublicData, apiTagOldStyle))
@ -182,7 +182,7 @@ trait APIMethods200 {
case "accounts" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
(privateViewsUserCanAccess, privateAccountAccess) <- Full(Views.views.vend.privateViewsUserCanAccess(u))
privateAccounts <- Full(BankAccountX.privateAccounts(privateAccountAccess))
} yield {
@ -221,7 +221,7 @@ trait APIMethods200 {
case "my" :: "accounts" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
(privateViewsUserCanAccess, privateAccountAccess) <- Full(Views.views.vend.privateViewsUserCanAccess(u))
privateAccounts <- Full(BankAccountX.privateAccounts(privateAccountAccess))
} yield {
@ -250,7 +250,7 @@ trait APIMethods200 {
|""".stripMargin,
EmptyBody,
basicAccountsJSON,
List(UserNotLoggedIn, CannotGetAccounts, UnknownError),
List(AuthenticatedUserIsRequired, CannotGetAccounts, UnknownError),
List(apiTagAccountPublic, apiTagAccount, apiTagPublicData)
)
lazy val publicAccountsAllBanks : OBPEndpoint = {
@ -332,7 +332,7 @@ trait APIMethods200 {
|""".stripMargin,
EmptyBody,
coreAccountsJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagAccount, apiTagPrivateData, apiTagPsd2))
apiRelations += ApiRelation(corePrivateAccountsAtOneBank, createAccount, "new")
@ -404,7 +404,7 @@ trait APIMethods200 {
|""".stripMargin,
EmptyBody,
basicAccountsJSON,
List(UserNotLoggedIn, BankNotFound, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, UnknownError),
List(apiTagAccount, apiTagPsd2)
)
@ -473,7 +473,7 @@ trait APIMethods200 {
|${userAuthenticationMessage(false)}""".stripMargin,
EmptyBody,
kycDocumentsJSON,
List(UserNotLoggedIn, CustomerNotFoundByCustomerId, UnknownError),
List(AuthenticatedUserIsRequired, CustomerNotFoundByCustomerId, UnknownError),
List(apiTagKyc, apiTagCustomer),
Some(List(canGetAnyKycDocuments))
)
@ -510,7 +510,7 @@ trait APIMethods200 {
|${userAuthenticationMessage(true)}""".stripMargin,
EmptyBody,
kycMediasJSON,
List(UserNotLoggedIn, CustomerNotFoundByCustomerId, UnknownError),
List(AuthenticatedUserIsRequired, CustomerNotFoundByCustomerId, UnknownError),
List(apiTagKyc, apiTagCustomer),
Some(List(canGetAnyKycMedia)))
@ -543,7 +543,7 @@ trait APIMethods200 {
|${userAuthenticationMessage(true)}""".stripMargin,
EmptyBody,
kycChecksJSON,
List(UserNotLoggedIn, CustomerNotFoundByCustomerId, UnknownError),
List(AuthenticatedUserIsRequired, CustomerNotFoundByCustomerId, UnknownError),
List(apiTagKyc, apiTagCustomer),
Some(List(canGetAnyKycChecks))
)
@ -576,7 +576,7 @@ trait APIMethods200 {
|${userAuthenticationMessage(true)}""".stripMargin,
EmptyBody,
kycStatusesJSON,
List(UserNotLoggedIn, CustomerNotFoundByCustomerId, UnknownError),
List(AuthenticatedUserIsRequired, CustomerNotFoundByCustomerId, UnknownError),
List(apiTagKyc, apiTagCustomer),
Some(List(canGetAnyKycStatuses))
)
@ -610,7 +610,7 @@ trait APIMethods200 {
|${userAuthenticationMessage(true)}""".stripMargin,
EmptyBody,
socialMediasJSON,
List(UserNotLoggedIn, UserHasMissingRoles, CustomerNotFoundByCustomerId, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, CustomerNotFoundByCustomerId, UnknownError),
List(apiTagCustomer),
Some(List(canGetSocialMediaHandles)))
@ -645,7 +645,7 @@ trait APIMethods200 {
"Add a KYC document for the customer specified by CUSTOMER_ID. KYC Documents contain the document type (e.g. passport), place of issue, expiry etc. ",
postKycDocumentJSON,
kycDocumentJSON,
List(UserNotLoggedIn, InvalidJsonFormat, BankNotFound, CustomerNotFoundByCustomerId,"Server error: could not add KycDocument", UnknownError),
List(AuthenticatedUserIsRequired, InvalidJsonFormat, BankNotFound, CustomerNotFoundByCustomerId,"Server error: could not add KycDocument", UnknownError),
List(apiTagKyc, apiTagCustomer),
Some(List(canAddKycDocument))
)
@ -697,7 +697,7 @@ trait APIMethods200 {
"Add some KYC media for the customer specified by CUSTOMER_ID. KYC Media resources relate to KYC Documents and KYC Checks and contain media urls for scans of passports, utility bills etc",
postKycMediaJSON,
kycMediaJSON,
List(UserNotLoggedIn, InvalidJsonFormat, CustomerNotFoundByCustomerId, ServerAddDataError, UnknownError),
List(AuthenticatedUserIsRequired, InvalidJsonFormat, CustomerNotFoundByCustomerId, ServerAddDataError, UnknownError),
List(apiTagKyc, apiTagCustomer),
Some(List(canAddKycMedia))
)
@ -747,7 +747,7 @@ trait APIMethods200 {
"Add a KYC check for the customer specified by CUSTOMER_ID. KYC Checks store details of checks on a customer made by the KYC team, their comments and a satisfied status",
postKycCheckJSON,
kycCheckJSON,
List(UserNotLoggedIn, InvalidJsonFormat, BankNotFound, CustomerNotFoundByCustomerId, ServerAddDataError, UnknownError),
List(AuthenticatedUserIsRequired, InvalidJsonFormat, BankNotFound, CustomerNotFoundByCustomerId, ServerAddDataError, UnknownError),
List(apiTagKyc, apiTagCustomer),
Some(List(canAddKycCheck))
)
@ -798,7 +798,7 @@ trait APIMethods200 {
"Add a kyc_status for the customer specified by CUSTOMER_ID. KYC Status is a timeline of the KYC status of the customer",
postKycStatusJSON,
kycStatusJSON,
List(UserNotLoggedIn, InvalidJsonFormat, InvalidBankIdFormat,UnknownError, BankNotFound ,ServerAddDataError ,CustomerNotFoundByCustomerId),
List(AuthenticatedUserIsRequired, InvalidJsonFormat, InvalidBankIdFormat,UnknownError, BankNotFound ,ServerAddDataError ,CustomerNotFoundByCustomerId),
List(apiTagKyc, apiTagCustomer),
Some(List(canAddKycStatus))
)
@ -843,7 +843,7 @@ trait APIMethods200 {
socialMediaJSON,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidBankIdFormat,
UserHasMissingRoles,
@ -919,7 +919,7 @@ trait APIMethods200 {
// TODO return specific error if bankId == "BANK_ID" or accountId == "ACCOUNT_ID"
// Should be a generic guard we can use for all calls (also for userId etc.)
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
account <- BankAccountX(bankId, accountId) ?~ BankAccountNotFound
// Assume owner view was requested
view <- u.checkOwnerViewAccessAndReturnOwnerView(BankIdAccountId(account.bankId, account.accountId), Some(cc))
@ -960,7 +960,7 @@ trait APIMethods200 {
case "my" :: "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: "transactions" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
params <- createQueriesByHttpParams(req.request.headers)
(bank, callContext) <- BankX(bankId, Some(cc)) ?~ BankNotFound
bankAccount <- BankAccountX(bankId, accountId) ?~! BankAccountNotFound
@ -1010,7 +1010,7 @@ trait APIMethods200 {
case "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: ViewId(viewId) :: "account" :: Nil JsonGet req => {
cc =>
for {
u <- cc.user ?~! UserNotLoggedIn
u <- cc.user ?~! AuthenticatedUserIsRequired
(bank, callContext) <- BankX(bankId, Some(cc)) ?~ BankNotFound // Check bank exists.
account <- BankAccountX(bank.bankId, accountId) ?~ {ErrorMessages.AccountNotFound} // Check Account exists.
availableViews <- Full(Views.views.vend.privateViewsUserCanAccessForAccount(u, BankIdAccountId(account.bankId, account.accountId)))
@ -1039,7 +1039,7 @@ trait APIMethods200 {
|""",
EmptyBody,
permissionsJSON,
List(UserNotLoggedIn, BankNotFound, AccountNotFound ,UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, AccountNotFound ,UnknownError),
List(apiTagView, apiTagAccount, apiTagUser, apiTagEntitlement)
)
@ -1081,7 +1081,7 @@ trait APIMethods200 {
|The user needs to have access to the owner view.""",
EmptyBody,
viewsJSONV121,
List(UserNotLoggedIn,BankNotFound, AccountNotFound,UnknownError),
List(AuthenticatedUserIsRequired,BankNotFound, AccountNotFound,UnknownError),
List(apiTagView, apiTagAccount, apiTagUser, apiTagOldStyle))
lazy val getPermissionForUserForBankAccount : OBPEndpoint = {
@ -1089,7 +1089,7 @@ trait APIMethods200 {
case "banks" :: BankId(bankId) :: "accounts" :: AccountId(accountId) :: "permissions" :: provider :: providerId :: Nil JsonGet req => {
cc =>
for {
loggedInUser <- cc.user ?~! ErrorMessages.UserNotLoggedIn // Check we have a user (rather than error or empty)
loggedInUser <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired // Check we have a user (rather than error or empty)
(bank, callContext) <- BankX(bankId, Some(cc)) ?~! BankNotFound // Check bank exists.
account <- BankAccountX(bank.bankId, accountId) ?~! {ErrorMessages.AccountNotFound} // Check Account exists.
loggedInUserPermissionBox = Views.views.vend.permission(BankIdAccountId(bankId, accountId), loggedInUser)
@ -1134,7 +1134,7 @@ trait APIMethods200 {
CreateAccountJSON("A user_id","CURRENT", "Label", AmountOfMoneyJSON121("EUR", "0")),
coreAccountJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidUserId,
InvalidAccountIdFormat,
@ -1319,7 +1319,7 @@ trait APIMethods200 {
|""",
createUserJson,
userJsonV200,
List(UserNotLoggedIn, InvalidJsonFormat, InvalidStrongPasswordFormat, DuplicateUsername, "Error occurred during user creation.", UnknownError),
List(AuthenticatedUserIsRequired, InvalidJsonFormat, InvalidStrongPasswordFormat, DuplicateUsername, "Error occurred during user creation.", UnknownError),
List(apiTagUser, apiTagOnboarding))
lazy val createUser: OBPEndpoint = {
@ -1395,7 +1395,7 @@ trait APIMethods200 {
// CreateMeetingJson("tokbox", "onboarding"),
// meetingJson,
// List(
// UserNotLoggedIn,
// AuthenticatedUserIsRequired,
// MeetingApiKeyNotConfigured,
// MeetingApiSecretNotConfigured,
// InvalidBankIdFormat,
@ -1415,7 +1415,7 @@ trait APIMethods200 {
// // TODO use these keys to get session and tokens from tokbox
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_key") ~> APIFailure(MeetingApiKeyNotConfigured, 403)
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_secret") ~> APIFailure(MeetingApiSecretNotConfigured, 403)
// u <- cc.user ?~! UserNotLoggedIn
// u <- cc.user ?~! AuthenticatedUserIsRequired
// _ <- tryo(assert(isValidID(bankId.value)))?~! InvalidBankIdFormat
// (bank, callContext) <- BankX(bankId, Some(cc)) ?~! BankNotFound
// postedData <- tryo {json.extract[CreateMeetingJson]} ?~! InvalidJsonFormat
@ -1455,7 +1455,7 @@ trait APIMethods200 {
// EmptyBody,
// meetingsJson,
// List(
// UserNotLoggedIn,
// AuthenticatedUserIsRequired,
// MeetingApiKeyNotConfigured,
// MeetingApiSecretNotConfigured,
// BankNotFound,
@ -1469,11 +1469,11 @@ trait APIMethods200 {
// cc =>
// if (APIUtil.getPropsAsBoolValue("meeting.tokbox_enabled", false)) {
// for {
// _ <- cc.user ?~! ErrorMessages.UserNotLoggedIn
// _ <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
// (bank, callContext ) <- BankX(bankId, Some(cc)) ?~! BankNotFound
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_key") ~> APIFailure(ErrorMessages.MeetingApiKeyNotConfigured, 403)
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_secret") ~> APIFailure(ErrorMessages.MeetingApiSecretNotConfigured, 403)
// u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
// u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
// (bank, callContext) <- BankX(bankId, Some(cc)) ?~! BankNotFound
// // now = Calendar.getInstance().getTime()
// meetings <- Meetings.meetingProvider.vend.getMeetings(bank.bankId, u)
@ -1510,7 +1510,7 @@ trait APIMethods200 {
// EmptyBody,
// meetingJson,
// List(
// UserNotLoggedIn,
// AuthenticatedUserIsRequired,
// BankNotFound,
// MeetingApiKeyNotConfigured,
// MeetingApiSecretNotConfigured,
@ -1526,7 +1526,7 @@ trait APIMethods200 {
// cc =>
// if (APIUtil.getPropsAsBoolValue("meeting.tokbox_enabled", false)) {
// for {
// u <- cc.user ?~! UserNotLoggedIn
// u <- cc.user ?~! AuthenticatedUserIsRequired
// (bank, callContext ) <- BankX(bankId, Some(cc)) ?~! BankNotFound
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_key") ~> APIFailure(ErrorMessages.MeetingApiKeyNotConfigured, 403)
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_secret") ~> APIFailure(ErrorMessages.MeetingApiSecretNotConfigured, 403)
@ -1563,7 +1563,7 @@ trait APIMethods200 {
customerJsonV140,
List(
InvalidBankIdFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
CustomerNumberAlreadyExists,
UserHasMissingRoles,
@ -1588,7 +1588,7 @@ trait APIMethods200 {
case "banks" :: BankId(bankId) :: "customers" :: Nil JsonPost json -> _ => {
cc =>
for {
u <- cc.user ?~! UserNotLoggedIn// TODO. CHECK user has role to create a customer / create a customer for another user id.
u <- cc.user ?~! AuthenticatedUserIsRequired // TODO. CHECK user has role to create a customer / create a customer for another user id.
_ <- tryo(assert(isValidID(bankId.value)))?~! ErrorMessages.InvalidBankIdFormat
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! BankNotFound
postedData <- tryo{json.extract[CreateCustomerJson]} ?~! ErrorMessages.InvalidJsonFormat
@ -1646,7 +1646,7 @@ trait APIMethods200 {
""".stripMargin,
EmptyBody,
userJsonV200,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagUser, apiTagOldStyle))
@ -1654,7 +1654,7 @@ trait APIMethods200 {
case "users" :: "current" :: Nil JsonGet _ => {
cc =>
for {
u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
}
yield {
// Format the data as V2.0.0 json
@ -1680,7 +1680,7 @@ trait APIMethods200 {
""".stripMargin,
EmptyBody,
usersJsonV200,
List(UserNotLoggedIn, UserHasMissingRoles, UserNotFoundByEmail, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UserNotFoundByEmail, UnknownError),
List(apiTagUser, apiTagOldStyle),
Some(List(canGetAnyUser)))
@ -1689,7 +1689,7 @@ trait APIMethods200 {
case "users" :: userEmail :: Nil JsonGet _ => {
cc =>
for {
l <- cc.user ?~! ErrorMessages.UserNotLoggedIn
l <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
_ <- NewStyle.function.ownEntitlement("", l.userId, ApiRole.canGetAnyUser, cc.callContext)
// Workaround to get userEmail address directly from URI without needing to URL-encode it
users <- tryo{AuthUser.getResourceUsersByEmail(CurrentReq.value.uri.split("/").last)} ?~! {ErrorMessages.UserNotFoundByEmail}
@ -1725,7 +1725,7 @@ trait APIMethods200 {
createUserCustomerLinkJson,
userCustomerLinkJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidBankIdFormat,
BankNotFound,
InvalidJsonFormat,
@ -1797,7 +1797,7 @@ trait APIMethods200 {
code.api.ResourceDocs1_4_0.SwaggerDefinitionsJSON.createEntitlementJSON,
entitlementJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserNotFoundById,
UserNotSuperAdmin,
InvalidJsonFormat,
@ -1861,7 +1861,7 @@ trait APIMethods200 {
""".stripMargin,
EmptyBody,
entitlementJSONs,
List(UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagRole, apiTagEntitlement, apiTagUser, apiTagOldStyle),
Some(List(canGetEntitlementsForAnyUserAtAnyBank)))
@ -1870,7 +1870,7 @@ trait APIMethods200 {
case "users" :: userId :: "entitlements" :: Nil JsonGet _ => {
cc =>
for {
u <- cc.user ?~ ErrorMessages.UserNotLoggedIn
u <- cc.user ?~ ErrorMessages.AuthenticatedUserIsRequired
_ <- NewStyle.function.ownEntitlement("", u.userId, canGetEntitlementsForAnyUserAtAnyBank, cc.callContext)
entitlements <- Entitlement.entitlement.vend.getEntitlementsByUserId(userId)
}
@ -1906,7 +1906,7 @@ trait APIMethods200 {
""".stripMargin,
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UserHasMissingRoles, EntitlementNotFound, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, EntitlementNotFound, UnknownError),
List(apiTagRole, apiTagUser, apiTagEntitlement),
Some(List(canDeleteEntitlementAtAnyBank)))
@ -1945,7 +1945,7 @@ trait APIMethods200 {
""".stripMargin,
EmptyBody,
entitlementJSONs,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagRole, apiTagEntitlement),
Some(List(canGetEntitlementsForAnyUserAtAnyBank)))
@ -2040,7 +2040,7 @@ trait APIMethods200 {
""",
EmptyBody,
emptyElasticSearch, //TODO what is output here?
List(UserNotLoggedIn, BankNotFound, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, UserHasMissingRoles, UnknownError),
List(apiTagSearchWarehouse, apiTagOldStyle),
Some(List(canSearchWarehouse)))
@ -2049,7 +2049,7 @@ trait APIMethods200 {
case "search" :: "warehouse" :: queryString :: Nil JsonGet _ => {
cc =>
for {
u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
_ <- Entitlement.entitlement.vend.getEntitlement("", u.userId, ApiRole.CanSearchWarehouse.toString) ?~! {UserHasMissingRoles + CanSearchWarehouse}
} yield {
successJsonResponse(Extraction.decompose(esw.searchProxy(u.userId, queryString)))
@ -2126,7 +2126,7 @@ trait APIMethods200 {
""",
EmptyBody,
emptyElasticSearch,
List(UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagMetric, apiTagApi, apiTagOldStyle),
Some(List(canSearchMetrics)))
@ -2135,7 +2135,7 @@ trait APIMethods200 {
case "search" :: "metrics" :: queryString :: Nil JsonGet _ => {
cc =>
for {
u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
_ <- Entitlement.entitlement.vend.getEntitlement("", u.userId, ApiRole.CanSearchMetrics.toString) ?~! {UserHasMissingRoles + CanSearchMetrics}
} yield {
successJsonResponse(Extraction.decompose(esm.searchProxy(u.userId, queryString)))
@ -2156,14 +2156,14 @@ trait APIMethods200 {
|Authentication via OAuth is required.""",
EmptyBody,
customersJsonV140,
List(UserNotLoggedIn, UserCustomerLinksNotFoundForUser, UnknownError),
List(AuthenticatedUserIsRequired, UserCustomerLinksNotFoundForUser, UnknownError),
List(apiTagPerson, apiTagCustomer, apiTagOldStyle))
lazy val getCustomers : OBPEndpoint = {
case "users" :: "current" :: "customers" :: Nil JsonGet _ => {
cc => {
for {
u <- cc.user ?~! ErrorMessages.UserNotLoggedIn
u <- cc.user ?~! ErrorMessages.AuthenticatedUserIsRequired
//(bank, callContext) <- Bank(bankId, Some(cc)) ?~! BankNotFound
customers <- tryo{CustomerX.customerProvider.vend.getCustomersByUserId(u.userId)} ?~! UserCustomerLinksNotFoundForUser
} yield {

View File

@ -123,7 +123,7 @@ trait APIMethods210 {
SandboxData.importJson,
successMessage,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
DataImportDisabled,
UserHasMissingRoles,
@ -171,7 +171,7 @@ trait APIMethods210 {
|""",
EmptyBody,
transactionRequestTypesJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagTransactionRequest, apiTagBank))
@ -275,8 +275,8 @@ trait APIMethods210 {
transactionRequestBodyJsonV200,
transactionRequestWithChargeJSON210,
List(
UserNotLoggedIn,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
AuthenticatedUserIsRequired,
InvalidBankIdFormat,
InvalidAccountIdFormat,
InvalidJsonFormat,
@ -315,8 +315,8 @@ trait APIMethods210 {
transactionRequestBodyCounterpartyJSON,
transactionRequestWithChargeJSON210,
List(
UserNotLoggedIn,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
AuthenticatedUserIsRequired,
InvalidBankIdFormat,
InvalidAccountIdFormat,
InvalidJsonFormat,
@ -359,8 +359,8 @@ trait APIMethods210 {
transactionRequestBodySEPAJSON,
transactionRequestWithChargeJSON210,
List(
UserNotLoggedIn,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
AuthenticatedUserIsRequired,
InvalidBankIdFormat,
InvalidAccountIdFormat,
InvalidJsonFormat,
@ -394,8 +394,8 @@ trait APIMethods210 {
transactionRequestBodyFreeFormJSON,
transactionRequestWithChargeJSON210,
List(
UserNotLoggedIn,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
AuthenticatedUserIsRequired,
InvalidBankIdFormat,
InvalidAccountIdFormat,
InvalidJsonFormat,
@ -613,7 +613,7 @@ trait APIMethods210 {
challengeAnswerJSON,
transactionRequestWithChargeJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidBankIdFormat,
InvalidAccountIdFormat,
InvalidJsonFormat,
@ -727,7 +727,7 @@ trait APIMethods210 {
EmptyBody,
transactionRequestWithChargeJSONs210,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
AccountNotFound,
UserHasMissingRoles,
@ -740,7 +740,7 @@ trait APIMethods210 {
cc =>
if (APIUtil.getPropsAsBoolValue("transactionRequests_enabled", false)) {
for {
u <- cc.user ?~ UserNotLoggedIn
u <- cc.user ?~ AuthenticatedUserIsRequired
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {BankNotFound}
(fromAccount, callContext) <- BankAccountX(bankId, accountId, Some(cc)) ?~! {AccountNotFound}
view <- APIUtil.checkViewAccessAndReturnView(viewId, BankIdAccountId(bankId, accountId), Some(u), callContext)
@ -773,7 +773,7 @@ trait APIMethods210 {
""".stripMargin,
EmptyBody,
availableRolesJSON,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagRole))
lazy val getRoles: OBPEndpoint = {
@ -808,7 +808,7 @@ trait APIMethods210 {
EmptyBody,
entitlementJSONs,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -859,7 +859,7 @@ trait APIMethods210 {
EmptyBody,
consumerJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidConsumerId,
UnknownError
@ -872,7 +872,7 @@ trait APIMethods210 {
case "management" :: "consumers" :: consumerId :: Nil JsonGet _ => {
cc =>
for {
u <- cc.user ?~! UserNotLoggedIn
u <- cc.user ?~! AuthenticatedUserIsRequired
_ <- NewStyle.function.ownEntitlement("", u.userId, ApiRole.canGetConsumers, cc.callContext)
consumerIdToLong <- tryo{consumerId.toLong} ?~! InvalidConsumerId
@ -898,7 +898,7 @@ trait APIMethods210 {
EmptyBody,
consumersJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -910,7 +910,7 @@ trait APIMethods210 {
case "management" :: "consumers" :: Nil JsonGet _ => {
cc =>
for {
u <- cc.user ?~! UserNotLoggedIn
u <- cc.user ?~! AuthenticatedUserIsRequired
_ <- NewStyle.function.ownEntitlement("", u.userId, ApiRole.canGetConsumers, cc.callContext)
consumers <- Some(Consumer.findAll())
} yield {
@ -935,7 +935,7 @@ trait APIMethods210 {
putEnabledJSON,
putEnabledJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -947,7 +947,7 @@ trait APIMethods210 {
case "management" :: "consumers" :: consumerId :: Nil JsonPut json -> _ => {
cc =>
for {
u <- cc.user ?~! UserNotLoggedIn
u <- cc.user ?~! AuthenticatedUserIsRequired
putData <- tryo{json.extract[PutEnabledJSON]} ?~! InvalidJsonFormat
_ <- putData.enabled match {
case true => NewStyle.function.ownEntitlement("", u.userId, ApiRole.canEnableConsumers, cc.callContext)
@ -980,7 +980,7 @@ trait APIMethods210 {
postPhysicalCardJSON,
physicalCardJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
AllowedValuesAre,
UnknownError
@ -1065,7 +1065,7 @@ trait APIMethods210 {
EmptyBody,
usersJsonV200,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1110,7 +1110,7 @@ trait APIMethods210 {
transactionTypeJsonV200,
transactionType,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
InsufficientAuthorisationToCreateTransactionType,
@ -1158,7 +1158,7 @@ trait APIMethods210 {
|${userAuthenticationMessage(!getAtmsIsPublic)}""".stripMargin,
EmptyBody,
atmJson,
List(UserNotLoggedIn, BankNotFound, AtmNotFoundByAtmId, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, AtmNotFoundByAtmId, UnknownError),
List(apiTagATM, apiTagOldStyle)
)
@ -1170,7 +1170,7 @@ trait APIMethods210 {
_ <- if (getAtmsIsPublic)
Box(Some(1))
else
cc.user ?~! UserNotLoggedIn
cc.user ?~! AuthenticatedUserIsRequired
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {BankNotFound}
atm <- Box(Atms.atmsProvider.vend.getAtm(bankId, atmId)) ?~! {AtmNotFoundByAtmId}
} yield {
@ -1204,7 +1204,7 @@ trait APIMethods210 {
EmptyBody,
branchJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BranchNotFoundByBranchId,
UnknownError
),
@ -1218,7 +1218,7 @@ trait APIMethods210 {
_ <- if (getBranchesIsPublic)
Box(Some(1))
else
cc.user ?~! UserNotLoggedIn
cc.user ?~! AuthenticatedUserIsRequired
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {BankNotFound}
branch <- Box(Branches.branchesProvider.vend.getBranch(bankId, branchId)) ?~! BranchNotFoundByBranchId
} yield {
@ -1255,7 +1255,7 @@ trait APIMethods210 {
EmptyBody,
productJsonV210,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
ProductNotFoundByProductCode,
UnknownError
),
@ -1302,7 +1302,7 @@ trait APIMethods210 {
EmptyBody,
productsJsonV210,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
ProductNotFoundByProductCode,
UnknownError
@ -1355,7 +1355,7 @@ trait APIMethods210 {
postCustomerJsonV210,
customerJsonV210,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
CustomerNumberAlreadyExists,
@ -1378,7 +1378,7 @@ trait APIMethods210 {
case "banks" :: BankId(bankId) :: "customers" :: Nil JsonPost json -> _ => {
cc =>
for {
u <- cc.user ?~! UserNotLoggedIn // TODO. CHECK user has role to create a customer / create a customer for another user id.
u <- cc.user ?~! AuthenticatedUserIsRequired // TODO. CHECK user has role to create a customer / create a customer for another user id.
_ <- tryo(assert(isValidID(bankId.value)))?~! InvalidBankIdFormat
(bank, callContext ) <- BankX(bankId, Some(cc)) ?~! {BankNotFound}
postedData <- tryo{json.extract[PostCustomerJsonV210]} ?~! InvalidJsonFormat
@ -1431,7 +1431,7 @@ trait APIMethods210 {
EmptyBody,
customerJsonV210,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1441,7 +1441,7 @@ trait APIMethods210 {
case "users" :: "current" :: "customers" :: Nil JsonGet _ => {
cc => {
for {
u <- cc.user ?~! UserNotLoggedIn
u <- cc.user ?~! AuthenticatedUserIsRequired
customers <- tryo{CustomerX.customerProvider.vend.getCustomersByUserId(u.userId)} ?~! UserCustomerLinksNotFoundForUser
} yield {
val json = JSONFactory210.createCustomersJson(customers)
@ -1465,7 +1465,7 @@ trait APIMethods210 {
EmptyBody,
customerJSONs,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UserCustomerLinksNotFoundForUser,
UserCustomerLinksNotFoundForUser,
@ -1508,7 +1508,7 @@ trait APIMethods210 {
branchJsonPut,
branchJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
UserHasMissingRoles,
@ -1555,7 +1555,7 @@ trait APIMethods210 {
branchJsonPost,
branchJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
InsufficientAuthorisationToCreateBranch,
@ -1608,7 +1608,7 @@ trait APIMethods210 {
consumerRedirectUrlJSON,
consumerJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1718,7 +1718,7 @@ trait APIMethods210 {
EmptyBody,
metricsJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),

View File

@ -123,7 +123,7 @@ trait APIMethods220 {
EmptyBody,
viewsJSONV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError
),
@ -179,7 +179,7 @@ trait APIMethods220 {
createViewJsonV121,
viewJSONV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
BankAccountNotFound,
UnknownError
@ -194,7 +194,7 @@ trait APIMethods220 {
createViewJsonV121 <- tryo{json.extract[CreateViewJsonV121]} ?~!InvalidJsonFormat
//customer views are started ith `_`,eg _life, _work, and System views startWith letter, eg: owner
_<- booleanToBox(isValidCustomViewName(createViewJsonV121.name), InvalidCustomViewFormat+s"Current view_name (${createViewJsonV121.name})")
u <- cc.user ?~!UserNotLoggedIn
u <- cc.user ?~!AuthenticatedUserIsRequired
account <- BankAccountX(bankId, accountId) ?~! BankAccountNotFound
createViewJson = CreateViewJson(
createViewJsonV121.name,
@ -238,7 +238,7 @@ trait APIMethods220 {
viewJSONV220,
List(
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError
),
@ -255,7 +255,7 @@ trait APIMethods220 {
_ <- booleanToBox(viewId.value.startsWith("_"), InvalidCustomViewFormat+s"Current view_name (${viewId.value})")
view <- APIUtil.checkViewAccessAndReturnView(viewId, BankIdAccountId(bankId, accountId), cc.user, Some(cc))
_ <- booleanToBox(!view.isSystem, SystemViewsCanNotBeModified)
u <- cc.user ?~!UserNotLoggedIn
u <- cc.user ?~!AuthenticatedUserIsRequired
account <- BankAccountX(bankId, accountId) ?~!BankAccountNotFound
updateViewJson = UpdateViewJSON(
description = updateJsonV121.description,
@ -309,7 +309,7 @@ trait APIMethods220 {
""".stripMargin,
EmptyBody,
fXRateJSON,
List(InvalidISOCurrencyCode,UserNotLoggedIn,FXCurrencyCodeCombinationsNotSupported, UnknownError),
List(InvalidISOCurrencyCode,AuthenticatedUserIsRequired,FXCurrencyCodeCombinationsNotSupported, UnknownError),
List(apiTagFx))
val getCurrentFxRateIsPublic = APIUtil.getPropsAsBoolValue("apiOptions.getCurrentFxRateIsPublic", false)
@ -355,7 +355,7 @@ trait APIMethods220 {
EmptyBody,
counterpartiesJsonV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
ViewNotFound,
NoViewPermission,
@ -413,7 +413,7 @@ trait APIMethods220 {
|""".stripMargin,
EmptyBody,
counterpartyWithMetadataJson,
List(UserNotLoggedIn, BankNotFound, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, UnknownError),
List(apiTagCounterparty, apiTagPSD2PIS, apiTagCounterpartyMetaData, apiTagPsd2)
)
@ -493,7 +493,7 @@ trait APIMethods220 {
bankJSONV220,
List(
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InsufficientAuthorisationToCreateBank,
UnknownError
),
@ -515,7 +515,7 @@ trait APIMethods220 {
_ <- Helper.booleanToBox(
!`checkIfContains::::` (bank.id), s"$InvalidJsonFormat BANK_ID can not contain `::::` characters")
u <- cc.user ?~!ErrorMessages.UserNotLoggedIn
u <- cc.user ?~!ErrorMessages.AuthenticatedUserIsRequired
consumer <- cc.consumer ?~! ErrorMessages.InvalidConsumerCredentials
_ <- NewStyle.function.hasEntitlementAndScope("", u.userId, consumer.id.get.toString, canCreateBank, cc.callContext)
success <- Connector.connector.vend.createOrUpdateBank(
@ -577,7 +577,7 @@ trait APIMethods220 {
branchJsonV220,
branchJsonV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InsufficientAuthorisationToCreateBranch,
UnknownError
@ -626,7 +626,7 @@ trait APIMethods220 {
atmJsonV220,
atmJsonV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UserHasMissingRoles,
UnknownError
@ -677,7 +677,7 @@ trait APIMethods220 {
productJsonV220,
productJsonV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UserHasMissingRoles,
UnknownError
@ -754,7 +754,7 @@ trait APIMethods220 {
fxJsonV220,
fxJsonV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UserHasMissingRoles,
UnknownError
@ -828,7 +828,7 @@ trait APIMethods220 {
List(
InvalidJsonFormat,
BankNotFound,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidUserId,
InvalidAccountIdFormat,
InvalidBankIdFormat,
@ -933,7 +933,7 @@ trait APIMethods220 {
EmptyBody,
configurationJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1051,7 +1051,7 @@ trait APIMethods220 {
|-----END CERTIFICATE-----""".stripMargin
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -1064,7 +1064,7 @@ trait APIMethods220 {
case "management" :: "consumers" :: Nil JsonPost json -> _ => {
cc =>
for {
u <- cc.user ?~! UserNotLoggedIn
u <- cc.user ?~! AuthenticatedUserIsRequired
_ <- NewStyle.function.ownEntitlement("", u.userId, ApiRole.canCreateConsumer, cc.callContext)
postedJson <- tryo {json.extract[ConsumerPostJSON]} ?~! InvalidJsonFormat
consumer <- Consumers.consumers.vend.createConsumer(Some(generateUUID()),
@ -1177,7 +1177,7 @@ trait APIMethods220 {
postCounterpartyJSON,
counterpartyWithMetadataJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidAccountIdFormat,
InvalidBankIdFormat,
BankNotFound,
@ -1300,7 +1300,7 @@ trait APIMethods220 {
EmptyBody,
customerViewsJsonV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
AccountNotFound,
ViewNotFound
@ -1336,7 +1336,7 @@ trait APIMethods220 {
case "management" :: "connector" :: "metrics" :: Nil JsonGet _ => {
cc =>{
for {
u <- user ?~! ErrorMessages.UserNotLoggedIn
u <- user ?~! ErrorMessages.AuthenticatedUserIsRequired
_ <- booleanToBox(hasEntitlement("", u.userId, ApiRole.CanGetConnectorMetrics), s"$CanGetConnectorMetrics entitlement required")
} yield {

View File

@ -126,7 +126,7 @@ trait APIMethods300 {
EmptyBody,
viewsJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError
),
@ -186,7 +186,7 @@ trait APIMethods300 {
SwaggerDefinitionsJSON.createViewJsonV300,
viewJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
BankAccountNotFound,
UnknownError
@ -239,7 +239,7 @@ trait APIMethods300 {
|The user needs to have access to the owner view.""",
EmptyBody,
viewsJsonV300,
List(UserNotLoggedIn,BankNotFound, AccountNotFound,UnknownError),
List(AuthenticatedUserIsRequired,BankNotFound, AccountNotFound,UnknownError),
List(apiTagView, apiTagAccount, apiTagUser))
lazy val getPermissionForUserForBankAccount : OBPEndpoint = {
@ -285,7 +285,7 @@ trait APIMethods300 {
viewJsonV300,
List(
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError
),
@ -477,7 +477,7 @@ trait APIMethods300 {
|""",
EmptyBody,
coreAccountsJsonV300,
List(UserNotLoggedIn,UnknownError),
List(AuthenticatedUserIsRequired,UnknownError),
List(apiTagAccount, apiTagPSD2AIS, apiTagPrivateData, apiTagPsd2)
)
@ -534,7 +534,7 @@ trait APIMethods300 {
|""".stripMargin,
EmptyBody,
moderatedCoreAccountsJsonV300,
List(UserNotLoggedIn,AccountFirehoseNotAllowedOnThisInstance,UnknownError),
List(AuthenticatedUserIsRequired,AccountFirehoseNotAllowedOnThisInstance,UnknownError),
List(apiTagAccount, apiTagAccountFirehose, apiTagFirehoseData),
Some(List(canUseAccountFirehoseAtAnyBank, ApiRole.canUseAccountFirehose))
)
@ -623,7 +623,7 @@ trait APIMethods300 {
|""".stripMargin,
EmptyBody,
transactionsJsonV300,
List(UserNotLoggedIn, AccountFirehoseNotAllowedOnThisInstance, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, AccountFirehoseNotAllowedOnThisInstance, UserHasMissingRoles, UnknownError),
List(apiTagTransaction, apiTagAccountFirehose, apiTagTransactionFirehose, apiTagFirehoseData),
Some(List(canUseAccountFirehoseAtAnyBank, ApiRole.canUseAccountFirehose))
)
@ -693,7 +693,7 @@ trait APIMethods300 {
FilterOffersetError,
FilterLimitError ,
FilterDateFormatError,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
ViewNotFound,
UnknownError
@ -751,7 +751,7 @@ trait APIMethods300 {
FilterOffersetError,
FilterLimitError ,
FilterDateFormatError,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
ViewNotFound,
UnknownError
@ -824,7 +824,7 @@ trait APIMethods300 {
""",
elasticSearchJsonV300,
emptyElasticSearch, //TODO what is output here?
List(UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagSearchWarehouse),
Some(List(canSearchWarehouse)))
val esw = new elasticsearchWarehouse
@ -903,7 +903,7 @@ trait APIMethods300 {
""",
elasticSearchJsonV300,
emptyElasticSearch, //TODO what is output here?
List(UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagSearchWarehouse),
Some(List(canSearchWarehouseStatistics))
)
@ -958,7 +958,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
usersJsonV200,
List(UserNotLoggedIn, UserHasMissingRoles, UserNotFoundByEmail, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UserNotFoundByEmail, UnknownError),
List(apiTagUser),
Some(List(canGetAnyUser)))
@ -991,7 +991,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
usersJsonV200,
List(UserNotLoggedIn, UserHasMissingRoles, UserNotFoundById, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UserNotFoundById, UnknownError),
List(apiTagUser),
Some(List(canGetAnyUser)))
@ -1028,7 +1028,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
usersJsonV200,
List(UserNotLoggedIn, UserHasMissingRoles, UserNotFoundByProviderAndUsername, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UserNotFoundByProviderAndUsername, UnknownError),
List(apiTagUser),
Some(List(canGetAnyUser)))
@ -1064,7 +1064,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
adapterInfoJsonV300,
List(UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagApi),
Some(List(canGetAdapterInfoAtOneBank))
)
@ -1106,7 +1106,7 @@ trait APIMethods300 {
branchJsonV300,
branchJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InsufficientAuthorisationToCreateBranch,
UnknownError
@ -1156,7 +1156,7 @@ trait APIMethods300 {
postBranchJsonV300,
branchJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InsufficientAuthorisationToCreateBranch,
UnknownError
@ -1223,7 +1223,7 @@ trait APIMethods300 {
atmJsonV300,
atmJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UserHasMissingRoles,
UnknownError
@ -1276,7 +1276,7 @@ trait APIMethods300 {
EmptyBody,
branchJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BranchNotFoundByBranchId,
UnknownError
),
@ -1338,7 +1338,7 @@ trait APIMethods300 {
EmptyBody,
branchesJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
BranchesNotFoundLicense,
UnknownError),
@ -1454,7 +1454,7 @@ trait APIMethods300 {
|${userAuthenticationMessage(!getAtmsIsPublic)}""".stripMargin,
EmptyBody,
atmJsonV300,
List(UserNotLoggedIn, BankNotFound, AtmNotFoundByAtmId, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, AtmNotFoundByAtmId, UnknownError),
List(apiTagATM)
)
lazy val getAtm: OBPEndpoint = {
@ -1496,7 +1496,7 @@ trait APIMethods300 {
EmptyBody,
atmJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
"No ATMs available. License may not be set.",
UnknownError),
@ -1575,7 +1575,7 @@ trait APIMethods300 {
EmptyBody,
usersJsonV200,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1617,7 +1617,7 @@ trait APIMethods300 {
EmptyBody,
customersWithAttributesJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1665,7 +1665,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
userJsonV300,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagUser))
lazy val getCurrentUser: OBPEndpoint = {
@ -1700,7 +1700,7 @@ trait APIMethods300 {
|${userAuthenticationMessage(true)}""".stripMargin,
EmptyBody,
coreAccountsJsonV300,
List(UserNotLoggedIn, BankNotFound, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, UnknownError),
List(apiTagAccount,apiTagPSD2AIS, apiTagPsd2)
)
@ -1739,7 +1739,7 @@ trait APIMethods300 {
|${userAuthenticationMessage(true)}""".stripMargin,
EmptyBody,
accountsIdsJsonV300,
List(UserNotLoggedIn, BankNotFound, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, UnknownError),
List(apiTagAccount, apiTagPSD2AIS, apiTagPsd2)
)
@ -1775,7 +1775,7 @@ trait APIMethods300 {
EmptyBody,
otherAccountsJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
ViewNotFound,
InvalidConnectorResponse,
@ -1812,7 +1812,7 @@ trait APIMethods300 {
EmptyBody,
otherAccountJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
ViewNotFound,
InvalidConnectorResponse,
@ -1860,7 +1860,7 @@ trait APIMethods300 {
code.api.ResourceDocs1_4_0.SwaggerDefinitionsJSON.createEntitlementJSON,
entitlementRequestJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserNotFoundById,
InvalidJsonFormat,
IncorrectRoleName,
@ -1917,7 +1917,7 @@ trait APIMethods300 {
EmptyBody,
entitlementRequestsJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidConnectorResponse,
UnknownError
),
@ -1956,7 +1956,7 @@ trait APIMethods300 {
EmptyBody,
entitlementRequestsJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidConnectorResponse,
UnknownError
),
@ -1995,7 +1995,7 @@ trait APIMethods300 {
EmptyBody,
entitlementRequestsJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidConnectorResponse,
UnknownError
),
@ -2030,7 +2030,7 @@ trait APIMethods300 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidConnectorResponse,
UnknownError
),
@ -2070,7 +2070,7 @@ trait APIMethods300 {
EmptyBody,
entitlementJSONs,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidConnectorResponse,
UnknownError
),
@ -2146,7 +2146,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
coreAccountsHeldJsonV300,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagAccount, apiTagPSD2AIS, apiTagView, apiTagPsd2)
)
@ -2223,7 +2223,7 @@ trait APIMethods300 {
EmptyBody,
aggregateMetricsJSONV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2269,7 +2269,7 @@ trait APIMethods300 {
SwaggerDefinitionsJSON.createScopeJson,
scopeJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
ConsumerNotFoundById,
InvalidJsonFormat,
IncorrectRoleName,
@ -2348,7 +2348,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, EntitlementNotFound, UnknownError),
List(AuthenticatedUserIsRequired, EntitlementNotFound, UnknownError),
List(apiTagScope, apiTagConsumer))
lazy val deleteScope: OBPEndpoint = {
@ -2386,7 +2386,7 @@ trait APIMethods300 {
""".stripMargin,
EmptyBody,
scopeJsons,
List(UserNotLoggedIn, EntitlementNotFound, UnknownError),
List(AuthenticatedUserIsRequired, EntitlementNotFound, UnknownError),
List(apiTagScope, apiTagConsumer))
lazy val getScopes: OBPEndpoint = {
@ -2453,7 +2453,7 @@ trait APIMethods300 {
|* Website""",
EmptyBody,
bankJson400,
List(UserNotLoggedIn, UnknownError, BankNotFound),
List(AuthenticatedUserIsRequired, UnknownError, BankNotFound),
apiTagBank :: apiTagPSD2AIS :: apiTagPsd2 :: Nil
)

View File

@ -120,7 +120,7 @@ trait APIMethods310 {
EmptyBody,
checkbookOrdersJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
BankAccountNotFound,
InvalidConnectorResponseForGetCheckbookOrdersFuture,
@ -161,7 +161,7 @@ trait APIMethods310 {
EmptyBody,
creditCardOrderStatusResponseJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
BankAccountNotFound,
InvalidConnectorResponseForGetStatusOfCreditCardOrderFuture,
@ -244,7 +244,7 @@ trait APIMethods310 {
EmptyBody,
topApisJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidFilterParameterFormat,
GetTopApisError,
@ -331,7 +331,7 @@ trait APIMethods310 {
EmptyBody,
topConsumersJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidFilterParameterFormat,
GetMetricsTopConsumersError,
@ -392,7 +392,7 @@ trait APIMethods310 {
|""".stripMargin,
EmptyBody,
customerJSONs,
List(UserNotLoggedIn, CustomerFirehoseNotAllowedOnThisInstance, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, CustomerFirehoseNotAllowedOnThisInstance, UserHasMissingRoles, UnknownError),
List(apiTagCustomer, apiTagFirehoseData),
Some(List(canUseCustomerFirehoseAtAnyBank)))
@ -442,7 +442,7 @@ trait APIMethods310 {
|""".stripMargin,
EmptyBody,
badLoginStatusJson,
List(UserNotLoggedIn, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(apiTagUser),
Some(List(canReadUserLockedStatus))
)
@ -481,7 +481,7 @@ trait APIMethods310 {
|""".stripMargin,
EmptyBody,
badLoginStatusJson,
List(UserNotLoggedIn, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(apiTagUser),
Some(List(canUnlockUser)))
@ -530,7 +530,7 @@ trait APIMethods310 {
callLimitPostJson,
callLimitPostJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
@ -589,7 +589,7 @@ trait APIMethods310 {
EmptyBody,
callLimitJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
@ -636,7 +636,7 @@ trait APIMethods310 {
EmptyBody,
checkFundsAvailableJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
BankAccountNotFound,
InvalidAmount,
@ -701,7 +701,7 @@ trait APIMethods310 {
EmptyBody,
consumerJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
ConsumerNotFoundByConsumerId,
UnknownError
@ -738,7 +738,7 @@ trait APIMethods310 {
EmptyBody,
consumersJson310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagConsumer)
@ -776,7 +776,7 @@ trait APIMethods310 {
EmptyBody,
consumersJson310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -937,7 +937,7 @@ trait APIMethods310 {
EmptyBody,
accountWebhooksJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -980,7 +980,7 @@ trait APIMethods310 {
EmptyBody,
configurationJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1012,7 +1012,7 @@ trait APIMethods310 {
""".stripMargin,
EmptyBody,
adapterInfoJsonV300,
List(UserNotLoggedIn,UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired,UserHasMissingRoles, UnknownError),
List(apiTagApi),
Some(List(canGetAdapterInfo))
)
@ -1048,7 +1048,7 @@ trait APIMethods310 {
|""",
EmptyBody,
transactionJsonV300,
List(UserNotLoggedIn, BankAccountNotFound ,ViewNotFound, UserNoPermissionAccessView, UnknownError),
List(AuthenticatedUserIsRequired, BankAccountNotFound ,ViewNotFound, UserNoPermissionAccessView, UnknownError),
List(apiTagTransaction))
lazy val getTransactionByIdForBankAccount : OBPEndpoint = {
@ -1106,7 +1106,7 @@ trait APIMethods310 {
EmptyBody,
transactionRequestWithChargeJSONs210,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
BankAccountNotFound,
UserNoPermissionAccessView,
@ -1158,7 +1158,7 @@ trait APIMethods310 {
postCustomerJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
CustomerNumberAlreadyExists,
@ -1271,7 +1271,7 @@ trait APIMethods310 {
EmptyBody,
customerWithAttributesJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserCustomerLinksNotFoundForUser,
UnknownError
@ -1314,7 +1314,7 @@ trait APIMethods310 {
postCustomerNumberJsonV310,
customerWithAttributesJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1358,7 +1358,7 @@ trait APIMethods310 {
postUserAuthContextJson,
userAuthContextJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
CreateUserAuthContextError,
UnknownError
@ -1400,7 +1400,7 @@ trait APIMethods310 {
EmptyBody,
userAuthContextsJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1439,7 +1439,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1477,7 +1477,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1514,7 +1514,7 @@ trait APIMethods310 {
postTaxResidenceJsonV310,
taxResidenceV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -1558,7 +1558,7 @@ trait APIMethods310 {
EmptyBody,
taxResidencesJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1596,7 +1596,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1636,7 +1636,7 @@ trait APIMethods310 {
""".stripMargin,
EmptyBody,
entitlementJSonsV310,
List(UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagRole, apiTagEntitlement))
@ -1674,7 +1674,7 @@ trait APIMethods310 {
postCustomerAddressJsonV310,
customerAddressJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -1731,7 +1731,7 @@ trait APIMethods310 {
postCustomerAddressJsonV310,
customerAddressJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -1786,7 +1786,7 @@ trait APIMethods310 {
EmptyBody,
customerAddressesJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1825,7 +1825,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2229,7 +2229,7 @@ trait APIMethods310 {
EmptyBody,
accountApplicationsJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2272,7 +2272,7 @@ trait APIMethods310 {
EmptyBody,
accountApplicationResponseJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2318,7 +2318,7 @@ trait APIMethods310 {
accountApplicationUpdateStatusJson,
accountApplicationResponseJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2409,7 +2409,7 @@ trait APIMethods310 {
postPutProductJsonV310,
productJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UserHasMissingRoles,
UnknownError
@ -2483,7 +2483,7 @@ trait APIMethods310 {
EmptyBody,
productJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
ProductNotFoundByProductCode,
UnknownError
),
@ -2538,7 +2538,7 @@ trait APIMethods310 {
EmptyBody,
childProductTreeJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
ProductNotFoundByProductCode,
UnknownError
),
@ -2591,7 +2591,7 @@ trait APIMethods310 {
EmptyBody,
productsJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
ProductNotFoundByProductCode,
UnknownError
@ -2664,7 +2664,7 @@ trait APIMethods310 {
accountAttributeJson,
accountAttributeResponseJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -2737,7 +2737,7 @@ trait APIMethods310 {
accountAttributeJson,
accountAttributeResponseJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -2820,7 +2820,7 @@ trait APIMethods310 {
putProductCollectionsV310,
productCollectionsJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UserHasMissingRoles,
UnknownError
@ -2879,7 +2879,7 @@ trait APIMethods310 {
EmptyBody,
productCollectionJsonTreeV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError
),
@ -2921,7 +2921,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InsufficientAuthorisationToDeleteBranch,
UnknownError
@ -2969,7 +2969,7 @@ trait APIMethods310 {
createMeetingJsonV310,
meetingJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
UnknownError
@ -2989,7 +2989,7 @@ trait APIMethods310 {
// These following are only for `tokbox` stuff, for now, just ignore it.
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_key") ~> APIFailure(MeetingApiKeyNotConfigured, 403)
// _ <- APIUtil.getPropsValue("meeting.tokbox_api_secret") ~> APIFailure(MeetingApiSecretNotConfigured, 403)
// u <- cc.user ?~! UserNotLoggedIn
// u <- cc.user ?~! AuthenticatedUserIsRequired
// _ <- tryo(assert(isValidID(bankId.value)))?~! InvalidBankIdFormat
// (bank, callContext) <- Bank(bankId, Some(cc)) ?~! BankNotFound
// postedData <- tryo {json.extract[CreateMeetingJson]} ?~! InvalidJsonFormat
@ -3047,7 +3047,7 @@ trait APIMethods310 {
EmptyBody,
meetingsJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError),
List(apiTagMeeting, apiTagCustomer, apiTagExperimental))
@ -3085,7 +3085,7 @@ trait APIMethods310 {
EmptyBody,
meetingJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
MeetingNotFound,
UnknownError
@ -3327,7 +3327,7 @@ trait APIMethods310 {
postConsentEmailJsonV310,
consentJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
ConsentAllowedScaMethods,
@ -3406,7 +3406,7 @@ trait APIMethods310 {
postConsentPhoneJsonV310,
consentJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
ConsentAllowedScaMethods,
@ -3484,7 +3484,7 @@ trait APIMethods310 {
postConsentImplicitJsonV310,
consentJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
ConsentAllowedScaMethods,
@ -3687,7 +3687,7 @@ trait APIMethods310 {
status = "INITIATED"
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
InvalidConnectorResponse,
@ -3730,7 +3730,7 @@ trait APIMethods310 {
EmptyBody,
consentsJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError
),
@ -3775,7 +3775,7 @@ trait APIMethods310 {
EmptyBody,
revokedConsentJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError
),
@ -3820,7 +3820,7 @@ trait APIMethods310 {
postUserAuthContextJson,
userAuthContextUpdateJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
CreateUserAuthContextError,
UnknownError
@ -3866,7 +3866,7 @@ trait APIMethods310 {
PostUserAuthContextUpdateJsonV310(answer = "12345678"),
userAuthContextUpdateJson,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
InvalidConnectorResponse,
@ -3931,7 +3931,7 @@ trait APIMethods310 {
EmptyBody,
viewJSONV220,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError
),
@ -3979,7 +3979,7 @@ trait APIMethods310 {
SwaggerDefinitionsJSON.createSystemViewJsonV300,
viewJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -4023,7 +4023,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError,
"user does not have owner access"
@ -4065,7 +4065,7 @@ trait APIMethods310 {
viewJsonV300,
List(
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError
),
@ -4151,7 +4151,7 @@ trait APIMethods310 {
)
,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4253,7 +4253,7 @@ trait APIMethods310 {
Some("this-method-routing-Id")
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
InvalidConnectorName,
@ -4356,7 +4356,7 @@ trait APIMethods310 {
MethodRoutingCommons("getBank", "rest_vMar2019", true, Some("some_bankId"), List(MethodRoutingParam("url", "http://mydomain.com/xxx"))),
MethodRoutingCommons("getBank", "rest_vMar2019", true, Some("some_bankId"), List(MethodRoutingParam("url", "http://mydomain.com/xxx")), Some("this-method-routing-Id")),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
InvalidConnectorName,
@ -4434,7 +4434,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4472,7 +4472,7 @@ trait APIMethods310 {
putUpdateCustomerEmailJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4521,7 +4521,7 @@ trait APIMethods310 {
putUpdateCustomerNumberJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4576,7 +4576,7 @@ trait APIMethods310 {
putUpdateCustomerMobileNumberJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4625,7 +4625,7 @@ trait APIMethods310 {
putUpdateCustomerIdentityJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4682,7 +4682,7 @@ trait APIMethods310 {
putUpdateCustomerCreditLimitJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4731,7 +4731,7 @@ trait APIMethods310 {
putUpdateCustomerCreditRatingAndSourceJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4778,7 +4778,7 @@ trait APIMethods310 {
""".stripMargin,
updateAccountRequestJsonV310,
updateAccountResponseJsonV310,
List(InvalidJsonFormat, UserNotLoggedIn, UnknownError, BankAccountNotFound),
List(InvalidJsonFormat, AuthenticatedUserIsRequired, UnknownError, BankAccountNotFound),
List(apiTagAccount),
Some(List(canUpdateAccount))
)
@ -4841,7 +4841,7 @@ trait APIMethods310 {
createPhysicalCardJsonV310,
physicalCardJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
AllowedValuesAre,
UnknownError
@ -4936,7 +4936,7 @@ trait APIMethods310 {
updatePhysicalCardJsonV310,
physicalCardJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
AllowedValuesAre,
UnknownError
@ -5021,7 +5021,7 @@ trait APIMethods310 {
|${userAuthenticationMessage(true)}""".stripMargin,
EmptyBody,
physicalCardsJsonV310,
List(UserNotLoggedIn,BankNotFound, UnknownError),
List(AuthenticatedUserIsRequired,BankNotFound, UnknownError),
List(apiTagCard))
lazy val getCardsForBank : OBPEndpoint = {
case "management" :: "banks" :: BankId(bankId) :: "cards" :: Nil JsonGet _ => {
@ -5056,7 +5056,7 @@ trait APIMethods310 {
""".stripMargin,
EmptyBody,
physicalCardWithAttributesJsonV310,
List(UserNotLoggedIn,BankNotFound, UnknownError),
List(AuthenticatedUserIsRequired,BankNotFound, UnknownError),
List(apiTagCard),
Some(List(canGetCardsForBank)))
lazy val getCardForBank : OBPEndpoint = {
@ -5092,7 +5092,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
AllowedValuesAre,
UnknownError
@ -5144,7 +5144,7 @@ trait APIMethods310 {
CardAttributeType.DOUBLE,
cardAttributeValueExample.value),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -5215,7 +5215,7 @@ trait APIMethods310 {
CardAttributeType.DOUBLE,
cardAttributeValueExample.value),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -5273,7 +5273,7 @@ trait APIMethods310 {
putCustomerBranchJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5329,7 +5329,7 @@ trait APIMethods310 {
putUpdateCustomerDataJsonV310,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5394,7 +5394,7 @@ trait APIMethods310 {
List(
InvalidJsonFormat,
BankNotFound,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidUserId,
InvalidAccountIdFormat,
InvalidBankIdFormat,
@ -5788,7 +5788,7 @@ trait APIMethods310 {
)
,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5879,7 +5879,7 @@ trait APIMethods310 {
WebUiPropsCommons("webui_api_explorer_url", "https://apiexplorer.openbankproject.com"),
WebUiPropsCommons( "webui_api_explorer_url", "https://apiexplorer.openbankproject.com", Some("some-web-ui-props-id")),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5925,7 +5925,7 @@ trait APIMethods310 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5990,7 +5990,7 @@ trait APIMethods310 {
putEnabledJSON,
putEnabledJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),

File diff suppressed because it is too large Load Diff

View File

@ -165,7 +165,7 @@ trait APIMethods500 {
bankJson500,
List(
InvalidJsonFormat,
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InsufficientAuthorisationToCreateBank,
UnknownError
),
@ -251,7 +251,7 @@ trait APIMethods500 {
bankJson500,
List(
InvalidJsonFormat,
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
BankNotFound,
updateBankError,
UnknownError
@ -324,7 +324,7 @@ trait APIMethods500 {
List(
InvalidJsonFormat,
BankNotFound,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidUserId,
InvalidAccountIdFormat,
InvalidBankIdFormat,
@ -453,7 +453,7 @@ trait APIMethods500 {
postUserAuthContextJson,
userAuthContextJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
CreateUserAuthContextError,
UnknownError
@ -495,7 +495,7 @@ trait APIMethods500 {
EmptyBody,
userAuthContextJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -533,7 +533,7 @@ trait APIMethods500 {
postUserAuthContextJson,
userAuthContextUpdateJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
CreateUserAuthContextError,
@ -579,7 +579,7 @@ trait APIMethods500 {
postUserAuthContextUpdateJsonV310,
userAuthContextUpdateJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
InvalidConnectorResponse,
@ -752,7 +752,7 @@ trait APIMethods500 {
EmptyBody,
consentJsonV500,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagConsent, apiTagPSD2AIS, apiTagPsd2))
@ -828,7 +828,7 @@ trait APIMethods500 {
EmptyBody,
consentJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
ConsentAllowedScaMethods,
@ -859,7 +859,7 @@ trait APIMethods500 {
EmptyBody,
consentJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
ConsentRequestIsInvalid,
@ -891,7 +891,7 @@ trait APIMethods500 {
EmptyBody,
consentJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
ConsentRequestIsInvalid,
@ -1354,7 +1354,7 @@ trait APIMethods500 {
postCustomerJsonV500,
customerJsonV310,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
CustomerNumberAlreadyExists,
@ -1430,7 +1430,7 @@ trait APIMethods500 {
postCustomerOverviewJsonV500,
customerOverviewJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1479,7 +1479,7 @@ trait APIMethods500 {
postCustomerOverviewJsonV500,
customerOverviewFlatJsonV500,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1526,7 +1526,7 @@ trait APIMethods500 {
EmptyBody,
customerJsonV210,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1562,7 +1562,7 @@ trait APIMethods500 {
EmptyBody,
customerJSONs,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserCustomerLinksNotFoundForUser,
UnknownError
@ -1607,7 +1607,7 @@ trait APIMethods500 {
EmptyBody,
customersJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1693,7 +1693,7 @@ trait APIMethods500 {
putProductJsonV500,
productJsonV400.copy(attributes = None, fees = None),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserHasMissingRoles,
UnknownError
@ -1755,7 +1755,7 @@ trait APIMethods500 {
createPhysicalCardJsonV500,
physicalCardJsonV500,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserHasMissingRoles,
AllowedValuesAre,
@ -1874,7 +1874,7 @@ trait APIMethods500 {
EmptyBody,
viewsJsonV500,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankAccountNotFound,
UnknownError
),
@ -1917,7 +1917,7 @@ trait APIMethods500 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError,
"user does not have owner access"
@ -2005,7 +2005,7 @@ trait APIMethods500 {
EmptyBody,
metricsJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2042,7 +2042,7 @@ trait APIMethods500 {
EmptyBody,
viewJsonV500,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -2076,7 +2076,7 @@ trait APIMethods500 {
EmptyBody,
viewIdsJsonV500,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -2123,7 +2123,7 @@ trait APIMethods500 {
createSystemViewJsonV500,
viewJsonV500,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -2171,7 +2171,7 @@ trait APIMethods500 {
viewJsonV500,
List(
InvalidJsonFormat,
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
BankAccountNotFound,
UnknownError
),
@ -2214,7 +2214,7 @@ trait APIMethods500 {
createCustomerAccountLinkJson,
customerAccountLinkJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
BankAccountNotFound,
InvalidJsonFormat,
@ -2269,7 +2269,7 @@ trait APIMethods500 {
EmptyBody,
customerAccountLinksJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
CustomerNotFoundByCustomerId,
UserHasMissingRoles,
@ -2307,7 +2307,7 @@ trait APIMethods500 {
EmptyBody,
customerAccountLinksJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
BankAccountNotFound,
UserHasMissingRoles,
@ -2342,7 +2342,7 @@ trait APIMethods500 {
EmptyBody,
customerAccountLinkJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserHasMissingRoles,
UnknownError
@ -2376,7 +2376,7 @@ trait APIMethods500 {
updateCustomerAccountLinkJson,
customerAccountLinkJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserHasMissingRoles,
UnknownError
@ -2415,7 +2415,7 @@ trait APIMethods500 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserHasMissingRoles,
UnknownError
@ -2449,7 +2449,7 @@ trait APIMethods500 {
""".stripMargin,
EmptyBody,
adapterInfoJsonV500,
List($UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List($AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagApi),
Some(List(canGetAdapterInfo))
)

View File

@ -11,7 +11,7 @@ import code.api.cache.RedisLogger
import code.api.util.APIUtil._
import code.api.util.ApiRole._
import code.api.util.ApiTag._
import code.api.util.ErrorMessages.{$UserNotLoggedIn, BankNotFound, ConsentNotFound, InvalidJsonFormat, UnknownError, UserNotFoundByUserId, UserNotLoggedIn, _}
import code.api.util.ErrorMessages.{$AuthenticatedUserIsRequired, BankNotFound, ConsentNotFound, InvalidJsonFormat, UnknownError, UserNotFoundByUserId, AuthenticatedUserIsRequired, _}
import code.api.util.FutureUtil.{EndpointContext, EndpointTimeout}
import code.api.util.JwtUtil.{getSignedPayloadAsJson, verifyJwt}
import code.api.util.NewStyle.HttpCode
@ -270,7 +270,7 @@ trait APIMethods510 {
""",
EmptyBody,
EmptyBody,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
apiTagSystem :: apiTagApi :: apiTagLogCache :: Nil,
Some(List(canGetSystemLogCacheTrace, canGetSystemLogCacheAll)))
@ -301,7 +301,7 @@ trait APIMethods510 {
""",
EmptyBody,
EmptyBody,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
apiTagSystem :: apiTagApi :: apiTagLogCache :: Nil,
Some(List(canGetSystemLogCacheDebug, canGetSystemLogCacheAll)))
@ -332,7 +332,7 @@ trait APIMethods510 {
""",
EmptyBody,
EmptyBody,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
apiTagSystem :: apiTagApi :: apiTagLogCache :: Nil,
Some(List(canGetSystemLogCacheInfo, canGetSystemLogCacheAll)))
@ -363,7 +363,7 @@ trait APIMethods510 {
""",
EmptyBody,
EmptyBody,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
apiTagSystem :: apiTagApi :: apiTagLogCache :: Nil,
Some(List(canGetSystemLogCacheWarning, canGetSystemLogCacheAll)))
@ -394,7 +394,7 @@ trait APIMethods510 {
""",
EmptyBody,
EmptyBody,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
apiTagSystem :: apiTagApi :: apiTagLogCache :: Nil,
Some(List(canGetSystemLogCacheError, canGetSystemLogCacheAll)))
@ -425,7 +425,7 @@ trait APIMethods510 {
""",
EmptyBody,
EmptyBody,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
apiTagSystem :: apiTagApi :: apiTagLogCache :: Nil,
Some(List(canGetSystemLogCacheAll)))
@ -479,7 +479,7 @@ trait APIMethods510 {
regulatedEntityPostJsonV510,
regulatedEntityJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -535,7 +535,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidConnectorResponse,
UnknownError
@ -638,7 +638,7 @@ trait APIMethods510 {
postAgentJsonV510,
agentJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
AgentNumberAlreadyExists,
@ -697,7 +697,7 @@ trait APIMethods510 {
putAgentJsonV510,
agentJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
AgentNotFound,
@ -746,7 +746,7 @@ trait APIMethods510 {
EmptyBody,
agentJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
AgentNotFound,
AgentAccountLinkNotFound,
@ -788,7 +788,7 @@ trait APIMethods510 {
userAttributeJsonV510,
userAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -840,7 +840,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidConnectorResponse,
UnknownError
@ -880,7 +880,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidConnectorResponse,
UnknownError
@ -924,7 +924,7 @@ trait APIMethods510 {
EmptyBody,
refresUserJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -965,7 +965,7 @@ trait APIMethods510 {
EmptyBody,
coreAccountsHeldJsonV300,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserNotFoundByUserId,
UnknownError
@ -1012,7 +1012,7 @@ trait APIMethods510 {
EmptyBody,
coreAccountsHeldJsonV300,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserNotFoundByUserId,
UnknownError
@ -1056,7 +1056,7 @@ trait APIMethods510 {
EmptyBody,
userJsonV300,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserNotFoundByUserId,
UserHasMissingRoles,
UnknownError),
@ -1092,7 +1092,7 @@ trait APIMethods510 {
EmptyBody,
CheckSystemIntegrityJsonV510(true),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1128,7 +1128,7 @@ trait APIMethods510 {
EmptyBody,
CheckSystemIntegrityJsonV510(true),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1165,7 +1165,7 @@ trait APIMethods510 {
EmptyBody,
CheckSystemIntegrityJsonV510(true),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1201,7 +1201,7 @@ trait APIMethods510 {
EmptyBody,
CheckSystemIntegrityJsonV510(true),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1237,7 +1237,7 @@ trait APIMethods510 {
EmptyBody,
currenciesJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagFx)
@ -1275,7 +1275,7 @@ trait APIMethods510 {
EmptyBody,
CheckSystemIntegrityJsonV510(true),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1326,7 +1326,7 @@ trait APIMethods510 {
atmAttributeJsonV510,
atmAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
UnknownError
@ -1414,7 +1414,7 @@ trait APIMethods510 {
EmptyBody,
atmAttributesResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
UnknownError
@ -1450,7 +1450,7 @@ trait APIMethods510 {
EmptyBody,
atmAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
UnknownError
@ -1489,7 +1489,7 @@ trait APIMethods510 {
atmAttributeJsonV510,
atmAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserHasMissingRoles,
UnknownError
@ -1547,7 +1547,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UserHasMissingRoles,
UnknownError
@ -1593,7 +1593,7 @@ trait APIMethods510 {
status = "AUTHORISED"
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
ConsentNotFound,
@ -1657,7 +1657,7 @@ trait APIMethods510 {
status = "AUTHORISED"
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
ConsentNotFound,
@ -1735,7 +1735,7 @@ trait APIMethods510 {
status = "AUTHORISED"
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
ConsentNotFound,
@ -1809,7 +1809,7 @@ trait APIMethods510 {
EmptyBody,
consentsInfoJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -1848,7 +1848,7 @@ trait APIMethods510 {
EmptyBody,
consentsInfoJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -1899,7 +1899,7 @@ trait APIMethods510 {
EmptyBody,
consentsJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -1961,7 +1961,7 @@ trait APIMethods510 {
EmptyBody,
consentsJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -2003,7 +2003,7 @@ trait APIMethods510 {
EmptyBody,
consentJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagConsent, apiTagPSD2AIS, apiTagPsd2))
@ -2041,7 +2041,7 @@ trait APIMethods510 {
EmptyBody,
consentJsonV500,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagConsent, apiTagPSD2AIS, apiTagPsd2))
@ -2085,7 +2085,7 @@ trait APIMethods510 {
EmptyBody,
revokedConsentJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError
),
@ -2138,7 +2138,7 @@ trait APIMethods510 {
EmptyBody,
revokedConsentJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError
),
@ -2188,7 +2188,7 @@ trait APIMethods510 {
EmptyBody,
revokedConsentJsonV310,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagConsent, apiTagPSD2AIS, apiTagPsd2))
@ -2330,7 +2330,7 @@ trait APIMethods510 {
postConsentImplicitJsonV310,
consentJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
InvalidJsonFormat,
ConsentAllowedScaMethods,
@ -2556,7 +2556,7 @@ trait APIMethods510 {
EmptyBody,
certificateInfoJsonV510,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
UnknownError
),
@ -2591,7 +2591,7 @@ trait APIMethods510 {
postApiCollectionJson400,
apiCollectionJson400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
UserNotFoundByUserId,
UnknownError
@ -2653,7 +2653,7 @@ trait APIMethods510 {
""".stripMargin,
EmptyBody,
userJsonV400,
List($UserNotLoggedIn, UserHasMissingRoles, UserNotFoundByProviderAndUsername, UnknownError),
List($AuthenticatedUserIsRequired, UserHasMissingRoles, UserNotFoundByProviderAndUsername, UnknownError),
List(apiTagUser),
Some(List(canGetAnyUser))
)
@ -2687,7 +2687,7 @@ trait APIMethods510 {
|""".stripMargin,
EmptyBody,
badLoginStatusJson,
List(UserNotLoggedIn, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(apiTagUser),
Some(List(canReadUserLockedStatus))
)
@ -2729,7 +2729,7 @@ trait APIMethods510 {
|""".stripMargin,
EmptyBody,
badLoginStatusJson,
List(UserNotLoggedIn, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(apiTagUser),
Some(List(canUnlockUser)))
lazy val unlockUserByProviderAndUsername: OBPEndpoint = {
@ -2774,7 +2774,7 @@ trait APIMethods510 {
|""".stripMargin,
EmptyBody,
userLockStatusJson,
List($UserNotLoggedIn, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List($AuthenticatedUserIsRequired, UserNotFoundByProviderAndUsername, UserHasMissingRoles, UnknownError),
List(apiTagUser),
Some(List(canLockUser)))
lazy val lockUserByProviderAndUsername: OBPEndpoint = {
@ -2809,7 +2809,7 @@ trait APIMethods510 {
EmptyBody,
userLockStatusJson,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserNotFoundByUserId,
UserHasMissingRoles,
UnknownError
@ -2881,7 +2881,7 @@ trait APIMethods510 {
EmptyBody,
aggregateMetricsJSONV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3006,7 +3006,7 @@ trait APIMethods510 {
EmptyBody,
metricsJsonV510,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3048,7 +3048,7 @@ trait APIMethods510 {
EmptyBody,
customersWithAttributesJsonV300,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -3087,7 +3087,7 @@ trait APIMethods510 {
postCustomerLegalNameJsonV510,
customerJsonV310,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -3126,7 +3126,7 @@ trait APIMethods510 {
postAtmJsonV510,
atmJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -3168,7 +3168,7 @@ trait APIMethods510 {
atmJsonV510.copy(id = None, attributes = None),
atmJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -3282,7 +3282,7 @@ trait APIMethods510 {
|${userAuthenticationMessage(!getAtmsIsPublic)}""".stripMargin,
EmptyBody,
atmJsonV510,
List(UserNotLoggedIn, BankNotFound, AtmNotFoundByAtmId, UnknownError),
List(AuthenticatedUserIsRequired, BankNotFound, AtmNotFoundByAtmId, UnknownError),
List(apiTagATM)
)
lazy val getAtm: OBPEndpoint = {
@ -3317,7 +3317,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagATM),
@ -3584,7 +3584,7 @@ trait APIMethods510 {
createConsumerRequestJsonV510,
consumerJsonOnlyForPostResponseV510,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -3637,7 +3637,7 @@ trait APIMethods510 {
createConsumerRequestJsonV510,
consumerJsonV510,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -3691,7 +3691,7 @@ trait APIMethods510 {
EmptyBody,
callLimitsJson510Example,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
@ -3735,7 +3735,7 @@ trait APIMethods510 {
consumerRedirectUrlJSON,
consumerJSON,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3794,7 +3794,7 @@ trait APIMethods510 {
consumerLogoUrlJson,
consumerJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3841,7 +3841,7 @@ trait APIMethods510 {
consumerCertificateJson,
consumerJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3889,7 +3889,7 @@ trait APIMethods510 {
consumerNameJson,
consumerJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3931,7 +3931,7 @@ trait APIMethods510 {
EmptyBody,
consumerJSON,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
ConsumerNotFoundByConsumerId,
UnknownError
@ -3970,7 +3970,7 @@ trait APIMethods510 {
EmptyBody,
consumersJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4052,7 +4052,7 @@ trait APIMethods510 {
postAccountAccessJsonV510,
viewJsonV300,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4113,7 +4113,7 @@ trait APIMethods510 {
postAccountAccessJsonV510,
revokedJsonV400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4187,7 +4187,7 @@ trait APIMethods510 {
postCreateUserAccountAccessJsonV400,
List(viewJsonV300),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4251,7 +4251,7 @@ trait APIMethods510 {
EmptyBody,
transactionRequestWithChargeJSON210,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
GetTransactionRequestsException,
UnknownError
),
@ -4308,7 +4308,7 @@ trait APIMethods510 {
EmptyBody,
transactionRequestWithChargeJSONs210,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
BankNotFound,
BankAccountNotFound,
UserNoPermissionAccessView,
@ -4367,7 +4367,7 @@ trait APIMethods510 {
PostTransactionRequestStatusJsonV510(TransactionRequestStatus.COMPLETED.toString),
PostTransactionRequestStatusJsonV510(TransactionRequestStatus.COMPLETED.toString),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
InvalidJsonFormat,
@ -4410,7 +4410,7 @@ trait APIMethods510 {
EmptyBody,
accountsMinimalJson400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserNotFoundByUserId,
UnknownError
),
@ -4471,7 +4471,7 @@ trait APIMethods510 {
|""".stripMargin,
EmptyBody,
moderatedCoreAccountJsonV400,
List($UserNotLoggedIn, $BankAccountNotFound,UnknownError),
List($AuthenticatedUserIsRequired, $BankAccountNotFound,UnknownError),
apiTagAccount :: apiTagPSD2AIS :: apiTagPsd2 :: Nil
)
lazy val getCoreAccountByIdThroughView : OBPEndpoint = {
@ -4500,7 +4500,7 @@ trait APIMethods510 {
EmptyBody,
accountBalanceV400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
UserNoPermissionAccessView,
@ -4539,7 +4539,7 @@ trait APIMethods510 {
EmptyBody,
accountBalancesV400Json,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -4570,7 +4570,7 @@ trait APIMethods510 {
EmptyBody,
accountBalancesV400Json,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
UnknownError
),
@ -4625,7 +4625,7 @@ trait APIMethods510 {
postCounterpartyLimitV510,
counterpartyLimitV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4688,7 +4688,7 @@ trait APIMethods510 {
postCounterpartyLimitV510,
counterpartyLimitV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4740,7 +4740,7 @@ trait APIMethods510 {
EmptyBody,
counterpartyLimitV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4779,7 +4779,7 @@ trait APIMethods510 {
EmptyBody,
counterpartyLimitStatusV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4933,7 +4933,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -4986,7 +4986,7 @@ trait APIMethods510 {
createCustomViewJson,
customViewJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -5044,7 +5044,7 @@ trait APIMethods510 {
updateCustomViewJson,
customViewJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -5120,7 +5120,7 @@ trait APIMethods510 {
EmptyBody,
customViewJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -5162,7 +5162,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -5322,7 +5322,7 @@ trait APIMethods510 {
""".stripMargin,
regulatedEntityAttributeRequestJsonV510,
regulatedEntityAttributeResponseJsonV510,
List($UserNotLoggedIn, InvalidJsonFormat, UnknownError),
List($AuthenticatedUserIsRequired, InvalidJsonFormat, UnknownError),
List(apiTagDirectory, apiTagApi),
Some(List(canCreateRegulatedEntityAttribute))
)
@ -5372,7 +5372,7 @@ trait APIMethods510 {
""".stripMargin,
EmptyBody,
EmptyBody,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
List(apiTagDirectory, apiTagApi),
Some(List(canDeleteRegulatedEntityAttribute))
)
@ -5405,7 +5405,7 @@ trait APIMethods510 {
""".stripMargin,
EmptyBody,
regulatedEntityAttributeResponseJsonV510,
List($UserNotLoggedIn,UnknownError),
List($AuthenticatedUserIsRequired,UnknownError),
List(apiTagDirectory, apiTagApi),
Some(List(canGetRegulatedEntityAttribute))
)
@ -5438,7 +5438,7 @@ trait APIMethods510 {
""".stripMargin,
EmptyBody,
regulatedEntityAttributesJsonV510,
List($UserNotLoggedIn, UnknownError),
List($AuthenticatedUserIsRequired, UnknownError),
List(apiTagDirectory, apiTagApi),
Some(List(canGetRegulatedEntityAttributes))
)
@ -5471,7 +5471,7 @@ trait APIMethods510 {
""".stripMargin,
regulatedEntityAttributeRequestJsonV510,
regulatedEntityAttributeResponseJsonV510,
List($UserNotLoggedIn, InvalidJsonFormat, UnknownError),
List($AuthenticatedUserIsRequired, InvalidJsonFormat, UnknownError),
List(apiTagDirectory, apiTagApi),
Some(List(canUpdateRegulatedEntityAttribute))
)
@ -5521,7 +5521,7 @@ trait APIMethods510 {
bankAccountBalanceRequestJsonV510,
bankAccountBalanceResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5571,7 +5571,7 @@ trait APIMethods510 {
EmptyBody,
bankAccountBalanceResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5609,7 +5609,7 @@ trait APIMethods510 {
EmptyBody,
bankAccountBalancesJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5647,7 +5647,7 @@ trait APIMethods510 {
bankAccountBalanceRequestJsonV510,
bankAccountBalanceResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5701,7 +5701,7 @@ trait APIMethods510 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5803,7 +5803,7 @@ trait APIMethods510 {
createViewPermissionJson,
entitlementJSON,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
IncorrectRoleName,
EntitlementAlreadyExists,
@ -5847,7 +5847,7 @@ trait APIMethods510 {
""".stripMargin,
EmptyBody,
EmptyBody,
List(UserNotLoggedIn, UserHasMissingRoles, UnknownError),
List(AuthenticatedUserIsRequired, UserHasMissingRoles, UnknownError),
List(apiTagSystemView),
Some(List(canDeleteSystemViewPermission))
)

View File

@ -10,7 +10,7 @@ import code.api.util.APIUtil._
import code.api.util.ApiRole
import code.api.util.ApiRole._
import code.api.util.ApiTag._
import code.api.util.ErrorMessages.{$UserNotLoggedIn, InvalidDateFormat, InvalidJsonFormat, UnknownError, DynamicEntityOperationNotAllowed, _}
import code.api.util.ErrorMessages.{$AuthenticatedUserIsRequired, InvalidDateFormat, InvalidJsonFormat, UnknownError, DynamicEntityOperationNotAllowed, _}
import code.api.util.FutureUtil.EndpointContext
import code.api.util.Glossary
import code.api.util.NewStyle.HttpCode
@ -48,7 +48,7 @@ import code.dynamicEntity.DynamicEntityCommons
import code.DynamicData.{DynamicData, DynamicDataProvider}
import com.github.dwickern.macros.NameOf.nameOf
import com.openbankproject.commons.ExecutionContext.Implicits.global
import com.openbankproject.commons.model.{CustomerAttribute, _}
import com.openbankproject.commons.model._
import com.openbankproject.commons.model.enums.DynamicEntityOperation._
import com.openbankproject.commons.model.enums.UserAttributeType
import com.openbankproject.commons.util.{ApiVersion, ScannedApiVersion}
@ -137,7 +137,7 @@ trait APIMethods600 {
transactionRequestBodyHoldJsonV600,
transactionRequestWithChargeJSON400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
InsufficientAuthorisationToCreateTransactionRequest,
@ -176,7 +176,7 @@ trait APIMethods600 {
EmptyBody,
moderatedCoreAccountsJsonV300,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
$UserNoPermissionAccessView,
@ -248,7 +248,7 @@ trait APIMethods600 {
EmptyBody,
redisCallCountersJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
@ -289,7 +289,7 @@ trait APIMethods600 {
callLimitPostJsonV600,
callLimitJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
@ -359,7 +359,7 @@ trait APIMethods600 {
callLimitPostJsonV400,
callLimitPostJsonV400,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
InvalidJsonFormat,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
@ -419,7 +419,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
UserHasMissingRoles,
@ -480,7 +480,7 @@ trait APIMethods600 {
EmptyBody,
activeRateLimitsJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
UserHasMissingRoles,
@ -531,7 +531,7 @@ trait APIMethods600 {
EmptyBody,
activeRateLimitsJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidConsumerId,
ConsumerNotFoundByConsumerId,
UserHasMissingRoles,
@ -581,7 +581,7 @@ trait APIMethods600 {
call_counters = redisCallCountersJsonV600
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidConsumerCredentials,
UnknownError
@ -618,7 +618,7 @@ trait APIMethods600 {
),
List(
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -694,7 +694,7 @@ trait APIMethods600 {
global_prefix = "obp_dev_"
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -771,7 +771,7 @@ trait APIMethods600 {
redis_available = true
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -890,7 +890,7 @@ trait APIMethods600 {
total_issues = 1
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -986,7 +986,7 @@ trait APIMethods600 {
)
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1063,7 +1063,7 @@ trait APIMethods600 {
""".stripMargin,
EmptyBody,
userJsonV300,
List(UserNotLoggedIn, UnknownError),
List(AuthenticatedUserIsRequired, UnknownError),
List(apiTagUser))
lazy val getCurrentUser: OBPEndpoint = {
@ -1128,7 +1128,7 @@ trait APIMethods600 {
EmptyBody,
usersInfoJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1169,7 +1169,7 @@ trait APIMethods600 {
EmptyBody,
userInfoJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserNotFoundByUserId,
UnknownError
@ -1232,7 +1232,7 @@ trait APIMethods600 {
EmptyBody,
migrationScriptLogsJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1305,7 +1305,7 @@ trait APIMethods600 {
)
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1375,7 +1375,7 @@ trait APIMethods600 {
transactionRequestBodyCardanoJsonV600,
transactionRequestWithChargeJSON400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
InsufficientAuthorisationToCreateTransactionRequest,
@ -1415,7 +1415,7 @@ trait APIMethods600 {
transactionRequestBodyEthereumJsonV600,
transactionRequestWithChargeJSON400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
InsufficientAuthorisationToCreateTransactionRequest,
@ -1454,7 +1454,7 @@ trait APIMethods600 {
transactionRequestBodyEthSendRawTransactionJsonV600,
transactionRequestWithChargeJSON400,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
$BankAccountNotFound,
InsufficientAuthorisationToCreateTransactionRequest,
@ -1501,7 +1501,7 @@ trait APIMethods600 {
bankJson600,
List(
InvalidJsonFormat,
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InsufficientAuthorisationToCreateBank,
UnknownError
),
@ -1598,7 +1598,7 @@ trait APIMethods600 {
EmptyBody,
JSONFactory600.createProvidersJson(List("http://127.0.0.1:8080", "OBP", "google.com")),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1672,7 +1672,7 @@ trait APIMethods600 {
EmptyBody,
ConnectorMethodNamesJsonV600(List("getBank", "getBanks", "getUser", "getAccount", "makePayment", "getTransactions")),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -1839,7 +1839,7 @@ trait APIMethods600 {
postCustomerJsonV600,
customerJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
$BankNotFound,
InvalidJsonFormat,
InvalidJsonContent,
@ -1956,7 +1956,7 @@ trait APIMethods600 {
EmptyBody,
customerJSONsV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -1998,7 +1998,7 @@ trait APIMethods600 {
PostCustomerLegalNameJsonV510(legal_name = "John Smith"),
customerJSONsV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -2048,7 +2048,7 @@ trait APIMethods600 {
EmptyBody,
customerJSONsV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -2088,7 +2088,7 @@ trait APIMethods600 {
EmptyBody,
customerWithAttributesJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserCustomerLinksNotFoundForUser,
UnknownError
@ -2130,7 +2130,7 @@ trait APIMethods600 {
postCustomerNumberJsonV310,
customerWithAttributesJsonV600,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserCustomerLinksNotFoundForUser,
UnknownError
),
@ -2261,7 +2261,7 @@ trait APIMethods600 {
EmptyBody,
metricsJsonV510,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2395,7 +2395,7 @@ trait APIMethods600 {
EmptyBody,
aggregateMetricsJSONV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2636,7 +2636,7 @@ trait APIMethods600 {
is_enabled = true
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -2713,7 +2713,7 @@ trait APIMethods600 {
is_enabled = true
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2784,7 +2784,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -2873,7 +2873,7 @@ trait APIMethods600 {
is_enabled = true
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -3081,7 +3081,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
EntitlementCannotBeDeleted,
UnknownError
@ -3148,7 +3148,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3200,7 +3200,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3278,7 +3278,7 @@ trait APIMethods600 {
entitlements_skipped = List("CanCreateTransaction")
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -3391,7 +3391,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3488,7 +3488,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3559,7 +3559,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3643,7 +3643,7 @@ trait APIMethods600 {
)
)),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3704,7 +3704,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
SystemViewNotFound,
UnknownError
@ -3766,7 +3766,7 @@ trait APIMethods600 {
// )
// ),
// List(
// UserNotLoggedIn,
// AuthenticatedUserIsRequired,
// UserHasMissingRoles,
// SystemViewNotFound,
// UnknownError
@ -3839,7 +3839,7 @@ trait APIMethods600 {
),
List(
InvalidJsonFormat,
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
SystemViewNotFound,
SystemViewCannotBePublicError,
@ -3897,7 +3897,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -3980,7 +3980,7 @@ trait APIMethods600 {
createViewJsonV300,
viewJsonV300,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
InvalidCustomViewFormat,
@ -4031,7 +4031,7 @@ trait APIMethods600 {
EmptyBody,
ViewsJsonV500(List()),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4089,7 +4089,7 @@ trait APIMethods600 {
"https://api.example.com/user_mgt/reset_password/QOL1CPNJPCZ4BRMPX3Z01DPOX1HMGU3L"
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4421,7 +4421,7 @@ trait APIMethods600 {
WebUiPropsPutJsonV600("https://apiexplorer.openbankproject.com"),
WebUiPropsCommons("webui_api_explorer_url", "https://apiexplorer.openbankproject.com", Some("some-web-ui-props-id")),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
InvalidWebUiProps,
@ -4491,7 +4491,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidWebUiProps,
UnknownError
@ -4563,7 +4563,7 @@ trait APIMethods600 {
List(dynamicEntityResponseBodyExample)
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4639,7 +4639,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4764,7 +4764,7 @@ trait APIMethods600 {
updated_by_user_id = "user123"
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -4841,7 +4841,7 @@ trait APIMethods600 {
updated_by_user_id = "user123"
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4899,7 +4899,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -4968,7 +4968,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5026,7 +5026,7 @@ trait APIMethods600 {
updated_by_user_id = "user456"
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5092,7 +5092,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5193,7 +5193,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5446,7 +5446,7 @@ trait APIMethods600 {
)
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
UnknownError
),
@ -5513,7 +5513,7 @@ trait APIMethods600 {
message = "ABAC rule code is valid"
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5610,7 +5610,7 @@ trait APIMethods600 {
result = true
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5710,7 +5710,7 @@ trait APIMethods600 {
result = true
),
List(
UserNotLoggedIn,
AuthenticatedUserIsRequired,
UserHasMissingRoles,
InvalidJsonFormat,
UnknownError
@ -5808,7 +5808,7 @@ trait APIMethods600 {
),
userAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserNotFoundByUserId,
InvalidJsonFormat,
@ -5866,7 +5866,7 @@ trait APIMethods600 {
user_attributes = List(userAttributeResponseJsonV510)
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserNotFoundByUserId,
UnknownError
@ -5903,7 +5903,7 @@ trait APIMethods600 {
EmptyBody,
userAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserNotFoundByUserId,
UserAttributeNotFound,
@ -5950,7 +5950,7 @@ trait APIMethods600 {
),
userAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserNotFoundByUserId,
UserAttributeNotFound,
@ -6011,7 +6011,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserHasMissingRoles,
UserNotFoundByUserId,
UserAttributeNotFound,
@ -6075,7 +6075,7 @@ trait APIMethods600 {
),
userAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
InvalidJsonFormat,
UnknownError
),
@ -6129,7 +6129,7 @@ trait APIMethods600 {
user_attributes = List(userAttributeResponseJsonV510)
),
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UnknownError
),
List(apiTagUser, apiTagUserAttribute, apiTagAttribute),
@ -6162,7 +6162,7 @@ trait APIMethods600 {
EmptyBody,
userAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserAttributeNotFound,
UnknownError
),
@ -6205,7 +6205,7 @@ trait APIMethods600 {
),
userAttributeResponseJsonV510,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserAttributeNotFound,
InvalidJsonFormat,
UnknownError
@ -6262,7 +6262,7 @@ trait APIMethods600 {
EmptyBody,
EmptyBody,
List(
$UserNotLoggedIn,
$AuthenticatedUserIsRequired,
UserAttributeNotFound,
UnknownError
),

View File

@ -442,7 +442,7 @@ object LocalMappedConnector extends Connector with MdcLoggable {
hashOfSuppliedAnswer: String,
callContext: Option[CallContext]
): OBPReturnType[Box[ChallengeTrait]] = Future {
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$UserNotLoggedIn Can not find the userId here."))
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$AuthenticatedUserIsRequired Can not find the userId here."))
(Challenges.ChallengeProvider.vend.validateChallenge(challengeId, hashOfSuppliedAnswer, userId), callContext)
}
override def validateChallengeAnswerC3(
@ -453,7 +453,7 @@ object LocalMappedConnector extends Connector with MdcLoggable {
hashOfSuppliedAnswer: String,
callContext: Option[CallContext]
) : OBPReturnType[Box[ChallengeTrait]] = Future {
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$UserNotLoggedIn Can not find the userId here."))
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$AuthenticatedUserIsRequired Can not find the userId here."))
(Challenges.ChallengeProvider.vend.validateChallenge(challengeId, hashOfSuppliedAnswer, userId), callContext)
}
@ -466,7 +466,7 @@ object LocalMappedConnector extends Connector with MdcLoggable {
suppliedAnswerType: SuppliedAnswerType.Value,
callContext: Option[CallContext]
): OBPReturnType[Box[ChallengeTrait]] = Future {
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$UserNotLoggedIn Can not find the userId here."))
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$AuthenticatedUserIsRequired Can not find the userId here."))
(Challenges.ChallengeProvider.vend.validateChallenge(challengeId, suppliedAnswer, userId), callContext)
}
@ -479,7 +479,7 @@ object LocalMappedConnector extends Connector with MdcLoggable {
suppliedAnswerType: SuppliedAnswerType.Value,
callContext: Option[CallContext]
): OBPReturnType[Box[ChallengeTrait]] = Future {
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$UserNotLoggedIn Can not find the userId here."))
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$AuthenticatedUserIsRequired Can not find the userId here."))
(Challenges.ChallengeProvider.vend.validateChallenge(challengeId, suppliedAnswer, userId), callContext)
}
@ -497,14 +497,14 @@ object LocalMappedConnector extends Connector with MdcLoggable {
override def validateChallengeAnswerV2(challengeId: String, suppliedAnswer: String, suppliedAnswerType:SuppliedAnswerType, callContext: Option[CallContext]): OBPReturnType[Box[Boolean]] =
Future {
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$UserNotLoggedIn Can not find the userId here."))
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$AuthenticatedUserIsRequired Can not find the userId here."))
//In OBP, we only validateChallenge with SuppliedAnswerType.PLAN_TEXT,
(Full(Challenges.ChallengeProvider.vend.validateChallenge(challengeId, suppliedAnswer, userId).isDefined), callContext)
}
override def validateChallengeAnswer(challengeId: String, hashOfSuppliedAnswer: String, callContext: Option[CallContext]): OBPReturnType[Box[Boolean]] =
Future {
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$UserNotLoggedIn Can not find the userId here."))
val userId = callContext.map(_.user.map(_.userId).openOrThrowException(s"$AuthenticatedUserIsRequired Can not find the userId here."))
(Full(Challenges.ChallengeProvider.vend.validateChallenge(challengeId, hashOfSuppliedAnswer, userId).isDefined), callContext)
}

View File

@ -123,7 +123,7 @@ class ModeratedTransactionMetadata(
*/
def deleteTag(tagId : String, user: Option[User], bankAccount : BankAccount, view: View, callContext: Option[CallContext]) : Box[Unit] = {
for {
u <- Box(user) ?~ { UserNotLoggedIn}
u <- Box(user) ?~ { AuthenticatedUserIsRequired}
tagList <- Box(tags) ?~ { s"$NoViewPermission can_delete_tag. " }
tag <- Box(tagList.find(tag => tag.id_ == tagId)) ?~ {"Tag with id " + tagId + "not found for this transaction"}
deleteFunc <- if(tag.postedBy == user||view.allowed_actions.exists(_ == CAN_DELETE_TAG))
@ -140,7 +140,7 @@ class ModeratedTransactionMetadata(
*/
def deleteImage(imageId : String, user: Option[User], bankAccount : BankAccount, view: View, callContext: Option[CallContext]) : Box[Unit] = {
for {
u <- Box(user) ?~ { UserNotLoggedIn}
u <- Box(user) ?~ { AuthenticatedUserIsRequired}
imageList <- Box(images) ?~ { s"$NoViewPermission can_delete_image." }
image <- Box(imageList.find(image => image.id_ == imageId)) ?~ {"Image with id " + imageId + "not found for this transaction"}
deleteFunc <- if(image.postedBy == user || view.allowed_actions.exists(_ ==CAN_DELETE_IMAGE))
@ -154,7 +154,7 @@ class ModeratedTransactionMetadata(
def deleteComment(commentId: String, user: Option[User],bankAccount: BankAccount, view: View, callContext: Option[CallContext]) : Box[Unit] = {
for {
u <- Box(user) ?~ { UserNotLoggedIn}
u <- Box(user) ?~ { AuthenticatedUserIsRequired}
commentList <- Box(comments) ?~ { s"$NoViewPermission can_delete_comment." }
comment <- Box(commentList.find(comment => comment.id_ == commentId)) ?~ {"Comment with id "+commentId+" not found for this transaction"}
deleteFunc <- if(comment.postedBy == user || view.allowed_actions.exists(_ ==CAN_DELETE_COMMENT))
@ -168,7 +168,7 @@ class ModeratedTransactionMetadata(
def deleteWhereTag(viewId: ViewId, user: Option[User],bankAccount: BankAccount, view: View, callContext: Option[CallContext]) : Box[Boolean] = {
for {
u <- Box(user) ?~ { UserNotLoggedIn}
u <- Box(user) ?~ { AuthenticatedUserIsRequired}
whereTagOption <- Box(whereTag) ?~ { s"$NoViewPermission can_delete_where_tag. Current ViewId($viewId)" }
whereTag <- Box(whereTagOption) ?~ {"there is no tag to delete"}
deleteFunc <- if(whereTag.postedBy == user || view.allowed_actions.exists(_ ==CAN_DELETE_WHERE_TAG))

View File

@ -160,7 +160,7 @@ class BerlinGroupConsent extends MdcLoggable with RestHelper with APIMethods510
// Get all accounts held by the current user
val userAccounts: Set[BankIdAccountId] =
AccountHolders.accountHolders.vend.getAccountsHeldByUser(AuthUser.currentUser.flatMap(_.user.foreign).openOrThrowException(ErrorMessages.UserNotLoggedIn), Some(null)).toSet
AccountHolders.accountHolders.vend.getAccountsHeldByUser(AuthUser.currentUser.flatMap(_.user.foreign).openOrThrowException(ErrorMessages.AuthenticatedUserIsRequired), Some(null)).toSet
val userIbans: Set[String] = userAccounts.flatMap { acc =>
BankAccountRouting.find(
By(BankAccountRouting.BankId, acc.bankId.value),
@ -429,7 +429,7 @@ class BerlinGroupConsent extends MdcLoggable with RestHelper with APIMethods510
}
private def updateConsentUser(consent: MappedConsent): Box[MappedConsent] = {
val loggedInUser = AuthUser.currentUser.flatMap(_.user.foreign).openOrThrowException(ErrorMessages.UserNotLoggedIn)
val loggedInUser = AuthUser.currentUser.flatMap(_.user.foreign).openOrThrowException(ErrorMessages.AuthenticatedUserIsRequired)
Consents.consentProvider.vend.updateConsentUser(consent.consentId, loggedInUser)
val jwt = Consent.updateUserIdOfBerlinGroupConsentJWT(loggedInUser.userId, consent, None).openOrThrowException(ErrorMessages.InvalidConnectorResponse)
Consents.consentProvider.vend.setJsonWebToken(consent.consentId, jwt)

View File

@ -406,7 +406,7 @@ class WebUI extends MdcLoggable{
val htmlDescription = if (APIUtil.glossaryDocsRequireRole){
val userId = AuthUser.getCurrentResourceUserUserId
if (userId == ""){
s"<h1>${ErrorMessages.UserNotLoggedIn}</h1>"
s"<h1>${ErrorMessages.AuthenticatedUserIsRequired}</h1>"
} else{
if(APIUtil.hasEntitlement("", userId, ApiRole.canReadGlossary)) {
PegdownOptions.convertPegdownToHtmlTweaked(propsValue)

View File

@ -3,7 +3,7 @@ package code.api.ResourceDocs1_4_0
import code.api.ResourceDocs1_4_0.ResourceDocs140.ImplementationsResourceDocs
import code.api.berlin.group.ConstantsBG
import code.api.util.APIUtil.OAuth._
import code.api.util.ErrorMessages.{InvalidApiCollectionIdParameter, UserHasMissingRoles, UserNotLoggedIn}
import code.api.util.ErrorMessages.{InvalidApiCollectionIdParameter, UserHasMissingRoles, AuthenticatedUserIsRequired}
import code.api.util.{ApiRole, CustomJsonFormats}
import code.api.v1_4_0.JSONFactory1_4_0.ResourceDocsJson
import code.setup.{DefaultUsers, PropsReset}
@ -394,7 +394,7 @@ class ResourceDocsTest extends ResourceDocsV140ServerSetup with PropsReset with
And("We should get 200 and the response can be extract to case classes")
val responseDocs = responseGetObp.body.extract[ResourceDocsJson]
responseGetObp.code should equal(401)
responseGetObp.toString contains(UserNotLoggedIn) should be (true)
responseGetObp.toString contains(AuthenticatedUserIsRequired) should be (true)
}
scenario(s"We will test ${ApiEndpoint1.name} Api -v4.0.0 - resource_docs_requires_role props- login in user", ApiEndpoint1, VersionOfApi) {
@ -669,7 +669,7 @@ class ResourceDocsTest extends ResourceDocsV140ServerSetup with PropsReset with
And("We should get 200 and the response can be extract to case classes")
val responseDocs = responseGetObp.body.extract[ResourceDocsJson]
responseGetObp.code should equal(401)
responseGetObp.toString contains(UserNotLoggedIn) should be (true)
responseGetObp.toString contains(AuthenticatedUserIsRequired) should be (true)
}
scenario(s"We will test ${ApiEndpoint2.name} Api -v4.0.0 - resource_docs_requires_role props- login in user", ApiEndpoint1, VersionOfApi) {

View File

@ -68,7 +68,7 @@ class AccountInformationServiceAISApiTest extends BerlinGroupServerSetupV1_3 wit
Then("We should get a 401 ")
response.code should equal(401)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(UserNotLoggedIn)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(AuthenticatedUserIsRequired)
}
scenario("Authentication User, test failed", BerlinGroupV1_3, getAccountList) {
@ -88,7 +88,7 @@ class AccountInformationServiceAISApiTest extends BerlinGroupServerSetupV1_3 wit
Then("We should get a 401 ")
response.code should equal(401)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(UserNotLoggedIn)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(AuthenticatedUserIsRequired)
}
scenario("Authentication User, test succeed", BerlinGroupV1_3, getAccountDetails) {

View File

@ -35,7 +35,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val response: APIResponse = makePostRequest(requestPost, postJson)
Then("We should get a 401 ")
response.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}
@ -86,7 +86,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401 ")
responseGet.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
responseGet.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}
@ -98,7 +98,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401 ")
responseGet.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
responseGet.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}
@ -110,7 +110,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val response = makeDeleteRequest(request)
Then("We should get a 401 ")
response.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}
@ -123,7 +123,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val response = makePostRequest(request, postJson)
Then("We should get a 401 ")
response.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}
@ -135,7 +135,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401 ")
responseGet.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
responseGet.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}
@ -147,7 +147,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401 ")
responseGet.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
responseGet.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}
@ -160,7 +160,7 @@ class SigningBasketServiceSBSApiTest extends BerlinGroupServerSetupV1_3 with Def
val response = makePutRequest(request, putJson)
Then("We should get a 401 ")
response.code should equal(401)
val error = s"$UserNotLoggedIn"
val error = s"$AuthenticatedUserIsRequired"
And("error should be " + error)
response.body.extract[ErrorMessagesBG].tppMessages.head.text should startWith(error)
}

View File

@ -29,8 +29,8 @@ class EntitlementTests extends V200ServerSetup with DefaultUsers {
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401")
responseGet.code should equal(401)
And("We should get a message: " + ErrorMessages.UserNotLoggedIn)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.UserNotLoggedIn)
And("We should get a message: " + ErrorMessages.AuthenticatedUserIsRequired)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.AuthenticatedUserIsRequired)
}

View File

@ -34,8 +34,8 @@ class EntitlementTests extends V210ServerSetup with DefaultUsers {
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401")
responseGet.code should equal(401)
And("We should get a message: " + ErrorMessages.UserNotLoggedIn)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.UserNotLoggedIn)
And("We should get a message: " + ErrorMessages.AuthenticatedUserIsRequired)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.AuthenticatedUserIsRequired)
}
@ -56,8 +56,8 @@ class EntitlementTests extends V210ServerSetup with DefaultUsers {
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401")
responseGet.code should equal(401)
And("We should get a message: " + ErrorMessages.UserNotLoggedIn)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.UserNotLoggedIn)
And("We should get a message: " + ErrorMessages.AuthenticatedUserIsRequired)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.AuthenticatedUserIsRequired)
}

View File

@ -307,7 +307,7 @@ class TransactionRequestsTest extends V210ServerSetup with DefaultUsers {
response.code should equal(401)
Then("We should have the error message")
response.body.extract[ErrorMessage].message should startWith(ErrorMessages.UserNotLoggedIn)
response.body.extract[ErrorMessage].message should startWith(ErrorMessages.AuthenticatedUserIsRequired)
}
}

View File

@ -19,8 +19,8 @@ class UserTests extends V210ServerSetup {
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401")
responseGet.code should equal(401)
And("We should get a message: " + ErrorMessages.UserNotLoggedIn)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.UserNotLoggedIn)
And("We should get a message: " + ErrorMessages.AuthenticatedUserIsRequired)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.AuthenticatedUserIsRequired)
}

View File

@ -41,7 +41,7 @@ class EntitlementRequestsTest extends V300ServerSetup with DefaultUsers {
val response300 = makePostRequest(request300, postJson)
Then("We should get a 401 and error message")
response300.code should equal(401)
response300.body.toString contains UserNotLoggedIn should be (true)
response300.body.toString contains AuthenticatedUserIsRequired should be (true)
}
scenario("create entitlement request - non existing bank", VersionOfApi, ApiEndpoint1) {

View File

@ -26,7 +26,7 @@ TESOBE (http://www.tesobe.com/)
package code.api.v3_0_0
import code.api.util.ApiRole.canGetAdapterInfoAtOneBank
import code.api.util.ErrorMessages.{UserHasMissingRoles, UserNotLoggedIn}
import code.api.util.ErrorMessages.{UserHasMissingRoles, AuthenticatedUserIsRequired}
import code.api.v3_0_0.OBPAPI3_0_0.Implementations3_0_0
import code.api.util.APIUtil.OAuth._
import code.entitlement.Entitlement
@ -50,14 +50,14 @@ class GetAdapterInfoTest extends V300ServerSetup with DefaultUsers {
feature("Get Adapter Info v3.1.0")
{
scenario(s"$UserNotLoggedIn error case", ApiEndpoint, VersionOfApi) {
scenario(s"$AuthenticatedUserIsRequired error case", ApiEndpoint, VersionOfApi) {
When("We make a request v3.1.0")
val request310 = (v3_0Request /"banks"/testBankId1.value/ "adapter").GET
val response310 = makeGetRequest(request310)
Then("We should get a 401")
response310.code should equal(401)
And("error should be " + UserNotLoggedIn)
response310.body.extract[ErrorMessage].message should equal (UserNotLoggedIn)
And("error should be " + AuthenticatedUserIsRequired)
response310.body.extract[ErrorMessage].message should equal (AuthenticatedUserIsRequired)
}
scenario(s"$UserHasMissingRoles error case", ApiEndpoint, VersionOfApi) {
When("We make a request v3.1.0")

View File

@ -42,8 +42,8 @@ class UserTest extends V300ServerSetup with DefaultUsers {
val responseGet = makeGetRequest(requestGet)
Then("We should get a 401")
responseGet.code should equal(401)
And("We should get a message: " + ErrorMessages.UserNotLoggedIn)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.UserNotLoggedIn)
And("We should get a message: " + ErrorMessages.AuthenticatedUserIsRequired)
responseGet.body.extract[ErrorMessage].message should equal (ErrorMessages.AuthenticatedUserIsRequired)
}

View File

@ -120,8 +120,8 @@ class AccountAttributeTest extends V310ServerSetup {
val response310 = makePostRequest(request310, write(postAccountAttributeJson))
Then("We should get a 401")
response310.code should equal(401)
And("error should be " + UserNotLoggedIn)
response310.body.extract[ErrorMessage].message should equal (UserNotLoggedIn)
And("error should be " + AuthenticatedUserIsRequired)
response310.body.extract[ErrorMessage].message should equal (AuthenticatedUserIsRequired)
}
scenario("We will call the Create endpoint without a proper role", ApiEndpoint1, VersionOfApi) {
When(s"We make a request $VersionOfApi")
@ -155,8 +155,8 @@ class AccountAttributeTest extends V310ServerSetup {
val response310 = makePutRequest(request310, write(putAccountAttributeJson))
Then("We should get a 401")
response310.code should equal(401)
And("error should be " + UserNotLoggedIn)
response310.body.extract[ErrorMessage].message should equal (UserNotLoggedIn)
And("error should be " + AuthenticatedUserIsRequired)
response310.body.extract[ErrorMessage].message should equal (AuthenticatedUserIsRequired)
}
scenario("We will call the Update endpoint without a proper role", ApiEndpoint2, VersionOfApi) {
When(s"We make a request $VersionOfApi")

View File

@ -6,7 +6,7 @@ import code.api.ResourceDocs1_4_0.SwaggerDefinitionsJSON
import code.api.ResourceDocs1_4_0.SwaggerDefinitionsJSON.updateAccountRequestJsonV310
import code.api.util.APIUtil.OAuth._
import code.api.util.APIUtil.extractErrorMessageCode
import code.api.util.ErrorMessages.{UserHasMissingRoles, UserNotLoggedIn}
import code.api.util.ErrorMessages.{UserHasMissingRoles, AuthenticatedUserIsRequired}
import code.api.util.ApiRole
import code.api.v2_0_0.BasicAccountJSON
import code.api.v2_2_0.CreateAccountJSONV220
@ -187,8 +187,8 @@ class AccountTest extends V310ServerSetup with DefaultUsers {
val response310 = makePutRequest(request310, write(putCreateAccountJSONV310))
Then("We should get a 401")
response310.code should equal(401)
And("error should be " + UserNotLoggedIn)
response310.body.extract[ErrorMessage].message should equal (UserNotLoggedIn)
And("error should be " + AuthenticatedUserIsRequired)
response310.body.extract[ErrorMessage].message should equal (AuthenticatedUserIsRequired)
}
}
feature("Create Account v3.1.0 - Authorized access") {

View File

@ -60,7 +60,7 @@ class CardTest extends V310ServerSetup with DefaultUsers {
val responseAnonymous = makePostRequest(requestAnonymous, write(properCardJson))
And(s"We should get 401 and get the authentication error")
responseAnonymous.code should equal(401)
responseAnonymous.body.toString contains(s"$UserNotLoggedIn") should be (true)
responseAnonymous.body.toString contains(s"$AuthenticatedUserIsRequired") should be (true)
Then(s"We call the authentication user, but totally wrong Json format.")

View File

@ -96,7 +96,7 @@ class ConsentTest extends V310ServerSetup {
val response400 = makePostRequest(request400, write(postConsentEmailJsonV310))
Then("We should get a 401")
response400.code should equal(401)
response400.body.extract[ErrorMessage].message should equal(UserNotLoggedIn)
response400.body.extract[ErrorMessage].message should equal(AuthenticatedUserIsRequired)
}
scenario("We will call the endpoint without user credentials-IMPLICIT", ApiEndpoint1, VersionOfApi) {
@ -105,7 +105,7 @@ class ConsentTest extends V310ServerSetup {
val response400 = makePostRequest(request400, write(postConsentImplicitJsonV310))
Then("We should get a 401")
response400.code should equal(401)
response400.body.extract[ErrorMessage].message should equal(UserNotLoggedIn)
response400.body.extract[ErrorMessage].message should equal(AuthenticatedUserIsRequired)
}
scenario("We will call the endpoint with user credentials but wrong SCA method", ApiEndpoint1, VersionOfApi) {

Some files were not shown because too many files have changed in this diff Show More