API REFERENCE
ZEPETO World Open API
Deleting Specific Ranking Data Within the Leaderboard
2min
you can use the openapi to delete specific ranking data within the leaderboard to use the openapi, please first managing open api docid\ wlbkg6ocli2huaffg3bvf from zepeto studio afterwards, creating a jwt authentication token for use with the open api docid\ l87uuxz3d9tk7231lyxni according to the openapi format and call the delete world ranking docid\ nnadtjtfv4gdj1cv2 wmf please enter the utc timestamp value at the same time value as when the jwt authentication token is issued example code python import time import jwt import uuid import hashlib import base64 import requests as requests import simplejson as json access key = 'your access key' secret key = 'your secret key' uri = '/operation/v1/rank/delete' hash = hashlib sha256() hash update(uri encode()) reqtimestamp = int(time time()) json param = { "worldid" "", "leaderboardid" "", "member" "", #user id "reqtimestamp" reqtimestamp \# "prevranking" false, # nullable } param hash = hashlib sha256() param hash update(json dumps(json param, ensure ascii=false, encoding="surrogatepass") encode()) jwt payload = { 'access key' access key, 'nonce' str(uuid uuid4()), 'uri hash' base64 b64encode(hash digest()) decode('utf8'), 'body hash' base64 b64encode(param hash digest()) decode('utf8'), } jwt token = jwt encode(jwt payload, secret key) authorization = 'bearer {}' format(jwt token) print(reqtimestamp) print(authorization) url = "https //openapi zepeto zone" + uri # openapi url headers = { "accept" "application/json", "content type" "application/json", "authorization" authorization } response = requests post(url, json=json param, headers=headers) print(response status code) print(response text)