Chilkat Online Tools

ERROR!

------------------- GenerateCode ----------------------
---- begin chilkat script ----
// This example assumes the Chilkat API to have been previously unlocked.
// See {{-global_unlock:::Global Unlock Sample-}} for sample code.

new Http http;
ckbool success;

call http.SetRequestHeader("Authorization","API-Key {{api_key}}");

new StringBuilder sbResponseBody;
success = http.QuickGetSb("https://api.pandadoc.com/public/v1/logs",sbResponseBody);
if (success == ckfalse) {
    println http.LastErrorText;
    return;
}

println "Response status code = ",http.LastStatus;
println sbResponseBody.GetAsString();

---- end chilkat script ----

Mono / PandaDoc API Reference / List API Logs

Back to Collection Items

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

Chilkat.Http http = new Chilkat.Http();
bool success;

ERROR: Non-existent Chilkat method:  Http.SetRequestHeader
ERROR: Non-existent Chilkat method:  Http.SetRequestHeader

Chilkat.StringBuilder sbResponseBody = new Chilkat.StringBuilder();
ERROR: Entry not found: Http.QuickGetSb
ERROR: CodeGen:
  emitNewObject:
    atgType: Http
    varName: http
  --emitNewObject
  emitNewObject:
    atgType: StringBuilder
    varName: sbResponseBody
  --emitNewObject
  failedToLoadClass: Http
  failedToLoadClass: Http
  getApiProperty:
    Class not found
    className: Http
  --getApiProperty
--CodeGen

ERROR: Non-existent Chilkat method:  Http.QuickGetSb
Assignment type mismatch.  ExpressionType=ERROR:, atgType=ckbool

if (success == false) {
ERROR: Entry not found: Http.LastErrorText
ERROR: CodeGen:
  emitNewObject:
    atgType: Http
    varName: http
  --emitNewObject
  emitNewObject:
    atgType: StringBuilder
    varName: sbResponseBody
  --emitNewObject
  failedToLoadClass: Http
  failedToLoadClass: Http
  getApiProperty:
    Class not found
    className: Http
  --getApiProperty
  failedToLoadClass: Http
  failedToLoadClass: Http
  getApiProperty:
    Class not found
    className: Http
  --getApiProperty
--CodeGen

    Debug.WriteLine(Convert.ToString(ERROR: Property not found: Http.LastErrorText
));
    return;
}

ERROR: Entry not found: Http.LastStatus
ERROR: CodeGen:
  emitNewObject:
    atgType: Http
    varName: http
  --emitNewObject
  emitNewObject:
    atgType: StringBuilder
    varName: sbResponseBody
  --emitNewObject
  failedToLoadClass: Http
  failedToLoadClass: Http
  getApiProperty:
    Class not found
    className: Http
  --getApiProperty
  failedToLoadClass: Http
  failedToLoadClass: Http
  getApiProperty:
    Class not found
    className: Http
  --getApiProperty
  failedToLoadClass: Http
  getApiProperty:
    Class not found
    className: Http
  --getApiProperty
  failedToLoadClass: Http
  failedToLoadClass: Http
  getApiProperty:
    Class not found
    className: Http
  --getApiProperty
--CodeGen

Debug.WriteLine("Response status code = " + Convert.ToString(ERROR: Property not found: Http.LastStatus
));
Debug.WriteLine(sbResponseBody.GetAsString());

Curl Command

curl -X GET
	-H "Authorization: Bearer {{access_token}}"
	-H "Authorization: API-Key {{api_key}}"
https://api.pandadoc.com/public/v1/logs

Postman Collection Item JSON

{
  "name": "List API Logs",
  "request": {
    "method": "GET",
    "header": [
      {
        "key": "Authorization",
        "value": "Bearer {{access_token}}",
        "type": "text",
        "disabled": true
      },
      {
        "key": "Authorization",
        "value": "API-Key {{api_key}}",
        "type": "text"
      }
    ],
    "url": {
      "raw": "https://api.pandadoc.com/public/v1/logs",
      "protocol": "https",
      "host": [
        "api",
        "pandadoc",
        "com"
      ],
      "path": [
        "public",
        "v1",
        "logs"
      ]
    }
  },
  "response": [
  ]
}