Submit file for approval as profile document

Updated on 30 Apr 2020

Description

A User or External Entity on behalf of a User with role permission PROFILE_DOCUMENTS_OWNERwill go through all steps of “Get profile documents, last of each type” Use Case, and then send a request to Endpoint “Submit file for approval as profile document”.

Actors

  1. External Entity that can interact with System Operator API acting as a registered System Operator User with permissions: PROFILE_DOCUMENTS_OWNER
  2. System Operator running “SDK.Finance” software and exposing the portfolio of financial APIs.

Preconditions

  1. The user must have a System Operator profile with sufficient access privileges.

Basic Flow

By default, this flow assumes that External Entity sends Requests to System Operator Endpoints, and System Operator sends back Responses to External Entity.

  1. Perform all steps of Use Case “Get profile documents, last of each type”.
  2. External Entity sends a request to Endpoint “Submit file for approval as a profile document”.

API endpoint: https://sdkfinance.app/api/ui/#!/Profile_-_documents_uploading/submitDocument

Parameters

Authorization – Authorization token

Request body example:



   "fileId":"string",

   "type":"string"

}
  1. System Operator returns result information to External Entity. (See Result example below)

Optional Flow with Web Browser UI

  1. Perform all steps of Use Case “Get profile documents, last of each type”.
  2. A user sends a request to Endpoint “Submit file for approval as profile document”.

API endpoint: https://sdkfinance.app/api/ui/#!/Profile_-_documents_uploading/submitDocument

Parameters

Authorization – Authorization token

Request body example:



   "fileId":"string",

   "type":"string"

}
  1. System Operator returns result information to User (See Result example below).

Post Conditions

The file is submitted.

Result example



   "document":{ 

      "id":"string",

      "file":{ 

         "id":"string",

         "ownerId":"string",

         "mediaType":"string",

         "name":"string",

         "url":"string",

         "md5":"string",

         "sha1":"string",

         "size":0,

         "used":false,

         "createdAt":"2018-07-25T12:12:33.903Z",

         "expiresAt":"2018-07-25T12:12:33.903Z",

         "tag":"string"

      },

      "type":"string",

      "label":"string",

      "status":"PENDING",

      "updatedAt":"2018-07-25T12:12:33.903Z"

   },

   "status":"ok",

   "message":"string"

}