Note creation through API

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tibenian
    Junior Member
    • Apr 2018
    • 12

    Note creation through API

    Hello!

    We are facing strange behaviour:
    Note is successfully created however it's missing "parent_type" and "parent_id" in database.

    Simple and lightning fast image sharing. Upload clipboard images with Copy & Paste and image files with Drag & Drop


    When we create a Note manually (comment to Case) these fields are properly set.

    Can you kindly advice how do we add Note to Case properly using API?

    CallAPI(
    "POST",
    $__espoAPIURL."Note",
    json_encode(
    array(
    "post" => $messageText,
    "data" => "{}",
    "type" => "Post",
    "parent_type" => "Case",
    "parent_id" => $caseId,
    "created_by_id" => 1,
    )
    )
    );
  • tibenian
    Junior Member
    • Apr 2018
    • 12

    #2
    Solved by:
    "parent_type" => "Case",
    "parent_id" => $caseId,

    changed to

    "parentType" => "Case",
    "parentId" => $caseId,

    Comment

    Working...