Tally Platform API
member-tier
Update Member Tier
1 min
code examples curl location globoff 'https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/tiers?migrate=boolean\&async=boolean' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ data '{ "tiercode" "b", "tieryear" 2027, "comments" "tier manually updated to platinum because of xyz reason ", "forcetierchange" true }'require "uri" require "json" require "net/http" url = uri("https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/tiers?migrate=boolean\&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({ "tiercode" "b", "tieryear" 2027, "comments" "tier manually updated to platinum because of xyz reason ", "forcetierchange" true }) response = https request(request) puts response read body import requests import json url = "https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/tiers?migrate=boolean\&async=boolean" payload = json dumps({ "tiercode" "b", "tieryear" 2027, "comments" "tier manually updated to platinum because of xyz reason ", "forcetierchange" true }) 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 \\"tiercode\\" \\"b\\",\n \\"tieryear\\" 2027,\n \\"comments\\" \\"tier manually updated to platinum because of xyz reason \\",\n \\"forcetierchange\\" true\n}"); request request = new request builder() url("https //api b preview\ loyaltyservices io/api/v3/members/{memberidentifier}/tiers?migrate=boolean\&async=boolean") method("post", body) addheader("accept", "application/json") addheader("content type", "application/json") build(); response response = client newcall(request) execute(); responses // success { "tiercode" "b", "description" "base", "rank" 10, "typecode" "earned", "startdate" "2020 01 01", "enddate" "2020 12 31", "grandfathered" false, "earned" true, "lifetime" false, "rollovernights" 10, "assignmentreason" "bonus", "assignmentreasonobjectexternalreference" "", "assignmentreasonobjectdescription" "adjustment bonus 1000 points", "createdby" "" }// accepted { "asynctaskid" "", "tasktypecode" "platformapi", "taskcode" "enrollmember", "requestdate" "", "requestdata" {}, "statuscode" "", "responsedate" "", "responsedata" {}, "filename" "", "linenumber" 0, "filedata" "" }// bad request { "errors" \[ { "code" "", "fieldname" "", "message" "", "messageparameters" \[ {} ] } ] }// unauthorized // forbidden // internal error