{
  "name": "SOT Integration Examples",
  "version": "1",
  "items": [
    {
      "type": "folder",
      "name": "Multitenant Access Control",
      "filename": "Multitenant Access Control",
      "root": {
        "meta": {
          "name": "Multitenant Access Control"
        }
      },
      "items": [
        {
          "type": "folder",
          "name": "Access Management",
          "filename": "Access Management",
          "root": {
            "meta": {
              "name": "Access Management"
            }
          },
          "items": [
            {
              "type": "folder",
              "name": "PKCE Code flow",
              "filename": "PKCE Code flow",
              "root": {
                "meta": {
                  "name": "PKCE Code flow"
                }
              },
              "items": [
                {
                  "type": "http",
                  "name": "PKCE code flow to get user token",
                  "filename": "PKCE code flow to get user token.bru",
                  "seq": 1,
                  "request": {
                    "url": "{{base_url}}/iam/access-management/v1/openid-connect/userinfo",
                    "method": "GET",
                    "headers": [],
                    "params": [],
                    "body": {
                      "mode": "none",
                      "formUrlEncoded": [],
                      "multipartForm": [],
                      "file": []
                    },
                    "script": {},
                    "vars": {},
                    "assertions": [],
                    "tests": "",
                    "docs": "",
                    "auth": {
                      "mode": "oauth2",
                      "oauth2": {
                        "grantType": "authorization_code",
                        "callbackUrl": "{{redirect_uri}}",
                        "authorizationUrl": "{{base_url}}/iam/auth/realms/{{tenant_id}}/protocol/openid-connect/auth",
                        "accessTokenUrl": "{{base_url}}/iam/auth/realms/{{tenant_id}}/protocol/openid-connect/token",
                        "refreshTokenUrl": "",
                        "clientId": "{{client_id}}-frontend",
                        "clientSecret": "",
                        "scope": "openid",
                        "credentialsPlacement": "body",
                        "pkce": true,
                        "credentialsId": "credentials",
                        "tokenPlacement": "header",
                        "tokenHeaderPrefix": "Bearer",
                        "tokenQueryKey": "access_token",
                        "autoFetchToken": true,
                        "autoRefreshToken": false
                      }
                    }
                  }
                },
                {
                  "type": "http",
                  "name": "User Info",
                  "filename": "User Info.bru",
                  "seq": 2,
                  "request": {
                    "url": "{{base_url}}/iam/access-management/v1/openid-connect/userinfo",
                    "method": "GET",
                    "headers": [],
                    "params": [],
                    "body": {
                      "mode": "none",
                      "formUrlEncoded": [],
                      "multipartForm": [],
                      "file": []
                    },
                    "script": {},
                    "vars": {},
                    "assertions": [],
                    "tests": "",
                    "docs": "",
                    "auth": {
                      "mode": "inherit"
                    }
                  }
                },
                {
                  "type": "http",
                  "name": "Read the ACL -Access Control List- for the given user",
                  "filename": "Read the ACL -Access Control List- for the given user.bru",
                  "seq": 4,
                  "request": {
                    "url": "{{base_url}}/iam/access-management/v1/user/acl",
                    "method": "GET",
                    "headers": [],
                    "params": [],
                    "body": {
                      "mode": "none",
                      "formUrlEncoded": [],
                      "multipartForm": [],
                      "file": []
                    },
                    "script": {},
                    "vars": {},
                    "assertions": [],
                    "tests": "",
                    "docs": "",
                    "auth": {
                      "mode": "inherit"
                    }
                  }
                },
                {
                  "type": "http",
                  "name": "OpenID Introspect Endpoint",
                  "filename": "OpenID Introspect Endpoint.bru",
                  "seq": 3,
                  "request": {
                    "url": "{{base_url}}/iam/access-management/v1/openid-connect/introspect",
                    "method": "POST",
                    "headers": [],
                    "params": [],
                    "body": {
                      "mode": "formUrlEncoded",
                      "formUrlEncoded": [
                        {
                          "name": "token",
                          "value": "eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJiZGZlNlZrTkVwZjdsS0gyTHhIVTVLQnYwblQ5RUYyMjRoZ0RfemdOX3BvIn0.eyJleHAiOjE3NDIzMDM2NDksImlhdCI6MTc0MjMwMzM0OSwiYXV0aF90aW1lIjoxNzQyMzAzMzQ5LCJqdGkiOiI5NGQ4NzdlMy04NjVmLTQ0NDAtYTk1NC1hN2I2NGI4ZWZmN2IiLCJpc3MiOiJodHRwczovL3NpMHZtYzM0NTAuZGUuYm9zY2guY29tL2lhbS9hdXRoL3JlYWxtcy9mMTQzMGRkOC1kOWI4LTQ3MmYtYjIyZi02ZmJiNDk3OGYwYTQiLCJhdWQiOiJsc2lkZ2pnMml6dDFlbWVyemJiaWgwZTAiLCJzdWIiOiJjYmNkNWVkOC0xZGE1LTRmMzItODY3NS03NzE4MjYzYTA3ZDYiLCJ0eXAiOiJCZWFyZXIiLCJhenAiOiJsc2lkZ2pnMml6dDFlbWVyemJiaWgwZTAtZnJvbnRlbmQiLCJzaWQiOiI2MmY2ZTM2Yy00OGE4LTQ3ZTctYjE0Ny0yZmYxYzNmNjFkNWUiLCJhY3IiOiIxIiwic2NvcGUiOiJvcGVuaWQgTmV4ZWVkX0lBTSBwcm9maWxlIGVtYWlsIiwidG5hbWUiOiJFQVAgVHJhaW5pbmciLCJ0aWQiOiJmMTQzMGRkOC1kOWI4LTQ3MmYtYjIyZi02ZmJiNDk3OGYwYTQifQ.YmKumSeuFrBdwCZOVkqMt5Q-SNP10CbMp8ACRSEaro4fRGWbuidjsoY-J5lhLWZ0QIEw_WUI1thBM-AJVst12-zW7d4bKopb39l_AftTSanQc8EgNQyQgaEgPXzH00LtRVx7k_cUw9DChqn7cEqZaC4PmnQf6xmoI5MXw3qisWpkruoSovCmACtrRtvBd_DPAX80CEkcc4QMXiUDMm-N5XzqF5tMLG4BqDIAQo9QWLeujDTMvhE0VOSZ83byoWg2UtLZIKRWuLPEWWkYjcRzIcskX7mkR5BHvlo0f3ARal3jxyRalvZylPbhKmebkpPIpPyJ8HGbPuUeFVzc0zxBlw",
                          "enabled": true
                        }
                      ],
                      "multipartForm": [],
                      "file": []
                    },
                    "script": {},
                    "vars": {},
                    "assertions": [],
                    "tests": "",
                    "docs": "",
                    "auth": {
                      "mode": "basic",
                      "basic": {
                        "username": "{{client_id}}",
                        "password": "{{client_secret}}"
                      }
                    }
                  }
                }
              ]
            },
            {
              "type": "folder",
              "name": "Client Credentials Flow",
              "filename": "Client Credentials Flow",
              "root": {
                "meta": {
                  "name": "Client Credentials Flow"
                }
              },
              "items": [
                {
                  "type": "http",
                  "name": "Client Credentials Flow",
                  "filename": "Client Credentials Flow.bru",
                  "seq": 1,
                  "request": {
                    "url": "{{base_url}}/iam/access-management/v1/tenants/{{tenant_id}}/openid-connect/token",
                    "method": "POST",
                    "headers": [],
                    "params": [],
                    "body": {
                      "mode": "formUrlEncoded",
                      "formUrlEncoded": [
                        {
                          "name": "grant_type",
                          "value": "client_credentials",
                          "enabled": true
                        },
                        {
                          "name": "client_id",
                          "value": "{{client_id}}",
                          "enabled": true
                        },
                        {
                          "name": "client_secret",
                          "value": "{{client_secret}}",
                          "enabled": true
                        },
                        {
                          "name": "scope",
                          "value": "aud:{{macma_client_id}} openid",
                          "enabled": true
                        }
                      ],
                      "multipartForm": [],
                      "file": []
                    },
                    "script": {},
                    "vars": {},
                    "assertions": [],
                    "tests": "",
                    "docs": "",
                    "auth": {
                      "mode": "inherit"
                    }
                  }
                },
                {
                  "type": "http",
                  "name": "Read the ACL -Access Control List- for all resources registered for the given application",
                  "filename": "Read the ACL -Access Control List- for all resources registered for the given application.bru",
                  "seq": 2,
                  "request": {
                    "url": "{{base_url}}/iam/access-management/v1/application/acl",
                    "method": "GET",
                    "headers": [],
                    "params": [],
                    "body": {
                      "mode": "none",
                      "formUrlEncoded": [],
                      "multipartForm": [],
                      "file": []
                    },
                    "script": {},
                    "vars": {},
                    "assertions": [],
                    "tests": "",
                    "docs": "",
                    "auth": {
                      "mode": "inherit"
                    }
                  }
                }
              ]
            }
          ]
        },
        {
          "type": "folder",
          "name": "Resource Management",
          "filename": "Resource Management",
          "root": {
            "meta": {
              "name": "Resource Management"
            }
          },
          "items": [
            {
              "type": "http",
              "name": "Create or update static resources",
              "filename": "Create or update static resources.bru",
              "seq": 1,
              "request": {
                "url": "{{base_url}}/iam/application-management-bulk/v1/tenants/{{tenant_id}}/applications/{{client_id}}/resources/create-or-update",
                "method": "POST",
                "headers": [],
                "params": [],
                "body": {
                  "mode": "json",
                  "json": "{\n  \"items\": [\n    {\n      \"id\": \"urn.com.bosch.bap.trainingApp.homePage\",\n      \"name\": \"Training application home page\",\n      \"type\": \"view\",\n      \"description\": \"The home page of training demo application.\",\n      \"privileges\": [\n        \"read\"\n      ]\n    },\n    {\n      \"id\": \"urn.com.bosch.bap.trainingApp.demoData\",\n      \"name\": \"Training application demo data\",\n      \"type\": \"api\",\n      \"description\": \"The demo data of training demo application.\",\n      \"privileges\": [\n        \"read\",\n        \"modify\",\n        \"add\",\n        \"delete\"\n      ]\n    }\n  ]\n}",
                  "formUrlEncoded": [],
                  "multipartForm": [],
                  "file": []
                },
                "script": {},
                "vars": {},
                "assertions": [],
                "tests": "",
                "docs": "",
                "auth": {
                  "mode": "inherit"
                }
              }
            },
            {
              "type": "http",
              "name": "Delete Static Resource",
              "filename": "Delete Static Resource.bru",
              "seq": 2,
              "request": {
                "url": "{{base_url}}/iam/application-management-bulk/v1/tenants/{{tenant_id}}/applications/{{client_id}}/resources/delete",
                "method": "POST",
                "headers": [],
                "params": [],
                "body": {
                  "mode": "json",
                  "json": "{\n  \"items\": [\n    {\n      \"id\": \"urn.com.bosch.bap.trainingApp.homePage\",\n      \"type\": \"view\"\n    },\n    {\n      \"id\": \"urn.com.bosch.bap.trainingApp.demoData\",\n      \"type\": \"api\"\n    }\n  ]\n}",
                  "formUrlEncoded": [],
                  "multipartForm": [],
                  "file": []
                },
                "script": {},
                "vars": {},
                "assertions": [],
                "tests": "",
                "docs": "",
                "auth": {
                  "mode": "inherit"
                }
              }
            }
          ]
        },
        {
          "type": "folder",
          "name": "Application Management Bulk",
          "filename": "Application Management Bulk",
          "root": {
            "meta": {
              "name": "Application Management Bulk"
            }
          },
          "items": [
            {
              "type": "http",
              "name": "Create or Update Roles",
              "filename": "Create or Update Roles.bru",
              "seq": 1,
              "request": {
                "url": "{{base_url}}/iam/application-management-bulk/v1/tenants/{{tenant_id}}/applications/{{client_id}}/roles/create-or-update",
                "method": "POST",
                "headers": [],
                "params": [],
                "body": {
                  "mode": "json",
                  "json": "{\n  \"items\": [\n    {\n      \"name\": \"TrainingAppUser\",\n      \"displayName\": \"TrainingApp User\",\n      \"description\": \"User with basic permission.\",\n      \"permissions\": [\n        {\n          \"resourceId\": \"urn.com.bosch.bap.trainingApp.homePage\",\n          \"resourceType\": \"view\",\n          \"privileges\": [\n            \"read\"\n          ]\n        },\n        {\n          \"resourceId\": \"urn.com.bosch.bap.trainingApp.demoData\",\n          \"resourceType\": \"api\",\n          \"privileges\": [\n            \"read\"\n          ]\n        }\n      ]\n    },\n    {\n      \"name\": \"TrainingAppAdministrator\",\n      \"displayName\": \"TrainingApp Administrator\",\n      \"description\": \"Administrator with advanced permission.\",\n      \"permissions\": [\n        {\n          \"resourceId\": \"urn.com.bosch.bap.trainingApp.homePage\",\n          \"resourceType\": \"view\",\n          \"privileges\": [\n            \"read\"\n          ]\n        },\n        {\n          \"resourceId\": \"urn.com.bosch.bap.trainingApp.demoData\",\n          \"resourceType\": \"api\",\n          \"privileges\": [\n            \"read\",\n            \"modify\",\n            \"add\",\n            \"delete\"\n          ]\n        }\n      ]\n    }\n  ]\n}",
                  "formUrlEncoded": [],
                  "multipartForm": [],
                  "file": []
                },
                "script": {},
                "vars": {},
                "assertions": [],
                "tests": "",
                "docs": "",
                "auth": {
                  "mode": "inherit"
                }
              }
            },
            {
              "type": "http",
              "name": "Delete Roles",
              "filename": "Delete Roles.bru",
              "seq": 2,
              "request": {
                "url": "{{base_url}}/iam/application-management-bulk/v1/tenants/{{tenant_id}}/applications/{{client_id}}/roles/delete",
                "method": "POST",
                "headers": [],
                "params": [],
                "body": {
                  "mode": "json",
                  "json": "{\n  \"items\": [\n    {\n      \"name\": \"TrainingAppUser\"\n    },\n    {\n      \"name\": \"TrainingAppAdministrator\"\n    }\n  ]\n}",
                  "formUrlEncoded": [],
                  "multipartForm": [],
                  "file": []
                },
                "script": {},
                "vars": {},
                "assertions": [],
                "tests": "",
                "docs": "",
                "auth": {
                  "mode": "inherit"
                }
              }
            }
          ]
        }
      ]
    },
    {
      "type": "folder",
      "name": "Web Portal",
      "filename": "Web Portal",
      "root": {
        "meta": {
          "name": "Web Portal"
        }
      },
      "items": [
        {
          "type": "http",
          "name": "Create or update a registered module",
          "filename": "Create or update a registered module.bru",
          "seq": 1,
          "request": {
            "url": "{{base_url}}/api/core/api/v3/{{tenant_id}}/registry/{{client_id}}",
            "method": "PUT",
            "headers": [
              {
                "name": "Content-Type",
                "value": "application/json",
                "enabled": true
              }
            ],
            "params": [],
            "body": {
              "mode": "json",
              "json": "{\n\"TenantId\": \"f1430dd8-d9b8-472f-b22f-6fbb4978f0a4\",\n\"Url\": \"https://si0vmc3450.de.bosch.com\",\n \"info\": {\n   \"name\": \"Training Demo Application\",\n   \"id\": \"lsidgjg2izt1emerzbbih0e0\",\n   \"version\": \"1.0.0\",\n   \"Vendor\": \"ESW\",\n   \"baseUrl\": \"https://bzo.bosch.com/bzo/de/start_page.html\",\n   \"supportedLanguages\": [\n     \"en\",\n     \"de\",\n     \"zh\"\n   ],\n   \"authProviderClientId\": \"lsidgjg2izt1emerzbbih0e0\"\n },\n \"Views\": {\n   \"items\": [\n     {\n       \"title\": \"TrainingDemoApp\",\n       \"navigationPriority\": 0,\n       \"navigationPath\": [ \"demoeap\" ],\n       \"icon\": \"bosch-ic-analysis\",\n       \"resourceId\": \"urn.com.bosch.bap.trainingApp.homePage\",\n       \"resourceType\": \"view\",\n       \"localization\": {\n         \"title\": {\n           \"de\": \"TrainingDemoApp\",\n           \"en\": \"TrainingDemoApp\",\n           \"zh\": \"TrainingDemoApp\"\n         },\n         \"tags\": {\n           \"en\": [\n             \"TrainingDemoApp\",\n             \"Integration\"\n           ],\n           \"de\": [\n             \"TrainingDemoApp\",\n             \"Integration\"\n           ],\n           \"zh\": [\n             \"TrainingDemoApp\",\n             \"Integration\"\n           ]\n         }\n       }\n     },\n     {\n       \"title\": \"HomePage\",\n       \"htmlFile\": \"?tenantId=##tenantId##\",\n       \"resourceId\": \"urn.com.bosch.bap.trainingApp.homePage\",\n       \"resourceType\": \"view\",\n       \"navigationPriority\": 1,\n       \"navigationPath\": [ \"demoeap\", \"home\" ],\n       \"navigationRoute\": \"/home\",\n       \"localization\": {\n         \"title\": {\n           \"de\": \"HomePage\",\n           \"en\": \"HomePage\",\n           \"zh\": \"HomePage\"\n         },\n         \"tags\": {\n           \"de\": [ \"Iframe Demo\", \"Visualization\" ],\n           \"en\": [ \"Iframe Demo\", \"Visualization\" ],\n           \"zh\": [ \"Iframe Demo\", \"Visualization\" ]\n         }\n       }\n     }\n   ]\n }\n}",
              "formUrlEncoded": [],
              "multipartForm": [],
              "file": []
            },
            "script": {},
            "vars": {},
            "assertions": [],
            "tests": "",
            "docs": "Create or update a registered module in Web Portal and its resources like views, widgets, contributions and documents.",
            "auth": {
              "mode": "inherit"
            }
          }
        },
        {
          "type": "http",
          "name": "Delete a registered module",
          "filename": "Delete a registered module.bru",
          "seq": 3,
          "request": {
            "url": "{{base_url}}/api/core/api/v3/{{tenant_id}}/registry/{{client_id}}",
            "method": "DELETE",
            "headers": [],
            "params": [],
            "body": {
              "mode": "none",
              "formUrlEncoded": [],
              "multipartForm": [],
              "file": []
            },
            "script": {},
            "vars": {},
            "assertions": [],
            "tests": "",
            "docs": "Deletes a registered module in Web Portal and its resources like views, widgets, contributions and documents with the given module ID.",
            "auth": {
              "mode": "inherit"
            }
          }
        },
        {
          "type": "http",
          "name": "Gets all registered modules",
          "filename": "Gets all registered modules.bru",
          "seq": 2,
          "request": {
            "url": "{{base_url}}/api/core/api/v3/{{tenant_id}}/registry/modules",
            "method": "GET",
            "headers": [],
            "params": [],
            "body": {
              "mode": "none",
              "formUrlEncoded": [],
              "multipartForm": [],
              "file": []
            },
            "script": {},
            "vars": {},
            "assertions": [],
            "tests": "",
            "docs": "Get a list of all registered modules for a given organization.",
            "auth": {
              "mode": "inherit"
            }
          }
        }
      ]
    },
    {
      "type": "folder",
      "name": "Master Data Management",
      "filename": "Master Data Management",
      "root": {
        "meta": {
          "name": "Master Data Management"
        }
      },
      "items": [
        {
          "type": "http",
          "name": "Create a device type",
          "filename": "Create a device type.bru",
          "seq": 2,
          "request": {
            "url": "{{base_url}}/mdm/equipment-management/api/v1/{{tenant_id}}/devicetypes",
            "method": "POST",
            "headers": [],
            "params": [],
            "body": {
              "mode": "json",
              "json": "{\n  \"metaData\": {\n    \"modelId\": \"urn:industry:bosch:entitytype:devicetype:api:equipment:v1\"\n  },\n  \"baseCategory\": \"Machine\",\n  \"name\": \"Sensor\",\n  \"manufacturer\": \"Mfc\",\n  \"version\": \"v1\",\n  \"customProperties\": [\n    {\n      \"metaData\": {\n        \"modelId\": \"urn:industry:bosch:entitytype:generic:customproperty:api:v1\"\n      },\n      \"name\": \"Temperature\",\n      \"unit\": \"°C\",\n      \"description\": \"Operating Temperature\",\n      \"dataType\": \"Number\",\n      \"defaultValue\": \"22\",\n      \"mandatory\": false\n    }\n  ]\n}",
              "formUrlEncoded": [],
              "multipartForm": [],
              "file": []
            },
            "script": {},
            "vars": {},
            "assertions": [],
            "tests": "",
            "docs": "",
            "auth": {
              "mode": "inherit"
            }
          }
        },
        {
          "type": "http",
          "name": "Get a device type by id",
          "filename": "Get a device type by id.bru",
          "seq": 3,
          "request": {
            "url": "{{base_url}}/mdm/equipment-management/api/v1/{{tenant_id}}/devicetypes/233b5845-da7a-4075-94fd-df85d555f89a",
            "method": "GET",
            "headers": [],
            "params": [],
            "body": {
              "mode": "none",
              "formUrlEncoded": [],
              "multipartForm": [],
              "file": []
            },
            "script": {},
            "vars": {},
            "assertions": [],
            "tests": "",
            "docs": "",
            "auth": {
              "mode": "inherit"
            }
          }
        },
        {
          "type": "http",
          "name": "Get Devices",
          "filename": "Get Devices.bru",
          "seq": 1,
          "request": {
            "url": "{{base_url}}/mdm/equipment-management/api/v1/{{tenant_id}}/devices",
            "method": "GET",
            "headers": [],
            "params": [],
            "body": {
              "mode": "none",
              "formUrlEncoded": [],
              "multipartForm": [],
              "file": []
            },
            "script": {},
            "vars": {},
            "assertions": [],
            "tests": "",
            "docs": "",
            "auth": {
              "mode": "inherit"
            }
          }
        }
      ]
    }
  ],
  "activeEnvironmentUid": "qquSf09NBfjDMrpZLZPVb",
  "environments": [
    {
      "variables": [
        {
          "name": "base_url",
          "value": "https://si0vmc3450.de.bosch.com",
          "enabled": true,
          "secret": false,
          "type": "text"
        },
        {
          "name": "tenant_id",
          "value": "38e99987-6c0b-42b8-ae05-b408a40d9c29",
          "enabled": true,
          "secret": false,
          "type": "text"
        },
        {
          "name": "client_id",
          "value": "e4unrh9yvcyz1wew4jd52arkv",
          "enabled": true,
          "secret": false,
          "type": "text"
        },
        {
          "name": "redirect_uri",
          "value": "https://si0vmc3450.de.bosch.com/*",
          "enabled": true,
          "secret": false,
          "type": "text"
        },
        {
          "name": "macma_client_id",
          "value": "macma",
          "enabled": true,
          "secret": false,
          "type": "text"
        },
        {
          "name": "mdm_client_id",
          "value": "1v5huf4zzk37k1favb16ttzja1",
          "enabled": true,
          "secret": false,
          "type": "text"
        },
        {
          "name": "portal_client_id",
          "value": "18t5aw8vt4doy1rln66w2cpb1e",
          "enabled": true,
          "secret": false,
          "type": "text"
        },
        {
          "name": "client_secret",
          "value": "TrainingDemoAppByWeiyan",
          "enabled": true,
          "secret": false,
          "type": "text"
        }
      ],
      "name": "SOT Integration"
    }
  ],
  "root": {
    "request": {
      "auth": {
        "mode": "oauth2",
        "oauth2": {
          "grantType": "client_credentials",
          "accessTokenUrl": "{{base_url}}/iam/access-management/v1/tenants/{{tenant_id}}/openid-connect/token",
          "clientId": "{{client_id}}",
          "clientSecret": "{{client_secret}}",
          "scope": "openid aud:{{macma_client_id}}",
          "credentialsPlacement": "body",
          "credentialsId": "credentials",
          "tokenPlacement": "header",
          "tokenHeaderPrefix": "Bearer",
          "tokenQueryKey": "access_token",
          "refreshTokenUrl": "",
          "autoRefreshToken": false,
          "autoFetchToken": true
        }
      }
    },
    "meta": {
      "name": "SOT Integration Examples"
    }
  },
  "brunoConfig": {
    "version": "1",
    "name": "SOT Integration Examples",
    "type": "collection",
    "ignore": [
      "node_modules",
      ".git"
    ],
    "size": 0.0117950439453125,
    "filesCount": 24
  }
}