Skip to content

Delete Asset

DELETE
/api/v1/assets/{id}
curl --request DELETE \
--url https://indepai.app/api/v1/assets/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \
--header 'Authorization: Bearer <token>'

Delete an asset from the portfolio

id
required

Asset ID (UUID)

string format: uuid

Asset deleted

Media typeapplication/json
object
success
required
boolean
data
required
object
deleted
required
boolean
id
required

ID of the deleted asset

string
meta
required
object
timestamp
required

Timestamp in ISO 8601 format

string format: date-time
recalculated
required
boolean
Example
{
"success": true,
"data": {
"deleted": true
},
"meta": {
"timestamp": "2024-01-15T10:30:00Z"
}
}

Unauthorized

Media typeapplication/json
object
success
required

Always false for error responses

boolean
error
required

Error type

string
code

Machine-readable error code

string
details

Detailed validation errors

Array<object>
object
path
required

Path to the invalid field

string
message
required

Error message

string
Example
{
"success": false,
"error": "Validation error",
"code": "VALIDATION_ERROR",
"details": [
{
"path": "currentAge",
"message": "Must be between 18 and 100"
}
]
}

Asset not found

Media typeapplication/json
object
success
required

Always false for error responses

boolean
error
required

Error type

string
code

Machine-readable error code

string
details

Detailed validation errors

Array<object>
object
path
required

Path to the invalid field

string
message
required

Error message

string
Example
{
"success": false,
"error": "Validation error",
"code": "VALIDATION_ERROR",
"details": [
{
"path": "currentAge",
"message": "Must be between 18 and 100"
}
]
}