Skip to main content

Good Day. I would like to know if there is a way on how to create technical programmatically?

Use case: 

  • We are trying to automate many queries and mutations vie pipeline and central hub. The token that technical user provided will be stored inside or in a vault. We don’t want anyone to see the token that is being created.

Is there a way for this?

Hi, 

 

There must definitely be a way, as there is a POST /technicalusers action in the MTM API. There is a token returned in the response, so I assume it would be returned after creation. 

However, the MTM API is used by Support, so there may be some operations that cannot be done. I would contact the support to get some documentation related this operation.

If I interpret the payload to be sent, I’d try something like: 
 

{

  "userName": "tech_user_01",

  "email": "techuser01@example.com",

  "permissionRole": "ADMIN",

  "customerRoles": "ROLE_CUSTOMER_ADMIN", -- (your customer role)

  "accessControlEntities": "ACE_ROLE_1235", -- (your ACL, if any) 

  "apiTokenData": {

    "expiry": {

      "chronology": {

        "zone": {

          "id": "UTC",

          "fixed": true

        }

      },

      "millis": 1735689600000,  -- the epoch time converted for the expiry

      "zone": {

        "id": "UTC",

        "fixed": true

      },

      "afterNow": true,

      "beforeNow": false,

      "equalNow": false

    },

    "description": "Token for automated integration"

  }

}

 


 


Hello.. We have just did it yesterday and we can confirm that technical user can be created programmatically via MTM api.. 

 

Thank you so much for answering.. 


Reply