Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

Passing single string in DisableAccountJSON

nkellycrp
New Contributor
New Contributor

Is there any way to handle sending a raw string in a put request within the JSON config? I'm trying to get the DisableAccountJSON for one of my connections working. The endpoint is expecting to simply receive "Activated" or "Deactivated" to enable/disable an account, not a JSON key/value pair.

Any ideas?

 

{
    "call": [
      {
        "name": "call1",
        "connection": "acctAuth",
        "url": "https://removed/v2-edge/vendors/<accountid>/status",
        "httpMethod": "PUT",
        "httpParams": "\"Deactivated\"",
        "httpHeaders": {
          "Authorization": "${access_token}",
          "Accept": "application/json"
        },
        "httpContentType": "application/json",
        "successResponses": {
          "statusCode": [
            200,
            201
          ]
        }
      }
    ]
}
 
Error on provisioning: 
 
{"auditDetails":{"call1":[{"message":"Unrecognized token 'Deactivated': was expecting ('true', 'false' or 'null')\n at [Source: Deactivated; line: 1, column: 23]","status":"Failed"},{"message":"Can not construct instance of java.util.LinkedHashMap: no String-argument constructor/factory method to deserialize from String value ('Deactivated')\n at [Source: \"Deactivated\";
 
[This message has been edited by moderator to mask url]
 
2 REPLIES 2

Manu269
All-Star
All-Star

Did you validate the same via Postman?

Moreover, you can check to pass this value as body.

Regards
Manish Kumar
If the response answered your query, please Accept As Solution and Kudos
.

rushikeshvartak
All-Star
All-Star

Please share curl command [Refer https://codingnconcepts.com/postman/how-to-generate-curl-command-from-postman/ ]


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.