准备撤销一笔链下订单的签名
curl --request POST \
--url https://api.renaiss.xyz/v2/marketplace/orders/cancel/prepare \
--header 'Content-Type: application/json' \
--header 'x-builder-api-key: <api-key>' \
--data '
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>"
}
'const options = {
method: 'POST',
headers: {'x-builder-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({orderId: '3c90c3cc-0d44-4b50-8888-8dd25736052a', walletAddress: '<string>'})
};
fetch('https://api.renaiss.xyz/v2/marketplace/orders/cancel/prepare', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.renaiss.xyz/v2/marketplace/orders/cancel/prepare"
payload = {
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>"
}
headers = {
"x-builder-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"payload": {
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>",
"deadline": "<string>"
},
"typedData": {
"domain": {},
"types": {},
"primaryType": "<string>",
"message": {}
}
}Malformed JSON in request body{
"error": "Required authentication credential is missing",
"code": "API_AUTH_MISSING_CREDENTIAL"
}{
"error": "Credential is not allowed by this policy",
"code": "API_AUTH_CREDENTIAL_NOT_ALLOWED"
}{
"error": "Active order not found for this wallet",
"code": "ORDER_NOT_FOUND"
}Payload Too Large{
"error": "Authentication rate limit exceeded",
"code": "API_AUTH_RATE_LIMITED"
}Internal Server Error订单
准备撤单
获取撤单授权,让订单持有人签名后从市场订单簿移除指定订单。
POST
/
v2
/
marketplace
/
orders
/
cancel
/
prepare
准备撤销一笔链下订单的签名
curl --request POST \
--url https://api.renaiss.xyz/v2/marketplace/orders/cancel/prepare \
--header 'Content-Type: application/json' \
--header 'x-builder-api-key: <api-key>' \
--data '
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>"
}
'const options = {
method: 'POST',
headers: {'x-builder-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({orderId: '3c90c3cc-0d44-4b50-8888-8dd25736052a', walletAddress: '<string>'})
};
fetch('https://api.renaiss.xyz/v2/marketplace/orders/cancel/prepare', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.renaiss.xyz/v2/marketplace/orders/cancel/prepare"
payload = {
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>"
}
headers = {
"x-builder-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"payload": {
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>",
"deadline": "<string>"
},
"typedData": {
"domain": {},
"types": {},
"primaryType": "<string>",
"message": {}
}
}Malformed JSON in request body{
"error": "Required authentication credential is missing",
"code": "API_AUTH_MISSING_CREDENTIAL"
}{
"error": "Credential is not allowed by this policy",
"code": "API_AUTH_CREDENTIAL_NOT_ALLOWED"
}{
"error": "Active order not found for this wallet",
"code": "ORDER_NOT_FOUND"
}Payload Too Large{
"error": "Authentication rate limit exceeded",
"code": "API_AUTH_RATE_LIMITED"
}Internal Server Error请求
需要开发者密钥
响应
错误码
在下表中查找接口返回的 HTTP 状态码和响应原文。有关各接口通用的处理建议,请参阅错误码含义与处理方式。
| HTTP | 错误码 | 文本字段 | 响应文本与处理方式 |
|---|---|---|---|
400 | WRONG_REQUEST_PARAMS | error | Invalid marketplace request: Expected object, received arrayInvalid marketplace request: orderId: Required字段缺失、格式错误或过期时间超出允许范围。根据错误消息指出的字段修正后重新提交。 |
400 | 无错误码 | text/plain | Malformed JSON in request body |
401 | API_AUTH_INVALID_CREDENTIAL | error | Invalid authentication credential开发者密钥格式错误、未知、已过期或已撤销。请核对并更换密钥。 |
401 | API_AUTH_MISSING_CREDENTIAL | error | Required authentication credential is missing请在 x-builder-api-key 请求头中提供开发者密钥。 |
403 | API_AUTH_CREDENTIAL_NOT_ALLOWED | error | Credential is not allowed by this policy此路由只接受开发者密钥。移除 Authorization 请求头及其他凭据,再重新发送。 |
403 | GACHA_V3_BUILDER_NOT_ACCEPTED_ON_PUBLIC_API | error | This builder checks out on its own surface, not on the public API此密钥无法用于当前 API。请联系 Renaiss,无需重试。 |
404 | ORDER_NOT_FOUND | error | Active order not found for this wallet该钱包没有此 ID 的有效订单。请刷新订单列表,不要重发原请求。 |
413 | 无错误码 | text/plain | Payload Too Large |
429 | API_AUTH_RATE_LIMITED | error | Authentication rate limit exceeded已达到密钥的请求频率上限。稍候再以较低频率重试。 |
500 | API_AUTH_ERROR | error | Internal server error |
500 | FUNCTION_ERROR | error | Internal server error |
500 | 无错误码 | text/plain | Internal Server Error |