Tally Platform API
member-comment
Create a member comment
1 min
code examples curl location globoff 'https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/comments?async=boolean' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ data '{ "status" "c", "comment" "adding member adjustment to account 12345x" }'require "uri" require "json" require "net/http" url = uri("https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/comments?async=boolean") https = net http new(url host, url port) https use ssl = true request = net http post new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" request body = json dump({ "status" "c", "comment" "adding member adjustment to account 12345x" }) response = https request(request) puts response read body import requests import json url = "https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/comments?async=boolean" payload = json dumps({ "status" "c", "comment" "adding member adjustment to account 12345x" }) headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("post", url, headers=headers, data=payload) print(response text) okhttpclient client = new okhttpclient() newbuilder() build(); mediatype mediatype = mediatype parse("application/json"); requestbody body = requestbody create(mediatype, "{\n \\"status\\" \\"c\\",\n \\"comment\\" \\"adding member adjustment to account 12345x\\"\n}"); request request = new request builder() url("https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/comments?async=boolean") method("post", body) addheader("accept", "application/json") addheader("content type", "application/json") build(); response response = client newcall(request) execute(); responses // success { "membercommentid" "", "membercommenttype" "", "memberidentifier" "", "accountnumber" "", "companyname" "", "membername" "", "membertype" "", "commentname" "", "title" "", "status" "", "followupflag" false, "followupdate" "", "assignedto" "", "createdatetime" "", "updatedatetime" "", "exceedssla" false, "locked" false, "lockerid" "", "lockername" "", "lockerrank" "", "closeddate" "", "reason" "", "subreason" "", "correspondencetosendtomemberid" "", "externalreference" "", "comments" \[ { "createdate" "", "createdby" "", "comment" "", "assignedtouser" "", "assignedtorole" "", "reassigned" false, "assignedfromuser" "", "assignedfromrole" "" } ], "customdata" { "ace01" "", "ace01description" "", "ace02" "", "ace02description" "", "ace03" "", "ace03description" "", "ace04" "", "ace04description" "", "ace05" "", "ace05description" "", "ace06" "", "ace06description" "", "ace07" "", "ace07description" "", "ace08" "", "ace08description" "", "ace09" "", "ace09description" "", "ace10" "", "ace10description" "", "ace11" "", "ace11description" "", "ace12" "", "ace12description" "", "ace13" "", "ace13description" "", "ace14" "", "ace14description" "", "ace15" "", "ace15description" "" }, "externalprogram" "", "externalprogramstatus" "", "sourceapplicationip" "", "commentclosereason" "", "membercommentimages" \[ { "imageid" "", "status" "", "tag" "", "format" "" } ], "closeddatetime" "", "createdby" "", "updatedby" "", "firstcomment" "", "statusdescription" "", "reasondescription" "", "subreasondescription" "" }// accepted { "asynctaskid" "", "tasktypecode" "platformapi", "taskcode" "enrollmember", "requestdate" "", "requestdata" {}, "statuscode" "", "responsedate" "", "responsedata" {}, "filename" "", "linenumber" 0, "filedata" "" }// bad request { "errors" \[ { "code" "", "fieldname" "", "message" "", "messageparameters" \[ {} ] } ] }// unauthorized // internal error