---
title: Deleting Specific Ranking Data Within the Leaderboard
slug: world-sdk-guide/deleting-specific-ranking-data-within-the-leaderboard
docTags: 
createdAt: 2024-09-02T08:34:13.134Z
---

You can use the OpenAPI to delete specific ranking data within the leaderboard.

To use the OpenAPI, please first [obtain an OpenAPI Key](docId\:wlBKg6oCli2hUAfFG3BvF) from ZEPETO Studio.

Afterwards, [obtain a JWT authentication token](docId\:l87UUxZ3D9tK7231LYxni) according to the OpenAPI format and call the [Delete Rank OpenAPI](docId\:nNADtjTFv4gDj1cV2_WMf) .

:::hint{type="danger"}
- Please enter the UTC Timestamp value at the same time value as when the JWT authentication token is issued.
:::



## Example Code - Python

```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)
```

