Integrations

Azure OAuth2

10min

Work in progress



You need first to go to the Azure Portal. From there, you will need to go through the following steps:

Select or Create a storage account

  1. In the search bar, search for the Storage accountCreate or select a Storage account:
Document image

Document image


2. Create a new app dedicated to you PROCESIO usage:

Search for the App Registration in the search bar and select or create a new app.

Document image


3. After the app is created, select the app and from the left side meniu, select API permissions and in the Azure Storage Permissions select user impersonation and add the permissison:

Document image

Document image


After you have the user impersonation permission also select the Grant admin consent for Default Directory:

Document image


3. Navigate to PROCESIO and create a OAuth2 credential:

Document image

  • For the URL enter: https://<AppName>.blob.core.windows.net/ ( Replace <AppName> with the name of the app created at step 2.
  • For the Scopes add : https://storage.azure.com/.default offline_access
  • In the Azure Portan navigate to the app overview:
Document image

  • Copy the Application (client) ID and paste it in the PROCESIO credential Client ID field.
  • For the client secretet, select the app created in Azure, on the left side meniu, navigate to Certificates & Secrets and create a new Client secret, then add it in the Client Secret field of the PROCESIO credential.
  • For the URLs, navigate to the app overview in Azure Portal and click on the Endpoints, from there the first 2 endpoints are required in the PROCESIO credential ( authorization and token v2)
Document image

  • Copy the OAuth Redirect URL from the PROCESIO credential and in the Azure Portal, select your app, navigate to Authentication, click on add a platform, select "web" and paste the OAuth URL.
Document image

Document image


4. Click Save and authorize, login with your azure account.

List blobs

The call API to list all files in the azure storage account:

url: ?comp=list

no query params

headers: x-ms-version 2023-11-03

Document image


Download file

The call API to download a file from the azure storage account:

The download file call api is similar to the list files, the only difference is the endpoint, where you have to specifiy the contaner and the name of the file you want to download. In the example below, the container name is fileupload, and the file is sample.pdf:

Document image

Document image


Upload File

Document image


headers:

x-ms-version 2023-11-03

x-ms-blob-type BlockBlob

body: binary file that you want to upload

Document image