Chilkat Online Tools

PowerBuilder / Zoho CRM REST APIs / Subforms

Back to Collection Items

integer li_rc
oleobject loo_Http
integer li_Success
oleobject loo_SbResponseBody
oleobject loo_JResp
integer li_RespStatusCode
string ls_Name
string ls_Id
string ls_V_Email
string ls_Company
string ls_Scurrency_symbol
string ls_Image123
string ls_Ssharing_permission
string ls_Image
string ls_Last_Activity_Time
string ls_Industry
string ls_Sstate
string ls_Unsubscribed_Mode
integer li_Sconverted
integer li_Sprocess_flow
integer li_Exchange_Rate
string ls_V_Currency
string ls_Street
string ls_Zip_Code
string ls_Data_Processing_Basis_Details
string ls_Id
string ls_Data_Source
integer li_Sapproved
integer li_Delegate
integer li_Approve
integer li_Reject
integer li_Resubmit
string ls_Sdata_source_details
string ls_Created_Time
integer li_Seditable
string ls_City
string ls_No_of_Employees
string ls_State
string ls_Country
string ls_Created_ByName
string ls_Created_ById
string ls_Created_ByEmail
string ls_Annual_Revenue
string ls_Secondary_Email
string ls_Description
string ls_Rating
integer li_Sreview_processApprove
integer li_Sreview_processReject
integer li_Sreview_processResubmit
string ls_Website
string ls_Twitter
string ls_Scanvas_id
string ls_Salutation
string ls_First_Name
string ls_Lead_Status
string ls_Full_Name
string ls_Record_Image
string ls_Modified_ByName
string ls_Modified_ById
string ls_Modified_ByEmail
string ls_Sreview
string ls_Lead_Conversion_Time
string ls_Skype_ID
string ls_Phone
string ls_HIPAA
integer li_Email_Opt_Out
string ls_Designation
string ls_Modified_Time
string ls_Unsubscribed_Time
string ls_Mobile
integer li_Sorchestration
integer li_Sstop_processing
string ls_Last_Name
integer li_Sin_merge
string ls_Lead_Source
string ls_Fax
string ls_Sapproval_state
integer li_Interested_Leads
integer li_Multiuser
integer j
integer li_Count_j
integer i
integer li_Count_i

// This example assumes the Chilkat API to have been previously unlocked.
// See Global Unlock Sample for sample code.

loo_Http = create oleobject
// Use "Chilkat_9_5_0.Http" for versions of Chilkat < 10.0.0
li_rc = loo_Http.ConnectToNewObject("Chilkat.Http")
if li_rc < 0 then
    destroy loo_Http
    MessageBox("Error","Connecting to COM object failed")
    return
end if

// Adds the "Authorization: Bearer <access_token>" header.
loo_Http.AuthToken = "<access_token>"

loo_SbResponseBody = create oleobject
// Use "Chilkat_9_5_0.StringBuilder" for versions of Chilkat < 10.0.0
li_rc = loo_SbResponseBody.ConnectToNewObject("Chilkat.StringBuilder")

li_Success = loo_Http.QuickGetSb("https://domain.com/crm/v2.1/Leads/{{record_id}}",loo_SbResponseBody)
if li_Success = 0 then
    Write-Debug loo_Http.LastErrorText
    destroy loo_Http
    destroy loo_SbResponseBody
    return
end if

loo_JResp = create oleobject
// Use "Chilkat_9_5_0.JsonObject" for versions of Chilkat < 10.0.0
li_rc = loo_JResp.ConnectToNewObject("Chilkat.JsonObject")

loo_JResp.LoadSb(loo_SbResponseBody)
loo_JResp.EmitCompact = 0

Write-Debug "Response Body:"
Write-Debug loo_JResp.Emit()

li_RespStatusCode = loo_Http.LastStatus
Write-Debug "Response Status Code = " + string(li_RespStatusCode)
if li_RespStatusCode >= 400 then
    Write-Debug "Response Header:"
    Write-Debug loo_Http.LastHeader
    Write-Debug "Failed."
    destroy loo_Http
    destroy loo_SbResponseBody
    destroy loo_JResp
    return
end if

// Sample JSON response:
// (Sample code for parsing the JSON response is shown below)

// {
//   "data": [
//     {
//       "Owner": {
//         "name": "patricia patricia",
//         "id": "738964000000291009",
//         "email": "patricia.ss@zylker.com"
//       },
//       "Company": null,
//       "Email": null,
//       "$currency_symbol": "Af",
//       "Interested_Leads": [
//       ],
//       "Image123": null,
//       "$sharing_permission": "full_access",
//       "Image": null,
//       "Last_Activity_Time": null,
//       "Industry": null,
//       "$state": "save",
//       "Unsubscribed_Mode": null,
//       "$converted": false,
//       "$process_flow": false,
//       "Exchange_Rate": 1,
//       "Currency": "AFN",
//       "Street": null,
//       "Zip_Code": null,
//       "multiuser": [
//       ],
//       "Data_Processing_Basis_Details": null,
//       "id": "738964000002131001",
//       "Data_Source": "Manual",
//       "$approved": true,
//       "$approval": {
//         "delegate": false,
//         "approve": false,
//         "reject": false,
//         "resubmit": false
//       },
//       "$data_source_details": null,
//       "Created_Time": "2021-05-07T06:23:10+00:00",
//       "$editable": true,
//       "City": null,
//       "No_of_Employees": null,
//       "State": null,
//       "Country": null,
//       "Created_By": {
//         "name": "patricia patricia",
//         "id": "738964000000291009",
//         "email": "patricia.ss@zylker.com"
//       },
//       "Annual_Revenue": null,
//       "Secondary_Email": null,
//       "Description": null,
//       "Rating": null,
//       "$review_process": {
//         "approve": false,
//         "reject": false,
//         "resubmit": false
//       },
//       "Website": null,
//       "Twitter": null,
//       "$canvas_id": null,
//       "Salutation": null,
//       "First_Name": null,
//       "Lead_Status": null,
//       "Full_Name": "sample",
//       "Record_Image": null,
//       "Modified_By": {
//         "name": "patricia patricia",
//         "id": "738964000000291009",
//         "email": "patricia.ss@zylker.com"
//       },
//       "$review": null,
//       "Lead_Conversion_Time": null,
//       "Skype_ID": null,
//       "Phone": null,
//       "HIPAA": null,
//       "Email_Opt_Out": false,
//       "Designation": null,
//       "Modified_Time": "2021-05-07T06:23:10+00:00",
//       "$converted_detail": {},
//       "Unsubscribed_Time": null,
//       "Mobile": "9898989898",
//       "$orchestration": false,
//       "$stop_processing": false,
//       "Last_Name": "sample",
//       "$in_merge": false,
//       "Lead_Source": null,
//       "Tag": [
//       ],
//       "Fax": null,
//       "$approval_state": "approved",
//       "$has_more": {
//         "Interested_Leads": false,
//         "multiuser": false
//       }
//     }
//   ]
// }

// Sample code for parsing the JSON response...
// Use this online tool to generate parsing code from sample JSON: Generate JSON Parsing Code

i = 0
li_Count_i = loo_JResp.SizeOfArray("data")
do while i < li_Count_i
    loo_JResp.I = i
    ls_Name = loo_JResp.StringOf("data[i].Owner.name")
    ls_Id = loo_JResp.StringOf("data[i].Owner.id")
    ls_V_Email = loo_JResp.StringOf("data[i].Owner.email")
    ls_Company = loo_JResp.StringOf("data[i].Company")
    ls_V_Email = loo_JResp.StringOf("data[i].Email")
    ls_Scurrency_symbol = loo_JResp.StringOf("data[i].$currency_symbol")
    ls_Image123 = loo_JResp.StringOf("data[i].Image123")
    ls_Ssharing_permission = loo_JResp.StringOf("data[i].$sharing_permission")
    ls_Image = loo_JResp.StringOf("data[i].Image")
    ls_Last_Activity_Time = loo_JResp.StringOf("data[i].Last_Activity_Time")
    ls_Industry = loo_JResp.StringOf("data[i].Industry")
    ls_Sstate = loo_JResp.StringOf("data[i].$state")
    ls_Unsubscribed_Mode = loo_JResp.StringOf("data[i].Unsubscribed_Mode")
    li_Sconverted = loo_JResp.BoolOf("data[i].$converted")
    li_Sprocess_flow = loo_JResp.BoolOf("data[i].$process_flow")
    li_Exchange_Rate = loo_JResp.IntOf("data[i].Exchange_Rate")
    ls_V_Currency = loo_JResp.StringOf("data[i].Currency")
    ls_Street = loo_JResp.StringOf("data[i].Street")
    ls_Zip_Code = loo_JResp.StringOf("data[i].Zip_Code")
    ls_Data_Processing_Basis_Details = loo_JResp.StringOf("data[i].Data_Processing_Basis_Details")
    ls_Id = loo_JResp.StringOf("data[i].id")
    ls_Data_Source = loo_JResp.StringOf("data[i].Data_Source")
    li_Sapproved = loo_JResp.BoolOf("data[i].$approved")
    li_Delegate = loo_JResp.BoolOf("data[i].$approval.delegate")
    li_Approve = loo_JResp.BoolOf("data[i].$approval.approve")
    li_Reject = loo_JResp.BoolOf("data[i].$approval.reject")
    li_Resubmit = loo_JResp.BoolOf("data[i].$approval.resubmit")
    ls_Sdata_source_details = loo_JResp.StringOf("data[i].$data_source_details")
    ls_Created_Time = loo_JResp.StringOf("data[i].Created_Time")
    li_Seditable = loo_JResp.BoolOf("data[i].$editable")
    ls_City = loo_JResp.StringOf("data[i].City")
    ls_No_of_Employees = loo_JResp.StringOf("data[i].No_of_Employees")
    ls_State = loo_JResp.StringOf("data[i].State")
    ls_Country = loo_JResp.StringOf("data[i].Country")
    ls_Created_ByName = loo_JResp.StringOf("data[i].Created_By.name")
    ls_Created_ById = loo_JResp.StringOf("data[i].Created_By.id")
    ls_Created_ByEmail = loo_JResp.StringOf("data[i].Created_By.email")
    ls_Annual_Revenue = loo_JResp.StringOf("data[i].Annual_Revenue")
    ls_Secondary_Email = loo_JResp.StringOf("data[i].Secondary_Email")
    ls_Description = loo_JResp.StringOf("data[i].Description")
    ls_Rating = loo_JResp.StringOf("data[i].Rating")
    li_Sreview_processApprove = loo_JResp.BoolOf("data[i].$review_process.approve")
    li_Sreview_processReject = loo_JResp.BoolOf("data[i].$review_process.reject")
    li_Sreview_processResubmit = loo_JResp.BoolOf("data[i].$review_process.resubmit")
    ls_Website = loo_JResp.StringOf("data[i].Website")
    ls_Twitter = loo_JResp.StringOf("data[i].Twitter")
    ls_Scanvas_id = loo_JResp.StringOf("data[i].$canvas_id")
    ls_Salutation = loo_JResp.StringOf("data[i].Salutation")
    ls_First_Name = loo_JResp.StringOf("data[i].First_Name")
    ls_Lead_Status = loo_JResp.StringOf("data[i].Lead_Status")
    ls_Full_Name = loo_JResp.StringOf("data[i].Full_Name")
    ls_Record_Image = loo_JResp.StringOf("data[i].Record_Image")
    ls_Modified_ByName = loo_JResp.StringOf("data[i].Modified_By.name")
    ls_Modified_ById = loo_JResp.StringOf("data[i].Modified_By.id")
    ls_Modified_ByEmail = loo_JResp.StringOf("data[i].Modified_By.email")
    ls_Sreview = loo_JResp.StringOf("data[i].$review")
    ls_Lead_Conversion_Time = loo_JResp.StringOf("data[i].Lead_Conversion_Time")
    ls_Skype_ID = loo_JResp.StringOf("data[i].Skype_ID")
    ls_Phone = loo_JResp.StringOf("data[i].Phone")
    ls_HIPAA = loo_JResp.StringOf("data[i].HIPAA")
    li_Email_Opt_Out = loo_JResp.BoolOf("data[i].Email_Opt_Out")
    ls_Designation = loo_JResp.StringOf("data[i].Designation")
    ls_Modified_Time = loo_JResp.StringOf("data[i].Modified_Time")
    ls_Unsubscribed_Time = loo_JResp.StringOf("data[i].Unsubscribed_Time")
    ls_Mobile = loo_JResp.StringOf("data[i].Mobile")
    li_Sorchestration = loo_JResp.BoolOf("data[i].$orchestration")
    li_Sstop_processing = loo_JResp.BoolOf("data[i].$stop_processing")
    ls_Last_Name = loo_JResp.StringOf("data[i].Last_Name")
    li_Sin_merge = loo_JResp.BoolOf("data[i].$in_merge")
    ls_Lead_Source = loo_JResp.StringOf("data[i].Lead_Source")
    ls_Fax = loo_JResp.StringOf("data[i].Fax")
    ls_Sapproval_state = loo_JResp.StringOf("data[i].$approval_state")
    li_Interested_Leads = loo_JResp.BoolOf("data[i].$has_more.Interested_Leads")
    li_Multiuser = loo_JResp.BoolOf("data[i].$has_more.multiuser")
    j = 0
    li_Count_j = loo_JResp.SizeOfArray("data[i].Interested_Leads")
    do while j < li_Count_j
        loo_JResp.J = j
        j = j + 1
    loop
    j = 0
    li_Count_j = loo_JResp.SizeOfArray("data[i].multiuser")
    do while j < li_Count_j
        loo_JResp.J = j
        j = j + 1
    loop
    j = 0
    li_Count_j = loo_JResp.SizeOfArray("data[i].Tag")
    do while j < li_Count_j
        loo_JResp.J = j
        j = j + 1
    loop
    i = i + 1
loop


destroy loo_Http
destroy loo_SbResponseBody
destroy loo_JResp

Curl Command

curl -X GET
	-H "Authorization: Bearer <access_token>"
https://domain.com/crm/v2.1/Leads/{{record_id}}

Postman Collection Item JSON

{
  "name": "Subforms",
  "request": {
    "auth": {
      "type": "bearer",
      "bearer": [
        {
          "key": "token",
          "value": "{{access-token}}",
          "type": "string"
        }
      ]
    },
    "method": "GET",
    "header": [
    ],
    "url": {
      "raw": "{{api-domain}}/crm/v2.1/Leads/{{record_id}}",
      "host": [
        "{{api-domain}}"
      ],
      "path": [
        "crm",
        "v2.1",
        "Leads",
        "{{record_id}}"
      ]
    },
    "description": "To get the subform data in a record."
  },
  "response": [
    {
      "name": "SUCCESS RESPONSE",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{api-domain}}/crm/v2.1/Leads/738964000002131001",
          "host": [
            "{{api-domain}}"
          ],
          "path": [
            "crm",
            "v2.1",
            "Leads",
            "738964000002131001"
          ]
        }
      },
      "status": "OK",
      "code": 200,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Server",
          "value": "ZGS"
        },
        {
          "key": "Date",
          "value": "Fri, 07 May 2021 06:32:59 GMT"
        },
        {
          "key": "Content-Type",
          "value": "application/json;charset=utf-8"
        },
        {
          "key": "Transfer-Encoding",
          "value": "chunked"
        },
        {
          "key": "Connection",
          "value": "keep-alive"
        },
        {
          "key": "Referrer-Policy",
          "value": "strict-origin"
        },
        {
          "key": "X-Content-Type-Options",
          "value": "nosniff"
        },
        {
          "key": "X-XSS-Protection",
          "value": "1; mode=block"
        },
        {
          "key": "Pragma",
          "value": "no-cache"
        },
        {
          "key": "Cache-Control",
          "value": "no-cache"
        },
        {
          "key": "Expires",
          "value": "Thu, 01 Jan 1970 00:00:00 GMT"
        },
        {
          "key": "X-Frame-Options",
          "value": "SAMEORIGIN"
        },
        {
          "key": "X-ACCESSTOKEN-RESET",
          "value": "2021-05-07T06:44:53+00:00"
        },
        {
          "key": "clientVersion",
          "value": "4016256"
        },
        {
          "key": "clientsubVersion",
          "value": "8ef7aa3133ce0e105307c407d89b23d9"
        },
        {
          "key": "Content-Disposition",
          "value": "attachment; filename=response.json"
        },
        {
          "key": "vary",
          "value": "accept-encoding"
        },
        {
          "key": "Content-Encoding",
          "value": "gzip"
        },
        {
          "key": "Content-Language",
          "value": "en-US"
        },
        {
          "key": "Strict-Transport-Security",
          "value": "max-age=15768000"
        }
      ],
      "cookie": [
      ],
      "body": "{\n    \"data\": [\n        {\n            \"Owner\": {\n                \"name\": \"patricia patricia\",\n                \"id\": \"738964000000291009\",\n                \"email\": \"patricia.ss@zylker.com\"\n            },\n            \"Company\": null,\n            \"Email\": null,\n            \"$currency_symbol\": \"Af\",\n            \"Interested_Leads\": [],\n            \"Image123\": null,\n            \"$sharing_permission\": \"full_access\",\n            \"Image\": null,\n            \"Last_Activity_Time\": null,\n            \"Industry\": null,\n            \"$state\": \"save\",\n            \"Unsubscribed_Mode\": null,\n            \"$converted\": false,\n            \"$process_flow\": false,\n            \"Exchange_Rate\": 1,\n            \"Currency\": \"AFN\",\n            \"Street\": null,\n            \"Zip_Code\": null,\n            \"multiuser\": [],\n            \"Data_Processing_Basis_Details\": null,\n            \"id\": \"738964000002131001\",\n            \"Data_Source\": \"Manual\",\n            \"$approved\": true,\n            \"$approval\": {\n                \"delegate\": false,\n                \"approve\": false,\n                \"reject\": false,\n                \"resubmit\": false\n            },\n            \"$data_source_details\": null,\n            \"Created_Time\": \"2021-05-07T06:23:10+00:00\",\n            \"$editable\": true,\n            \"City\": null,\n            \"No_of_Employees\": null,\n            \"State\": null,\n            \"Country\": null,\n            \"Created_By\": {\n                \"name\": \"patricia patricia\",\n                \"id\": \"738964000000291009\",\n                \"email\": \"patricia.ss@zylker.com\"\n            },\n            \"Annual_Revenue\": null,\n            \"Secondary_Email\": null,\n            \"Description\": null,\n            \"Rating\": null,\n            \"$review_process\": {\n                \"approve\": false,\n                \"reject\": false,\n                \"resubmit\": false\n            },\n            \"Website\": null,\n            \"Twitter\": null,\n            \"$canvas_id\": null,\n            \"Salutation\": null,\n            \"First_Name\": null,\n            \"Lead_Status\": null,\n            \"Full_Name\": \"sample\",\n            \"Record_Image\": null,\n            \"Modified_By\": {\n                \"name\": \"patricia patricia\",\n                \"id\": \"738964000000291009\",\n                \"email\": \"patricia.ss@zylker.com\"\n            },\n            \"$review\": null,\n            \"Lead_Conversion_Time\": null,\n            \"Skype_ID\": null,\n            \"Phone\": null,\n            \"HIPAA\": null,\n            \"Email_Opt_Out\": false,\n            \"Designation\": null,\n            \"Modified_Time\": \"2021-05-07T06:23:10+00:00\",\n            \"$converted_detail\": {},\n            \"Unsubscribed_Time\": null,\n            \"Mobile\": \"9898989898\",\n            \"$orchestration\": false,\n            \"$stop_processing\": false,\n            \"Last_Name\": \"sample\",\n            \"$in_merge\": false,\n            \"Lead_Source\": null,\n            \"Tag\": [],\n            \"Fax\": null,\n            \"$approval_state\": \"approved\",\n            \"$has_more\": {\n                \"Interested_Leads\": false,\n                \"multiuser\": false\n            }\n        }\n    ]\n}"
    },
    {
      "name": "INVALID_MODULE",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{api-domain}}/crm/v2.1/Lead/738964000002131001",
          "host": [
            "{{api-domain}}"
          ],
          "path": [
            "crm",
            "v2.1",
            "Lead",
            "738964000002131001"
          ]
        }
      },
      "status": "Bad Request",
      "code": 400,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Server",
          "value": "ZGS"
        },
        {
          "key": "Date",
          "value": "Fri, 07 May 2021 06:33:30 GMT"
        },
        {
          "key": "Content-Type",
          "value": "application/json;charset=utf-8"
        },
        {
          "key": "Content-Length",
          "value": "133"
        },
        {
          "key": "Connection",
          "value": "keep-alive"
        },
        {
          "key": "Referrer-Policy",
          "value": "strict-origin"
        },
        {
          "key": "X-Content-Type-Options",
          "value": "nosniff"
        },
        {
          "key": "X-XSS-Protection",
          "value": "1; mode=block"
        },
        {
          "key": "Pragma",
          "value": "no-cache"
        },
        {
          "key": "Cache-Control",
          "value": "no-cache"
        },
        {
          "key": "Expires",
          "value": "Thu, 01 Jan 1970 00:00:00 GMT"
        },
        {
          "key": "X-Frame-Options",
          "value": "SAMEORIGIN"
        },
        {
          "key": "X-ACCESSTOKEN-RESET",
          "value": "2021-05-07T06:44:53+00:00"
        },
        {
          "key": "clientVersion",
          "value": "4016256"
        },
        {
          "key": "clientsubVersion",
          "value": "8ef7aa3133ce0e105307c407d89b23d9"
        },
        {
          "key": "Content-Disposition",
          "value": "attachment; filename=response.json"
        },
        {
          "key": "X-Download-Options",
          "value": "noopen"
        },
        {
          "key": "Content-Language",
          "value": "en-US"
        }
      ],
      "cookie": [
      ],
      "body": "{\n    \"code\": \"INVALID_MODULE\",\n    \"details\": {\n        \"resource_path_index\": 0\n    },\n    \"message\": \"the module name given seems to be invalid\",\n    \"status\": \"error\"\n}"
    },
    {
      "name": "INVALID_REQUEST_METHOD",
      "originalRequest": {
        "method": "COPY",
        "header": [
        ],
        "url": {
          "raw": "{{api-domain}}/crm/v2.1/Leads/738964000002131001",
          "host": [
            "{{api-domain}}"
          ],
          "path": [
            "crm",
            "v2.1",
            "Leads",
            "738964000002131001"
          ]
        }
      },
      "status": "Bad Request",
      "code": 400,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Server",
          "value": "ZGS"
        },
        {
          "key": "Date",
          "value": "Fri, 07 May 2021 06:34:10 GMT"
        },
        {
          "key": "Content-Type",
          "value": "application/json;charset=utf-8"
        },
        {
          "key": "Content-Length",
          "value": "124"
        },
        {
          "key": "Connection",
          "value": "keep-alive"
        },
        {
          "key": "X-Frame-Options",
          "value": "deny"
        },
        {
          "key": "X-Download-Options",
          "value": "noopen"
        },
        {
          "key": "X-Content-Type-Options",
          "value": "nosniff"
        }
      ],
      "cookie": [
      ],
      "body": "{\n    \"code\": \"INVALID_REQUEST_METHOD\",\n    \"details\": {},\n    \"message\": \"The http request method type is not a valid one\",\n    \"status\": \"error\"\n}"
    },
    {
      "name": "AUTHENTICATION_FAILURE",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{api-domain}}/crm/v2.1/Leads/738964000002131001",
          "host": [
            "{{api-domain}}"
          ],
          "path": [
            "crm",
            "v2.1",
            "Leads",
            "738964000002131001"
          ]
        }
      },
      "status": "Unauthorized",
      "code": 401,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Server",
          "value": "ZGS"
        },
        {
          "key": "Date",
          "value": "Fri, 07 May 2021 06:34:28 GMT"
        },
        {
          "key": "Content-Type",
          "value": "application/json;charset=utf-8"
        },
        {
          "key": "Content-Length",
          "value": "98"
        },
        {
          "key": "Connection",
          "value": "keep-alive"
        },
        {
          "key": "Referrer-Policy",
          "value": "strict-origin"
        },
        {
          "key": "X-Content-Type-Options",
          "value": "nosniff"
        },
        {
          "key": "X-XSS-Protection",
          "value": "1; mode=block"
        },
        {
          "key": "Pragma",
          "value": "no-cache"
        },
        {
          "key": "Cache-Control",
          "value": "no-cache"
        },
        {
          "key": "Expires",
          "value": "Thu, 01 Jan 1970 00:00:00 GMT"
        },
        {
          "key": "X-Frame-Options",
          "value": "SAMEORIGIN"
        },
        {
          "key": "X-Download-Options",
          "value": "noopen"
        }
      ],
      "cookie": [
      ],
      "body": "{\n    \"code\": \"AUTHENTICATION_FAILURE\",\n    \"details\": {},\n    \"message\": \"Authentication failed\",\n    \"status\": \"error\"\n}"
    },
    {
      "name": "INVALID_REQUEST",
      "originalRequest": {
        "method": "GET",
        "header": [
        ],
        "url": {
          "raw": "{{api-domain}}/crm/v2.1/Leads/{{record_id}}",
          "host": [
            "{{api-domain}}"
          ],
          "path": [
            "crm",
            "v2.1",
            "Leads",
            "{{record_id}}"
          ]
        }
      },
      "status": "Bad Request",
      "code": 400,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Server",
          "value": "ZGS"
        },
        {
          "key": "Date",
          "value": "Thu, 13 May 2021 06:51:53 GMT"
        },
        {
          "key": "Content-Type",
          "value": "application/json;charset=utf-8"
        },
        {
          "key": "Content-Length",
          "value": "192"
        },
        {
          "key": "Connection",
          "value": "keep-alive"
        },
        {
          "key": "Referrer-Policy",
          "value": "strict-origin"
        },
        {
          "key": "X-Content-Type-Options",
          "value": "nosniff"
        },
        {
          "key": "X-XSS-Protection",
          "value": "1; mode=block"
        },
        {
          "key": "Pragma",
          "value": "no-cache"
        },
        {
          "key": "Cache-Control",
          "value": "no-cache"
        },
        {
          "key": "Expires",
          "value": "Thu, 01 Jan 1970 00:00:00 GMT"
        },
        {
          "key": "X-Frame-Options",
          "value": "SAMEORIGIN"
        },
        {
          "key": "X-Download-Options",
          "value": "noopen"
        }
      ],
      "cookie": [
      ],
      "body": "{\n    \"code\": \"INVALID_REQUEST\",\n    \"details\": {},\n    \"message\": \"unable to process your request. please verify whether you have entered proper method name, parameter and parameter values.\",\n    \"status\": \"error\"\n}"
    }
  ]
}