Update asset
API Configuration
After saving, the Try It panel below sends real requests with this key.
Base: api.xrtoken.ai
Update the name of an asset. Only assets owned by the current user can be modified.
Authorization
BearerAuth AuthorizationBearer <token>
API key authentication (OpenAI format). Pass in the Authorization header:
Authorization: Bearer tr-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
In: header
Path Parameters
assetId*string
Asset ID
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
name?string
New asset name
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X put "https://api.xrtoken.ai/v1/assets/string" \ -H "Content-Type: application/json" \ -d '{}'{
"Id": "string",
"Name": "string",
"AssetType": "Image",
"Status": "Active",
"GroupId": "string",
"URL": "string",
"CreateTime": "string",
"UpdateTime": "string",
"Error": {
"Code": "string",
"Message": "string"
}
}{
"error": "model field is required",
"type": "invalid_request_error"
}{
"error": "invalid or missing API key",
"type": "auth_error"
}{
"error": "string",
"type": "invalid_request_error"
}{
"error": "rate limit exceeded",
"type": "rate_limit_error"
}