API Explorer 936 endpoints

Create Bank Level Dynamic Resource Doc

POST /obp/v7.0.0/management/banks/BANK_ID/dynamic-resource-docs

OBPv4.0.0-createBankLevelDynamicResourceDoc Roles: CanCreateBankLevelDynamicResourceDoc(per bank) Dynamic-Resource-Doc

Create a Bank Level Dynamic Resource Doc.

The connector_method_body is URL-encoded format String

User Authentication is Required. The User must be logged in. The Application must also be authenticated.

URL Parameters:

BANK_ID: gh.29.uk

JSON request body fields (4)
description
Description of the object. Maximum length is 2000. It can be any characters here.
roles
CanCreateMyUser
summary
tags
Create-My-User
JSON response body fields (4)
description
Description of the object. Maximum length is 2000. It can be any characters here.
roles
CanCreateMyUser
summary
tags
Create-My-User
Example request body
{
  "request_url": "/my_user/MY_USER_ID",
  "success_response_body": {
    "my_user_id": "some_id_value",
    "name": "Jhon",
    "age": 12,
    "hobby": [
      "coding"
    ],
    "_optional_fields_": [
      "hobby"
    ]
  },
  "example_request_body": {
    "name": "Jhon",
    "age": 12,
    "hobby": [
      "coding"
    ],
    "_optional_fields_": [
      "hobby"
    ]
  },
  "programming_lang": "Scala",
  "bank_id": "gh.29.uk",
  "roles": "CanCreateMyUser",
  "summary": "Create My User",
  "error_response_bodies": "OBP-50000: Unknown Error.,OBP-20001: User not logged in. Authentication is required!,OBP-20006: User is missing one or more roles: ,OBP-10001: Incorrect json format.",
  "request_verb": "POST",
  "description": "Create one User",
  "tags": "Create-My-User",
  "method_body": "%20%20%20%20val%20Some(resourceDoc)%20%3D%20callContext.resourceDocument%0A%20%20%20%20val%20hasRequestBody%20%3D%20callContext.httpBody.exists(_.nonEmpty)%0A%0A%20%20%20%20%2F%2F%20get%20Path%20Parameters%2C%20example%3A%0A%20%20%20%20%2F%2F%20if%20the%20requestUrl%20of%20resourceDoc%20is%20%2Fhello%2Fbanks%2FBANK_ID%2Fworld%0A%20%20%20%20%2F%2F%20the%20request%20path%20is%20%2Fhello%2Fbanks%2Fbank_x%2Fworld%0A%20%20%20%20%2F%2FpathParams.get(%22BANK_ID%22)%20will%20get%20Option(%22bank_x%22)%20value%0A%0A%20%20%20%20val%20myUserId%20%3D%20pathParams(%22MY_USER_ID%22)%0A%0A%0A%20%20%20%20val%20requestEntity%20%3D%20callContext.httpBody.filter(_.nonEmpty)%20match%20%7B%0A%20%20%20%20%20%20case%20Some(rawBody)%20%3D%3E%0A%20%20%20%20%20%20%20%20try%20%7B%0A%20%20%20%20%20%20%20%20%20%20com.openbankproject.commons.util.JsonAliases.parse(rawBody).extract%5BRequestRootJsonClass%5D%0A%20%20%20%20%20%20%20%20%7D%20catch%20%7B%0A%20%20%20%20%20%20%20%20%20%20case%20e%3A%20MappingException%20%3D%3E%0A%20%20%20%20%20%20%20%20%20%20%20%20return%20errorResponse(s%22%24InvalidJsonFormat%20%24%7Be.msg%7D%22)%0A%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20case%20None%20%3D%3E%0A%20%20%20%20%20%20%20%20return%20errorResponse(s%22%24InvalidRequestPayload%20Current%20request%20has%20no%20payload%22)%0A%20%20%20%20%7D%0A%0A%0A%20%20%20%20%2F%2F%20please%20add%20business%20logic%20here%0A%20%20%20%20val%20responseBody%3AResponseRootJsonClass%20%3D%20ResponseRootJsonClass(s%22%24%7BmyUserId%7D_from_path%22%2C%20requestEntity.name%2C%20requestEntity.age%2C%20requestEntity.hobby)%0A%20%20%20%20Future.successful%20%7B%0A%20%20%20%20%20%20(responseBody%2C%20HttpCode.%60200%60(callContext.callContext))%0A%20%20%20%20%7D",
  "partial_function_name": "createUser"
}
Example success response
{
  "request_url": "/my_user/MY_USER_ID",
  "success_response_body": {
    "my_user_id": "some_id_value",
    "name": "Jhon",
    "age": 12,
    "hobby": [
      "coding"
    ],
    "_optional_fields_": [
      "hobby"
    ]
  },
  "example_request_body": {
    "name": "Jhon",
    "age": 12,
    "hobby": [
      "coding"
    ],
    "_optional_fields_": [
      "hobby"
    ]
  },
  "programming_lang": "Scala",
  "bank_id": "gh.29.uk",
  "roles": "CanCreateMyUser",
  "summary": "Create My User",
  "error_response_bodies": "OBP-50000: Unknown Error.,OBP-20001: User not logged in. Authentication is required!,OBP-20006: User is missing one or more roles: ,OBP-10001: Incorrect json format.",
  "request_verb": "POST",
  "description": "Create one User",
  "tags": "Create-My-User",
  "method_body": "%20%20%20%20val%20Some(resourceDoc)%20%3D%20callContext.resourceDocument%0A%20%20%20%20val%20hasRequestBody%20%3D%20callContext.httpBody.exists(_.nonEmpty)%0A%0A%20%20%20%20%2F%2F%20get%20Path%20Parameters%2C%20example%3A%0A%20%20%20%20%2F%2F%20if%20the%20requestUrl%20of%20resourceDoc%20is%20%2Fhello%2Fbanks%2FBANK_ID%2Fworld%0A%20%20%20%20%2F%2F%20the%20request%20path%20is%20%2Fhello%2Fbanks%2Fbank_x%2Fworld%0A%20%20%20%20%2F%2FpathParams.get(%22BANK_ID%22)%20will%20get%20Option(%22bank_x%22)%20value%0A%0A%20%20%20%20val%20myUserId%20%3D%20pathParams(%22MY_USER_ID%22)%0A%0A%0A%20%20%20%20val%20requestEntity%20%3D%20callContext.httpBody.filter(_.nonEmpty)%20match%20%7B%0A%20%20%20%20%20%20case%20Some(rawBody)%20%3D%3E%0A%20%20%20%20%20%20%20%20try%20%7B%0A%20%20%20%20%20%20%20%20%20%20com.openbankproject.commons.util.JsonAliases.parse(rawBody).extract%5BRequestRootJsonClass%5D%0A%20%20%20%20%20%20%20%20%7D%20catch%20%7B%0A%20%20%20%20%20%20%20%20%20%20case%20e%3A%20MappingException%20%3D%3E%0A%20%20%20%20%20%20%20%20%20%20%20%20return%20errorResponse(s%22%24InvalidJsonFormat%20%24%7Be.msg%7D%22)%0A%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20case%20None%20%3D%3E%0A%20%20%20%20%20%20%20%20return%20errorResponse(s%22%24InvalidRequestPayload%20Current%20request%20has%20no%20payload%22)%0A%20%20%20%20%7D%0A%0A%0A%20%20%20%20%2F%2F%20please%20add%20business%20logic%20here%0A%20%20%20%20val%20responseBody%3AResponseRootJsonClass%20%3D%20ResponseRootJsonClass(s%22%24%7BmyUserId%7D_from_path%22%2C%20requestEntity.name%2C%20requestEntity.age%2C%20requestEntity.hobby)%0A%20%20%20%20Future.successful%20%7B%0A%20%20%20%20%20%20(responseBody%2C%20HttpCode.%60200%60(callContext.callContext))%0A%20%20%20%20%7D",
  "dynamic_resource_doc_id": "vce035ca-9a0f-4bfa-b30b-9003aa467f51",
  "partial_function_name": "createUser"
}
Possible errors (6)
  • OBP-30001: Bank not found. Please specify a valid value for BANK_ID.
  • OBP-20001: User not logged in. Authentication is required!
  • OBP-20006: User is missing one or more roles:
  • OBP-10001: Incorrect json format.
  • OBP-09032: This would make a path ambiguous in its space. The Dynamic Entities and Dynamic Resource Docs of a space share one set of paths, which a Domain API can publish under its base path at any time, and a Domain API reads a hyphen in an entity name as an underscore, so a Dynamic Resource Doc's path may not start with a path variable, with my, public, community, openapi.json or openapi.yaml, or with the name of one of the space's Dynamic Entities in either spelling (like-this or like_this); a Dynamic Entity may not be named my, public, community, openapi.json or openapi.yaml, nor after the first segment of one of the space's Dynamic Resource Docs, nor so that it differs from another of the space's Dynamic Entities only by hyphens for underscores; and two Dynamic Resource Docs of one verb may not both match one request. Rename one of them:
  • OBP-50000: Unknown Error.
Implemented by OBPv4.0.0 createBankLevelDynamicResourceDoc Originally /obp/v4.0.0/management/banks/BANK_ID/dynamic-resource-docs