Search code examples
ibm-cloud-infrastructure

Do SoftLayer API'S support querying the "auto-approval" settings of accounts?


We are currently investigating to see if SL API's support the check for "auto-approval" setting of the SL account. From a quick search I am not sure that the documented SL API allows us to interrogate this. Could you please confirm if we can do this or not?


Solution

  • you need to call the method getAttributes

    in the response you will see somethng like this:

    {
            "accountAttributeTypeId": 1,
            "accountId": 22222,
            "id": 111111,
            "value": "1",
            "accountAttributeType": {
                "description": "All sales orders for the account will be set to auto approve.",
                "id": 1,
                "keyName": "ORDER_AUTO_APPROVE"
            }
    

    If the "value" has the value "1", so your account has enabled the auto aprove otherwise it has not.

    Just in case you cannot change that setting only the softlayer's employeers can do it.